Debian Codegraph @

modules/gdscript/tests/scripts/runtime/features/constants_are_read_only.gd

raw
1 const array: Array = [0]
2 const dictionary := {1: 2}
3
4 func test():
5 Utils.check(array.is_read_only() == true)
6 Utils.check(str(array) == '[0]')
7 Utils.check(dictionary.is_read_only() == true)
8 Utils.check(str(dictionary) == '{ 1: 2 }')
9 print('ok')