aboutsummaryrefslogtreecommitdiff
path: root/src/check_expr.cpp
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2018-03-03 11:16:48 +0000
committergingerBill <bill@gingerbill.org>2018-03-03 11:16:48 +0000
commit9274f29ca950a1f6b91506b56a291fce0b534f64 (patch)
treeb9a8b563fc23492e23921258b3f0150adb041082 /src/check_expr.cpp
parent08c87e57f878130fd10d8845115070e8bce2a588 (diff)
`deprecated` attribute for procedure declarations
Diffstat (limited to 'src/check_expr.cpp')
-rw-r--r--src/check_expr.cpp10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/check_expr.cpp b/src/check_expr.cpp
index 7d4c759d9..853760204 100644
--- a/src/check_expr.cpp
+++ b/src/check_expr.cpp
@@ -4943,6 +4943,16 @@ ExprKind check_call_expr(Checker *c, Operand *operand, AstNode *call) {
}
}
+ // NOTE(bill): Should this be here or on the `add_entity_use`?
+ // if (ce->proc != nullptr) {
+ // Entity *e = entity_of_node(&c->info, ce->proc);
+ // if (e != nullptr && e->kind == Entity_Procedure) {
+ // String msg = e->Procedure.deprecated_message;
+ // if (msg.len > 0) {
+ // warning(call, "%.*s is deprecated: %.*s", LIT(e->token.string), LIT(msg));
+ // }
+ // }
+ // }
CallArgumentData data = check_call_arguments(c, operand, proc_type, call);
Type *result_type = data.result_type;