Skip to content

armgit / godot

Public Imported from GitHub
0

Godot Engine – Multi-platform 2D and 3D game engine

269 B
Raw Blame
# https://github.com/godotengine/godot/issues/90086

class MyObj:
	var obj : WeakRef

func test():
	var obj_1 = MyObj.new()
	var obj_2 = MyObj.new()
	Utils.check(obj_2.get_reference_count() == 1)
	obj_1.set(&"obj", obj_2)
	Utils.check(obj_2.get_reference_count() == 1)