aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLefteris Karapetsas <lefteris@refu.co>2015-02-14 00:34:46 +0800
committerLefteris Karapetsas <lefteris@refu.co>2015-02-14 06:16:14 +0800
commitb20ce4451bb4c2b64b112b8654b36502ae654a24 (patch)
treed9ecfcbf2a386e546f25594f377ceb669bd22997
parentfb4ff4af286f66dab3fde5bf33815c407f56b2db (diff)
downloaddexon-solidity-b20ce4451bb4c2b64b112b8654b36502ae654a24.tar
dexon-solidity-b20ce4451bb4c2b64b112b8654b36502ae654a24.tar.gz
dexon-solidity-b20ce4451bb4c2b64b112b8654b36502ae654a24.tar.bz2
dexon-solidity-b20ce4451bb4c2b64b112b8654b36502ae654a24.tar.lz
dexon-solidity-b20ce4451bb4c2b64b112b8654b36502ae654a24.tar.xz
dexon-solidity-b20ce4451bb4c2b64b112b8654b36502ae654a24.tar.zst
dexon-solidity-b20ce4451bb4c2b64b112b8654b36502ae654a24.zip
Typo in EnumValue
-rw-r--r--AST.cpp8
-rw-r--r--AST.h14
-rw-r--r--ASTForward.h2
-rw-r--r--ASTPrinter.cpp4
-rw-r--r--ASTPrinter.h4
-rw-r--r--ASTVisitor.h8
-rw-r--r--AST_accept.h4
-rw-r--r--Parser.cpp6
-rw-r--r--Parser.h2
-rw-r--r--Types.cpp2
10 files changed, 27 insertions, 27 deletions
diff --git a/AST.cpp b/AST.cpp
index 2baf9dae..9d7d2169 100644
--- a/AST.cpp
+++ b/AST.cpp
@@ -206,7 +206,7 @@ vector<pair<FixedHash<4>, FunctionTypePointer>> const& ContractDefinition::getIn
return *m_interfaceFunctionList;
}
-TypePointer EnumvValue::getType(ContractDefinition const*) const
+TypePointer EnumValue::getType(ContractDefinition const*) const
{
EnumDefinition const* parentDef = dynamic_cast<EnumDefinition const*>(getScope());
return make_shared<EnumType>(*parentDef);
@@ -263,8 +263,8 @@ void StructDefinition::checkRecursion() const
void EnumDefinition::checkValidityOfMembers() const
{
- vector<ASTPointer<EnumvValue>> members(getMembers());
- auto compareDecls = [](ASTPointer<EnumvValue> a, ASTPointer<EnumvValue> b)
+ vector<ASTPointer<EnumValue>> members(getMembers());
+ auto compareDecls = [](ASTPointer<EnumValue> a, ASTPointer<EnumValue> b)
{
return a->getName() < b->getName();
};
@@ -283,7 +283,7 @@ TypePointer EnumDefinition::getType(ContractDefinition const*) const
unsigned int EnumDefinition::getMemberValue(ASTString const& _member) const
{
unsigned int index = 0;
- for (ASTPointer<EnumvValue> const& decl: m_members)
+ for (ASTPointer<EnumValue> const& decl: m_members)
{
if (decl->getName() == _member)
return index;
diff --git a/AST.h b/AST.h
index 11dfef59..3485631b 100644
--- a/AST.h
+++ b/AST.h
@@ -168,12 +168,12 @@ private:
/**
* Declaration of an Enum Value
*/
-class EnumvValue : public Declaration
+class EnumValue: public Declaration
{
public:
- EnumvValue(Location const& _location,
- ASTPointer<ASTString> const& _name):
- Declaration(_location, _name) {}
+ EnumValue(Location const& _location,
+ ASTPointer<ASTString> const& _name):
+ Declaration(_location, _name) {}
virtual void accept(ASTVisitor& _visitor) override;
virtual void accept(ASTConstVisitor& _visitor) const override;
@@ -339,12 +339,12 @@ class EnumDefinition: public Declaration
public:
EnumDefinition(Location const& _location,
ASTPointer<ASTString> const& _name,
- std::vector<ASTPointer<EnumvValue>> const& _members):
+ std::vector<ASTPointer<EnumValue>> const& _members):
Declaration(_location, _name), m_members(_members) {}
virtual void accept(ASTVisitor& _visitor) override;
virtual void accept(ASTConstVisitor& _visitor) const override;
- std::vector<ASTPointer<EnumvValue>> const& getMembers() const { return m_members; }
+ std::vector<ASTPointer<EnumValue>> const& getMembers() const { return m_members; }
virtual TypePointer getType(ContractDefinition const*) const override;
@@ -356,7 +356,7 @@ public:
private:
- std::vector<ASTPointer<EnumvValue>> m_members;
+ std::vector<ASTPointer<EnumValue>> m_members;
};
/**
diff --git a/ASTForward.h b/ASTForward.h
index 3370e88a..0b6817e4 100644
--- a/ASTForward.h
+++ b/ASTForward.h
@@ -41,7 +41,7 @@ class ContractDefinition;
class InheritanceSpecifier;
class StructDefinition;
class EnumDefinition;
-class EnumvValue;
+class EnumValue;
class ParameterList;
class FunctionDefinition;
class VariableDeclaration;
diff --git a/ASTPrinter.cpp b/ASTPrinter.cpp
index dd66bf0d..d380b002 100644
--- a/ASTPrinter.cpp
+++ b/ASTPrinter.cpp
@@ -77,7 +77,7 @@ bool ASTPrinter::visit(EnumDefinition const& _node)
return goDeeper();
}
-bool ASTPrinter::visit(EnumvValue const& _node)
+bool ASTPrinter::visit(EnumValue const& _node)
{
writeLine("EnumValue \"" + _node.getName() + "\"");
return goDeeper();
@@ -364,7 +364,7 @@ void ASTPrinter::endVisit(EnumDefinition const&)
m_indentation--;
}
-void ASTPrinter::endVisit(EnumvValue const&)
+void ASTPrinter::endVisit(EnumValue const&)
{
m_indentation--;
}
diff --git a/ASTPrinter.h b/ASTPrinter.h
index dda2f1c4..d9072aac 100644
--- a/ASTPrinter.h
+++ b/ASTPrinter.h
@@ -47,7 +47,7 @@ public:
bool visit(InheritanceSpecifier const& _node) override;
bool visit(StructDefinition const& _node) override;
bool visit(EnumDefinition const& _node) override;
- bool visit(EnumvValue const& _node) override;
+ bool visit(EnumValue const& _node) override;
bool visit(ParameterList const& _node) override;
bool visit(FunctionDefinition const& _node) override;
bool visit(VariableDeclaration const& _node) override;
@@ -88,7 +88,7 @@ public:
void endVisit(InheritanceSpecifier const&) override;
void endVisit(StructDefinition const&) override;
void endVisit(EnumDefinition const&) override;
- void endVisit(EnumvValue const&) override;
+ void endVisit(EnumValue const&) override;
void endVisit(ParameterList const&) override;
void endVisit(FunctionDefinition const&) override;
void endVisit(VariableDeclaration const&) override;
diff --git a/ASTVisitor.h b/ASTVisitor.h
index 392da761..a7fa6b1c 100644
--- a/ASTVisitor.h
+++ b/ASTVisitor.h
@@ -48,7 +48,7 @@ public:
virtual bool visit(InheritanceSpecifier&) { return true; }
virtual bool visit(StructDefinition&) { return true; }
virtual bool visit(EnumDefinition&) { return true; }
- virtual bool visit(EnumvValue&) { return true; }
+ virtual bool visit(EnumValue&) { return true; }
virtual bool visit(ParameterList&) { return true; }
virtual bool visit(FunctionDefinition&) { return true; }
virtual bool visit(VariableDeclaration&) { return true; }
@@ -91,7 +91,7 @@ public:
virtual void endVisit(InheritanceSpecifier&) { }
virtual void endVisit(StructDefinition&) { }
virtual void endVisit(EnumDefinition&) { }
- virtual void endVisit(EnumvValue&) { }
+ virtual void endVisit(EnumValue&) { }
virtual void endVisit(ParameterList&) { }
virtual void endVisit(FunctionDefinition&) { }
virtual void endVisit(VariableDeclaration&) { }
@@ -138,7 +138,7 @@ public:
virtual bool visit(InheritanceSpecifier const&) { return true; }
virtual bool visit(StructDefinition const&) { return true; }
virtual bool visit(EnumDefinition const&) { return true; }
- virtual bool visit(EnumvValue const&) { return true; }
+ virtual bool visit(EnumValue const&) { return true; }
virtual bool visit(ParameterList const&) { return true; }
virtual bool visit(FunctionDefinition const&) { return true; }
virtual bool visit(VariableDeclaration const&) { return true; }
@@ -181,7 +181,7 @@ public:
virtual void endVisit(InheritanceSpecifier const&) { }
virtual void endVisit(StructDefinition const&) { }
virtual void endVisit(EnumDefinition const&) { }
- virtual void endVisit(EnumvValue const&) { }
+ virtual void endVisit(EnumValue const&) { }
virtual void endVisit(ParameterList const&) { }
virtual void endVisit(FunctionDefinition const&) { }
virtual void endVisit(VariableDeclaration const&) { }
diff --git a/AST_accept.h b/AST_accept.h
index e6877d93..b71e103d 100644
--- a/AST_accept.h
+++ b/AST_accept.h
@@ -121,13 +121,13 @@ void EnumDefinition::accept(ASTConstVisitor& _visitor) const
_visitor.endVisit(*this);
}
-void EnumvValue::accept(ASTVisitor& _visitor)
+void EnumValue::accept(ASTVisitor& _visitor)
{
_visitor.visit(*this);
_visitor.endVisit(*this);
}
-void EnumvValue::accept(ASTConstVisitor& _visitor) const
+void EnumValue::accept(ASTConstVisitor& _visitor) const
{
_visitor.visit(*this);
_visitor.endVisit(*this);
diff --git a/Parser.cpp b/Parser.cpp
index 3e077261..28339a46 100644
--- a/Parser.cpp
+++ b/Parser.cpp
@@ -266,12 +266,12 @@ ASTPointer<StructDefinition> Parser::parseStructDefinition()
return nodeFactory.createNode<StructDefinition>(name, members);
}
-ASTPointer<EnumvValue> Parser::parseEnumDeclaration()
+ASTPointer<EnumValue> Parser::parseEnumDeclaration()
{
ASTNodeFactory nodeFactory(*this);
ASTPointer<ASTString> name = expectIdentifierToken();
nodeFactory.markEndPosition();
- return nodeFactory.createNode<EnumvValue>(name);
+ return nodeFactory.createNode<EnumValue>(name);
}
ASTPointer<EnumDefinition> Parser::parseEnumDefinition()
@@ -279,7 +279,7 @@ ASTPointer<EnumDefinition> Parser::parseEnumDefinition()
ASTNodeFactory nodeFactory(*this);
expectToken(Token::Enum);
ASTPointer<ASTString> name = expectIdentifierToken();
- vector<ASTPointer<EnumvValue>> members;
+ vector<ASTPointer<EnumValue>> members;
expectToken(Token::LBrace);
while (m_scanner->getCurrentToken() != Token::RBrace)
diff --git a/Parser.h b/Parser.h
index 44b14da0..172b45dd 100644
--- a/Parser.h
+++ b/Parser.h
@@ -62,7 +62,7 @@ private:
ASTPointer<FunctionDefinition> parseFunctionDefinition(ASTString const* _contractName);
ASTPointer<StructDefinition> parseStructDefinition();
ASTPointer<EnumDefinition> parseEnumDefinition();
- ASTPointer<EnumvValue> parseEnumDeclaration();
+ ASTPointer<EnumValue> parseEnumDeclaration();
ASTPointer<VariableDeclaration> parseVariableDeclaration(VarDeclParserOptions const& _options = VarDeclParserOptions());
ASTPointer<ModifierDefinition> parseModifierDefinition();
ASTPointer<EventDefinition> parseEventDefinition();
diff --git a/Types.cpp b/Types.cpp
index df62773a..06c0af32 100644
--- a/Types.cpp
+++ b/Types.cpp
@@ -952,7 +952,7 @@ MemberList const& TypeType::getMembers() const
else if (m_actualType->getCategory() == Category::Enum)
{
EnumDefinition const& enumDef = dynamic_cast<EnumType const&>(*m_actualType).getEnumDefinition();
- for (ASTPointer<EnumvValue> const& enumValue: enumDef.getMembers())
+ for (ASTPointer<EnumValue> const& enumValue: enumDef.getMembers())
members.insert(make_pair(enumValue->getName(), make_shared<EnumType>(enumDef)));
m_members.reset(new MemberList(members));
}