diff options
author | Rémi Verschelde <rverschelde@gmail.com> | 2020-06-08 11:00:07 +0200 |
---|---|---|
committer | Rémi Verschelde <rverschelde@gmail.com> | 2020-06-08 11:01:45 +0200 |
commit | e34f33711b172a9fe6e5c562dee693ed467576be (patch) | |
tree | a9e7c1bef65144f16a4263498f7d0244d6e801ce /modules/gdscript/language_server/gdscript_workspace.cpp | |
parent | 87b2d3f9cf2dee1f885eaba9d17215ecbcacf391 (diff) |
GDScript LSP: Fix crash in notify_client
`latest_client_id` now defaults to `-1` (invalid ID) instead of `0`.
Also fix typo in notification `gdscrip_client/changeWorkspace`,
and fix argument names in method binds.
Fixes #39375.
Diffstat (limited to 'modules/gdscript/language_server/gdscript_workspace.cpp')
-rw-r--r-- | modules/gdscript/language_server/gdscript_workspace.cpp | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/modules/gdscript/language_server/gdscript_workspace.cpp b/modules/gdscript/language_server/gdscript_workspace.cpp index 9285d88157..a203b9bfdb 100644 --- a/modules/gdscript/language_server/gdscript_workspace.cpp +++ b/modules/gdscript/language_server/gdscript_workspace.cpp @@ -29,6 +29,7 @@ /*************************************************************************/ #include "gdscript_workspace.h" + #include "../gdscript.h" #include "../gdscript_parser.h" #include "core/project_settings.h" @@ -41,12 +42,12 @@ void GDScriptWorkspace::_bind_methods() { ClassDB::bind_method(D_METHOD("symbol"), &GDScriptWorkspace::symbol); - ClassDB::bind_method(D_METHOD("parse_script", "p_path", "p_content"), &GDScriptWorkspace::parse_script); - ClassDB::bind_method(D_METHOD("parse_local_script", "p_path"), &GDScriptWorkspace::parse_local_script); - ClassDB::bind_method(D_METHOD("get_file_path", "p_uri"), &GDScriptWorkspace::get_file_path); - ClassDB::bind_method(D_METHOD("get_file_uri", "p_path"), &GDScriptWorkspace::get_file_uri); - ClassDB::bind_method(D_METHOD("publish_diagnostics", "p_path"), &GDScriptWorkspace::publish_diagnostics); - ClassDB::bind_method(D_METHOD("generate_script_api", "p_path"), &GDScriptWorkspace::generate_script_api); + ClassDB::bind_method(D_METHOD("parse_script", "path", "content"), &GDScriptWorkspace::parse_script); + ClassDB::bind_method(D_METHOD("parse_local_script", "path"), &GDScriptWorkspace::parse_local_script); + ClassDB::bind_method(D_METHOD("get_file_path", "uri"), &GDScriptWorkspace::get_file_path); + ClassDB::bind_method(D_METHOD("get_file_uri", "path"), &GDScriptWorkspace::get_file_uri); + ClassDB::bind_method(D_METHOD("publish_diagnostics", "path"), &GDScriptWorkspace::publish_diagnostics); + ClassDB::bind_method(D_METHOD("generate_script_api", "path"), &GDScriptWorkspace::generate_script_api); } void GDScriptWorkspace::remove_cache_parser(const String &p_path) { |