aboutsummaryrefslogtreecommitdiff
path: root/backendC/CleanCompilerSources/instructions.c
diff options
context:
space:
mode:
authorjohnvg2003-01-07 12:08:08 +0000
committerjohnvg2003-01-07 12:08:08 +0000
commitd7e708706dd5663b3abd7b1192590076e16023b3 (patch)
tree7c86bc4819e4daa6c2710316ce139f32d872f887 /backendC/CleanCompilerSources/instructions.c
parentprevent compiler crash if an array pattern is not a variable (diff)
export labels if ExportLocalLabels==True for lazy record selectors
and fix exported label name for unboxed lists of records git-svn-id: https://svn.cs.ru.nl/repos/clean-compiler/trunk@1305 1f8540f1-abd5-4d5b-9d24-4c5ce8603e2d
Diffstat (limited to 'backendC/CleanCompilerSources/instructions.c')
-rw-r--r--backendC/CleanCompilerSources/instructions.c20
1 files changed, 10 insertions, 10 deletions
diff --git a/backendC/CleanCompilerSources/instructions.c b/backendC/CleanCompilerSources/instructions.c
index 5857168..ed7ed5f 100644
--- a/backendC/CleanCompilerSources/instructions.c
+++ b/backendC/CleanCompilerSources/instructions.c
@@ -3182,22 +3182,22 @@ void GenFieldSelectorDescriptor (SymbDef sdef,int has_gc_apply_entry)
CurrentModule,record_name,name,
arity,record_name,name);
} else if ((sdef->sdef_mark & SDEF_USED_LAZILY_MASK) || has_gc_apply_entry){
- char *record_name;
-
- record_name = sdef->sdef_type->type_lhs->ft_symbol->symb_def->sdef_ident->ident_name;
-
- if (DoDebug)
+ if (ExportLocalLabels)
+ FPrintF (OutFile, "e_%s_" D_PREFIX "%s.%s ",CurrentModule,record_name,name);
+ else if (DoDebug)
FPrintF (OutFile, D_PREFIX "%s.%s ",record_name,name);
else
FPrintF (OutFile, LOCAL_D_PREFIX "%u ", sdef->sdef_number);
-
+
if (sdef->sdef_mark & SDEF_USED_LAZILY_MASK){
- if (DoDebug)
+ if (ExportLocalLabels)
+ FPrintF (OutFile, "e_%s_" N_PREFIX "%s.%s ",CurrentModule,record_name,name);
+ else if (DoDebug)
FPrintF (OutFile, N_PREFIX "%s.%s ",record_name,name);
else
FPrintF (OutFile, N_PREFIX "%u ",sdef->sdef_number);
} else
- FPrintF (OutFile, "%s ", hnf_lab.lab_name);
+ FPrintF (OutFile, "%s ",hnf_lab.lab_name);
if (has_gc_apply_entry){
if (DoDebug)
@@ -3205,9 +3205,9 @@ void GenFieldSelectorDescriptor (SymbDef sdef,int has_gc_apply_entry)
else
FPrintF (OutFile, "%s%u ",l_pref,sdef->sdef_number);
} else
- FPrintF (OutFile, "%s ", hnf_lab.lab_name);
+ FPrintF (OutFile, "%s ",hnf_lab.lab_name);
- FPrintF (OutFile, "%d 0 \"%s.%s\"", arity,record_name,name);
+ FPrintF (OutFile, "%d 0 \"%s.%s\"",arity,record_name,name);
} else if (DoDebug){
FPrintF (OutFile, D_PREFIX "%s %s %s %d 0 \"%s.%s\"", name, hnf_lab.lab_name,
hnf_lab.lab_name,arity,record_name,name);