Detect circular references for library and free functions

This commit is contained in:
Mathias Baumann
2021-03-30 23:06:30 +02:00
committed by chriseth
parent 15fe07bebe
commit e590a99f39
37 changed files with 1168 additions and 288 deletions
+3 -1
View File
@@ -41,7 +41,9 @@
#include <algorithm>
#include <limits>
#include <type_traits>
#include <range/v3/view/map.hpp>
using namespace ranges;
using namespace std;
using namespace solidity::langutil;
@@ -269,7 +271,7 @@ bool ASTJsonConverter::visit(ContractDefinition const& _node)
make_pair("contractKind", contractKind(_node.contractKind())),
make_pair("abstract", _node.abstract()),
make_pair("baseContracts", toJson(_node.baseContracts())),
make_pair("contractDependencies", getContainerIds(_node.annotation().contractDependencies, true)),
make_pair("contractDependencies", getContainerIds(_node.annotation().contractDependencies | views::keys)),
make_pair("nodes", toJson(_node.subNodes())),
make_pair("scope", idOrNull(_node.scope()))
};