aboutsummaryrefslogtreecommitdiffstats
path: root/Types.cpp
diff options
context:
space:
mode:
authorLefteris Karapetsas <lefteris@refu.co>2015-02-12 04:40:47 +0800
committerLefteris Karapetsas <lefteris@refu.co>2015-02-14 06:16:14 +0800
commita989f6f97a9fd5615500e561f51b5c160df08183 (patch)
tree5e0b016b71aa9cbbefd9e89aa8436e0fb3f7675c /Types.cpp
parent931e96838a433b3634ae7ab3347f7650cd78003d (diff)
downloaddexon-solidity-a989f6f97a9fd5615500e561f51b5c160df08183.tar.gz
dexon-solidity-a989f6f97a9fd5615500e561f51b5c160df08183.tar.zst
dexon-solidity-a989f6f97a9fd5615500e561f51b5c160df08183.zip
Enums NameAndTypeResolution - WIP
- Also adding an EndToEnd enum test
Diffstat (limited to 'Types.cpp')
-rw-r--r--Types.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/Types.cpp b/Types.cpp
index 6b6a70c2..418d6b17 100644
--- a/Types.cpp
+++ b/Types.cpp
@@ -74,6 +74,8 @@ TypePointer Type::fromUserDefinedTypeName(UserDefinedTypeName const& _typeName)
Declaration const* declaration = _typeName.getReferencedDeclaration();
if (StructDefinition const* structDef = dynamic_cast<StructDefinition const*>(declaration))
return make_shared<StructType>(*structDef);
+ else if (EnumDefinition const* enumDef = dynamic_cast<EnumDefinition const*>(declaration))
+ return make_shared<EnumType>(*enumDef);
else if (FunctionDefinition const* function = dynamic_cast<FunctionDefinition const*>(declaration))
return make_shared<FunctionType>(*function);
else if (ContractDefinition const* contract = dynamic_cast<ContractDefinition const*>(declaration))