Serialization: Don't serialize contextual enum argument type

Storing this separately is unnecessary since we already
serialize the enum element's interface type. Also, this
eliminates one of the few remaining cases where we serialize
archetypes during AST serialization.
This commit is contained in:
Slava Pestov
2017-01-29 23:53:39 -08:00
parent 00bceec613
commit dca292c652
33 changed files with 102 additions and 97 deletions

View File

@@ -2694,8 +2694,8 @@ public:
setClangDeclKeywords(EED, Pairs, Builder);
addLeadingDot(Builder);
Builder.addTextChunk(EED->getName().str());
if (EED->hasArgumentType())
addPatternFromType(Builder, EED->getArgumentType());
if (auto argTy = EED->getArgumentInterfaceType())
addPatternFromType(Builder, argTy);
// Enum element is of function type such as EnumName.type -> Int ->
// EnumName; however we should show Int -> EnumName as the type