You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-19 14:31:59 +00:00
Merge pull request #96666 from aXu-AP/unique-node-no-quotes
Remove unneeded quotes from autocomplete % nodes
This commit is contained in:
@@ -3486,10 +3486,10 @@ static void _find_call_arguments(GDScriptParser::CompletionContext &p_context, c
|
|||||||
opt = opt.substr(1);
|
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.
|
// is not a valid identifier.
|
||||||
bool path_needs_quote = false;
|
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()) {
|
if (!part.is_valid_ascii_identifier()) {
|
||||||
path_needs_quote = true;
|
path_needs_quote = true;
|
||||||
break;
|
break;
|
||||||
|
|||||||
@@ -0,0 +1,9 @@
|
|||||||
|
[input]
|
||||||
|
scene="res://completion/get_node/get_node.tscn"
|
||||||
|
[output]
|
||||||
|
include=[
|
||||||
|
{"display": "%UniqueA"},
|
||||||
|
]
|
||||||
|
exclude=[
|
||||||
|
{"display": "\"%UniqueA\""},
|
||||||
|
]
|
||||||
@@ -0,0 +1,5 @@
|
|||||||
|
extends Node
|
||||||
|
|
||||||
|
func a():
|
||||||
|
$➡
|
||||||
|
pass
|
||||||
Reference in New Issue
Block a user