summaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2017-08-10Add syntax coloring for type-inferred constants and variablesPer Nordlöw
2017-08-05Merge pull request #220 from Aankhen/highlight-string-interpolationTom Tromey
Highlight interpolation in arguments to print! &c.
2017-08-04Merge pull request #224 from tromey/beginning-of-defunTom Tromey
Make rust-beginning-of-defun ignore comments and strings
2017-08-02Make rust-beginning-of-defun ignore comments and stringsTom Tromey
Change rust-beginning-of-defun to keep searching when it stops in a comment or a string. Fixes #222.
2017-08-02Highlight interpolation in arguments to print! &c.Aankhen
2017-08-01Merge pull request #221 from Wilfred/highlight_union_contextual_keywordTom Tromey
Add syntax highlighting and imenu support for `union`
2017-07-30Add syntax highlighting and imenu support for `union`Wilfred Hughes
`union` is a contextual keyword, so highlight it in the correct context. Otherwise, treat `union` similarly to `struct`.
2017-07-28Merge pull request #219 from Aankhen/highlight-question-markTom Tromey
Highlight question mark operator using new `rust-question-mark-face'
2017-07-28Highlight question mark operator using new `rust-question-mark-face'.Aankhen
2017-07-19Merge pull request #217 from Aankhen/add-clippy-commandTom Tromey
Add `rust-run-clippy' and `rust-buffer-project' with testing paraphernalia
2017-07-16Improve content of `test-project/Cargo.toml'.Aankhen
2017-07-13Define `rust-test-project-located' conditionally instead of using `skip-unless'.Aankhen
2017-07-13Skip `rust-test-project-located' without cargo and avoid `find-file' in test.Aankhen
2017-07-13Add `rust-cargo-bin' custom variable.Aankhen
2017-07-13Declare `rust-buffer-project' and require `json' at runtime.Aankhen
2017-07-13Require `json'.Aankhen
2017-07-13Add `rust-run-clippy' and `rust-buffer-project' with testing paraphernalia.Aankhen
2017-07-12Merge pull request #216 from Aankhen/set-compile-commandNiko Matsakis
Set `compile-command' in `rust-mode'
2017-06-26Set `compile-command' in `rust-mode'.Aankhen
2017-06-06Merge pull request #213 from KeenS/restore-pointsTom Tromey
restore points even when an error occurs
2017-06-06restore points when an error occurs tooSunrin SHIMURA (keen)
2017-05-31Merge pull request #206 from cjhowe7/masterTom Tromey
Allow formatting with long lines (fixes #186)
2017-05-31Address review commentsChristian Howe
2017-05-14Merge pull request #209 from tromey/default-keywordTom Tromey
Add support for "default" keyword
2017-05-06Add support for "default" keywordTom Tromey
Add context-sensitive fontification for the "default" keyword.
2017-04-23Fix stupid mistake in rustfmt conditionalChristian Howe
2017-04-21Remove unnecessary debugging messageChristian Howe
2017-04-18Add stderr output from rustfmt on exit code 3Christian Howe
2017-04-18Allow formatting with long linesChristian Howe
2017-04-11Merge pull request #198 from tromey/indentation-fixTom Tromey
fix rust indentation bug
2017-04-11fix rust indentation bugTom Tromey
This patch fixes a bug I found where rust-mode would misindent code like: fn each_split_within<'a, F>(ss: &'a str, lim: usize, mut it: F) -> bool where F: FnMut(&'a str) -> bool { } fn test_split_within() { } In particular the second "fn" would be indented a level. On the "fn" line, rust-mode-indent-line was calling rust-beginning-of-defun, which would go to the previous defun. Fixing this required moving the definition of rust-top-item-beg-re higher in the file, before its first use (recent versions of Emacs insist on this). And, this required removing the "^" from this regexp, which is ok because the sole use is already adding a "^". Additionally, I moved the "\\_>" into the regexp, rather than have it added at the point of use, so that the new use would also benefit. This patch includes two new test cases.
2017-04-11Merge pull request #201 from tromey/question-indentationNiko Matsakis
fix syntax of "<" appearing after "?"
2017-04-11Merge pull request #197 from tromey/syntax-propertizeNiko Matsakis
Syntax propertize
2017-04-11Merge pull request #172 from nokaa/masterNiko Matsakis
Add info to enable rustfmt
2017-04-11mention keybinding for rustfmtNiko Matsakis
2017-04-05fix syntax of "<" appearing after "?"Tom Tromey
The "<" syntax-setting code could be confused after a "?". This patch changes the code to treat "?" as an "ambiguous operator" and adjust according to further context. Fixes #200
2017-04-05Merge pull request #199 from tromey/open-paren-in-column-0Niko Matsakis
set open-paren-in-column-0-is-defun-start to nil
2017-03-19set open-paren-in-column-0-is-defun-start to nilTom Tromey
Set open-paren-in-column-0-is-defun-start to nil in rust-mode. This setting is a performance hack in Emacs, at the expense of correctness in some cases. However, due to the syntax-ppss cache, I doubt whether this hack is needed for Rust code. Fixes #107
2017-03-15Use syntax-propertize-function, not font-lock-syntactic-keywordsTom Tromey
font-lock-syntactic-keywords have been obsolete since Emacs 24.1, the earliest version supported by rust-mode. Instead, modes are encouraged to use syntax-propertize-function. syntax-propertize-function provides a generally better experience. Syntax propertization is not tied to font lock,so angle bracket matching will still work when font-lock is disabled. There's no longer a need to call font-lock-fontify-buffer or font-lock-ensure (you can see this in the tests). The resulting code is also shorter. I removed a few tests: * font-lock-raw-string-constant was written assuming font-lock based syntax propertization, but that's no longer the case. * font-lock-extend-region-in-string and rust-test-revert-hook-preserves-point both called functions that no longer exist. There's a fix for a hidden bug in rust-is-in-expression-context. This previously could signal in some situations, but the signal was hidden by font-lock. It was visible now when running tests, hence the new call to condition-case. I suspect this might fix #192, but I haven't tried it.
2017-03-14Don't use "&optional &rest"Tom Tromey
rust-mode-tests.el uses "&optional &rest" in some function signatures. This was never really correct, and newer versions of Emacs complain about it. &rest implies &optional, so removing &optional is all that is needed.
2017-01-17Merge pull request #190 from mrBliss/imenu-externNiko Matsakis
Recognize "extern" imenu items
2017-01-17Merge pull request #191 from Wooble/readme_linkFelix S Klock II
fix PR link in README
2017-01-12fix PR link in READMEGeoffrey Spear
2017-01-12Recognize "extern" imenu itemsmrBliss
Fixes #188.
2017-01-07Merge pull request #180 from MicahChalmer/melpa-stable-readmeNiko Matsakis
Add instructions for version tag update requests
2017-01-07Merge pull request #175 from mrBliss/imenu-unsafeNiko Matsakis
Recognize imenu items starting with "unsafe"
2017-01-07Merge pull request #187 from tspiteri/format-other-buffersNiko Matsakis
handle indirect buffers and multiple windows in rust-format-buffer
2017-01-07Merge pull request #189 from froydnj/minor-cleanupsNiko Matsakis
minor cleanups: https links and defcustom grouping
2017-01-06convert http links into https linksNathan Froyd
2017-01-06put remaining defcustoms into the rust-mode groupNathan Froyd