浏览代码

Add string constant values to stringconstn nodes in parse tree output

Charles Averill 1 年之前
父节点
当前提交
cd9ed54d35
共有 1 个文件被更改,包括 7 次插入0 次删除
  1. 7 0
      compiler/ncon.pas

+ 7 - 0
compiler/ncon.pas

@@ -144,6 +144,7 @@ interface
           { returns whether this platform uses the nil pointer to represent
             empty dynamic strings }
           class function emptydynstrnil: boolean; virtual;
+          procedure printnodedata(var T: Text); override;
 {$ifdef DEBUG_NODE_XML}
           procedure XMLPrintNodeData(var T: Text); override;
 {$endif DEBUG_NODE_XML}
@@ -1213,6 +1214,12 @@ implementation
         result:=true;
       end;
 
+      procedure tstringconstnode.printnodedata(var T: Text);
+      begin
+        inherited printnodedata(t);
+        writeln(t,printnodeindention,'value = "',value_str,'"');
+      end;
+
 {$ifdef DEBUG_NODE_XML}
     procedure TStringConstNode.XMLPrintNodeData(var T: Text);
       var