Skip to content

Commit e8b4021

Browse files
committed
Update TastyFormat for flexible types
1 parent 1b28f83 commit e8b4021

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

tasty/src/dotty/tools/tasty/TastyFormat.scala

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,6 +176,7 @@ Standard-Section: "ASTs" TopLevelStat*
176176
ORtype Length left_Type right_Type -- lefgt | right
177177
MATCHtype Length bound_Type sel_Type case_Type* -- sel match {cases} with optional upper `bound`
178178
MATCHCASEtype Length pat_type rhs_Type -- match cases are MATCHCASEtypes or TYPELAMBDAtypes over MATCHCASEtypes
179+
FLEXIBLEtype Length underlying_Type -- (underlying)?
179180
BIND Length boundName_NameRef bounds_Type Modifier* -- boundName @ bounds, for type-variables defined in a type pattern
180181
BYNAMEtype underlying_Type -- => underlying
181182
PARAMtype Length binder_ASTRef paramNum_Nat -- A reference to parameter # paramNum in lambda type `binder`
@@ -649,7 +650,7 @@ object TastyFormat {
649650
firstNatTreeTag <= tag && tag <= RENAMED ||
650651
firstASTTreeTag <= tag && tag <= BOUNDED ||
651652
firstNatASTTreeTag <= tag && tag <= NAMEDARG ||
652-
firstLengthTreeTag <= tag && tag <= MATCHCASEtype ||
653+
firstLengthTreeTag <= tag && tag <= FLEXIBLEtype ||
653654
tag == HOLE
654655

655656
def isParamTag(tag: Int): Boolean = tag == PARAM || tag == TYPEPARAM
@@ -851,6 +852,7 @@ object TastyFormat {
851852
case MATCHCASEtype => "MATCHCASEtype"
852853
case MATCHtpt => "MATCHtpt"
853854
case PARAMtype => "PARAMtype"
855+
case FLEXIBLEtype => "FLEXIBLEtype"
854856
case ANNOTATION => "ANNOTATION"
855857
case PRIVATEqualified => "PRIVATEqualified"
856858
case PROTECTEDqualified => "PROTECTEDqualified"

0 commit comments

Comments
 (0)