diff options
author | Yoichi Hirai <i@yoichihirai.com> | 2016-12-05 19:03:07 +0800 |
---|---|---|
committer | Yoichi Hirai <i@yoichihirai.com> | 2017-01-12 01:28:11 +0800 |
commit | 0216f34010343af6285305b59d47db62261c03c6 (patch) | |
tree | 533ae3d7a4ab0a504001d391186b56a19a575b6a /libsolidity | |
parent | 91d4e8e0bab6f5285103af6ef84a7813cfbb61a2 (diff) | |
download | dexon-solidity-0216f34010343af6285305b59d47db62261c03c6.tar.gz dexon-solidity-0216f34010343af6285305b59d47db62261c03c6.tar.zst dexon-solidity-0216f34010343af6285305b59d47db62261c03c6.zip |
analysis: avoid emscripten build failure
Diffstat (limited to 'libsolidity')
-rw-r--r-- | libsolidity/analysis/NameAndTypeResolver.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libsolidity/analysis/NameAndTypeResolver.cpp b/libsolidity/analysis/NameAndTypeResolver.cpp index ee05910c..260965ae 100644 --- a/libsolidity/analysis/NameAndTypeResolver.cpp +++ b/libsolidity/analysis/NameAndTypeResolver.cpp @@ -264,11 +264,11 @@ vector<Declaration const*> NameAndTypeResolver::cleanedDeclarations( solAssert(dynamic_cast<FunctionDefinition const*>(*it) || dynamic_cast<VariableDeclaration const*>(*it), "Found overloading involving something not a function or a variable"); - shared_ptr<FunctionType const> functionType {}; + unique_ptr<FunctionType const> functionType {}; if (FunctionDefinition const* functionDefinition = dynamic_cast<FunctionDefinition const*>(*it)) { - functionType = make_shared<FunctionType const>(*functionDefinition); + functionType = unique_ptr<FunctionType const>(new FunctionType(*functionDefinition)); for (auto parameter: functionType->parameterTypes() + functionType->returnParameterTypes()) if (!parameter) reportFatalDeclarationError(_identifier.location(), "Function type can not be used in this context"); @@ -276,7 +276,7 @@ vector<Declaration const*> NameAndTypeResolver::cleanedDeclarations( else { VariableDeclaration const* variableDeclaration = dynamic_cast<VariableDeclaration const*>(*it); - functionType = make_shared<FunctionType const>(*variableDeclaration); + functionType = unique_ptr<FunctionType const>(new FunctionType(*variableDeclaration)); } solAssert(functionType, "failed to determine the function type of the overloaded"); |