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
rust-mode.el: check for possible space between variable name and type #325
Conversation
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @nikomatsakis (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. |
Err, rather "before" the colon… Let me fix the description in a moment |
Done |
It looks ok. Could you add some tests? edit: it reminded me of something, because of #274 :) |
Sure, done. |
Although, wait a moment, I figured I shouldn't add this test to an existing one, but rather create a separate test. Let me fix this |
Fixes the following problem: consider code fn foo(a: u32, b : u32) {} Here, `b` was not highlighted as a variable, because the regex didn't take into account possible space before the colon. Signed-off-by: Konstantin Kharlamov <Hi-Angel@yandex.ru>
Done |
Sorry, didn't see the edit. That's cool btw, our code changes are pretty similar :) Why did you close it back then? |
because there was no answer, I thought that there was no interest. I will merge once tests pass. |
Well, it's a bugfix after all. They usually are boring, which doesn't make them less useful :) The font-lock-variable-face is important for users of |
I think there's a bug with Travis CI: while this page says lots of builds are queued, but if you click any link in them, for example 422.6, it says it already passed: |
thanks! |
Fixes the following problem: consider code
Here,
b
was not highlighted as a variable, because the regex didn'ttake into account possible space before the colon.
Signed-off-by: Konstantin Kharlamov Hi-Angel@yandex.ru