mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
feat(treesitter): include language in invalid query error (#14053)
This commit is contained in:
parent
ea611c7122
commit
c50460cf3b
@ -1276,8 +1276,8 @@ int tslua_parse_query(lua_State *L)
|
||||
TSQuery *query = ts_query_new(lang, src, (uint32_t)len, &error_offset, &error_type);
|
||||
|
||||
if (!query) {
|
||||
return luaL_error(L, "query: %s at position %d",
|
||||
query_err_string(error_type), (int)error_offset);
|
||||
return luaL_error(L, "query: %s at position %d for language %s",
|
||||
query_err_string(error_type), (int)error_offset, lang_name);
|
||||
}
|
||||
|
||||
TSQuery **ud = lua_newuserdata(L, sizeof(TSQuery *)); // [udata]
|
||||
|
Loading…
Reference in New Issue
Block a user