Skip to content

Commit

Permalink
bla
Browse files Browse the repository at this point in the history
  • Loading branch information
ethan-leba committed Nov 23, 2023
1 parent f9b8209 commit 5b8efa4
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 7 deletions.
2 changes: 1 addition & 1 deletion tests/test-elisp.el
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

(describe "elisp regressions"
(it "properly spaces the cons ."
;; Fixed in commit XXX
;; Fixed in commit 0393dc6
(expect (with-tree-test-buffer #'emacs-lisp-mode "'([foo] . bar)"
(evil-tree-edit-exchange 'symbol))
:to-have-buffer-contents"'([TREE] . bar)")))
3 changes: 1 addition & 2 deletions tree-edit-build.el
Original file line number Diff line number Diff line change
Expand Up @@ -275,7 +275,6 @@ https://tree-sitter.github.io/tree-sitter/using-parsers#named-vs-anonymous-nodes
(treesit-install-language-grammar lang)

(unless (treesit-language-available-p lang)
;; FIXME
(princ (string-join (directory-files (expand-file-name ".test-grammars/tree-sitter")) "\n"))
(error "%S grammar did not compile properly!" lang))

Expand Down Expand Up @@ -317,7 +316,7 @@ ACCEPT-ALL, if non-nil, installs all grammars without confirmation."
(`(,lang . ,url)
'((python "https://github.com/tree-edit/tree-sitter-python")
(c "https://github.com/tree-edit/tree-sitter-c")
(java "https://github.com/tree-edit/tree-sitter-java")
(elisp "https://github.com/tree-edit/tree-sitter-elisp")
(java "https://github.com/tree-edit/tree-sitter-java")))
(when
;; TODO: Some way to detect if the grammar is out of date
Expand Down
8 changes: 4 additions & 4 deletions tree-edit.el
Original file line number Diff line number Diff line change
Expand Up @@ -361,12 +361,12 @@ Relevant types are either supertypes of TYPE or alias names referring to TYPE."
(intern)
(require))

;; TODO: mode to parser mapping
;; FIXME: error hand;lnig
;; TODO: error handling
(treesit-parser-create parser)

(let ((grammar-file (expand-file-name (format "tree-edit-%s-grammar.el"
(alist-get major-mode tree-edit-language-alist)) tree-edit-storage-dir)))
(let ((grammar-file (expand-file-name
(format "tree-edit-%s-grammar.el" parser)
tree-edit-storage-dir)))
(if (file-exists-p grammar-file)
(let (sexp)
(with-temp-buffer
Expand Down

0 comments on commit 5b8efa4

Please sign in to comment.