Skip to content

Commit

Permalink
fix: avoid non-relative self-import
Browse files Browse the repository at this point in the history
Closes: #210
  • Loading branch information
wincent committed Aug 26, 2023
1 parent 71f55d7 commit 85989c8
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
4 changes: 2 additions & 2 deletions packages/graphql/src/parseDocument.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
// @ts-nocheck
/**
* vim: set nomodifiable : DO NOT EDIT - edit "build.ts", run "make parser" instead
* vim: set nomodifiable : DO NOT EDIT - edit "build.ts", run "make graphql" instead
*
* @generated
*/
import {Lexer} from '@masochist/graphql';
import {Token} from '@masochist/lexer';
import {Lexer} from './lex';
/**
* r0: no production
*/
Expand Down
4 changes: 2 additions & 2 deletions packages/graphql/src/parseSchema.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
// @ts-nocheck
/**
* vim: set nomodifiable : DO NOT EDIT - edit "build.ts", run "make parser" instead
* vim: set nomodifiable : DO NOT EDIT - edit "build.ts", run "make graphql" instead
*
* @generated
*/
import {Lexer} from '@masochist/graphql';
import {Token} from '@masochist/lexer';
import {Lexer} from './lex';
/**
* r0: no production
*/
Expand Down
3 changes: 2 additions & 1 deletion packages/parser/src/build.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,9 @@ export default function build(
'',
'@generated',
),
ast.import('{Lexer}', '@masochist/graphql'),
ast.import('{Token}', '@masochist/lexer'),
// TODO: don't assume lexer is written to lex.ts
ast.import('{Lexer}', './lex'),
...grammar.rules.map((rule, i): Statement => {
if (rule.action && rule.action !== '') {
stats['semanticActions']++;
Expand Down

0 comments on commit 85989c8

Please sign in to comment.