emacs-elpa-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[nongnu] elpa/julia-mode 389a942 038/352: adding macros. to define a mac


From: ELPA Syncer
Subject: [nongnu] elpa/julia-mode 389a942 038/352: adding macros. to define a macro:
Date: Sun, 29 Aug 2021 11:22:11 -0400 (EDT)

branch: elpa/julia-mode
commit 389a942b5b8a6da22f27b02b72f1eb6d4fd07761
Author: Jeff Bezanson <bezanson@post.harvard.edu>
Commit: Yichao Yu <yyc1992@gmail.com>

    adding macros. to define a macro:
    macro foo(arg)
     ...
    end
    
    to use a macro:
    
    @foo arg
    
    for now, macros take just 1 argument. the macro is called on the
    literal syntax of its argument, and its result is used in place of the
    macro call.
    
    while i'm at it, improving the internal interface to eval, and making
    the front end a bit more efficient (it no longer has to wrap
    everything in a thunk)
    
    making `x` parse to @cmd "x", but with different escaping behavior as
    discussed.
---
 julia-mode.el | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/julia-mode.el b/julia-mode.el
index f3ba1a3..831fd61 100644
--- a/julia-mode.el
+++ b/julia-mode.el
@@ -9,6 +9,7 @@
 (defvar julia-mode-syntax-table
   (let ((table (make-syntax-table)))
     (modify-syntax-entry ?_ "w" table)   ; underscores in words
+    (modify-syntax-entry ?@ "w" table)
     (modify-syntax-entry ?# "<" table)   ; #  single-line comment start
     (modify-syntax-entry ?\n ">" table)  ; \n single-line comment end
     (modify-syntax-entry ?\{ "(} " table)
@@ -47,7 +48,7 @@
           'identity
           '("if" "else" "elseif" "while" "for" "begin" "end" "quote"
             "try" "catch" "return" "local" "type" "function" "macro"
-           "typealias" "break" "continue" "struct" "global"
+           "typealias" "break" "continue" "struct" "global" "@\\w+"
            "module" "import" "export" "const" "let" "bitstype")
           "\\|") "\\)\\>")
      'font-lock-keyword-face)



reply via email to

[Prev in Thread] Current Thread [Next in Thread]