Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove unneeded quotes from autocomplete % nodes #96666

Merged
merged 1 commit into from
Sep 11, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions modules/gdscript/gdscript_editor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3482,10 +3482,10 @@ ::Error GDScriptLanguage::complete_code(const String &p_code, const String &p_pa
opt = opt.substr(1);
}

// The path needs quotes if at least one of its components (excluding `/` separations)
// The path needs quotes if at least one of its components (excluding `%` prefix and `/` separations)
// is not a valid identifier.
bool path_needs_quote = false;
for (const String &part : opt.split("/")) {
for (const String &part : opt.trim_prefix("%").split("/")) {
if (!part.is_valid_ascii_identifier()) {
path_needs_quote = true;
break;
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
[input]
scene="res://completion/get_node/get_node.tscn"
[output]
include=[
{"display": "%UniqueA"},
]
exclude=[
{"display": "\"%UniqueA\""},
]
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
extends Node

func a():
$➡
pass
Loading