Browse Source

Clarify null-safety vs type-safety

Changed the statement about the "as" keyword to clarify that it affects null-safety, not type-safety.
Lexyth 5 months ago
parent
commit
58c9fdb6b5
1 changed files with 1 additions and 1 deletions
  1. 1 1
      tutorials/scripting/gdscript/gdscript_styleguide.rst

+ 1 - 1
tutorials/scripting/gdscript/gdscript_styleguide.rst

@@ -1053,7 +1053,7 @@ that type will be used to infer the type of the var.
 
 .. note::
 
-    This option is considered less :ref:`type-safe<doc_gdscript_static_typing_safe_lines>` than type hints, as it silently casts the variable to null in case of a type mismatch at runtime, without an error/warning
+    This option is considered more :ref:`type-safe<doc_gdscript_static_typing_safe_lines>` than type hints, but also less null-safe as it silently casts the variable to null in case of a type mismatch at runtime, without an error/warning.
 
 **Bad**: