Merge branch 'emacs' of http://git.hacks-galore.org/jao/factor
commit
ad7e20a8d1
|
@ -79,11 +79,11 @@
|
|||
(save-excursion
|
||||
(goto-char (nth 8 state))
|
||||
(beginning-of-line)
|
||||
(cond ((looking-at "USING: ")
|
||||
(cond ((looking-at-p "USING: ")
|
||||
'factor-font-lock-vocabulary-name)
|
||||
((looking-at "\\(TUPLE\\|SYMBOLS\\|VARS\\): ")
|
||||
((looking-at-p "\\(TUPLE\\|SYMBOLS\\|VARS\\|SINGLETONS\\):")
|
||||
'factor-font-lock-symbol)
|
||||
((looking-at "C-ENUM:\\( \\|\n\\)")
|
||||
((looking-at-p "C-ENUM:\\( \\|\n\\)")
|
||||
'factor-font-lock-constant)
|
||||
(t 'default))))
|
||||
((or (char-equal c ?U) (char-equal c ?C))
|
||||
|
|
|
@ -106,9 +106,10 @@
|
|||
"\\_<\"[^>]\\([^\"\n]\\|\\\\\"\\)*\n")
|
||||
|
||||
(defconst fuel-syntax--word-definition-regex
|
||||
(fuel-syntax--second-word-regex
|
||||
'(":" "::" "GENERIC:" "DEFER:" "HOOK:" "MAIN:" "MATH:" "POSTPONE:"
|
||||
"SYMBOL:" "RENAME:")))
|
||||
(format "\\_<\\(%s\\)?: +\\_<\\(\\w+\\)\\_>"
|
||||
(regexp-opt
|
||||
'(":" "GENERIC" "DEFER" "HOOK" "MAIN" "MATH" "POSTPONE"
|
||||
"SYMBOL" "RENAME"))))
|
||||
|
||||
(defconst fuel-syntax--alias-definition-regex
|
||||
"^ALIAS: +\\(\\_<.+?\\_>\\) +\\(\\_<.+?\\_>\\)")
|
||||
|
@ -168,9 +169,6 @@
|
|||
(defconst fuel-syntax--indent-def-start-regex
|
||||
(format "^\\(%s:\\)\\( \\|\n\\)" (regexp-opt fuel-syntax--indent-def-starts)))
|
||||
|
||||
(defconst fuel-syntax--no-indent-def-start-regex
|
||||
(format "^\\(%s:\\) " (regexp-opt fuel-syntax--no-indent-def-starts)))
|
||||
|
||||
(defconst fuel-syntax--definition-start-regex
|
||||
(format "^\\(%s:\\) " (regexp-opt (append fuel-syntax--no-indent-def-starts
|
||||
fuel-syntax--indent-def-starts))))
|
||||
|
@ -261,8 +259,8 @@
|
|||
("\\_<\\(C\\)-ENUM: \\(;\\)" (1 "<b") (2 ">b"))
|
||||
("\\_<C-ENUM:\\( \\|\n\\)" (1 "<b"))
|
||||
("\\_<TUPLE: +\\w+? +< +\\w+? *\\( \\|\n\\)\\([^;]\\|$\\)" (1 "<b"))
|
||||
("\\_<\\(TUPLE\\|SYMBOLS\\|VARS\\): +\\w+? *\\( \\|\n\\)\\([^;<\n]\\|\\_>\\)"
|
||||
(2 "<b"))
|
||||
("\\_<TUPLE: +\\w+? *\\( \\|\n\\)\\([^;<\n]\\|\\_>\\)" (1 "<b"))
|
||||
("\\_<\\(SYMBOLS\\|VARS\\|SINGLETONS\\): *?\\( \\|\n\\)\\([^;\n]\\|\\_>\\)" (2 "<b"))
|
||||
("\\(\n\\| \\);\\_>" (1 ">b"))
|
||||
;; Let and lambda:
|
||||
("\\_<\\(!(\\) .* \\()\\)" (1 "<") (2 ">"))
|
||||
|
@ -323,7 +321,7 @@
|
|||
(defsubst fuel-syntax--is-last-char (pos)
|
||||
(save-excursion
|
||||
(goto-char (1+ pos))
|
||||
(fuel-syntax--looking-at-emptiness)))
|
||||
(looking-at-p "[ ]*$")))
|
||||
|
||||
(defsubst fuel-syntax--line-offset (pos)
|
||||
(- pos (save-excursion
|
||||
|
|
Loading…
Reference in New Issue