Debian Codegraph @

modules/gdscript/tests/scripts/runtime/errors/assign_freed_instance.gd

raw
1 class A extends Node:
2 pass
3
4 func subtest_native():
5 var x = Node.new()
6
7 x.free()
8
9 var _ok = x
10 var _bad: Node = x
11
12 func subtest_script():
13 var x = A.new()
14
15 x.free()
16
17 var _ok = x
18 var _bad: A = x
19
20 func test():
21 subtest_native()
22 subtest_script()