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

Fix linenumbers when using @q with macro calls #108

Closed
wants to merge 4 commits into from

Conversation

cstjean
Copy link
Collaborator

@cstjean cstjean commented Dec 13, 2018

Fix #107 by replacing the :macrocall line-number argument with nothing. I haven't read anywhere that this is Acceptable, but it seems to work.

@MikeInnes
Copy link
Member

Do you have a case where the current behaviour is a problem? I'm a bit wary of this given that macros are probably not expecting it in general.

@cstjean
Copy link
Collaborator Author

cstjean commented Dec 13, 2018

I @macroexpand1 a macro call that expands into other macro calls, and the line numbers are an eyesore.

I'm a bit wary of this given that macros are probably not expecting it in general.

Yeah, that's reasonable. We can leave the PR open until a more compelling use case comes up.

@Gnimuc
Copy link

Gnimuc commented Dec 14, 2018

I also hit this a while ago: https://stackoverflow.com/questions/53274001

It looks currently there is no elegant solution to strip line-number-node in macrocalls.

@cstjean
Copy link
Collaborator Author

cstjean commented Dec 14, 2018

FWIW, Jameson said on Slack that accepting nothing was intentional; “be liberal in what you accept, conservative in what you produce”.

EDIT: uh, that quote doesn't work in this PR's favor, does it.

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.

@q doesn't work with macros
3 participants