Skip to content

Commit 8af4b14

Browse files
committed
Replace tabs with 8-spaces to make upcoming commits easier to grok
1 parent bc87db1 commit 8af4b14

File tree

1 file changed

+45
-45
lines changed

1 file changed

+45
-45
lines changed

solidity-flycheck.el

Lines changed: 45 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -74,15 +74,15 @@ Possible values are:
7474
:package-version '(solidity . "0.1.5"))
7575

7676
(flycheck-def-option-var flycheck-solidity-solium-soliumrcfile nil solium-check
77-
"The path to use for soliumrc.json
77+
"The path to use for soliumrc.json
7878
7979
The value of this variable is either a string denoting a path to the soliumrc.json
8080
or nil, to use the current directory. When non-nil,
8181
we pass the directory to solium via the `--config' option."
82-
:type '(choice (const :tag "No custom soliumrc" nil)
83-
(string :tag "Custom soliumrc file location"))
84-
:safe #'stringp
85-
:package-version '(solidity-mode . "0.1.4"))
82+
:type '(choice (const :tag "No custom soliumrc" nil)
83+
(string :tag "Custom soliumrc file location"))
84+
:safe #'stringp
85+
:package-version '(solidity-mode . "0.1.4"))
8686

8787
;; add a solidity mode callback to set the executable of solc for flycheck
8888
;; define solidity's flycheck syntax checker
@@ -105,60 +105,60 @@ we pass the directory to solium via the `--config' option."
105105
(progn
106106
(flycheck-def-executable-var solidity-checker "solc")
107107
(flycheck-define-command-checker 'solidity-checker "A Solidity syntax checker using the solc compiler" :command
108-
'("solc" source-inplace)
109-
:error-patterns
110-
'((error line-start
111-
(file-name)
112-
":" line ":" column ":" " Error: "
113-
(message))
114-
(error line-start "Error: "
115-
(message))
116-
(warning line-start
117-
(file-name)
118-
":" line ":" column ":" " Warning: "
119-
(message)))
120-
:modes 'solidity-mode :predicate
121-
#'(lambda nil
122-
(eq major-mode 'solidity-mode))
123-
:next-checkers
124-
`((,solidity-flycheck-chaining-error-level . solium-checker))
125-
:standard-input 'nil :working-directory 'nil))
108+
'("solc" source-inplace)
109+
:error-patterns
110+
'((error line-start
111+
(file-name)
112+
":" line ":" column ":" " Error: "
113+
(message))
114+
(error line-start "Error: "
115+
(message))
116+
(warning line-start
117+
(file-name)
118+
":" line ":" column ":" " Warning: "
119+
(message)))
120+
:modes 'solidity-mode :predicate
121+
#'(lambda nil
122+
(eq major-mode 'solidity-mode))
123+
:next-checkers
124+
`((,solidity-flycheck-chaining-error-level . solium-checker))
125+
:standard-input 'nil :working-directory 'nil))
126126

127127
;; define solium flycheck syntax checker
128128
(flycheck-define-checker solium-checker
129-
"A Solidity linter using solium"
130-
:command ("solium"
131-
(option "--config=" flycheck-solidity-solium-soliumrcfile concat)
132-
"-f"
133-
source-inplace)
134-
:error-patterns
135-
((error line-start (zero-or-more " ") line ":" column (zero-or-more " ") "error" (message))
136-
(error line-start (zero-or-more not-newline) "[Fatal error]" (message))
137-
(warning line-start (zero-or-more " ") line ":" column (zero-or-more " ") "warning" (message)))
138-
:error-filter
139-
;; Add fake line numbers if they are missing in the lint output
140-
(lambda (errors)
141-
(dolist (err errors)
142-
(unless (flycheck-error-line err)
143-
(setf (flycheck-error-line err) 1)))
144-
errors)
145-
:modes solidity-mode
146-
:predicate (lambda () (eq major-mode 'solidity-mode)))
129+
"A Solidity linter using solium"
130+
:command ("solium"
131+
(option "--config=" flycheck-solidity-solium-soliumrcfile concat)
132+
"-f"
133+
source-inplace)
134+
:error-patterns
135+
((error line-start (zero-or-more " ") line ":" column (zero-or-more " ") "error" (message))
136+
(error line-start (zero-or-more not-newline) "[Fatal error]" (message))
137+
(warning line-start (zero-or-more " ") line ":" column (zero-or-more " ") "warning" (message)))
138+
:error-filter
139+
;; Add fake line numbers if they are missing in the lint output
140+
(lambda (errors)
141+
(dolist (err errors)
142+
(unless (flycheck-error-line err)
143+
(setf (flycheck-error-line err) 1)))
144+
errors)
145+
:modes solidity-mode
146+
:predicate (lambda () (eq major-mode 'solidity-mode)))
147147

148148
;; first try to add solium to the checker's list since if we got solc
149149
;; it must come after it in the list due to it being chained after solc
150150
(when solidity-flycheck-solium-checker-active
151151
(if (funcall flycheck-executable-find solidity-solium-path)
152152
(progn
153-
(add-to-list 'flycheck-checkers 'solium-checker)
154-
(setq flycheck-solium-checker-executable solidity-solium-path))
153+
(add-to-list 'flycheck-checkers 'solium-checker)
154+
(setq flycheck-solium-checker-executable solidity-solium-path))
155155
(error (format "Solidity Mode Configuration error. Requested solium flycheck integration but can't find solium at: %s" solidity-solium-path))))
156156

157157
(when solidity-flycheck-solc-checker-active
158158
(if (funcall flycheck-executable-find solidity-solc-path)
159159
(progn
160-
(add-to-list 'flycheck-checkers 'solidity-checker)
161-
(setq flycheck-solidity-checker-executable solidity-solc-path))
160+
(add-to-list 'flycheck-checkers 'solidity-checker)
161+
(setq flycheck-solidity-checker-executable solidity-solc-path))
162162
(error (format "Solidity Mode Configuration error. Requested solc flycheck integration but can't find solc at: %s" solidity-solc-path))))
163163

164164
(provide 'solidity-flycheck)

0 commit comments

Comments
 (0)