Flow opaque type aliases (#5990)
This commit is contained in:
@@ -88,6 +88,14 @@ defineType("DeclareTypeAlias", {
|
||||
},
|
||||
});
|
||||
|
||||
defineType("DeclareOpaqueType", {
|
||||
visitor: ["id", "typeParameters", "supertype"],
|
||||
aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"],
|
||||
fields: {
|
||||
// todo
|
||||
},
|
||||
});
|
||||
|
||||
defineType("DeclareVariable", {
|
||||
visitor: ["id"],
|
||||
aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"],
|
||||
@@ -252,6 +260,14 @@ defineType("TypeAlias", {
|
||||
},
|
||||
});
|
||||
|
||||
defineType("OpaqueType", {
|
||||
visitor: ["id", "typeParameters", "supertype", "impltype"],
|
||||
aliases: ["Flow", "FlowDeclaration", "Statement", "Declaration"],
|
||||
fields: {
|
||||
// todo
|
||||
},
|
||||
});
|
||||
|
||||
defineType("TypeCastExpression", {
|
||||
visitor: ["expression", "typeAnnotation"],
|
||||
aliases: ["Flow", "ExpressionWrapper", "Expression"],
|
||||
|
||||
@@ -70,6 +70,7 @@ getBindingIdentifiers.keys = {
|
||||
DeclareVariable: ["id"],
|
||||
InterfaceDeclaration: ["id"],
|
||||
TypeAlias: ["id"],
|
||||
OpaqueType: ["id"],
|
||||
|
||||
CatchClause: ["param"],
|
||||
LabeledStatement: ["label"],
|
||||
|
||||
Reference in New Issue
Block a user