fixes error after conflict resolving

This commit is contained in:
LianaHus 2015-10-15 11:10:55 +02:00
parent c3491e4469
commit 7a7a7dcbb5
4 changed files with 3 additions and 5 deletions

View File

@ -140,7 +140,7 @@ bool CompilerStack::parse()
{
m_globalContext->setCurrentContract(*contract);
resolver.updateDeclaration(*m_globalContext->currentThis());
TypeChecker typeChecker;
TypeChecker typeChecker(m_errors);
if (typeChecker.checkTypeRequirements(*contract))
{
contract->setDevDocumentation(interfaceHandler.devDocumentation(*contract));
@ -150,7 +150,6 @@ bool CompilerStack::parse()
typesFine = false;
m_contracts[contract->name()].contract = contract;
m_errors += typeChecker.errors();
}
m_parseSuccessful = typesFine;
return m_parseSuccessful;

View File

@ -60,7 +60,7 @@ bool ReferencesResolver::visit(UserDefinedTypeName const& _typeName)
Error(Error::Type::DeclarationError) <<
errinfo_sourceLocation(_typeName.location()) <<
errinfo_comment("Identifier not found or not unique.")
);
_typeName.annotation().referencedDeclaration = declaration;
return true;
}

View File

@ -607,7 +607,7 @@ bool TypeChecker::visit(VariableDeclarationStatement const& _statement)
{
if (ref->dataStoredIn(DataLocation::Storage))
{
auto err = make_shared<Warning>();
auto err = make_shared<Error>(Error::Type::Warning);
*err <<
errinfo_sourceLocation(varDecl.location()) <<
errinfo_comment("Uninitialized storage pointer. Did you mean '<type> memory " + varDecl.name() + "'?");

View File

@ -23,7 +23,6 @@
#pragma once
#include <libdevcore/Assertions.h>
#include <libsolidity/Exceptions.h>
/// Assertion that throws an InternalCompilerError containing the given description if it is not met.
#define solAssert(CONDITION, DESCRIPTION) \