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

Syntax check rust with -Zno-trans instead of -Zparse-only #72

Closed
wants to merge 2 commits into from
Closed

Syntax check rust with -Zno-trans instead of -Zparse-only #72

wants to merge 2 commits into from

Conversation

faern
Copy link

@faern faern commented Feb 9, 2016

Only parsing missed a lot of errors. This PR changes so more steps of the compile is executed and more errors are found. The solution required some extra code to detect if we are in a standalone rs file or inside a crate since that affected if I could use crate rustc -Zno-trans or rustc -Zno-trans

Fixes #67

@rust-highfive
Copy link

Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @chris-morgan (or someone else) soon.

If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes.

Please see the contribution instructions for more information.

@chris-morgan
Copy link
Member

With anything like this I’m concerned about performance. Even no-trans can take many seconds for larger crates, where parse-only of the current file is universally fast.

@faern
Copy link
Author

faern commented Feb 10, 2016

You are right, this is a problem. On the other hand the linting really need to get better IMO. Do you know if there is any way to run this in the background that will not block the editor?

@somini
Copy link

somini commented Mar 19, 2016

I'm sorry if I'm intruding, but this interests me, as syntax-only linting is pretty poor as @faern said.
I think the best course of action is making the fast behaviour the default, and having this as an option. You can then use syntastic in passive mode for rust files, meaning it will only run on SyntasticCheck. That should diminish the performance problems.

@faern
Copy link
Author

faern commented Mar 20, 2016

@somini Not intruding at all. You could continue on this PR if you would like to. I don't have any time to continue on this as I'm not using vim for Rust any longer.

somini added a commit to somini/rust.vim that referenced this pull request Mar 21, 2016
@somini somini mentioned this pull request Mar 21, 2016
@ticki
Copy link

ticki commented Oct 24, 2016

Any update on this?

@faern
Copy link
Author

faern commented Oct 24, 2016

Nope. I don't use vim any longer so I won't contribute to this. Could close the PR, but not sure if anyone else wanted to continue.

@somini
Copy link

somini commented Oct 30, 2016

I'm tracking this on #76, so you can close this.

@faern faern closed this Oct 31, 2016
@ghost
Copy link

ghost commented Apr 28, 2017

@faern what do you use instead? curious if I would be interested to make the same change :)

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.

None yet

5 participants