Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add stdin mode #8

Merged
merged 1 commit into from
May 15, 2023
Merged

Add stdin mode #8

merged 1 commit into from
May 15, 2023

Conversation

nobu
Copy link
Member

@nobu nobu commented May 13, 2023

When - is given as grammar file name, reads the grammar source from STDIN, and takes the next argument as the input file name. This mode helps pre-process a grammar source.

When `-` is given as grammar file name, reads the grammar source from
STDIN, and takes the next argument as the input file name.  This mode
helps pre-process a grammar source.
@yui-knk
Copy link
Collaborator

yui-knk commented May 15, 2023

Context: Current ruby/ruby build process is:

(1) line 927: Preprocess generates "parse.tmp.y" from "parse.c" by "tool/id2token.rb".
(2) line 928: Generate "y.tab.c" from "parse.tmp.y" by parser generator.
(3) line 930 & 932: Change file names in comments because temporal file name is used.

By this PR, we only need to pass preprocessed result to lrama command.

@yui-knk yui-knk merged commit 50642eb into ruby:master May 15, 2023
@nobu nobu deleted the stdin-mode branch May 15, 2023 11:43
alitaso345 added a commit to alitaso345/lrama that referenced this pull request Jun 22, 2023
There are the tests corresponding to the following implementation ruby#8
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants