Skip to content

Commit

Permalink
Remove Proposal alias
Browse files Browse the repository at this point in the history
  • Loading branch information
jridgewell committed Aug 16, 2021
1 parent a818759 commit 9da61e2
Show file tree
Hide file tree
Showing 9 changed files with 2 additions and 307 deletions.
4 changes: 0 additions & 4 deletions packages/babel-traverse/src/path/generated/asserts.ts
Expand Up @@ -416,7 +416,6 @@ export interface NodePathAssetions {
assertPrivateName(opts?: object): asserts this is NodePath<t.PrivateName>;
assertProgram(opts?: object): asserts this is NodePath<t.Program>;
assertProperty(opts?: object): asserts this is NodePath<t.Property>;
assertProposal(opts?: object): asserts this is NodePath<t.Proposal>;
assertPureish(opts?: object): asserts this is NodePath<t.Pureish>;
assertQualifiedTypeIdentifier(
opts?: object,
Expand All @@ -440,9 +439,6 @@ export interface NodePathAssetions {
opts?: object,
): asserts this is NodePath<t.SpreadProperty>;
assertStandardized(opts?: object): asserts this is NodePath<t.Standardized>;
assertStandardizedOrProposal(
opts?: object,
): asserts this is NodePath<t.StandardizedOrProposal>;
assertStatement(opts?: object): asserts this is NodePath<t.Statement>;
assertStaticBlock(opts?: object): asserts this is NodePath<t.StaticBlock>;
assertStringLiteral(opts?: object): asserts this is NodePath<t.StringLiteral>;
Expand Down
4 changes: 0 additions & 4 deletions packages/babel-traverse/src/path/generated/validators.ts
Expand Up @@ -261,7 +261,6 @@ export interface NodePathValidators {
isPrivateName(opts?: object): this is NodePath<t.PrivateName>;
isProgram(opts?: object): this is NodePath<t.Program>;
isProperty(opts?: object): this is NodePath<t.Property>;
isProposal(opts?: object): this is NodePath<t.Proposal>;
isPureish(opts?: object): this is NodePath<t.Pureish>;
isQualifiedTypeIdentifier(
opts?: object,
Expand All @@ -277,9 +276,6 @@ export interface NodePathValidators {
isSpreadElement(opts?: object): this is NodePath<t.SpreadElement>;
isSpreadProperty(opts?: object): this is NodePath<t.SpreadProperty>;
isStandardized(opts?: object): this is NodePath<t.Standardized>;
isStandardizedOrProposal(
opts?: object,
): this is NodePath<t.StandardizedOrProposal>;
isStatement(opts?: object): this is NodePath<t.Statement>;
isStaticBlock(opts?: object): this is NodePath<t.StaticBlock>;
isStringLiteral(opts?: object): this is NodePath<t.StringLiteral>;
Expand Down
4 changes: 0 additions & 4 deletions packages/babel-types/scripts/generators/docs.js
Expand Up @@ -231,16 +231,12 @@ const aliasDescriptions = {
"A cover of [BindingPattern](https://tc39.es/ecma262/#prod-BindingPattern)s. ",
Private: "A cover of private class elements and private identifiers.",
Property: "A cover of object properties and class properties.",
Proposal:
"A cover of AST nodes which are proprosed for inclusion in ECMAScript.",
Pureish:
"A cover of AST nodes which do not have side-effects. In other words, there is no observable behaviour changes if they are evaluated more than once.",
Scopable:
"A cover of [FunctionParent](#functionparent) and [BlockParent](#blockparent).",
Standardized:
"A cover of AST nodes which are part of an official ECMAScript specification.",
StandardizedOrProposal:
"A cover of AST nodes which are part of an official ECMAScript specification or a proposed for inclusion.",
Statement:
"A cover of any [Statement](https://tc39.es/ecma262/#prod-Statement)s.",
TSBaseType: "A cover of primary TypeScript type annotations.",
Expand Down
12 changes: 0 additions & 12 deletions packages/babel-types/src/asserts/generated/index.ts
Expand Up @@ -1496,12 +1496,6 @@ export function assertStandardized(
): asserts node is t.Standardized {
assert("Standardized", node, opts);
}
export function assertStandardizedOrProposal(
node: object | null | undefined,
opts?: object | null,
): asserts node is t.StandardizedOrProposal {
assert("StandardizedOrProposal", node, opts);
}
export function assertExpression(
node: object | null | undefined,
opts?: object | null,
Expand Down Expand Up @@ -1760,12 +1754,6 @@ export function assertMiscellaneous(
): asserts node is t.Miscellaneous {
assert("Miscellaneous", node, opts);
}
export function assertProposal(
node: object | null | undefined,
opts?: object | null,
): asserts node is t.Proposal {
assert("Proposal", node, opts);
}
export function assertTypeScript(
node: object | null | undefined,
opts?: object | null,
Expand Down
119 changes: 0 additions & 119 deletions packages/babel-types/src/ast-types/generated/index.ts
Expand Up @@ -2096,107 +2096,6 @@ export type Standardized =
| ClassPrivateProperty
| ClassPrivateMethod
| PrivateName;
export type StandardizedOrProposal =
| ArrayExpression
| AssignmentExpression
| BinaryExpression
| InterpreterDirective
| Directive
| DirectiveLiteral
| BlockStatement
| BreakStatement
| CallExpression
| CatchClause
| ConditionalExpression
| ContinueStatement
| DebuggerStatement
| DoWhileStatement
| EmptyStatement
| ExpressionStatement
| File
| ForInStatement
| ForStatement
| FunctionDeclaration
| FunctionExpression
| Identifier
| IfStatement
| LabeledStatement
| StringLiteral
| NumericLiteral
| NullLiteral
| BooleanLiteral
| RegExpLiteral
| LogicalExpression
| MemberExpression
| NewExpression
| Program
| ObjectExpression
| ObjectMethod
| ObjectProperty
| RestElement
| ReturnStatement
| SequenceExpression
| ParenthesizedExpression
| SwitchCase
| SwitchStatement
| ThisExpression
| ThrowStatement
| TryStatement
| UnaryExpression
| UpdateExpression
| VariableDeclaration
| VariableDeclarator
| WhileStatement
| WithStatement
| AssignmentPattern
| ArrayPattern
| ArrowFunctionExpression
| ClassBody
| ClassExpression
| ClassDeclaration
| ExportAllDeclaration
| ExportDefaultDeclaration
| ExportNamedDeclaration
| ExportSpecifier
| ForOfStatement
| ImportDeclaration
| ImportDefaultSpecifier
| ImportNamespaceSpecifier
| ImportSpecifier
| MetaProperty
| ClassMethod
| ObjectPattern
| SpreadElement
| Super
| TaggedTemplateExpression
| TemplateElement
| TemplateLiteral
| YieldExpression
| AwaitExpression
| Import
| BigIntLiteral
| ExportNamespaceSpecifier
| OptionalMemberExpression
| OptionalCallExpression
| ClassProperty
| ClassPrivateProperty
| ClassPrivateMethod
| PrivateName
| ArgumentPlaceholder
| BindExpression
| ImportAttribute
| Decorator
| DoExpression
| ExportDefaultSpecifier
| RecordExpression
| TupleExpression
| DecimalLiteral
| StaticBlock
| ModuleExpression
| TopicReference
| PipelineTopicExpression
| PipelineBareFunction
| PipelinePrimaryTopicReference;
export type Expression =
| ArrayExpression
| AssignmentExpression
Expand Down Expand Up @@ -2631,22 +2530,6 @@ export type JSX =
| JSXOpeningFragment
| JSXClosingFragment;
export type Miscellaneous = Noop | Placeholder | V8IntrinsicIdentifier;
export type Proposal =
| ArgumentPlaceholder
| BindExpression
| ImportAttribute
| Decorator
| DoExpression
| ExportDefaultSpecifier
| RecordExpression
| TupleExpression
| DecimalLiteral
| StaticBlock
| ModuleExpression
| TopicReference
| PipelineTopicExpression
| PipelineBareFunction
| PipelinePrimaryTopicReference;
export type TypeScript =
| TSParameterProperty
| TSDeclareFunction
Expand Down Expand Up @@ -2772,7 +2655,6 @@ export type TSBaseType =

export interface Aliases {
Standardized: Standardized;
StandardizedOrProposal: StandardizedOrProposal;
Expression: Expression;
Binary: Binary;
Scopable: Scopable;
Expand Down Expand Up @@ -2816,7 +2698,6 @@ export interface Aliases {
EnumMember: EnumMember;
JSX: JSX;
Miscellaneous: Miscellaneous;
Proposal: Proposal;
TypeScript: TypeScript;
TSTypeElement: TSTypeElement;
TSType: TSType;
Expand Down
3 changes: 0 additions & 3 deletions packages/babel-types/src/constants/generated/index.ts
Expand Up @@ -5,8 +5,6 @@
import { FLIPPED_ALIAS_KEYS } from "../../definitions";

export const STANDARDIZED_TYPES = FLIPPED_ALIAS_KEYS["Standardized"];
export const STANDARDIZEDORPROPOSAL_TYPES =
FLIPPED_ALIAS_KEYS["StandardizedOrProposal"];
export const EXPRESSION_TYPES = FLIPPED_ALIAS_KEYS["Expression"];
export const BINARY_TYPES = FLIPPED_ALIAS_KEYS["Binary"];
export const SCOPABLE_TYPES = FLIPPED_ALIAS_KEYS["Scopable"];
Expand Down Expand Up @@ -52,7 +50,6 @@ export const ENUMBODY_TYPES = FLIPPED_ALIAS_KEYS["EnumBody"];
export const ENUMMEMBER_TYPES = FLIPPED_ALIAS_KEYS["EnumMember"];
export const JSX_TYPES = FLIPPED_ALIAS_KEYS["JSX"];
export const MISCELLANEOUS_TYPES = FLIPPED_ALIAS_KEYS["Miscellaneous"];
export const PROPOSAL_TYPES = FLIPPED_ALIAS_KEYS["Proposal"];
export const TYPESCRIPT_TYPES = FLIPPED_ALIAS_KEYS["TypeScript"];
export const TSTYPEELEMENT_TYPES = FLIPPED_ALIAS_KEYS["TSTypeElement"];
export const TSTYPE_TYPES = FLIPPED_ALIAS_KEYS["TSType"];
Expand Down
2 changes: 1 addition & 1 deletion packages/babel-types/src/definitions/core.ts
Expand Up @@ -23,7 +23,7 @@ import {
validateOptional,
} from "./utils";

const defineType = defineAliasedType("Standardized", "StandardizedOrProposal");
const defineType = defineAliasedType("Standardized");

defineType("ArrayExpression", {
fields: {
Expand Down
5 changes: 1 addition & 4 deletions packages/babel-types/src/definitions/experimental.ts
@@ -1,13 +1,10 @@
import {
defineAliasedType,
import defineType, {
assertEach,
assertNodeType,
assertValueType,
chain,
} from "./utils";

const defineType = defineAliasedType("Proposal", "StandardizedOrProposal");

defineType("ArgumentPlaceholder", {});

defineType("BindExpression", {
Expand Down

0 comments on commit 9da61e2

Please sign in to comment.