HCoop
/
hcoop
/
domtool2.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Unused environment variable analysis
[hcoop/domtool2.git]
/
elisp
/
domtool-mode.el
diff --git
a/elisp/domtool-mode.el
b/elisp/domtool-mode.el
index
4b23e76
..
9330e0b
100644
(file)
--- a/
elisp/domtool-mode.el
+++ b/
elisp/domtool-mode.el
@@
-46,7
+46,7
@@
`(,(concat
"\\_<"
(regexp-opt '("let" "in" "begin" "end" "with" "where" "extern" "type"
`(,(concat
"\\_<"
(regexp-opt '("let" "in" "begin" "end" "with" "where" "extern" "type"
- "val" "context" "Root")
+ "val" "context" "Root"
"if" "then" "else"
)
t)
"\\_>")
t)
"\\_>")
@@
-85,7
+85,10
@@
. domtool-font-lock-syntactic-face-function)))
(set (make-local-variable 'comment-start) "(* ")
(set (make-local-variable 'comment-end) " *)")
. domtool-font-lock-syntactic-face-function)))
(set (make-local-variable 'comment-start) "(* ")
(set (make-local-variable 'comment-end) " *)")
- (set (make-local-variable 'comment-nested) t))
+ (set (make-local-variable 'comment-nested) t)
+
+ (set (make-local-variable 'compile-command)
+ (concat "domtool -tc " (file-relative-name buffer-file-name))))
(defun domtool-indent-line ()
(let ((savep (> (current-column) (current-indentation)))
(defun domtool-indent-line ()
(let ((savep (> (current-column) (current-indentation)))
@@
-97,7
+100,7
@@
(defun until-closed-helper (level)
(if
(defun until-closed-helper (level)
(if
- (re-search-backward "\\_<\\(with\\|where\\|begin\\|end\\)\\_>"
+ (re-search-backward "\\_<\\(with\\|where\\|begin\\|end\\
|let\\
)\\_>"
nil t)
(cond
((string= (match-string 0) "end")
nil t)
(cond
((string= (match-string 0) "end")
@@
-118,7
+121,7
@@
(back-to-indentation)
(multiple-value-bind (previous-keyword base-indent)
(save-excursion
(back-to-indentation)
(multiple-value-bind (previous-keyword base-indent)
(save-excursion
- (if (re-search-backward "\\_<\\(with\\|where\\|begin\\|end\\)\\_>"
+ (if (re-search-backward "\\_<\\(with\\|where\\|begin\\|end\\
|let\\|in\\
)\\_>"
nil t)
(values (match-string 0) (current-indentation))
(values nil 0)))
nil t)
(values (match-string 0) (current-indentation))
(values nil 0)))
@@
-128,7
+131,7
@@
'noindent)
((nth 4 state)
(domtool-calculate-comment-indent state))
'noindent)
((nth 4 state)
(domtool-calculate-comment-indent state))
- ((looking-at "\\_<\\(with\\|end\\)\\_>")
+ ((looking-at "\\_<\\(with\\|end\\
|in\\
)\\_>")
(until-closed))
((not previous-keyword)
base-indent)
(until-closed))
((not previous-keyword)
base-indent)