aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--libsolidity/CMakeLists.txt8
-rw-r--r--libsolidity/analysis/ConstantEvaluator.cpp (renamed from libsolidity/ConstantEvaluator.cpp)4
-rw-r--r--libsolidity/analysis/ConstantEvaluator.h (renamed from libsolidity/ConstantEvaluator.h)2
-rw-r--r--libsolidity/analysis/DeclarationContainer.cpp (renamed from libsolidity/DeclarationContainer.cpp)6
-rw-r--r--libsolidity/analysis/DeclarationContainer.h (renamed from libsolidity/DeclarationContainer.h)2
-rw-r--r--libsolidity/analysis/GlobalContext.cpp (renamed from libsolidity/GlobalContext.cpp)6
-rw-r--r--libsolidity/analysis/GlobalContext.h (renamed from libsolidity/GlobalContext.h)2
-rw-r--r--libsolidity/analysis/NameAndTypeResolver.cpp (renamed from libsolidity/NameAndTypeResolver.cpp)8
-rw-r--r--libsolidity/analysis/NameAndTypeResolver.h (renamed from libsolidity/NameAndTypeResolver.h)8
-rw-r--r--libsolidity/analysis/ReferencesResolver.cpp (renamed from libsolidity/ReferencesResolver.cpp)10
-rw-r--r--libsolidity/analysis/ReferencesResolver.h (renamed from libsolidity/ReferencesResolver.h)4
-rw-r--r--libsolidity/analysis/TypeChecker.cpp (renamed from libsolidity/TypeChecker.cpp)4
-rw-r--r--libsolidity/analysis/TypeChecker.h (renamed from libsolidity/TypeChecker.h)10
-rw-r--r--libsolidity/ast/AST.cpp (renamed from libsolidity/AST.cpp)10
-rw-r--r--libsolidity/ast/AST.h (renamed from libsolidity/AST.h)12
-rw-r--r--libsolidity/ast/ASTAnnotations.cpp (renamed from libsolidity/ASTAnnotations.cpp)2
-rw-r--r--libsolidity/ast/ASTAnnotations.h (renamed from libsolidity/ASTAnnotations.h)2
-rw-r--r--libsolidity/ast/ASTForward.h (renamed from libsolidity/ASTForward.h)0
-rw-r--r--libsolidity/ast/ASTJsonConverter.cpp (renamed from libsolidity/ASTJsonConverter.cpp)4
-rw-r--r--libsolidity/ast/ASTJsonConverter.h (renamed from libsolidity/ASTJsonConverter.h)8
-rw-r--r--libsolidity/ast/ASTPrinter.cpp (renamed from libsolidity/ASTPrinter.cpp)4
-rw-r--r--libsolidity/ast/ASTPrinter.h (renamed from libsolidity/ASTPrinter.h)4
-rw-r--r--libsolidity/ast/ASTUtils.cpp (renamed from libsolidity/ASTUtils.cpp)2
-rw-r--r--libsolidity/ast/ASTUtils.h (renamed from libsolidity/ASTUtils.h)2
-rw-r--r--libsolidity/ast/ASTVisitor.h (renamed from libsolidity/ASTVisitor.h)2
-rw-r--r--libsolidity/ast/AST_accept.h (renamed from libsolidity/AST_accept.h)4
-rw-r--r--libsolidity/ast/Types.cpp (renamed from libsolidity/Types.cpp)6
-rw-r--r--libsolidity/ast/Types.h (renamed from libsolidity/Types.h)6
-rw-r--r--libsolidity/codegen/ArrayUtils.cpp (renamed from libsolidity/ArrayUtils.cpp)12
-rw-r--r--libsolidity/codegen/ArrayUtils.h (renamed from libsolidity/ArrayUtils.h)0
-rw-r--r--libsolidity/codegen/Compiler.cpp (renamed from libsolidity/Compiler.cpp)8
-rw-r--r--libsolidity/codegen/Compiler.h (renamed from libsolidity/Compiler.h)4
-rw-r--r--libsolidity/codegen/CompilerContext.cpp (renamed from libsolidity/CompilerContext.cpp)8
-rw-r--r--libsolidity/codegen/CompilerContext.h (renamed from libsolidity/CompilerContext.h)6
-rw-r--r--libsolidity/codegen/CompilerUtils.cpp (renamed from libsolidity/CompilerUtils.cpp)8
-rw-r--r--libsolidity/codegen/CompilerUtils.h (renamed from libsolidity/CompilerUtils.h)4
-rw-r--r--libsolidity/codegen/ExpressionCompiler.cpp (renamed from libsolidity/ExpressionCompiler.cpp)10
-rw-r--r--libsolidity/codegen/ExpressionCompiler.h (renamed from libsolidity/ExpressionCompiler.h)6
-rw-r--r--libsolidity/codegen/LValue.cpp (renamed from libsolidity/LValue.cpp)8
-rw-r--r--libsolidity/codegen/LValue.h (renamed from libsolidity/LValue.h)2
-rw-r--r--libsolidity/interface/CompilerStack.cpp (renamed from libsolidity/CompilerStack.cpp)18
-rw-r--r--libsolidity/interface/CompilerStack.h (renamed from libsolidity/CompilerStack.h)2
-rw-r--r--libsolidity/interface/Exceptions.cpp (renamed from libsolidity/Exceptions.cpp)4
-rw-r--r--libsolidity/interface/Exceptions.h (renamed from libsolidity/Exceptions.h)0
-rw-r--r--libsolidity/interface/GasEstimator.cpp (renamed from libsolidity/GasEstimator.cpp)6
-rw-r--r--libsolidity/interface/GasEstimator.h (renamed from libsolidity/GasEstimator.h)4
-rw-r--r--libsolidity/interface/InterfaceHandler.cpp (renamed from libsolidity/InterfaceHandler.cpp)6
-rw-r--r--libsolidity/interface/InterfaceHandler.h (renamed from libsolidity/InterfaceHandler.h)0
-rw-r--r--libsolidity/interface/SourceReferenceFormatter.cpp (renamed from libsolidity/SourceReferenceFormatter.cpp)8
-rw-r--r--libsolidity/interface/SourceReferenceFormatter.h (renamed from libsolidity/SourceReferenceFormatter.h)0
-rw-r--r--libsolidity/interface/Utils.h (renamed from libsolidity/Utils.h)2
-rw-r--r--libsolidity/interface/Version.cpp (renamed from libsolidity/Version.cpp)4
-rw-r--r--libsolidity/interface/Version.h (renamed from libsolidity/Version.h)0
-rw-r--r--libsolidity/parsing/Parser.cpp (renamed from libsolidity/Parser.cpp)8
-rw-r--r--libsolidity/parsing/Parser.h (renamed from libsolidity/Parser.h)2
-rw-r--r--libsolidity/parsing/Scanner.cpp (renamed from libsolidity/Scanner.cpp)4
-rw-r--r--libsolidity/parsing/Scanner.h (renamed from libsolidity/Scanner.h)2
-rw-r--r--libsolidity/parsing/Token.cpp (renamed from libsolidity/Token.cpp)2
-rw-r--r--libsolidity/parsing/Token.h (renamed from libsolidity/Token.h)4
-rw-r--r--solc/CommandLineInterface.cpp20
-rw-r--r--solc/CommandLineInterface.h2
-rw-r--r--solc/jsonCompiler.cpp18
-rw-r--r--test/libsolidity/Assembly.cpp12
-rw-r--r--test/libsolidity/GasMeter.cpp6
-rw-r--r--test/libsolidity/SolidityABIJSON.cpp2
-rw-r--r--test/libsolidity/SolidityEndToEndTest.cpp2
-rw-r--r--test/libsolidity/SolidityExpressionCompiler.cpp14
-rw-r--r--test/libsolidity/SolidityInterface.cpp4
-rw-r--r--test/libsolidity/SolidityNameAndTypeResolution.cpp12
-rw-r--r--test/libsolidity/SolidityNatspecJSON.cpp4
-rw-r--r--test/libsolidity/SolidityParser.cpp6
-rw-r--r--test/libsolidity/SolidityScanner.cpp2
-rw-r--r--test/libsolidity/SolidityTypes.cpp2
-rw-r--r--test/libsolidity/solidityExecutionFramework.h4
74 files changed, 205 insertions, 199 deletions
diff --git a/libsolidity/CMakeLists.txt b/libsolidity/CMakeLists.txt
index 9fa35e3b..62e7bf93 100644
--- a/libsolidity/CMakeLists.txt
+++ b/libsolidity/CMakeLists.txt
@@ -1,10 +1,14 @@
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -DSTATICLIB")
-aux_source_directory(. SRC_LIST)
+aux_source_directory(analysis SRC_LIST)
+aux_source_directory(ast SRC_LIST)
+aux_source_directory(codegen SRC_LIST)
+aux_source_directory(interface SRC_LIST)
+aux_source_directory(parsing SRC_LIST)
set(EXECUTABLE solidity)
-file(GLOB HEADERS "*.h")
+file(GLOB HEADERS "*/*.h")
include_directories(BEFORE ..)
add_library(${EXECUTABLE} ${SRC_LIST} ${HEADERS})
diff --git a/libsolidity/ConstantEvaluator.cpp b/libsolidity/analysis/ConstantEvaluator.cpp
index 5936b3d4..6beb655e 100644
--- a/libsolidity/ConstantEvaluator.cpp
+++ b/libsolidity/analysis/ConstantEvaluator.cpp
@@ -20,8 +20,8 @@
* Evaluator for types of constant expressions.
*/
-#include <libsolidity/ConstantEvaluator.h>
-#include <libsolidity/AST.h>
+#include <libsolidity/analysis/ConstantEvaluator.h>
+#include <libsolidity/ast/AST.h>
using namespace std;
using namespace dev;
diff --git a/libsolidity/ConstantEvaluator.h b/libsolidity/analysis/ConstantEvaluator.h
index cf3d2094..f311efbf 100644
--- a/libsolidity/ConstantEvaluator.h
+++ b/libsolidity/analysis/ConstantEvaluator.h
@@ -22,7 +22,7 @@
#pragma once
-#include <libsolidity/ASTVisitor.h>
+#include <libsolidity/ast/ASTVisitor.h>
namespace dev
{
diff --git a/libsolidity/DeclarationContainer.cpp b/libsolidity/analysis/DeclarationContainer.cpp
index dbe9715d..7339ad5d 100644
--- a/libsolidity/DeclarationContainer.cpp
+++ b/libsolidity/analysis/DeclarationContainer.cpp
@@ -20,9 +20,9 @@
* Scope - object that holds declaration of names.
*/
-#include <libsolidity/DeclarationContainer.h>
-#include <libsolidity/AST.h>
-#include <libsolidity/Types.h>
+#include <libsolidity/analysis/DeclarationContainer.h>
+#include <libsolidity/ast/AST.h>
+#include <libsolidity/ast/Types.h>
using namespace std;
using namespace dev;
diff --git a/libsolidity/DeclarationContainer.h b/libsolidity/analysis/DeclarationContainer.h
index 3d6ed2cc..064724d1 100644
--- a/libsolidity/DeclarationContainer.h
+++ b/libsolidity/analysis/DeclarationContainer.h
@@ -26,7 +26,7 @@
#include <set>
#include <boost/noncopyable.hpp>
-#include <libsolidity/ASTForward.h>
+#include <libsolidity/ast/ASTForward.h>
namespace dev
{
diff --git a/libsolidity/GlobalContext.cpp b/libsolidity/analysis/GlobalContext.cpp
index a0f5396f..20f8272f 100644
--- a/libsolidity/GlobalContext.cpp
+++ b/libsolidity/analysis/GlobalContext.cpp
@@ -22,9 +22,9 @@
*/
#include <memory>
-#include <libsolidity/GlobalContext.h>
-#include <libsolidity/AST.h>
-#include <libsolidity/Types.h>
+#include <libsolidity/analysis/GlobalContext.h>
+#include <libsolidity/ast/AST.h>
+#include <libsolidity/ast/Types.h>
using namespace std;
diff --git a/libsolidity/GlobalContext.h b/libsolidity/analysis/GlobalContext.h
index 20ffecb4..482391d3 100644
--- a/libsolidity/GlobalContext.h
+++ b/libsolidity/analysis/GlobalContext.h
@@ -27,7 +27,7 @@
#include <map>
#include <memory>
#include <boost/noncopyable.hpp>
-#include <libsolidity/ASTForward.h>
+#include <libsolidity/ast/ASTForward.h>
namespace dev
{
diff --git a/libsolidity/NameAndTypeResolver.cpp b/libsolidity/analysis/NameAndTypeResolver.cpp
index edd0704d..ffd01137 100644
--- a/libsolidity/NameAndTypeResolver.cpp
+++ b/libsolidity/analysis/NameAndTypeResolver.cpp
@@ -20,10 +20,10 @@
* Parser part that determines the declarations corresponding to names and the types of expressions.
*/
-#include <libsolidity/NameAndTypeResolver.h>
-#include <libsolidity/AST.h>
-#include <libsolidity/TypeChecker.h>
-#include <libsolidity/Exceptions.h>
+#include <libsolidity/analysis/NameAndTypeResolver.h>
+#include <libsolidity/ast/AST.h>
+#include <libsolidity/analysis/TypeChecker.h>
+#include <libsolidity/interface/Exceptions.h>
using namespace std;
diff --git a/libsolidity/NameAndTypeResolver.h b/libsolidity/analysis/NameAndTypeResolver.h
index 7169f302..0d9b2477 100644
--- a/libsolidity/NameAndTypeResolver.h
+++ b/libsolidity/analysis/NameAndTypeResolver.h
@@ -25,10 +25,10 @@
#include <map>
#include <list>
#include <boost/noncopyable.hpp>
-#include <libsolidity/DeclarationContainer.h>
-#include <libsolidity/ReferencesResolver.h>
-#include <libsolidity/ASTVisitor.h>
-#include <libsolidity/ASTAnnotations.h>
+#include <libsolidity/analysis/DeclarationContainer.h>
+#include <libsolidity/analysis/ReferencesResolver.h>
+#include <libsolidity/ast/ASTVisitor.h>
+#include <libsolidity/ast/ASTAnnotations.h>
namespace dev
{
diff --git a/libsolidity/ReferencesResolver.cpp b/libsolidity/analysis/ReferencesResolver.cpp
index b1112dd9..fb7cdb3e 100644
--- a/libsolidity/ReferencesResolver.cpp
+++ b/libsolidity/analysis/ReferencesResolver.cpp
@@ -20,11 +20,11 @@
* Component that resolves type names to types and annotates the AST accordingly.
*/
-#include <libsolidity/ReferencesResolver.h>
-#include <libsolidity/AST.h>
-#include <libsolidity/NameAndTypeResolver.h>
-#include <libsolidity/Exceptions.h>
-#include <libsolidity/ConstantEvaluator.h>
+#include <libsolidity/analysis/ReferencesResolver.h>
+#include <libsolidity/ast/AST.h>
+#include <libsolidity/analysis/NameAndTypeResolver.h>
+#include <libsolidity/interface/Exceptions.h>
+#include <libsolidity/analysis/ConstantEvaluator.h>
using namespace std;
using namespace dev;
diff --git a/libsolidity/ReferencesResolver.h b/libsolidity/analysis/ReferencesResolver.h
index b8a55dc2..4276adaa 100644
--- a/libsolidity/ReferencesResolver.h
+++ b/libsolidity/analysis/ReferencesResolver.h
@@ -25,8 +25,8 @@
#include <map>
#include <list>
#include <boost/noncopyable.hpp>
-#include <libsolidity/ASTVisitor.h>
-#include <libsolidity/ASTAnnotations.h>
+#include <libsolidity/ast/ASTVisitor.h>
+#include <libsolidity/ast/ASTAnnotations.h>
namespace dev
{
diff --git a/libsolidity/TypeChecker.cpp b/libsolidity/analysis/TypeChecker.cpp
index 5ea5825d..6b12c57f 100644
--- a/libsolidity/TypeChecker.cpp
+++ b/libsolidity/analysis/TypeChecker.cpp
@@ -20,10 +20,10 @@
* Type analyzer and checker.
*/
-#include <libsolidity/TypeChecker.h>
+#include <libsolidity/analysis/TypeChecker.h>
#include <memory>
#include <boost/range/adaptor/reversed.hpp>
-#include <libsolidity/AST.h>
+#include <libsolidity/ast/AST.h>
using namespace std;
using namespace dev;
diff --git a/libsolidity/TypeChecker.h b/libsolidity/analysis/TypeChecker.h
index 7af5473b..9a568349 100644
--- a/libsolidity/TypeChecker.h
+++ b/libsolidity/analysis/TypeChecker.h
@@ -22,11 +22,11 @@
#pragma once
-#include <libsolidity/TypeChecker.h>
-#include <libsolidity/Types.h>
-#include <libsolidity/ASTAnnotations.h>
-#include <libsolidity/ASTForward.h>
-#include <libsolidity/ASTVisitor.h>
+#include <libsolidity/analysis/TypeChecker.h>
+#include <libsolidity/ast/Types.h>
+#include <libsolidity/ast/ASTAnnotations.h>
+#include <libsolidity/ast/ASTForward.h>
+#include <libsolidity/ast/ASTVisitor.h>
namespace dev
{
diff --git a/libsolidity/AST.cpp b/libsolidity/ast/AST.cpp
index 062febb9..71d80a36 100644
--- a/libsolidity/AST.cpp
+++ b/libsolidity/ast/AST.cpp
@@ -22,11 +22,11 @@
#include <algorithm>
#include <functional>
-#include <libsolidity/Utils.h>
-#include <libsolidity/AST.h>
-#include <libsolidity/ASTVisitor.h>
-#include <libsolidity/Exceptions.h>
-#include <libsolidity/AST_accept.h>
+#include <libsolidity/interface/Utils.h>
+#include <libsolidity/ast/AST.h>
+#include <libsolidity/ast/ASTVisitor.h>
+#include <libsolidity/interface/Exceptions.h>
+#include <libsolidity/ast/AST_accept.h>
#include <libdevcore/SHA3.h>
diff --git a/libsolidity/AST.h b/libsolidity/ast/AST.h
index fc1db3f3..3fe447eb 100644
--- a/libsolidity/AST.h
+++ b/libsolidity/ast/AST.h
@@ -28,12 +28,12 @@
#include <memory>
#include <boost/noncopyable.hpp>
#include <libevmasm/SourceLocation.h>
-#include <libsolidity/Utils.h>
-#include <libsolidity/ASTForward.h>
-#include <libsolidity/Token.h>
-#include <libsolidity/Types.h>
-#include <libsolidity/Exceptions.h>
-#include <libsolidity/ASTAnnotations.h>
+#include <libsolidity/interface/Utils.h>
+#include <libsolidity/ast/ASTForward.h>
+#include <libsolidity/parsing/Token.h>
+#include <libsolidity/ast/Types.h>
+#include <libsolidity/interface/Exceptions.h>
+#include <libsolidity/ast/ASTAnnotations.h>
namespace dev
{
diff --git a/libsolidity/ASTAnnotations.cpp b/libsolidity/ast/ASTAnnotations.cpp
index 4253e16d..416e6b44 100644
--- a/libsolidity/ASTAnnotations.cpp
+++ b/libsolidity/ast/ASTAnnotations.cpp
@@ -20,7 +20,7 @@
* Object containing the type and other annotations for the AST nodes.
*/
-#include <libsolidity/ASTAnnotations.h>
+#include <libsolidity/ast/ASTAnnotations.h>
using namespace std;
using namespace dev;
diff --git a/libsolidity/ASTAnnotations.h b/libsolidity/ast/ASTAnnotations.h
index 1b772ffa..d112b1ef 100644
--- a/libsolidity/ASTAnnotations.h
+++ b/libsolidity/ast/ASTAnnotations.h
@@ -26,7 +26,7 @@
#include <memory>
#include <vector>
#include <set>
-#include <libsolidity/ASTForward.h>
+#include <libsolidity/ast/ASTForward.h>
namespace dev
{
diff --git a/libsolidity/ASTForward.h b/libsolidity/ast/ASTForward.h
index 02dd054a..02dd054a 100644
--- a/libsolidity/ASTForward.h
+++ b/libsolidity/ast/ASTForward.h
diff --git a/libsolidity/ASTJsonConverter.cpp b/libsolidity/ast/ASTJsonConverter.cpp
index 34012c73..f208c3c9 100644
--- a/libsolidity/ASTJsonConverter.cpp
+++ b/libsolidity/ast/ASTJsonConverter.cpp
@@ -20,9 +20,9 @@
* Converts the AST into json format
*/
-#include <libsolidity/ASTJsonConverter.h>
+#include <libsolidity/ast/ASTJsonConverter.h>
#include <boost/algorithm/string/join.hpp>
-#include <libsolidity/AST.h>
+#include <libsolidity/ast/AST.h>
using namespace std;
diff --git a/libsolidity/ASTJsonConverter.h b/libsolidity/ast/ASTJsonConverter.h
index a62259e2..de891cc6 100644
--- a/libsolidity/ASTJsonConverter.h
+++ b/libsolidity/ast/ASTJsonConverter.h
@@ -24,10 +24,10 @@
#include <ostream>
#include <stack>
-#include <libsolidity/ASTVisitor.h>
-#include <libsolidity/Exceptions.h>
-#include <libsolidity/Utils.h>
-#include <libsolidity/ASTAnnotations.h>
+#include <libsolidity/ast/ASTVisitor.h>
+#include <libsolidity/interface/Exceptions.h>
+#include <libsolidity/interface/Utils.h>
+#include <libsolidity/ast/ASTAnnotations.h>
#include <json/json.h>
namespace dev
diff --git a/libsolidity/ASTPrinter.cpp b/libsolidity/ast/ASTPrinter.cpp
index cb231842..9253e0bf 100644
--- a/libsolidity/ASTPrinter.cpp
+++ b/libsolidity/ast/ASTPrinter.cpp
@@ -20,9 +20,9 @@
* Pretty-printer for the abstract syntax tree (the "pretty" is arguable), used for debugging.
*/
-#include <libsolidity/ASTPrinter.h>
+#include <libsolidity/ast/ASTPrinter.h>
#include <boost/algorithm/string/join.hpp>
-#include <libsolidity/AST.h>
+#include <libsolidity/ast/AST.h>
using namespace std;
diff --git a/libsolidity/ASTPrinter.h b/libsolidity/ast/ASTPrinter.h
index 95656436..d9b5e252 100644
--- a/libsolidity/ASTPrinter.h
+++ b/libsolidity/ast/ASTPrinter.h
@@ -23,8 +23,8 @@
#pragma once
#include <ostream>
-#include <libsolidity/ASTVisitor.h>
-#include <libsolidity/GasEstimator.h>
+#include <libsolidity/ast/ASTVisitor.h>
+#include <libsolidity/interface/GasEstimator.h>
namespace dev
{
diff --git a/libsolidity/ASTUtils.cpp b/libsolidity/ast/ASTUtils.cpp
index a617bf94..e9b70b62 100644
--- a/libsolidity/ASTUtils.cpp
+++ b/libsolidity/ast/ASTUtils.cpp
@@ -20,7 +20,7 @@
* Utilities to work with the AST.
*/
-#include <libsolidity/ASTUtils.h>
+#include <libsolidity/ast/ASTUtils.h>
using namespace std;
using namespace dev;
diff --git a/libsolidity/ASTUtils.h b/libsolidity/ast/ASTUtils.h
index b24a3404..237537ec 100644
--- a/libsolidity/ASTUtils.h
+++ b/libsolidity/ast/ASTUtils.h
@@ -23,7 +23,7 @@
#pragma once
#include <libevmasm/SourceLocation.h>
-#include <libsolidity/ASTVisitor.h>
+#include <libsolidity/ast/ASTVisitor.h>
namespace dev
{
diff --git a/libsolidity/ASTVisitor.h b/libsolidity/ast/ASTVisitor.h
index 3e50fb28..14c09fb4 100644
--- a/libsolidity/ASTVisitor.h
+++ b/libsolidity/ast/ASTVisitor.h
@@ -25,7 +25,7 @@
#include <string>
#include <functional>
#include <vector>
-#include <libsolidity/AST.h>
+#include <libsolidity/ast/AST.h>
namespace dev
{
diff --git a/libsolidity/AST_accept.h b/libsolidity/ast/AST_accept.h
index eb1f6098..12a26ea7 100644
--- a/libsolidity/AST_accept.h
+++ b/libsolidity/ast/AST_accept.h
@@ -23,8 +23,8 @@
#pragma once
-#include <libsolidity/AST.h>
-#include <libsolidity/ASTVisitor.h>
+#include <libsolidity/ast/AST.h>
+#include <libsolidity/ast/ASTVisitor.h>
namespace dev
{
diff --git a/libsolidity/Types.cpp b/libsolidity/ast/Types.cpp
index 02b86a7f..0253e843 100644
--- a/libsolidity/Types.cpp
+++ b/libsolidity/ast/Types.cpp
@@ -20,14 +20,14 @@
* Solidity data types
*/
-#include <libsolidity/Types.h>
+#include <libsolidity/ast/Types.h>
#include <limits>
#include <boost/range/adaptor/reversed.hpp>
#include <libdevcore/CommonIO.h>
#include <libdevcore/CommonData.h>
#include <libdevcore/SHA3.h>
-#include <libsolidity/Utils.h>
-#include <libsolidity/AST.h>
+#include <libsolidity/interface/Utils.h>
+#include <libsolidity/ast/AST.h>
using namespace std;
using namespace dev;
diff --git a/libsolidity/Types.h b/libsolidity/ast/Types.h
index 626ebbe4..2f75975f 100644
--- a/libsolidity/Types.h
+++ b/libsolidity/ast/Types.h
@@ -27,9 +27,9 @@
#include <map>
#include <boost/noncopyable.hpp>
#include <libdevcore/Common.h>
-#include <libsolidity/Exceptions.h>
-#include <libsolidity/ASTForward.h>
-#include <libsolidity/Token.h>
+#include <libsolidity/interface/Exceptions.h>
+#include <libsolidity/ast/ASTForward.h>
+#include <libsolidity/parsing/Token.h>
#include <libdevcore/UndefMacros.h>
namespace dev
diff --git a/libsolidity/ArrayUtils.cpp b/libsolidity/codegen/ArrayUtils.cpp
index 1999eb77..ba26caa6 100644
--- a/libsolidity/ArrayUtils.cpp
+++ b/libsolidity/codegen/ArrayUtils.cpp
@@ -20,13 +20,13 @@
* Code generation utils that handle arrays.
*/
-#include <libsolidity/ArrayUtils.h>
+#include <libsolidity/codegen/ArrayUtils.h>
#include <libevmcore/Instruction.h>
-#include <libsolidity/CompilerContext.h>
-#include <libsolidity/CompilerUtils.h>
-#include <libsolidity/Types.h>
-#include <libsolidity/Utils.h>
-#include <libsolidity/LValue.h>
+#include <libsolidity/codegen/CompilerContext.h>
+#include <libsolidity/codegen/CompilerUtils.h>
+#include <libsolidity/ast/Types.h>
+#include <libsolidity/interface/Utils.h>
+#include <libsolidity/codegen/LValue.h>
using namespace std;
using namespace dev;
diff --git a/libsolidity/ArrayUtils.h b/libsolidity/codegen/ArrayUtils.h
index 53d36c14..53d36c14 100644
--- a/libsolidity/ArrayUtils.h
+++ b/libsolidity/codegen/ArrayUtils.h
diff --git a/libsolidity/Compiler.cpp b/libsolidity/codegen/Compiler.cpp
index 679704ba..457b1e02 100644
--- a/libsolidity/Compiler.cpp
+++ b/libsolidity/codegen/Compiler.cpp
@@ -20,15 +20,15 @@
* Solidity compiler.
*/
-#include <libsolidity/Compiler.h>
+#include <libsolidity/codegen/Compiler.h>
#include <algorithm>
#include <boost/range/adaptor/reversed.hpp>
#include <libevmcore/Instruction.h>
#include <libevmasm/Assembly.h>
#include <libevmcore/Params.h>
-#include <libsolidity/AST.h>
-#include <libsolidity/ExpressionCompiler.h>
-#include <libsolidity/CompilerUtils.h>
+#include <libsolidity/ast/AST.h>
+#include <libsolidity/codegen/ExpressionCompiler.h>
+#include <libsolidity/codegen/CompilerUtils.h>
using namespace std;
using namespace dev;
diff --git a/libsolidity/Compiler.h b/libsolidity/codegen/Compiler.h
index 3cf1004a..14314434 100644
--- a/libsolidity/Compiler.h
+++ b/libsolidity/codegen/Compiler.h
@@ -24,8 +24,8 @@
#include <ostream>
#include <functional>
-#include <libsolidity/ASTVisitor.h>
-#include <libsolidity/CompilerContext.h>
+#include <libsolidity/ast/ASTVisitor.h>
+#include <libsolidity/codegen/CompilerContext.h>
#include <libevmasm/Assembly.h>
namespace dev {
diff --git a/libsolidity/CompilerContext.cpp b/libsolidity/codegen/CompilerContext.cpp
index 0ba7af5b..00b9d87c 100644
--- a/libsolidity/CompilerContext.cpp
+++ b/libsolidity/codegen/CompilerContext.cpp
@@ -20,12 +20,12 @@
* Utilities for the solidity compiler.
*/
-#include <libsolidity/CompilerContext.h>
+#include <libsolidity/codegen/CompilerContext.h>
#include <utility>
#include <numeric>
-#include <libsolidity/AST.h>
-#include <libsolidity/Compiler.h>
-#include <libsolidity/Version.h>
+#include <libsolidity/ast/AST.h>
+#include <libsolidity/codegen/Compiler.h>
+#include <libsolidity/interface/Version.h>
using namespace std;
diff --git a/libsolidity/CompilerContext.h b/libsolidity/codegen/CompilerContext.h
index 18865091..5287088a 100644
--- a/libsolidity/CompilerContext.h
+++ b/libsolidity/codegen/CompilerContext.h
@@ -27,9 +27,9 @@
#include <utility>
#include <libevmcore/Instruction.h>
#include <libevmasm/Assembly.h>
-#include <libsolidity/ASTForward.h>
-#include <libsolidity/Types.h>
-#include <libsolidity/ASTAnnotations.h>
+#include <libsolidity/ast/ASTForward.h>
+#include <libsolidity/ast/Types.h>
+#include <libsolidity/ast/ASTAnnotations.h>
#include <libdevcore/Common.h>
namespace dev {
diff --git a/libsolidity/CompilerUtils.cpp b/libsolidity/codegen/CompilerUtils.cpp
index f0dea708..cd84f5fc 100644
--- a/libsolidity/CompilerUtils.cpp
+++ b/libsolidity/codegen/CompilerUtils.cpp
@@ -20,12 +20,12 @@
* Routines used by both the compiler and the expression compiler.
*/
-#include <libsolidity/CompilerUtils.h>
-#include <libsolidity/AST.h>
+#include <libsolidity/codegen/CompilerUtils.h>
+#include <libsolidity/ast/AST.h>
#include <libevmcore/Instruction.h>
#include <libevmcore/Params.h>
-#include <libsolidity/ArrayUtils.h>
-#include <libsolidity/LValue.h>
+#include <libsolidity/codegen/ArrayUtils.h>
+#include <libsolidity/codegen/LValue.h>
using namespace std;
diff --git a/libsolidity/CompilerUtils.h b/libsolidity/codegen/CompilerUtils.h
index 01b9f422..6292e5c7 100644
--- a/libsolidity/CompilerUtils.h
+++ b/libsolidity/codegen/CompilerUtils.h
@@ -22,8 +22,8 @@
#pragma once
-#include <libsolidity/CompilerContext.h>
-#include <libsolidity/ASTForward.h>
+#include <libsolidity/codegen/CompilerContext.h>
+#include <libsolidity/ast/ASTForward.h>
namespace dev {
namespace solidity {
diff --git a/libsolidity/ExpressionCompiler.cpp b/libsolidity/codegen/ExpressionCompiler.cpp
index 112521f9..3774e731 100644
--- a/libsolidity/ExpressionCompiler.cpp
+++ b/libsolidity/codegen/ExpressionCompiler.cpp
@@ -26,11 +26,11 @@
#include <libevmcore/Params.h>
#include <libdevcore/Common.h>
#include <libdevcore/SHA3.h>
-#include <libsolidity/AST.h>
-#include <libsolidity/ExpressionCompiler.h>
-#include <libsolidity/CompilerContext.h>
-#include <libsolidity/CompilerUtils.h>
-#include <libsolidity/LValue.h>
+#include <libsolidity/ast/AST.h>
+#include <libsolidity/codegen/ExpressionCompiler.h>
+#include <libsolidity/codegen/CompilerContext.h>
+#include <libsolidity/codegen/CompilerUtils.h>
+#include <libsolidity/codegen/LValue.h>
using namespace std;
diff --git a/libsolidity/ExpressionCompiler.h b/libsolidity/codegen/ExpressionCompiler.h
index 44d27ea2..379aa65a 100644
--- a/libsolidity/ExpressionCompiler.h
+++ b/libsolidity/codegen/ExpressionCompiler.h
@@ -26,9 +26,9 @@
#include <boost/noncopyable.hpp>
#include <libdevcore/Common.h>
#include <libevmasm/SourceLocation.h>
-#include <libsolidity/ASTVisitor.h>
-#include <libsolidity/LValue.h>
-#include <libsolidity/Utils.h>
+#include <libsolidity/ast/ASTVisitor.h>
+#include <libsolidity/codegen/LValue.h>
+#include <libsolidity/interface/Utils.h>
namespace dev {
namespace eth
diff --git a/libsolidity/LValue.cpp b/libsolidity/codegen/LValue.cpp
index ac04ebef..574d42f8 100644
--- a/libsolidity/LValue.cpp
+++ b/libsolidity/codegen/LValue.cpp
@@ -20,11 +20,11 @@
* LValues for use in the expresison compiler.
*/
-#include <libsolidity/LValue.h>
+#include <libsolidity/codegen/LValue.h>
#include <libevmcore/Instruction.h>
-#include <libsolidity/Types.h>
-#include <libsolidity/AST.h>
-#include <libsolidity/CompilerUtils.h>
+#include <libsolidity/ast/Types.h>
+#include <libsolidity/ast/AST.h>
+#include <libsolidity/codegen/CompilerUtils.h>
using namespace std;
using namespace dev;
diff --git a/libsolidity/LValue.h b/libsolidity/codegen/LValue.h
index 94c8d3b8..35cbec5b 100644
--- a/libsolidity/LValue.h
+++ b/libsolidity/codegen/LValue.h
@@ -25,7 +25,7 @@
#include <memory>
#include <vector>
#include <libevmasm/SourceLocation.h>
-#include <libsolidity/ArrayUtils.h>
+#include <libsolidity/codegen/ArrayUtils.h>
namespace dev
{
diff --git a/libsolidity/CompilerStack.cpp b/libsolidity/interface/CompilerStack.cpp
index 03120f66..775c7eb6 100644
--- a/libsolidity/CompilerStack.cpp
+++ b/libsolidity/interface/CompilerStack.cpp
@@ -22,15 +22,15 @@
*/
#include <boost/algorithm/string.hpp>
-#include <libsolidity/AST.h>
-#include <libsolidity/Scanner.h>
-#include <libsolidity/Parser.h>
-#include <libsolidity/GlobalContext.h>
-#include <libsolidity/NameAndTypeResolver.h>
-#include <libsolidity/TypeChecker.h>
-#include <libsolidity/Compiler.h>
-#include <libsolidity/CompilerStack.h>
-#include <libsolidity/InterfaceHandler.h>
+#include <libsolidity/ast/AST.h>
+#include <libsolidity/parsing/Scanner.h>
+#include <libsolidity/parsing/Parser.h>
+#include <libsolidity/analysis/GlobalContext.h>
+#include <libsolidity/analysis/NameAndTypeResolver.h>
+#include <libsolidity/analysis/TypeChecker.h>
+#include <libsolidity/codegen/Compiler.h>
+#include <libsolidity/interface/CompilerStack.h>
+#include <libsolidity/interface/InterfaceHandler.h>
#include <libdevcore/SHA3.h>
diff --git a/libsolidity/CompilerStack.h b/libsolidity/interface/CompilerStack.h
index de548bee..1f1b74f5 100644
--- a/libsolidity/CompilerStack.h
+++ b/libsolidity/interface/CompilerStack.h
@@ -33,7 +33,7 @@
#include <libdevcore/FixedHash.h>
#include <libevmasm/SourceLocation.h>
#include <libevmasm/LinkerObject.h>
-#include <libsolidity/Exceptions.h>
+#include <libsolidity/interface/Exceptions.h>
namespace dev
{
diff --git a/libsolidity/Exceptions.cpp b/libsolidity/interface/Exceptions.cpp
index 96bb2e37..2e79ab39 100644
--- a/libsolidity/Exceptions.cpp
+++ b/libsolidity/interface/Exceptions.cpp
@@ -20,8 +20,8 @@
* Solidity exception hierarchy.
*/
-#include <libsolidity/Exceptions.h>
-#include <libsolidity/Utils.h>
+#include <libsolidity/interface/Exceptions.h>
+#include <libsolidity/interface/Utils.h>
using namespace dev;
using namespace dev::solidity;
diff --git a/libsolidity/Exceptions.h b/libsolidity/interface/Exceptions.h
index cda6b97e..cda6b97e 100644
--- a/libsolidity/Exceptions.h
+++ b/libsolidity/interface/Exceptions.h
diff --git a/libsolidity/GasEstimator.cpp b/libsolidity/interface/GasEstimator.cpp
index d576561a..d460ba76 100644
--- a/libsolidity/GasEstimator.cpp
+++ b/libsolidity/interface/GasEstimator.cpp
@@ -28,9 +28,9 @@
#include <libevmasm/ControlFlowGraph.h>
#include <libevmasm/KnownState.h>
#include <libevmasm/PathGasMeter.h>
-#include <libsolidity/AST.h>
-#include <libsolidity/ASTVisitor.h>
-#include <libsolidity/CompilerUtils.h>
+#include <libsolidity/ast/AST.h>
+#include <libsolidity/ast/ASTVisitor.h>
+#include <libsolidity/codegen/CompilerUtils.h>
using namespace std;
using namespace dev;
diff --git a/libsolidity/GasEstimator.h b/libsolidity/interface/GasEstimator.h
index 4020d60b..518e58e4 100644
--- a/libsolidity/GasEstimator.h
+++ b/libsolidity/interface/GasEstimator.h
@@ -25,7 +25,6 @@
#include <vector>
#include <map>
#include <array>
-#include <libsolidity/ASTForward.h>
#include <libevmasm/GasMeter.h>
#include <libevmasm/Assembly.h>
@@ -34,6 +33,9 @@ namespace dev
namespace solidity
{
+class ASTNode;
+class FunctionDefinition;
+
struct GasEstimator
{
public:
diff --git a/libsolidity/InterfaceHandler.cpp b/libsolidity/interface/InterfaceHandler.cpp
index 17ca66b4..136136e6 100644
--- a/libsolidity/InterfaceHandler.cpp
+++ b/libsolidity/interface/InterfaceHandler.cpp
@@ -1,8 +1,8 @@
-#include <libsolidity/InterfaceHandler.h>
+#include <libsolidity/interface/InterfaceHandler.h>
#include <boost/range/irange.hpp>
-#include <libsolidity/AST.h>
-#include <libsolidity/CompilerStack.h>
+#include <libsolidity/ast/AST.h>
+#include <libsolidity/interface/CompilerStack.h>
using namespace std;
namespace dev
diff --git a/libsolidity/InterfaceHandler.h b/libsolidity/interface/InterfaceHandler.h
index 62164517..62164517 100644
--- a/libsolidity/InterfaceHandler.h
+++ b/libsolidity/interface/InterfaceHandler.h
diff --git a/libsolidity/SourceReferenceFormatter.cpp b/libsolidity/interface/SourceReferenceFormatter.cpp
index 339d5b23..169e5c18 100644
--- a/libsolidity/SourceReferenceFormatter.cpp
+++ b/libsolidity/interface/SourceReferenceFormatter.cpp
@@ -20,10 +20,10 @@
* Formatting functions for errors referencing positions and locations in the source.
*/
-#include <libsolidity/SourceReferenceFormatter.h>
-#include <libsolidity/CompilerStack.h>
-#include <libsolidity/Scanner.h>
-#include <libsolidity/Exceptions.h>
+#include <libsolidity/interface/SourceReferenceFormatter.h>
+#include <libsolidity/interface/CompilerStack.h>
+#include <libsolidity/parsing/Scanner.h>
+#include <libsolidity/interface/Exceptions.h>
using namespace std;
diff --git a/libsolidity/SourceReferenceFormatter.h b/libsolidity/interface/SourceReferenceFormatter.h
index dd258c27..dd258c27 100644
--- a/libsolidity/SourceReferenceFormatter.h
+++ b/libsolidity/interface/SourceReferenceFormatter.h
diff --git a/libsolidity/Utils.h b/libsolidity/interface/Utils.h
index 48bb1e47..738669ac 100644
--- a/libsolidity/Utils.h
+++ b/libsolidity/interface/Utils.h
@@ -23,7 +23,7 @@
#pragma once
#include <libdevcore/Assertions.h>
-#include <libsolidity/Exceptions.h>
+#include <libsolidity/interface/Exceptions.h>
namespace dev
{
diff --git a/libsolidity/Version.cpp b/libsolidity/interface/Version.cpp
index 09a6d84b..d2a53440 100644
--- a/libsolidity/Version.cpp
+++ b/libsolidity/interface/Version.cpp
@@ -20,12 +20,12 @@
* Versioning.
*/
-#include <libsolidity/Version.h>
+#include <libsolidity/interface/Version.h>
#include <string>
#include <libdevcore/CommonData.h>
#include <libdevcore/Common.h>
#include <libevmasm/Version.h>
-#include <libsolidity/Utils.h>
+#include <libsolidity/interface/Utils.h>
#include <solidity/BuildInfo.h>
using namespace dev;
diff --git a/libsolidity/Version.h b/libsolidity/interface/Version.h
index fea73997..fea73997 100644
--- a/libsolidity/Version.h
+++ b/libsolidity/interface/Version.h
diff --git a/libsolidity/Parser.cpp b/libsolidity/parsing/Parser.cpp
index 4fdfd2e4..57f3e913 100644
--- a/libsolidity/Parser.cpp
+++ b/libsolidity/parsing/Parser.cpp
@@ -23,10 +23,10 @@
#include <vector>
#include <libdevcore/Log.h>
#include <libevmasm/SourceLocation.h>
-#include <libsolidity/Parser.h>
-#include <libsolidity/Scanner.h>
-#include <libsolidity/Exceptions.h>
-#include <libsolidity/InterfaceHandler.h>
+#include <libsolidity/parsing/Parser.h>
+#include <libsolidity/parsing/Scanner.h>
+#include <libsolidity/interface/Exceptions.h>
+#include <libsolidity/interface/InterfaceHandler.h>
using namespace std;
diff --git a/libsolidity/Parser.h b/libsolidity/parsing/Parser.h
index bd483e09..5e226ba5 100644
--- a/libsolidity/Parser.h
+++ b/libsolidity/parsing/Parser.h
@@ -22,7 +22,7 @@
#pragma once
-#include "libsolidity/AST.h"
+#include "libsolidity/ast/AST.h"
namespace dev
{
diff --git a/libsolidity/Scanner.cpp b/libsolidity/parsing/Scanner.cpp
index d67b6423..fe0807d5 100644
--- a/libsolidity/Scanner.cpp
+++ b/libsolidity/parsing/Scanner.cpp
@@ -52,8 +52,8 @@
#include <algorithm>
#include <tuple>
-#include <libsolidity/Utils.h>
-#include <libsolidity/Scanner.h>
+#include <libsolidity/interface/Utils.h>
+#include <libsolidity/parsing/Scanner.h>
using namespace std;
diff --git a/libsolidity/Scanner.h b/libsolidity/parsing/Scanner.h
index 29b44d15..a1a5c9c1 100644
--- a/libsolidity/Scanner.h
+++ b/libsolidity/parsing/Scanner.h
@@ -56,7 +56,7 @@
#include <libdevcore/Log.h>
#include <libdevcore/CommonData.h>
#include <libevmasm/SourceLocation.h>
-#include <libsolidity/Token.h>
+#include <libsolidity/parsing/Token.h>
namespace dev
{
diff --git a/libsolidity/Token.cpp b/libsolidity/parsing/Token.cpp
index d07d7502..cda639fb 100644
--- a/libsolidity/Token.cpp
+++ b/libsolidity/parsing/Token.cpp
@@ -41,7 +41,7 @@
// along with cpp-ethereum. If not, see <http://www.gnu.org/licenses/>.
#include <map>
-#include <libsolidity/Token.h>
+#include <libsolidity/parsing/Token.h>
using namespace std;
diff --git a/libsolidity/Token.h b/libsolidity/parsing/Token.h
index 2ea7eb01..98461fa4 100644
--- a/libsolidity/Token.h
+++ b/libsolidity/parsing/Token.h
@@ -44,8 +44,8 @@
#include <libdevcore/Common.h>
#include <libdevcore/Log.h>
-#include <libsolidity/Utils.h>
-#include <libsolidity/Exceptions.h>
+#include <libsolidity/interface/Utils.h>
+#include <libsolidity/interface/Exceptions.h>
#include <libdevcore/UndefMacros.h>
namespace dev
diff --git a/solc/CommandLineInterface.cpp b/solc/CommandLineInterface.cpp
index deae5928..fcea5bf9 100644
--- a/solc/CommandLineInterface.cpp
+++ b/solc/CommandLineInterface.cpp
@@ -35,16 +35,16 @@
#include <libdevcore/CommonIO.h>
#include <libevmcore/Instruction.h>
#include <libevmcore/Params.h>
-#include <libsolidity/Version.h>
-#include <libsolidity/Scanner.h>
-#include <libsolidity/Parser.h>
-#include <libsolidity/ASTPrinter.h>
-#include <libsolidity/ASTJsonConverter.h>
-#include <libsolidity/NameAndTypeResolver.h>
-#include <libsolidity/Exceptions.h>
-#include <libsolidity/CompilerStack.h>
-#include <libsolidity/SourceReferenceFormatter.h>
-#include <libsolidity/GasEstimator.h>
+#include <libsolidity/interface/Version.h>
+#include <libsolidity/parsing/Scanner.h>
+#include <libsolidity/parsing/Parser.h>
+#include <libsolidity/ast/ASTPrinter.h>
+#include <libsolidity/ast/ASTJsonConverter.h>
+#include <libsolidity/analysis/NameAndTypeResolver.h>
+#include <libsolidity/interface/Exceptions.h>
+#include <libsolidity/interface/CompilerStack.h>
+#include <libsolidity/interface/SourceReferenceFormatter.h>
+#include <libsolidity/interface/GasEstimator.h>
using namespace std;
namespace po = boost::program_options;
diff --git a/solc/CommandLineInterface.h b/solc/CommandLineInterface.h
index 2af5a5e9..1cde2acb 100644
--- a/solc/CommandLineInterface.h
+++ b/solc/CommandLineInterface.h
@@ -21,7 +21,7 @@
*/
#pragma once
-#include <libsolidity/CompilerStack.h>
+#include <libsolidity/interface/CompilerStack.h>
#include <memory>
#include <boost/program_options.hpp>
diff --git a/solc/jsonCompiler.cpp b/solc/jsonCompiler.cpp
index 1690fadb..43164807 100644
--- a/solc/jsonCompiler.cpp
+++ b/solc/jsonCompiler.cpp
@@ -28,15 +28,15 @@
#include <libdevcore/CommonIO.h>
#include <libevmcore/Instruction.h>
#include <libevmcore/Params.h>
-#include <libsolidity/Scanner.h>
-#include <libsolidity/Parser.h>
-#include <libsolidity/ASTPrinter.h>
-#include <libsolidity/NameAndTypeResolver.h>
-#include <libsolidity/Exceptions.h>
-#include <libsolidity/CompilerStack.h>
-#include <libsolidity/SourceReferenceFormatter.h>
-#include <libsolidity/ASTJsonConverter.h>
-#include <libsolidity/Version.h>
+#include <libsolidity/parsing/Scanner.h>
+#include <libsolidity/parsing/Parser.h>
+#include <libsolidity/ast/ASTPrinter.h>
+#include <libsolidity/analysis/NameAndTypeResolver.h>
+#include <libsolidity/interface/Exceptions.h>
+#include <libsolidity/interface/CompilerStack.h>
+#include <libsolidity/interface/SourceReferenceFormatter.h>
+#include <libsolidity/ast/ASTJsonConverter.h>
+#include <libsolidity/interface/Version.h>
using namespace std;
using namespace dev;
diff --git a/test/libsolidity/Assembly.cpp b/test/libsolidity/Assembly.cpp
index f69ae680..13665a33 100644
--- a/test/libsolidity/Assembly.cpp
+++ b/test/libsolidity/Assembly.cpp
@@ -26,12 +26,12 @@
#include <libdevcore/Log.h>
#include <libevmasm/SourceLocation.h>
#include <libevmasm/Assembly.h>
-#include <libsolidity/Scanner.h>
-#include <libsolidity/Parser.h>
-#include <libsolidity/NameAndTypeResolver.h>
-#include <libsolidity/Compiler.h>
-#include <libsolidity/AST.h>
-#include <libsolidity/TypeChecker.h>
+#include <libsolidity/parsing/Scanner.h>
+#include <libsolidity/parsing/Parser.h>
+#include <libsolidity/analysis/NameAndTypeResolver.h>
+#include <libsolidity/codegen/Compiler.h>
+#include <libsolidity/ast/AST.h>
+#include <libsolidity/analysis/TypeChecker.h>
using namespace std;
using namespace dev::eth;
diff --git a/test/libsolidity/GasMeter.cpp b/test/libsolidity/GasMeter.cpp
index 6d7c06a3..b5cee01e 100644
--- a/test/libsolidity/GasMeter.cpp
+++ b/test/libsolidity/GasMeter.cpp
@@ -24,9 +24,9 @@
#include <libevmasm/GasMeter.h>
#include <libevmasm/KnownState.h>
#include <libevmasm/PathGasMeter.h>
-#include <libsolidity/AST.h>
-#include <libsolidity/GasEstimator.h>
-#include <libsolidity/SourceReferenceFormatter.h>
+#include <libsolidity/ast/AST.h>
+#include <libsolidity/interface/GasEstimator.h>
+#include <libsolidity/interface/SourceReferenceFormatter.h>
using namespace std;
using namespace dev::eth;
diff --git a/test/libsolidity/SolidityABIJSON.cpp b/test/libsolidity/SolidityABIJSON.cpp
index 68f5a64a..77b39978 100644
--- a/test/libsolidity/SolidityABIJSON.cpp
+++ b/test/libsolidity/SolidityABIJSON.cpp
@@ -21,7 +21,7 @@
*/
#include "../TestHelper.h"
-#include <libsolidity/CompilerStack.h>
+#include <libsolidity/interface/CompilerStack.h>
#include <json/json.h>
#include <libdevcore/Exceptions.h>
diff --git a/test/libsolidity/SolidityEndToEndTest.cpp b/test/libsolidity/SolidityEndToEndTest.cpp
index 27c511f2..5f7c6684 100644
--- a/test/libsolidity/SolidityEndToEndTest.cpp
+++ b/test/libsolidity/SolidityEndToEndTest.cpp
@@ -25,7 +25,7 @@
#include <tuple>
#include <boost/test/unit_test.hpp>
#include <libdevcore/Hash.h>
-#include <libsolidity/Exceptions.h>
+#include <libsolidity/interface/Exceptions.h>
#include <test/libsolidity/solidityExecutionFramework.h>
using namespace std;
diff --git a/test/libsolidity/SolidityExpressionCompiler.cpp b/test/libsolidity/SolidityExpressionCompiler.cpp
index 4013581d..a622c738 100644
--- a/test/libsolidity/SolidityExpressionCompiler.cpp
+++ b/test/libsolidity/SolidityExpressionCompiler.cpp
@@ -23,13 +23,13 @@
#include <string>
#include <libdevcore/Log.h>
-#include <libsolidity/Scanner.h>
-#include <libsolidity/Parser.h>
-#include <libsolidity/NameAndTypeResolver.h>
-#include <libsolidity/CompilerContext.h>
-#include <libsolidity/ExpressionCompiler.h>
-#include <libsolidity/AST.h>
-#include <libsolidity/TypeChecker.h>
+#include <libsolidity/parsing/Scanner.h>
+#include <libsolidity/parsing/Parser.h>
+#include <libsolidity/analysis/NameAndTypeResolver.h>
+#include <libsolidity/codegen/CompilerContext.h>
+#include <libsolidity/codegen/ExpressionCompiler.h>
+#include <libsolidity/ast/AST.h>
+#include <libsolidity/analysis/TypeChecker.h>
#include "../TestHelper.h"
using namespace std;
diff --git a/test/libsolidity/SolidityInterface.cpp b/test/libsolidity/SolidityInterface.cpp
index f0d2be20..9a1c104d 100644
--- a/test/libsolidity/SolidityInterface.cpp
+++ b/test/libsolidity/SolidityInterface.cpp
@@ -21,8 +21,8 @@
*/
#include "../TestHelper.h"
-#include <libsolidity/CompilerStack.h>
-#include <libsolidity/AST.h>
+#include <libsolidity/interface/CompilerStack.h>
+#include <libsolidity/ast/AST.h>
using namespace std;
diff --git a/test/libsolidity/SolidityNameAndTypeResolution.cpp b/test/libsolidity/SolidityNameAndTypeResolution.cpp
index 4f0b70bd..6b36f4cc 100644
--- a/test/libsolidity/SolidityNameAndTypeResolution.cpp
+++ b/test/libsolidity/SolidityNameAndTypeResolution.cpp
@@ -24,12 +24,12 @@
#include <libdevcore/Log.h>
#include <libdevcore/SHA3.h>
-#include <libsolidity/Scanner.h>
-#include <libsolidity/Parser.h>
-#include <libsolidity/NameAndTypeResolver.h>
-#include <libsolidity/Exceptions.h>
-#include <libsolidity/GlobalContext.h>
-#include <libsolidity/TypeChecker.h>
+#include <libsolidity/parsing/Scanner.h>
+#include <libsolidity/parsing/Parser.h>
+#include <libsolidity/analysis/NameAndTypeResolver.h>
+#include <libsolidity/interface/Exceptions.h>
+#include <libsolidity/analysis/GlobalContext.h>
+#include <libsolidity/analysis/TypeChecker.h>
#include "../TestHelper.h"
using namespace std;
diff --git a/test/libsolidity/SolidityNatspecJSON.cpp b/test/libsolidity/SolidityNatspecJSON.cpp
index 5d20fe7b..ee67dd66 100644
--- a/test/libsolidity/SolidityNatspecJSON.cpp
+++ b/test/libsolidity/SolidityNatspecJSON.cpp
@@ -23,8 +23,8 @@
#include "../TestHelper.h"
#include <string>
#include <json/json.h>
-#include <libsolidity/CompilerStack.h>
-#include <libsolidity/Exceptions.h>
+#include <libsolidity/interface/CompilerStack.h>
+#include <libsolidity/interface/Exceptions.h>
#include <libdevcore/Exceptions.h>
namespace dev
diff --git a/test/libsolidity/SolidityParser.cpp b/test/libsolidity/SolidityParser.cpp
index 77582a2a..beb71942 100644
--- a/test/libsolidity/SolidityParser.cpp
+++ b/test/libsolidity/SolidityParser.cpp
@@ -23,9 +23,9 @@
#include <string>
#include <memory>
#include <libdevcore/Log.h>
-#include <libsolidity/Scanner.h>
-#include <libsolidity/Parser.h>
-#include <libsolidity/Exceptions.h>
+#include <libsolidity/parsing/Scanner.h>
+#include <libsolidity/parsing/Parser.h>
+#include <libsolidity/interface/Exceptions.h>
#include "../TestHelper.h"
using namespace std;
diff --git a/test/libsolidity/SolidityScanner.cpp b/test/libsolidity/SolidityScanner.cpp
index dadcd903..10f30b8e 100644
--- a/test/libsolidity/SolidityScanner.cpp
+++ b/test/libsolidity/SolidityScanner.cpp
@@ -20,7 +20,7 @@
* Unit tests for the solidity scanner.
*/
-#include <libsolidity/Scanner.h>
+#include <libsolidity/parsing/Scanner.h>
#include <boost/test/unit_test.hpp>
namespace dev
diff --git a/test/libsolidity/SolidityTypes.cpp b/test/libsolidity/SolidityTypes.cpp
index fc97667c..87dda9c2 100644
--- a/test/libsolidity/SolidityTypes.cpp
+++ b/test/libsolidity/SolidityTypes.cpp
@@ -20,7 +20,7 @@
* Unit tests for the type system of Solidity.
*/
-#include <libsolidity/Types.h>
+#include <libsolidity/ast/Types.h>
#include <boost/test/unit_test.hpp>
using namespace std;
diff --git a/test/libsolidity/solidityExecutionFramework.h b/test/libsolidity/solidityExecutionFramework.h
index 82fede84..ed317d2f 100644
--- a/test/libsolidity/solidityExecutionFramework.h
+++ b/test/libsolidity/solidityExecutionFramework.h
@@ -28,8 +28,8 @@
#include <libethcore/ABI.h>
#include <libethereum/State.h>
#include <libethereum/Executive.h>
-#include <libsolidity/CompilerStack.h>
-#include <libsolidity/Exceptions.h>
+#include <libsolidity/interface/CompilerStack.h>
+#include <libsolidity/interface/Exceptions.h>
namespace dev
{