aboutsummaryrefslogtreecommitdiff
path: root/src/checker.cpp
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2019-03-15 16:39:49 +0000
committergingerBill <bill@gingerbill.org>2019-03-15 16:39:49 +0000
commit885c5dc8b75dd88d376627195a5468d12264bcc5 (patch)
treee7a3c00409420fb8fca1728296ce6e9320923150 /src/checker.cpp
parent394baa9ddd0e2e0b6c5d69232a52785aea73ed22 (diff)
Fix issue with `deferred_*` attributes
Diffstat (limited to 'src/checker.cpp')
-rw-r--r--src/checker.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/checker.cpp b/src/checker.cpp
index 0253bc86b..8e8afc621 100644
--- a/src/checker.cpp
+++ b/src/checker.cpp
@@ -2005,7 +2005,7 @@ DECL_ATTRIBUTE_PROC(proc_decl_attribute) {
if (value != nullptr) {
Operand o = {};
check_expr(c, &o, value);
- Entity *e = entity_of_ident(o.expr);
+ Entity *e = entity_of_node(o.expr);
if (e != nullptr && e->kind == Entity_Procedure) {
warning(elem, "'%.*s' is deprecated, please use one of the following instead: 'deferred_none', 'deferred_in', 'deferred_out'", LIT(name));
if (ac->deferred_procedure.entity != nullptr) {
@@ -2022,7 +2022,7 @@ DECL_ATTRIBUTE_PROC(proc_decl_attribute) {
if (value != nullptr) {
Operand o = {};
check_expr(c, &o, value);
- Entity *e = entity_of_ident(o.expr);
+ Entity *e = entity_of_node(o.expr);
if (e != nullptr && e->kind == Entity_Procedure) {
ac->deferred_procedure.kind = DeferredProcedure_none;
ac->deferred_procedure.entity = e;
@@ -2035,7 +2035,7 @@ DECL_ATTRIBUTE_PROC(proc_decl_attribute) {
if (value != nullptr) {
Operand o = {};
check_expr(c, &o, value);
- Entity *e = entity_of_ident(o.expr);
+ Entity *e = entity_of_node(o.expr);
if (e != nullptr && e->kind == Entity_Procedure) {
if (ac->deferred_procedure.entity != nullptr) {
error(elem, "Previous usage of a 'deferred_*' attribute");
@@ -2051,7 +2051,7 @@ DECL_ATTRIBUTE_PROC(proc_decl_attribute) {
if (value != nullptr) {
Operand o = {};
check_expr(c, &o, value);
- Entity *e = entity_of_ident(o.expr);
+ Entity *e = entity_of_node(o.expr);
if (e != nullptr && e->kind == Entity_Procedure) {
if (ac->deferred_procedure.entity != nullptr) {
error(elem, "Previous usage of a 'deferred_*' attribute");