@@ -284,8 +284,6 @@ The first statement of CHEE above executes a piece of Python code that assigns t
The first statement of CHEE above sets a Python local variable named `x` using an HVML array, then calls Python's `reverse()` method for lists on it, and then uses `$PY.local.x()()` the usage calls the getter of `x` itself, which returns the HVML array corresponding to the Python list object. Therefore, the execution result of the above CHEE is [3, 2, 2, 1].
The first statement of CHEE above sets a Python local variable named `x` using an HVML array, then calls Python's `reverse()` method for lists on it, and then uses the usage of `$PY.local.x()()` The getter for `x` itself is called, which returns the HVML array corresponding to the Python list object. Therefore, the execution result of the above CHEE is [3, 2, 2, 1].
Among them, `$PY.local.x()` returns an HVML native entity (native entity) representing a Python complex object, and its default getter is called again on this native entity, namely `$PY.local.x()()`, will perform data type conversion. This conversion will construct Python's Unicode string, byte array (bytes or byte array), list, dictionary, and set into corresponding HVML data types, which are string, byte sequence, array , object and generic set. Without such conversion, these Python objects are represented in HVML programs as native entity dynamic objects. None, True, False, integers, and floating-point numbers in Python do not do this kind of processing, and are directly equivalent to the null, true, false, longint, and number data types of HVML. For cases where the conversion cannot be performed, such as executing the default getter on a custom Python class object, it will be equivalent to calling Python's `str()` function on it.
Obviously, by using `$PY` variable to construct our expected mixed evaluation expression, and using it for the attribute value of HVML element or the content of operation element, it is very convenient to embed Python code into HVML, thus taking full advantage of the rich modules and functions in the Python ecosystem.