Skip to content

Commit

Permalink
refactor: split ast-related code
Browse files Browse the repository at this point in the history
  • Loading branch information
verytactical committed Jan 14, 2025
1 parent e9b6874 commit b87288f
Show file tree
Hide file tree
Showing 9 changed files with 5 additions and 5 deletions.
File renamed without changes.
File renamed without changes.
2 changes: 1 addition & 1 deletion src/grammar/compare.ts → src/ast/compare.ts
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ import {
AstAsmInstruction,
AstDestructMapping,
AstStatementDestruct,
} from "./ast";
} from "../ast/ast";
import { AstRenamer } from "./rename";
import { throwInternalCompilerError } from "../error/errors";
import JSONbig from "json-bigint";
Expand Down
2 changes: 1 addition & 1 deletion src/grammar/ast-typed.ts → src/ast/getAstSchema.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

import { Loc } from "@tonstudio/parser-runtime";
import * as A from "./ast";
import { SrcInfo } from "./src-info";
import { SrcInfo } from "../grammar/src-info";

export const getAstSchema = (
factory: A.FactoryAst,
Expand Down
File renamed without changes.
File renamed without changes.
4 changes: 2 additions & 2 deletions src/grammar/rename.ts → src/ast/rename.ts
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ import {
AstConstantDecl,
AstNode,
AstFunctionAttribute,
} from "./ast";
} from "../ast/ast";
import { AstSorter } from "./sort";
import { AstHasher, AstHash } from "./hash";
import { AstHasher, AstHash } from "../ast/hash";
import { dummySrcInfo } from "./src-info";

type GivenName = string;
Expand Down
File renamed without changes.
2 changes: 1 addition & 1 deletion src/grammar/store.ts → src/context/store.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import {
AstNativeFunctionDecl,
AstTypeDecl,
AstAsmFunctionDef,
} from "./ast";
} from "../ast/ast";
import { throwInternalCompilerError } from "../error/errors";
import { CompilerContext, createContextStore } from "../context/context";
import { ItemOrigin } from "./src-info";
Expand Down

0 comments on commit b87288f

Please sign in to comment.