Compare commits

...

12 commits

Author SHA1 Message Date
Benson Chu
ea4f14bb5e Refactored 2025-08-12 16:16:12 -05:00
Benson Chu
0ab18831fb C-M works now 2025-08-12 10:01:27 -05:00
Benson Chu
79f776ab63 Oops, that's the correct modifyOtherKeys=2 syntax 2025-08-12 09:52:10 -05:00
Benson Chu
87e696e61b Widen definition of llvm dump file 2025-08-12 09:51:58 -05:00
Benson Chu
187713fc4a Step forwards and backwards through print IR 2025-08-12 09:51:44 -05:00
Benson Chu
7ff5c97122 INFINITE KNOWLEDGE, prepend discovered 2025-08-12 09:50:17 -05:00
Benson Chu
909e194396 Well, that should be all... 2025-08-12 09:49:54 -05:00
Benson Chu
7fcb4b7754 Alright stop doing that 2025-08-12 09:49:43 -05:00
Benson Chu
d2a83b2e27 Feels gooood 2025-08-12 09:05:49 -05:00
Benson Chu
d287ddf390 Nope, that's not the fix 2025-08-11 15:11:38 -05:00
Benson Chu
b9e5c21f54 Correctness 2025-08-11 15:04:23 -05:00
Benson Chu
492583f34f wtf? You're lucky I found a different way around this issue. 2025-08-11 15:04:04 -05:00
4 changed files with 54 additions and 4 deletions

View file

@ -29,8 +29,8 @@
'((assembly :key ?a :major-mode asm-mode :buffer-string "assembly" :description "[a]ssembly")))
(defun ll/is-dump-file (fname)
(and (string= "/tmp/"
(file-name-directory fname))
(and (string-match-p (rx line-start "/tmp/")
(file-name-directory fname))
(string-match-p (rx "/" (+ (not "/")) "-" (= 6 alphanumeric) "." (+ anything))
fname)))

View file

@ -44,8 +44,22 @@
(add-to-list 'llvm-font-lock-keywords
`(,(regexp-opt '("nnan" "ninf" "nsz" "arcp" "contract" "afn" "reassoc" "fast") 'symbols) . 'shadow)))
(defvar llvm-ir-dump-regexp
(rx line-start (optional (any "#;") " ") "*** IR Dump" (+ nonl) "***" (optional ":") "\n"))
(add-to-list 'llvm-font-lock-keywords
`(,(rx line-start (optional (any "#;") " ") "***" (+ nonl) "***" (optional ":") "\n") . 'llvm-separator-face))
`(,llvm-ir-dump-regexp 0 'llvm-separator-face prepend))
(defun llvm-previous-IR-dump ()
(interactive)
(re-search-backward llvm-ir-dump-regexp))
(defun llvm-next-IR-dump ()
(interactive)
(re-search-forward llvm-ir-dump-regexp))
(define-key llvm-mode-map (kbd "C-M-a") #'llvm-previous-IR-dump)
(define-key llvm-mode-map (kbd "C-M-e") #'llvm-next-IR-dump)
(-->
"\\b[-]?[0-9]+\\b"

View file

@ -24,6 +24,8 @@
;;; Code:
(require 'org)
(defun my/side-window-p (window)
(window-parameter window 'window-side))

View file

@ -25,9 +25,43 @@
;;; Code:
(require 'term/xterm)
(xterm--init-modify-other-keys)
(let ((ascii-start 97)
(C-M-start ?\C-\M-a))
(dotimes (n 26)
(define-key xterm-function-map
(format "\e[27;5;%d~" (+ ascii-start n))
(vector (1+ n)))
(define-key xterm-function-map
(format "\e[27;7;%d~" (+ ascii-start n))
(vector (+ n C-M-start)))))
(define-key xterm-function-map
"\e[27;5;8~"
[C-backspace])
(define-key xterm-function-map
"\e[27;5;32~"
[?\C-\s] ;; Or (kbd "C-SPC") ;; Or [?\C- ]
)
(define-key xterm-function-map
"\e[27;2;32~"
[?\S-\s])
;; (xterm--init-modify-other-keys)
(defun my/xterm--init-modify-other-keys ()
"Terminal initialization for xterm's modifyOtherKeys support."
(send-string-to-terminal "\e[>4;2m")
(push "\e[>4m" (terminal-parameter nil 'tty-mode-reset-strings))
(push "\e[>4;2m" (terminal-parameter nil 'tty-mode-set-strings)))
(advice-add #'xterm--init-modify-other-keys
:override
#'my/xterm--init-modify-other-keys)
(xterm-mouse-mode 1)
(terminal-init-xterm)
;; (global-set-key (kbd "M-[ emacs-C-SPC") #'set-mark-command)
;; (global-set-key (kbd "M-[ emacs-M-SPC") #'cycle-spacing)