Skip to content

Commit

Permalink
refactor: merge duplicate imports (#4669)
Browse files Browse the repository at this point in the history
  • Loading branch information
c0dedance committed Oct 13, 2022
1 parent fec5132 commit 9389609
Show file tree
Hide file tree
Showing 6 changed files with 12 additions and 16 deletions.
6 changes: 2 additions & 4 deletions src/ast/nodes/ArrowFunctionExpression.ts
@@ -1,5 +1,4 @@
import type { InclusionContext } from '../ExecutionContext';
import { type HasEffectsContext } from '../ExecutionContext';
import type { HasEffectsContext, InclusionContext } from '../ExecutionContext';
import type { NodeInteraction } from '../NodeInteractions';
import { INTERACTION_CALLED } from '../NodeInteractions';
import ReturnValueScope from '../scopes/ReturnValueScope';
Expand All @@ -9,8 +8,7 @@ import type BlockStatement from './BlockStatement';
import Identifier from './Identifier';
import type * as NodeType from './NodeType';
import FunctionBase from './shared/FunctionBase';
import type { IncludeChildren } from './shared/Node';
import { type ExpressionNode } from './shared/Node';
import type { ExpressionNode, IncludeChildren } from './shared/Node';
import { ObjectEntity } from './shared/ObjectEntity';
import { OBJECT_PROTOTYPE } from './shared/ObjectPrototype';
import type { PatternNode } from './shared/Pattern';
Expand Down
4 changes: 2 additions & 2 deletions src/ast/nodes/NewExpression.ts
Expand Up @@ -7,8 +7,8 @@ import type { NodeInteraction, NodeInteractionCalled } from '../NodeInteractions
import { INTERACTION_ACCESSED, INTERACTION_CALLED } from '../NodeInteractions';
import { EMPTY_PATH, type ObjectPath, UNKNOWN_PATH } from '../utils/PathTracker';
import type * as NodeType from './NodeType';
import type { IncludeChildren } from './shared/Node';
import { type ExpressionNode, NodeBase } from './shared/Node';
import type { ExpressionNode, IncludeChildren } from './shared/Node';
import { NodeBase } from './shared/Node';

export default class NewExpression extends NodeBase {
declare arguments: ExpressionNode[];
Expand Down
3 changes: 1 addition & 2 deletions src/ast/nodes/TaggedTemplateExpression.ts
Expand Up @@ -13,8 +13,7 @@ import type TemplateLiteral from './TemplateLiteral';
import CallExpressionBase from './shared/CallExpressionBase';
import type { ExpressionEntity } from './shared/Expression';
import { UNKNOWN_EXPRESSION } from './shared/Expression';
import type { IncludeChildren } from './shared/Node';
import { type ExpressionNode } from './shared/Node';
import type { ExpressionNode, IncludeChildren } from './shared/Node';

export default class TaggedTemplateExpression extends CallExpressionBase {
declare quasi: TemplateLiteral;
Expand Down
4 changes: 2 additions & 2 deletions src/ast/nodes/TemplateLiteral.ts
Expand Up @@ -11,8 +11,8 @@ import {
} from '../values';
import type * as NodeType from './NodeType';
import type TemplateElement from './TemplateElement';
import type { ExpressionEntity } from './shared/Expression';
import { type LiteralValueOrUnknown, UNKNOWN_EXPRESSION, UnknownValue } from './shared/Expression';
import type { ExpressionEntity, LiteralValueOrUnknown } from './shared/Expression';
import { UNKNOWN_EXPRESSION, UnknownValue } from './shared/Expression';
import { type ExpressionNode, NodeBase } from './shared/Node';

export default class TemplateLiteral extends NodeBase {
Expand Down
8 changes: 4 additions & 4 deletions src/ast/nodes/shared/FunctionBase.ts
Expand Up @@ -16,14 +16,14 @@ import {
NODE_INTERACTION_UNKNOWN_CALL
} from '../../NodeInteractions';
import type ReturnValueScope from '../../scopes/ReturnValueScope';
import type { PathTracker } from '../../utils/PathTracker';
import { type ObjectPath, UNKNOWN_PATH, UnknownKey } from '../../utils/PathTracker';
import type { ObjectPath, PathTracker } from '../../utils/PathTracker';
import { UNKNOWN_PATH, UnknownKey } from '../../utils/PathTracker';
import BlockStatement from '../BlockStatement';
import * as NodeType from '../NodeType';
import RestElement from '../RestElement';
import type SpreadElement from '../SpreadElement';
import type { LiteralValueOrUnknown } from './Expression';
import { type ExpressionEntity, UNKNOWN_EXPRESSION } from './Expression';
import type { ExpressionEntity, LiteralValueOrUnknown } from './Expression';
import { UNKNOWN_EXPRESSION } from './Expression';
import {
type ExpressionNode,
type GenericEsTreeNode,
Expand Down
3 changes: 1 addition & 2 deletions src/ast/nodes/shared/FunctionNode.ts
Expand Up @@ -2,8 +2,7 @@ import { type HasEffectsContext, type InclusionContext } from '../../ExecutionCo
import type { NodeInteraction, NodeInteractionWithThisArgument } from '../../NodeInteractions';
import { INTERACTION_CALLED } from '../../NodeInteractions';
import FunctionScope from '../../scopes/FunctionScope';
import type { PathTracker } from '../../utils/PathTracker';
import { type ObjectPath } from '../../utils/PathTracker';
import type { ObjectPath, PathTracker } from '../../utils/PathTracker';
import type BlockStatement from '../BlockStatement';
import Identifier, { type IdentifierWithVariable } from '../Identifier';
import { UNKNOWN_EXPRESSION } from './Expression';
Expand Down

0 comments on commit 9389609

Please sign in to comment.