Jelajahi Sumber

Minor change to section on for loop syntax

The C-like for loop is specific to languages that wanted to copy C syntax and has nothing to do with static vs dynamic typing. Most new languages do not have it and have a foreach loop over iterators instead, regardless of whether they are statically typed or not.
saolof 4 tahun lalu
induk
melakukan
15bcf71083
1 mengubah file dengan 2 tambahan dan 2 penghapusan
  1. 2 2
      tutorials/scripting/gdscript/gdscript_advanced.rst

+ 2 - 2
tutorials/scripting/gdscript/gdscript_advanced.rst

@@ -318,7 +318,7 @@ states and quick structs:
 For & while
 -----------
 
-Iterating in some statically typed languages can be quite complex:
+Iterating in C-derived languages can be quite complex:
 
 .. code-block:: cpp
 
@@ -338,7 +338,7 @@ Iterating in some statically typed languages can be quite complex:
         std::cout << *it << std::endl;
     }
 
-This is usually greatly simplified in dynamically typed languages:
+This is usually greatly simplified in modern languages using for loops over iterables:
 
 ::