-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathflychecked-c.el
28 lines (22 loc) · 1.05 KB
/
flychecked-c.el
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
;;; flychecked-c.el --- description -*- lexical-binding: t; -*-
;;; Code:
;; Load this file after emacs has initialized
; Set this var to your clang path
(defvar checked-c-clang "/media/aeline/Extra/checkedc/llvm.obj/bin/clang-8")
(flycheck-define-checker checked-c
"Checker using the checked c compiler"
:command (
"/media/aeline/Extra/checkedc/llvm.obj/bin/clang-8"
"-fsyntax-only"
"-iquote" (eval (flycheck-c/c++-quoted-include-directory))
"-I /media/aeline/Extra/checkedc/llvm.obj/lib/clang/8.0.0/include/"
source)
:error-patterns
((error line-start (file-name) ":" line ":" column ": error: " (message) line-end)
(error line-start (file-name) ":" line ":" column ": fatal error: " (message) line-end)
(warning line-start (file-name) ":" line ":" column ": warning: " (message) line-end)
(warning line-start (file-name) ":" line ":" column ": note: " (message) line-end)
)
:modes c-mode)
(add-to-list 'flycheck-checkers 'checked-c)
(flycheck-add-next-checker 'c/c++-clang 'checked-c)