瀏覽代碼

* don't typecast the localst of the main program to a localsymtable

git-svn-id: trunk@6188 -
Jonas Maebe 18 年之前
父節點
當前提交
fae803869f
共有 1 個文件被更改,包括 2 次插入0 次删除
  1. 2 0
      compiler/psub.pas

+ 2 - 0
compiler/psub.pas

@@ -784,6 +784,8 @@ implementation
             }
             if ((po_assembler in procdef.procoptions) and
                 (m_delphi in current_settings.modeswitches) and
+                { localst at main_program_level is a staticsymtable }
+                (procdef.localst.symtablelevel<>main_program_level) and
                 (tabstractlocalsymtable(procdef.localst).count_locals = 0)) or
                ((cs_opt_stackframe in current_settings.optimizerswitches) and
                 not(cs_generate_stackframes in current_settings.localswitches) and