|
|
@@ -1,187 +1,121 @@
|
|
|
from PikaObj import *
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
def int(arg: any, *base) -> int: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
def bool(arg: any) -> bool: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
def float(arg: any) -> float: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
def str(arg: any) -> str: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
def iter(arg: any) -> any: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
def range(*ax) -> any: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
def print(*val, **ops): ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
def __setitem__(obj: any, key: any, val: any) -> any: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
def __getitem__(obj: any, key: any) -> any: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def type(arg: any) -> any: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def isinstance(object: any, classinfo: any) -> bool: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
def len(arg: any) -> int: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("PIKA_BUILTIN_STRUCT_ENABLE")
|
|
|
def list(*val) -> any: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("PIKA_BUILTIN_STRUCT_ENABLE")
|
|
|
def dict(*val) -> any: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("PIKA_BUILTIN_STRUCT_ENABLE")
|
|
|
def tuple(arg: any) -> any: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def hex(val: int) -> str: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def ord(val: str) -> int: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def chr(val: int) -> str: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def bytes(val: any) -> bytes: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("PIKA_SYNTAX_FORMAT_ENABLE")
|
|
|
def cformat(fmt: str, *var) -> str: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def id(obj: any) -> int: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("PIKA_FILEIO_ENABLE")
|
|
|
def open(path: str, mode: str) -> object: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def dir(obj: any) -> list: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("PIKA_EXEC_ENABLE")
|
|
|
def exec(code: str): ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("PIKA_EXEC_ENABLE")
|
|
|
def eval(code: str) -> any: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def getattr(obj: object, name: str) -> any: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def setattr(obj: object, name: str, val: any): ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def hasattr(obj: object, name: str) -> int: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def exit(): ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def input(*info) -> str: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def abs(val: any) -> any: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def max(*val) -> any: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def min(*val) -> any: ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def help(name: str): ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def reboot(): ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("!PIKA_NANO_ENABLE")
|
|
|
def clear(): ...
|
|
|
|
|
|
|
|
|
-@staticmethod
|
|
|
-@PIKA_C_MACRO_IF("PIKA_GC_MARK_SWEEP_ENABLE")
|
|
|
def gcdump(): ...
|
|
|
|
|
|
|
|
|
-@PIKA_C_MACRO_IF("0")
|
|
|
class RangeObj:
|
|
|
def __next__(self) -> any: ...
|
|
|
|
|
|
|
|
|
-@PIKA_C_MACRO_IF("0")
|
|
|
class StringObj:
|
|
|
def __next__(self) -> any: ...
|
|
|
|
|
|
@@ -190,6 +124,24 @@ class object:
|
|
|
pass
|
|
|
|
|
|
|
|
|
+class bytearray:
|
|
|
+ def __init__(self, bytes: any):
|
|
|
+ """ convert a bytes to ByteArray """
|
|
|
+
|
|
|
+ def __iter__(self) -> any:
|
|
|
+ """ support for loop """
|
|
|
+
|
|
|
+ def __next__(self) -> any:
|
|
|
+ """ support for loop """
|
|
|
+
|
|
|
+ def __getitem__(self, __key: int) -> int:
|
|
|
+ """ support [] index """
|
|
|
+
|
|
|
+ def __setitem__(self, __key: int, __val: int): ...
|
|
|
+ def __str__(self) -> str: ...
|
|
|
+ def decode(self) -> str: ...
|
|
|
+
|
|
|
+
|
|
|
class BaseException:
|
|
|
pass
|
|
|
|
|
|
@@ -448,21 +400,3 @@ class BytesWarning(Warning):
|
|
|
|
|
|
class ResourceWarning(Warning):
|
|
|
pass
|
|
|
-
|
|
|
-
|
|
|
-class bytearray:
|
|
|
- def __init__(self, bytes: any):
|
|
|
- """ convert a bytes to ByteArray """
|
|
|
-
|
|
|
- def __iter__(self) -> any:
|
|
|
- """ support for loop """
|
|
|
-
|
|
|
- def __next__(self) -> any:
|
|
|
- """ support for loop """
|
|
|
-
|
|
|
- def __getitem__(self, __key: int) -> int:
|
|
|
- """ support [] index """
|
|
|
-
|
|
|
- def __setitem__(self, __key: int, __val: int): ...
|
|
|
- def __str__(self) -> str: ...
|
|
|
- def decode(self) -> str: ...
|