You've already forked godot
mirror of
https://github.com/godotengine/godot.git
synced 2025-11-05 12:10:55 +00:00
Add UID support to GDScript files
This commit is contained in:
@@ -0,0 +1,5 @@
|
||||
@uid("uid://c4ckv3ryprcn4")
|
||||
@uid("uid://c4ckv3ryprcn4")
|
||||
|
||||
func test():
|
||||
pass
|
||||
@@ -0,0 +1,2 @@
|
||||
GDTEST_PARSER_ERROR
|
||||
"@uid" annotation can only be used once.
|
||||
@@ -0,0 +1,4 @@
|
||||
@uid("not a valid uid")
|
||||
|
||||
func test():
|
||||
pass
|
||||
@@ -0,0 +1,2 @@
|
||||
GDTEST_PARSER_ERROR
|
||||
The annotated UID is invalid.
|
||||
@@ -0,0 +1,5 @@
|
||||
extends Object
|
||||
@uid("uid://c4ckv3ryprcn4")
|
||||
|
||||
func test():
|
||||
pass
|
||||
@@ -0,0 +1,2 @@
|
||||
GDTEST_PARSER_ERROR
|
||||
Annotation "@uid" must be at the top of the script, before "extends" and "class_name".
|
||||
5
modules/gdscript/tests/scripts/parser/features/uid.gd
Normal file
5
modules/gdscript/tests/scripts/parser/features/uid.gd
Normal file
@@ -0,0 +1,5 @@
|
||||
@uid("uid://c4ckv3ryprcn4")
|
||||
extends Object
|
||||
|
||||
func test():
|
||||
pass
|
||||
1
modules/gdscript/tests/scripts/parser/features/uid.out
Normal file
1
modules/gdscript/tests/scripts/parser/features/uid.out
Normal file
@@ -0,0 +1 @@
|
||||
GDTEST_OK
|
||||
Reference in New Issue
Block a user