feat: add __future__, fnmatch, graphlib, zoneinfo

This commit is contained in:
Shunsuke Shibayama 2024-06-30 13:13:38 +09:00
parent f299962ebc
commit d62bce689b
5 changed files with 57 additions and 1 deletions

View file

@ -0,0 +1,20 @@
.nested_scopes: ._Feature
.generators: ._Feature
.division: ._Feature
.absolute_import: ._Feature
.with_statement: ._Feature
.print_function: ._Feature
.unicode_literals: ._Feature
.generator_stop: ._Feature
.annotations: ._Feature
._Feature: ClassType
._Feature.
optional: (Nat, Nat, Nat, Str, Nat)
mandatory: (Nat, Nat, Nat, Str, Nat) or NoneType
compiler_flag: Nat
__call__: (
optional: (Nat, Nat, Nat, Str, Nat),
mandatory: (Nat, Nat, Nat, Str, Nat) or NoneType,
compiler_flag : Nat,
) -> ._Feature

View file

@ -1,6 +1,17 @@
.DataClass = 'dataclass': ClassType
.DataClass.
__call__: (init := Bool, repr := Bool, eq := Bool, order := Bool, unsafe_hash := Bool, frozen := Bool, match_args := Bool, kw_only := Bool, slots := Bool, weakref_slots := Bool) -> (ClassType -> ClassType)
__call__: (
init := Bool,
repr := Bool,
eq := Bool,
order := Bool,
unsafe_hash := Bool,
frozen := Bool,
match_args := Bool,
kw_only := Bool,
slots := Bool,
weakref_slots := Bool
) -> (ClassType -> ClassType)
.is_dataclass: (obj: Obj) -> Bool

View file

@ -0,0 +1,4 @@
.fnmatch: (name: Str, pat: Str) -> Bool
.fnmatchcase: (name: Str, pat: Str) -> Bool
.filter: (names: Iterable(Str), pat: Str) -> List(Str)
.translate: (pat: Str) -> Str

View file

@ -0,0 +1,12 @@
.TopologicalSorter!: ClassType
.TopologicalSorter!.
__call__: (graph := Obj) -> .TopologicalSorter!
prepare!: (self: .TopologicalSorter!) => NoneType
add!: (self: .TopologicalSorter!, node: Obj, *predecessors: Obj) => NoneType
done!: (self: .TopologicalSorter!, *nodes: Obj) => NoneType
is_active: (self: .TopologicalSorter!) -> Bool
get_ready: (self: .TopologicalSorter!) -> List Obj
static_order: (self: .TopologicalSorter!) -> Iterator Obj
.CycleError: ClassType
.CycleError <: ValueError

View file

@ -0,0 +1,9 @@
.available_zones: Set Str, _
.TZPATH: [Str; _]
.ZoneInfo: ClassType
.ZoneInfo.
key: Str
__call__: (key: Str) -> .ZoneInfo
from_file: (fobj: FileLike, key := Str) -> .ZoneInfo
__str__: (self: .ZoneInfo) -> Str