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

feedback on files being processed by build-tools #4283

Open
PierreVDL opened this issue Jan 31, 2017 · 2 comments
Open

feedback on files being processed by build-tools #4283

PierreVDL opened this issue Jan 31, 2017 · 2 comments

Comments

@PierreVDL
Copy link

Calling "stack build" currently doesn't report the files that are being processed by build-tools such as happy and alex.
When multiple files are processed by build-tools,
it is no longer clear to which file the reported errors and/or warnings belong.

Could the files being processed by build-tools be echoed,
such that it becomes clear to which file a message belongs?

To give an example:
I prefer

alex sys/front/TxsAlex.x
alex sys/smt/RegexAlex.x
alex sys/smt/SMTAlex.x
alex sys/smt/SMTStringAlex.x
happy sys/front/TxsHappy.y
unused rules: 4
unused terminals: 3
happy sys/smt/RegexPosixHappy.y
happy sys/smt/RegexSMTHappy.y
shift/reduce conflicts:  15
happy sys/smt/SMTHappy.y
happy sys/smt/SMTStringHappy.y

over the current output

unused rules: 4
unused terminals: 3
shift/reduce conflicts:  15

According to the stack developers (see
commercialhaskell/stack#2843 (comment))
this is a cabal issue!

@ezyang
Copy link
Contributor

ezyang commented Feb 4, 2017

Yes, this should be easy to do by modifying preprocessFile. Hardest thing is deciding exactly what we want output, at what verbosity. Your suggestion is to print just the preprocessor name and file name (NO flags), but this is a bit difficult because the PreProcessor struct doesn't record the name of the preprocessor (nor can we easily add it without breaking Custom setup compatibility.) What if we printed the actual command that was run? Or how about just the filename? (Preprocessing foo/Alex.x)? But maybe this is a bit chatty; perhaps you don't want to see the output if there is no change/output?

@PierreVDL
Copy link
Author

Since, in my case, the output is analyzed automatically, I don't mind a chatty output.
Yet, I can understand that some user only want the actual command that was run in case there was output.
For me, the crucial requirement is to be able to determine to which command the output belongs, when output occurs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants