Skip to content

Commit

Permalink
🐛 Fix #4: handle quotes
Browse files Browse the repository at this point in the history
  • Loading branch information
Freed-Wu committed Nov 27, 2023
1 parent 15f534e commit 8d678de
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions src/termux_language_server/schema.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ def from_node(cls, node: Node, parent: "Trie | None") -> "Trie":
"simple_expansion",
}
if node.type in string_types:
if node.type == "string":
node = node.children[1]
return cls(UNI.node2range(node), parent, UNI.node2text(node))
if node.type == "function_definition":
return cls(UNI.node2range(node), parent, 0)
Expand Down
2 changes: 1 addition & 1 deletion tests/PKGBUILD
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ pkgname=pkgbuild-language-server
pkgver=0.0.6
pkgrel=1
pkgdesc="Archlinux and Windows Msys2's PKGBUILD language server"
arch=(any)
arch=("any")
mingw_arch=(wrong_arch)
url=https://github.com/Freed-Wu/pkgbuild-language-server
depends=(python-colorama python-jinja python-platformdirs python-pygls python-tree-sitter)
Expand Down

0 comments on commit 8d678de

Please sign in to comment.