diff options
| author | Felix S Klock II <pnkfelix@pnkfx.org> | 2015-05-18 14:37:59 +0200 |
|---|---|---|
| committer | Felix S Klock II <pnkfelix@pnkfx.org> | 2015-05-18 14:37:59 +0200 |
| commit | 4e938b13b944ce14ca287eb05bde013f7dde1b9d (patch) | |
| tree | 6ee3b9683e450b1fb1ef1177ebd3a06bfe6213fe | |
| parent | 78e8b085dfcb5e4d3aaa81d8c796b14898b43e00 (diff) | |
| parent | f17e11ac890bcc8b91cf79e9b4dda66d5d9b97d6 (diff) | |
| download | rust-mode-4e938b13b944ce14ca287eb05bde013f7dde1b9d.tar.gz | |
Merge pull request #63 from krig/panic-compilation-warning
Match panics during build as compilation warnings
| -rw-r--r-- | rust-mode.el | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/rust-mode.el b/rust-mode.el index 948cc0e..d15dee4 100644 --- a/rust-mode.el +++ b/rust-mode.el @@ -752,11 +752,21 @@ This is written mainly to be used as `end-of-defun-function' for Rust." "Specifications for matching errors in rustc invocations. See `compilation-error-regexp-alist for help on their format.") +;; Match test run failures and panics during compilation as +;; compilation warnings +(defvar cargo-compilation-regexps + '("^\\s-+thread '[^']+' panicked at \\('[^']+', \\([^:]+\\):\\([0-9]+\\)\\)" 2 3 nil nil 1) + "Specifications for matching panics in cargo test invocations. +See `compilation-error-regexp-alist for help on their format.") + (eval-after-load 'compile '(progn (add-to-list 'compilation-error-regexp-alist-alist (cons 'rustc rustc-compilation-regexps)) - (add-to-list 'compilation-error-regexp-alist 'rustc))) + (add-to-list 'compilation-error-regexp-alist 'rustc) + (add-to-list 'compilation-error-regexp-alist-alist + (cons 'cargo cargo-compilation-regexps)) + (add-to-list 'compilation-error-regexp-alist 'cargo))) ;;; Functions to submit (parts of) buffers to the rust playpen, for ;;; sharing. |
