branch: elpa/racket-mode
commit 2a34bb7adc6146a23dd3a3a4a660b81433b608d2
Author: Bogdan Popa <[email protected]>
Commit: Greg Hendershott <[email protected]>
hash-lang: lex using 'semantic-type-guess when available
---
racket-custom.el | 3 ++-
racket/hash-lang-bridge.rkt | 3 ++-
2 files changed, 4 insertions(+), 2 deletions(-)
diff --git a/racket-custom.el b/racket-custom.el
index f4fe09a4ba..44fcf5e312 100644
--- a/racket-custom.el
+++ b/racket-custom.el
@@ -196,7 +196,8 @@ lines to show on screen."
:group 'racket)
(defcustom racket-hash-lang-token-face-alist
- `((constant . font-lock-constant-face)
+ `((builtin . font-lock-builtin-face)
+ (constant . font-lock-constant-face)
(error . error)
(other . font-lock-doc-face)
(keyword . font-lock-keyword-face)
diff --git a/racket/hash-lang-bridge.rkt b/racket/hash-lang-bridge.rkt
index 0200d6f5d0..113319fe66 100644
--- a/racket/hash-lang-bridge.rkt
+++ b/racket/hash-lang-bridge.rkt
@@ -130,7 +130,8 @@
(define (attribs->types attribs)
(match attribs
[(? symbol? s) (list s)]
- [(? hash? ht) (cons (hash-ref ht 'type 'unknown)
+ [(? hash? ht) (cons (or (hash-ref ht 'semantic-type-guess #f)
+ (hash-ref ht 'type 'unknown))
(if (hash-ref ht 'comment? #f)
'(sexp-comment-body)
null))]))