diff options
Diffstat (limited to 'modules/gdscript/tests/scripts/parser/warnings/shadowed_constant.gd')
| -rw-r--r-- | modules/gdscript/tests/scripts/parser/warnings/shadowed_constant.gd | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/modules/gdscript/tests/scripts/parser/warnings/shadowed_constant.gd b/modules/gdscript/tests/scripts/parser/warnings/shadowed_constant.gd new file mode 100644 index 0000000000..d565d38365 --- /dev/null +++ b/modules/gdscript/tests/scripts/parser/warnings/shadowed_constant.gd @@ -0,0 +1,8 @@ +# See also `parser-errors/redefine-class-constant.gd`. +const TEST = 25 + + +func test(): + # Warning here. This is not an error because a new constant is created, + # rather than attempting to set the value of an existing constant. + const TEST = 50 |
