diff options
author | Clifford Wolf <clifford@clifford.at> | 2014-03-05 19:56:31 +0100 |
---|---|---|
committer | Clifford Wolf <clifford@clifford.at> | 2014-03-05 19:56:31 +0100 |
commit | 09805ee9ec0408bdc68b914927899f02371efcb7 (patch) | |
tree | 12d36a023828adf7d07c5933d01cb62f38c00338 | |
parent | d6a01fe412419d32ec5b0d91f9076849d1ed489d (diff) | |
download | yosys-09805ee9ec0408bdc68b914927899f02371efcb7.tar.gz yosys-09805ee9ec0408bdc68b914927899f02371efcb7.tar.bz2 yosys-09805ee9ec0408bdc68b914927899f02371efcb7.zip |
Include id2ast pointers when dumping AST
-rw-r--r-- | frontends/ast/ast.cc | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/frontends/ast/ast.cc b/frontends/ast/ast.cc index d9ad6d8ef..f2f2d0e69 100644 --- a/frontends/ast/ast.cc +++ b/frontends/ast/ast.cc @@ -244,6 +244,12 @@ void AstNode::dumpAst(FILE *f, std::string indent) std::string type_name = type2str(type); fprintf(f, "%s%s <%s:%d>", indent.c_str(), type_name.c_str(), filename.c_str(), linenum); + + if (id2ast) + fprintf(f, " [%p -> %p]", this, id2ast); + else + fprintf(f, " [%p]", this); + if (!str.empty()) fprintf(f, " str='%s'", str.c_str()); if (!bits.empty()) { |