aboutsummaryrefslogtreecommitdiff
path: root/src/check_stmt.cpp
diff options
context:
space:
mode:
authorgingerBill <bill@gingerbill.org>2021-02-23 13:10:23 +0000
committergingerBill <bill@gingerbill.org>2021-02-23 13:10:23 +0000
commit28ed310f317d48835f089b6a6102259696b0f84c (patch)
tree80ce57ddd4d997d75458c108ce858fac24f10349 /src/check_stmt.cpp
parenta652c24ac3c8e592d413b3d3123e750fcaf314db (diff)
Remove `"pure"` and `"pure_none"` calling conventions
Diffstat (limited to 'src/check_stmt.cpp')
-rw-r--r--src/check_stmt.cpp11
1 files changed, 0 insertions, 11 deletions
diff --git a/src/check_stmt.cpp b/src/check_stmt.cpp
index 5e403134e..4c805481e 100644
--- a/src/check_stmt.cpp
+++ b/src/check_stmt.cpp
@@ -1403,11 +1403,6 @@ void check_stmt_internal(CheckerContext *ctx, Ast *node, u32 flags) {
case_end;
case_ast_node(as, AssignStmt, node);
- if (ctx->curr_proc_calling_convention == ProcCC_Pure) {
- error(node, "Assignment statements are not allowed within a \"pure\" procedure");
- // Continue
- }
-
switch (as->op.kind) {
case Token_Eq: {
// a, b, c = 1, 2, 3; // Multisided
@@ -2142,12 +2137,6 @@ void check_stmt_internal(CheckerContext *ctx, Ast *node, u32 flags) {
check_init_variables(ctx, entities, entity_count, vd->values, str_lit("variable declaration"));
check_arity_match(ctx, vd, false);
- if (ctx->curr_proc_calling_convention == ProcCC_Pure) {
- if (vd->values.count == 0) {
- error(node, "Variable declarations without assignment are not allowed within \"pure\" procedures");
- }
- }
-
for (isize i = 0; i < entity_count; i++) {
Entity *e = entities[i];