aboutsummaryrefslogtreecommitdiff
path: root/src/ssa.cpp
diff options
context:
space:
mode:
authorGinger Bill <bill@gingerbill.org>2017-06-28 23:47:06 +0100
committerGinger Bill <bill@gingerbill.org>2017-06-28 23:47:06 +0100
commit94afcec7577f24d7f027f72765928e6dc5738234 (patch)
tree3928353bd29c2d6b9f501243edf1fed52bf320c9 /src/ssa.cpp
parent4f28e9e1fbc1d2a61c3996b2813214e2344e7e6a (diff)
:: style procedure declarations; remove old parsing code
Diffstat (limited to 'src/ssa.cpp')
-rw-r--r--src/ssa.cpp16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/ssa.cpp b/src/ssa.cpp
index 6168b025f..eff892fb1 100644
--- a/src/ssa.cpp
+++ b/src/ssa.cpp
@@ -2377,12 +2377,12 @@ void ssa_build_proc(ssaModule *m, ssaProc *p) {
p->module = m;
m->proc = p;
- if (p->decl_info->proc_decl == NULL ||
- p->decl_info->proc_decl->kind != AstNode_ProcDecl) {
+ if (p->decl_info->proc_lit == NULL ||
+ p->decl_info->proc_lit->kind != AstNode_ProcLit) {
return;
}
- ast_node(pl, ProcLit, p->decl_info->proc_decl);
+ ast_node(pl, ProcLit, p->decl_info->proc_lit);
if (pl->body == NULL) {
return;
}
@@ -2495,14 +2495,14 @@ bool ssa_generate(Parser *parser, CheckerInfo *info) {
} break;
case Entity_Procedure: {
- ast_node(pd, ProcDecl, decl->proc_decl);
+ ast_node(pl, ProcLit, decl->proc_lit);
String original_name = name;
- AstNode *body = pd->body;
+ AstNode *body = pl->body;
if (e->Procedure.is_foreign) {
name = e->token.string; // NOTE(bill): Don't use the mangled name
}
- if (pd->link_name.len > 0) {
- name = pd->link_name;
+ if (pl->link_name.len > 0) {
+ name = pl->link_name;
}
if (e == entry_point) {
@@ -2511,7 +2511,7 @@ bool ssa_generate(Parser *parser, CheckerInfo *info) {
}
// ssaValue *p = ssa_make_value_procedure(a, m, e, e->type, decl->type_expr, body, name);
- // p->Proc.tags = pd->tags;
+ // p->Proc.tags = pl->tags;
// ssa_module_add_value(m, e, p);
// HashKey hash_name = hash_string(name);