|
|
@@ -23,12 +23,11 @@ The easiest way to test a feature is to [try it on your browser](https://pocketp
|
|
|
1. `__getattr__` and `__setattr__`.
|
|
|
2. Descriptor protocol `__get__` and `__set__`. However, `@property` is implemented.
|
|
|
3. `__slots__` in class definition.
|
|
|
-4. Unpacking in `list` and `dict` literals, e.g. `[1, 2, *a]`.
|
|
|
-5. Access the exception object in try..except.
|
|
|
-6. `else` clause in try..except.
|
|
|
-7. Inplace methods like `__iadd__` and `__imul__`.
|
|
|
-8. `__del__` in class definition.
|
|
|
-9. Multiple inheritance.
|
|
|
+4. Access the exception object in try..except.
|
|
|
+5. `else` clause in try..except.
|
|
|
+6. Inplace methods like `__iadd__` and `__imul__`.
|
|
|
+7. `__del__` in class definition.
|
|
|
+8. Multiple inheritance.
|
|
|
|
|
|
## Different behaviors
|
|
|
|
|
|
@@ -36,10 +35,9 @@ The easiest way to test a feature is to [try it on your browser](https://pocketp
|
|
|
2. When a generator is exhausted, `StopIteration` is returned instead of raised.
|
|
|
3. `++i` and `--j` is an increment/decrement statement, not an expression.
|
|
|
4. `int` does not derive from `bool`.
|
|
|
-5. `int` is not of unlimited precision. In 32 bit system, `int` and `float` is 30 bit; in 64 bit system, they are both 62 bit.
|
|
|
+5. `int` is not of unlimited precision. In 32 bit system, `int` and `float` is 30 bit; in 64 bit system, they are both 62 bit. You can use `long` type explicitly for arbitrary sized integers.
|
|
|
6. `__ne__` is not required. Define `__eq__` is enough.
|
|
|
7. Raw string cannot have boundary quotes in it, even escaped. See [#55](https://github.com/blueloveTH/pocketpy/issues/55).
|
|
|
8. In a starred unpacked assignment, e.g. `a, b, *c = x`, the starred variable can only be presented in the last position. `a, *b, c = x` is not supported.
|
|
|
9. A `Tab` is equivalent to 4 spaces. You can mix `Tab` and spaces in indentation, but it is not recommended.
|
|
|
-10. `%`, `&`, `//`, `^` and `|` for `int` behave the same as C, not python.
|
|
|
-11. `int` is of limited precision. For arbitrary sized integers, you may use `long` type explicitly.
|
|
|
+10. `%`, `&`, `//`, `^` and `|` for `int` behave the same as C, not python.
|