This commit is contained in:
2026-06-16 16:09:42 +08:00
commit bffb0cb6b7
644 changed files with 86620 additions and 0 deletions

View File

@@ -0,0 +1,67 @@
"""
Auto-generated Python stub file from stdint.py
Module: stdint
"""
import c
import t
INT: t.CTypedef = t.CInt
INTPTR: t.CTypedef = t.CInt | t.CPtr
BOOL: t.CTypedef = t.CInt
UINT: t.CTypedef = t.CUnsignedInt
UINTPTR: t.CTypedef = UINT | t.CPtr
BYTE: t.CTypedef = t.CUnsignedChar
BYTEPTR: t.CTypedef = BYTE | t.CPtr
WORD: t.CTypedef = t.CUInt16T
DWORD: t.CTypedef = t.CUInt32T
QWORD: t.CTypedef = t.CUInt64T
TCHAR: t.CTypedef = t.CChar
CHARLIST: t.CTypedef = str | t.CPtr
VOID: t.CTypedef = t.CVoid
SHORT: t.CTypedef = t.CShort
SHORTPTR: t.CTypedef = t.CShort | t.CPtr
USHORT: t.CTypedef = t.CUnsignedShort
USHORTPTR: t.CTypedef = t.CUnsignedShort | t.CPtr
LONGLONG: t.CTypedef = t.CLong | t.CLong
ULONGLONG: t.CTypedef = t.CUnsignedLong | t.CLong
LONG: t.CTypedef = t.CLong
ULONG: t.CTypedef = t.CUnsignedLong
WCHAR: t.CTypedef = WORD
WCHARPTR: t.CTypedef = WORD | t.CPtr
CHARPTR: t.CTypedef = t.CChar | t.CPtr
FSIZE_t: t.CTypedef = DWORD
LBA_t: t.CTypedef = DWORD
UINTPTR: t.CTypedef = t.CUnsignedInt | t.CPtr
VOIDPTR: t.CTypedef = t.CVoid | t.CPtr
FLOAT: t.CTypedef = t.CFloat
DOUBLE: t.CTypedef = t.CDouble
FLOAT8: t.CTypedef = t.CFloat8T
FLOAT16: t.CTypedef = t.CFloat16T
FLOAT32: t.CTypedef = t.CFloat32T
FLOAT64: t.CTypedef = t.CFloat64T
FLOAT128: t.CTypedef = t.CFloat128T
INT8: t.CTypedef = t.CInt8T
INT16: t.CTypedef = t.CInt16T
INT32: t.CTypedef = t.CInt32T
INT64: t.CTypedef = t.CInt64T
UINT8: t.CTypedef = t.CUInt8T
UINT16: t.CTypedef = t.CUInt16T
UINT32: t.CTypedef = t.CUInt32T
UINT64: t.CTypedef = t.CUInt64T
INT8PTR: t.CTypedef = t.CInt8T | t.CPtr
INT16PTR: t.CTypedef = t.CInt16T | t.CPtr
INT32PTR: t.CTypedef = t.CInt32T | t.CPtr
INT64PTR: t.CTypedef = t.CInt64T | t.CPtr
UINT8PTR: t.CTypedef = t.CUInt8T | t.CPtr
UINT16PTR: t.CTypedef = t.CUInt16T | t.CPtr
UINT32PTR: t.CTypedef = t.CUInt32T | t.CPtr
UINT64PTR: t.CTypedef = t.CUInt64T | t.CPtr
CHAR8: t.CTypedef = t.CChar8T
CHAR16: t.CTypedef = t.CChar16T
CHAR32: t.CTypedef = t.CChar32T
CHAR8PTR: t.CTypedef = t.CChar8T | t.CPtr
CHAR16PTR: t.CTypedef = t.CChar16T | t.CPtr
CHAR32PTR: t.CTypedef = t.CChar32T | t.CPtr

View File

@@ -0,0 +1,28 @@
"""
Auto-generated Python stub file from stdio.py
Module: stdio
"""
import t, c
def printf(fmt: t.CChar | t.CConst | t.CPtr, *args) -> t.CInt | t.CExtern | t.CExport: pass
def fprintf(stream: t.CVoid | t.CPtr, fmt: t.CChar | t.CConst | t.CPtr, *args) -> t.CInt | t.CExtern | t.CExport: pass
def sprintf(buf: t.CChar | t.CPtr, fmt: t.CChar | t.CConst | t.CPtr, *args) -> t.CInt | t.CExtern | t.CExport: pass
def snprintf(buf: t.CChar | t.CPtr, size: t.CSizeT, fmt: t.CChar | t.CConst | t.CPtr, *args) -> t.CInt | t.CExtern | t.CExport: pass
def puts(s: t.CChar | t.CConst | t.CPtr) -> t.CInt | t.CExtern | t.CExport: pass
def fputs(s: t.CChar | t.CConst | t.CPtr, stream: t.CVoid | t.CPtr) -> t.CInt | t.CExtern | t.CExport: pass
def fgets(buf: t.CChar | t.CPtr, size: t.CInt, stream: t.CVoid | t.CPtr) -> t.CChar | t.CPtr | t.CExtern | t.CExport: pass
def fflush(stream: t.CVoid | t.CPtr) -> t.CInt | t.CExtern | t.CExport: pass
stdin: t.CExtern | t.CVoid | t.CPtr
stdout: t.CExtern | t.CVoid | t.CPtr
stderr: t.CExtern | t.CVoid | t.CPtr

View File

@@ -0,0 +1,108 @@
"""
Auto-generated Python stub file from main.py
Module: main
"""
import c
import t
from stdint import *
from stdio import printf
_pass_count: t.CExtern | t.CInt
_fail_count: t.CExtern | t.CInt
def check(name: t.CChar | t.CPtr, condition: bool) -> t.CInt: pass
class Rect:
width: t.CInt
height: t.CInt
def __init__(self: Rect, w: t.CInt, h: t.CInt) -> t.CInt: pass
@property
def area(self: Rect) -> t.CInt: pass
@property
def is_square(self: Rect) -> bool: pass
def test_property_getter() -> t.CInt: pass
class Temperature:
_celsius: t.CDouble
def __init__(self: Temperature, c: t.CDouble) -> t.CInt: pass
@property
def celsius(self: Temperature) -> t.CDouble: pass
@celsius.setter
def celsius(self: Temperature, val: t.CDouble) -> t.CInt: pass
@property
def fahrenheit(self: Temperature) -> t.CDouble: pass
def test_property_setter() -> t.CInt: pass
class Counter:
_count: t.CInt
def __init__(self: Counter) -> t.CInt: pass
@property
def value(self: Counter) -> t.CInt: pass
@value.setter
def value(self: Counter, v: t.CInt) -> t.CInt: pass
def test_property_getter_redef() -> t.CInt: pass
class Config:
_value: t.CInt
_deleted: t.CInt
def __init__(self: Config, v: t.CInt) -> t.CInt: pass
@property
def value(self: Config) -> t.CInt: pass
@value.setter
def value(self: Config, v: t.CInt) -> t.CInt: pass
@value.deleter
def value(self: Config) -> t.CInt: pass
def is_deleted(self: Config) -> bool: pass
def test_property_deleter() -> t.CInt: pass
class MathUtils:
@staticmethod
def add(a: t.CInt, b: t.CInt) -> t.CInt: pass
@staticmethod
def max_val(a: t.CInt, b: t.CInt) -> t.CInt: pass
def test_staticmethod() -> t.CInt: pass
class Point:
x: t.CDouble
y: t.CDouble
def __init__(self: Point, x: t.CDouble, y: t.CDouble) -> t.CInt: pass
@classmethod
def origin(cls: Point) -> Point: pass
@classmethod
def from_int(cls: Point, x: t.CInt, y: t.CInt) -> Point: pass
def dist_sq(self: Point) -> t.CDouble: pass
def test_classmethod() -> t.CInt: pass
class Circle:
_radius: t.CDouble
def __init__(self: Circle, r: t.CDouble) -> t.CInt: pass
@property
def radius(self: Circle) -> t.CDouble: pass
@radius.setter
def radius(self: Circle, val: t.CDouble) -> t.CInt: pass
@property
def area(self: Circle) -> t.CDouble: pass
@staticmethod
def is_unit(r: t.CDouble) -> bool: pass
@classmethod
def unit(cls: Circle) -> Circle: pass
def test_combined() -> t.CInt: pass
def main() -> t.CInt | t.CExport: pass

View File

@@ -0,0 +1,3 @@
56cdd754a8a09347:includes/stdint.py
73edbcf76e32d00b:includes/stdio.py
7d5b7ce7c134ada7:main.py