Преглед на файлове

Fix incorrect explanation of successful evaluation in Evaluating expressions (#5424)

itsadrago преди 3 години
родител
ревизия
e9c31d9104
променени са 1 файла, в които са добавени 2 реда и са изтрити 2 реда
  1. 2 2
      tutorials/scripting/evaluating_expressions.rst

+ 2 - 2
tutorials/scripting/evaluating_expressions.rst

@@ -107,11 +107,11 @@ instance such as ``self``, another script instance or even a singleton::
         var expression = Expression.new()
         var expression = Expression.new()
         expression.parse("double(10)")
         expression.parse("double(10)")
 
 
-        # This won't work, since we're not passing the current script as the base instance.
+        # This won't work since we're not passing the current script as the base instance.
         var result = expression.execute([], null)
         var result = expression.execute([], null)
         print(result)  # null
         print(result)  # null
 
 
-        # This will work won't work, since we're not passing the current script
+        # This will work since we're passing the current script (i.e. self)
         # as the base instance.
         # as the base instance.
         result = expression.execute([], self)
         result = expression.execute([], self)
         print(result)  # 20
         print(result)  # 20