Open alandao opened 2 years ago
From https://github.com/nvim-treesitter/nvim-treesitter/issues/2538, I was able to successfully run ":TSInstall norg" after installing gnumake on NixOS
:TSInstall norg
==============================================================================
nvim-treesitter: require("nvim-treesitter.health").check()
Installation ~
- OK `tree-sitter` found 0.22.5 (parser generator, only needed for :TSInstallFromGrammar)
- OK `node` found v20.12.2 (only needed for :TSInstallFromGrammar)
- OK `git` executable found.
- OK `cc` executable found. Selected from { vim.NIL, "cc", "gcc", "clang", "cl", "zig" }
Version: Apple clang version 15.0.0 (clang-1500.3.9.4)
- OK Neovim was compiled with tree-sitter runtime ABI version 14 (required >=13). Parsers must be compatible with runtime ABI.
OS Info:
{
machine = "arm64",
release = "23.4.0",
sysname = "Darwin",
version = "Darwin Kernel Version 23.4.0: Fri Mar 15 00:12:41 PDT 2024; root:xnu-10063.101.17~1/RELEASE_ARM64_T8103"
} ~
Parser/Features H L F I J
- bash ✓ ✓ ✓ . ✓
- c ✓ ✓ ✓ ✓ ✓
- c_sharp ✓ ✓ ✓ . ✓
- fish ✓ ✓ ✓ ✓ ✓
- html ✓ ✓ ✓ ✓ ✓
- javascript ✓ ✓ ✓ ✓ ✓
- json ✓ ✓ ✓ ✓ .
- lua ✓ ✓ ✓ ✓ ✓
- markdown ✓ . ✓ ✓ ✓
- markdown_inline ✓ . . . ✓
- norg_meta ✓ . . ✓ .
- proto ✓ . ✓ . .
- rust ✓ ✓ ✓ ✓ ✓
- toml ✓ ✓ ✓ ✓ ✓
- typescript ✓ ✓ ✓ ✓ ✓
- vimdoc ✓ . . . ✓
- yaml ✓ ✓ ✓ ✓ ✓
Legend: H[ighlight], L[ocals], F[olds], I[ndents], In[j]ections
+) multiple parsers found, only one will be used
x) errors found in the query, try to run :TSUpdate {lang} ~
NVIM v0.10.0-dev-2995+ga1550dbf0-Homebrew
Build type: Release
LuaJIT 2.1.1713773202
Run "nvim -V1 -v" for more info
nvim-treesitter[norg]: Error during compilation
src/scanner.cc:176:6: warning: scoped enumerations are a C++11 extension [-Wc++11-extensions]
enum class TagType : char
^
src/scanner.cc:194:10: warning: 'auto' type specifier is a C++11 extension [-Wc++11-extensions]
for (auto& elem : vec)
^
src/scanner.cc:194:21: warning: range-based for loop is a C++11 extension [-Wc++11-extensions]
for (auto& elem : vec)
^
src/scanner.cc:213:16: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions]
m_Previous = 0, // previous char
^
src/scanner.cc:214:15: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions]
m_Current = 0; // current char
^
src/scanner.cc:216:26: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions]
TagType m_TagContext = TagType::NONE;
^
src/scanner.cc:217:23: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions]
size_t m_TagLevel = 0;
^
src/scanner.cc:219:27: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions]
bool m_InLinkLocation = false;
^
src/scanner.cc:223:27: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions]
TokenType m_LastToken = NONE;
^
src/scanner.cc:226:26: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions]
size_t m_ParsedChars = 0;
^
src/scanner.cc:228:50: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions]
const array<int32_t, 12> m_DetachedModifiers = {
^
src/scanner.cc:243:74: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions]
const unordered_map<int32_t, TokenType> m_DetachedModifierExtensions = {
^
src/scanner.cc:256:65: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions]
const unordered_map<int32_t, TokenType> m_AttachedModifiers = {
^
src/scanner.cc:811:6: error: expected expression
[[nodiscard]]
^
src/scanner.cc:812:5: error: expected member name or ';' after declaration specifiers
I also got error when I try to install it with
:TSInstall norg
Check health
============================================================================== nvim-treesitter: require("nvim-treesitter.health").check() Installation ~ - OK `tree-sitter` found 0.22.5 (parser generator, only needed for :TSInstallFromGrammar) - OK `node` found v20.12.2 (only needed for :TSInstallFromGrammar) - OK `git` executable found. - OK `cc` executable found. Selected from { vim.NIL, "cc", "gcc", "clang", "cl", "zig" } Version: Apple clang version 15.0.0 (clang-1500.3.9.4) - OK Neovim was compiled with tree-sitter runtime ABI version 14 (required >=13). Parsers must be compatible with runtime ABI. OS Info: { machine = "arm64", release = "23.4.0", sysname = "Darwin", version = "Darwin Kernel Version 23.4.0: Fri Mar 15 00:12:41 PDT 2024; root:xnu-10063.101.17~1/RELEASE_ARM64_T8103" } ~ Parser/Features H L F I J - bash ✓ ✓ ✓ . ✓ - c ✓ ✓ ✓ ✓ ✓ - c_sharp ✓ ✓ ✓ . ✓ - fish ✓ ✓ ✓ ✓ ✓ - html ✓ ✓ ✓ ✓ ✓ - javascript ✓ ✓ ✓ ✓ ✓ - json ✓ ✓ ✓ ✓ . - lua ✓ ✓ ✓ ✓ ✓ - markdown ✓ . ✓ ✓ ✓ - markdown_inline ✓ . . . ✓ - norg_meta ✓ . . ✓ . - proto ✓ . ✓ . . - rust ✓ ✓ ✓ ✓ ✓ - toml ✓ ✓ ✓ ✓ ✓ - typescript ✓ ✓ ✓ ✓ ✓ - vimdoc ✓ . . . ✓ - yaml ✓ ✓ ✓ ✓ ✓ Legend: H[ighlight], L[ocals], F[olds], I[ndents], In[j]ections +) multiple parsers found, only one will be used x) errors found in the query, try to run :TSUpdate {lang} ~
Neovim version
NVIM v0.10.0-dev-2995+ga1550dbf0-Homebrew Build type: Release LuaJIT 2.1.1713773202 Run "nvim -V1 -v" for more info
Error log
nvim-treesitter[norg]: Error during compilation src/scanner.cc:176:6: warning: scoped enumerations are a C++11 extension [-Wc++11-extensions] enum class TagType : char ^ src/scanner.cc:194:10: warning: 'auto' type specifier is a C++11 extension [-Wc++11-extensions] for (auto& elem : vec) ^ src/scanner.cc:194:21: warning: range-based for loop is a C++11 extension [-Wc++11-extensions] for (auto& elem : vec) ^ src/scanner.cc:213:16: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions] m_Previous = 0, // previous char ^ src/scanner.cc:214:15: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions] m_Current = 0; // current char ^ src/scanner.cc:216:26: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions] TagType m_TagContext = TagType::NONE; ^ src/scanner.cc:217:23: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions] size_t m_TagLevel = 0; ^ src/scanner.cc:219:27: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions] bool m_InLinkLocation = false; ^ src/scanner.cc:223:27: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions] TokenType m_LastToken = NONE; ^ src/scanner.cc:226:26: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions] size_t m_ParsedChars = 0; ^ src/scanner.cc:228:50: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions] const array<int32_t, 12> m_DetachedModifiers = { ^ src/scanner.cc:243:74: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions] const unordered_map<int32_t, TokenType> m_DetachedModifierExtensions = { ^ src/scanner.cc:256:65: warning: default member initializer for non-static data member is a C++11 extension [-Wc++11-extensions] const unordered_map<int32_t, TokenType> m_AttachedModifiers = { ^ src/scanner.cc:811:6: error: expected expression [[nodiscard]] ^ src/scanner.cc:812:5: error: expected member name or ';' after declaration specifiers
I also had this issue, there are steps in documentation to resolve this.
If you are on mac, for some reason for me even compiling it with clang 15 (installed via xcode-select --install
) didnt work, I had to set CC to gcc-14 (installed via homebrew) for it to finally compile.
theHamsta@ from nvim-treesitter/nvim-treesitter recommended me to forward this issue here.
Describe the bug
I’m not able to install the
norg
parser. It never finishes compiling.To Reproduce
Expected behavior
I expected the norg parser to be installed within a few seconds
Output of
:checkhealth nvim-treesitter
Output of
nvim --version
Additional context
No response