aboutsummaryrefslogtreecommitdiffstats
path: root/libsolidity/ASTPrinter.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'libsolidity/ASTPrinter.cpp')
-rw-r--r--libsolidity/ASTPrinter.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/libsolidity/ASTPrinter.cpp b/libsolidity/ASTPrinter.cpp
index 5762051d..cebf6b8b 100644
--- a/libsolidity/ASTPrinter.cpp
+++ b/libsolidity/ASTPrinter.cpp
@@ -105,6 +105,11 @@ bool ASTPrinter::visit(FunctionDefinition const& _node)
bool ASTPrinter::visit(VariableDeclaration const& _node)
{
writeLine("VariableDeclaration \"" + _node.name() + "\"");
+ *m_ostream << indentation() << (
+ _node.annotation().type ?
+ string(" Type: ") + _node.annotation().type->toString() :
+ string(" Type unknown.")
+ ) << "\n";
printSourcePart(_node);
return goDeeper();
}