aboutsummaryrefslogtreecommitdiff
path: root/src/check_decl.cpp
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2021-04-14 17:15:28 +0100
committergingerBill <bill@gingerbill.org>2021-04-14 17:15:28 +0100
commit9adec628c1c6b3d24f7a8642bbf5c0c84586d161 (patch)
tree7f4785bcb7615922f71fc657bab029218f9be996 /src/check_decl.cpp
parent3e54cddf641e7d8ca79b0cbb12e1595727a9e888 (diff)
Add `@(cold)` attribute to procedure declarations
Diffstat (limited to 'src/check_decl.cpp')
-rw-r--r--src/check_decl.cpp4
1 files changed, 4 insertions, 0 deletions
diff --git a/src/check_decl.cpp b/src/check_decl.cpp
index 5e52597b9..51c0b6ee5 100644
--- a/src/check_decl.cpp
+++ b/src/check_decl.cpp
@@ -690,6 +690,10 @@ void check_proc_decl(CheckerContext *ctx, Entity *e, DeclInfo *d) {
if (ac.test) {
e->flags |= EntityFlag_Test;
}
+ if (ac.set_cold) {
+ e->flags |= EntityFlag_Cold;
+ }
+
e->Procedure.is_export = ac.is_export;
e->deprecated_message = ac.deprecated_message;
ac.link_name = handle_link_name(ctx, e->token, ac.link_name, ac.link_prefix);