[Core] Fix property access on read-only Dictionary
This commit is contained in:
parent
7529c0bec5
commit
ec29c3e784
3 changed files with 23 additions and 7 deletions
|
|
@ -0,0 +1,4 @@
|
|||
func test():
|
||||
var dictionary := { "a": 0 }
|
||||
dictionary.make_read_only()
|
||||
dictionary.a = 1
|
||||
|
|
@ -0,0 +1,6 @@
|
|||
GDTEST_RUNTIME_ERROR
|
||||
>> SCRIPT ERROR
|
||||
>> on function: test()
|
||||
>> runtime/errors/read_only_dictionary.gd
|
||||
>> 4
|
||||
>> Invalid assignment of property or key 'a' with value of type 'int' on a base object of type 'Dictionary'.
|
||||
Loading…
Add table
Add a link
Reference in a new issue