Skip to content

Instantly share code, notes, and snippets.

@hebiyan
Last active February 6, 2020 16:58
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save hebiyan/211f9ae0bada68d402c2 to your computer and use it in GitHub Desktop.
Save hebiyan/211f9ae0bada68d402c2 to your computer and use it in GitHub Desktop.
Elisp code that enables syntax and type checking of Standard ML code using MLton through Flycheck.
(flycheck-define-checker mlton
"Standard ML type and syntax checking with mlton compiler.
See URL 'http://mlton.org"
:command ("mlton" "-stop" "tc" source)
:error-patterns
((error line-start "Error: " (file-name) blank line ?\. column ?\. "\n"
(message (1+ line-start (1+ blank) (+ nonl) "\n"))))
:mode (sml-mode))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment