mirror of
https://github.com/erg-lang/erg.git
synced 2025-08-04 10:49:54 +00:00
feat: add codecs/warnings
module
This commit is contained in:
parent
3366043a2d
commit
cdabb2e546
3 changed files with 160 additions and 0 deletions
52
crates/erg_compiler/lib/pystd/warnings.d.er
Normal file
52
crates/erg_compiler/lib/pystd/warnings.d.er
Normal file
|
@ -0,0 +1,52 @@
|
|||
.CatchWarnings = 'catch_warnings': ClassType
|
||||
.CatchWarnings.
|
||||
__call__: () => CatchWarnings
|
||||
.catch_warnings!: () => CatchWarnings
|
||||
|
||||
.warn!: (
|
||||
message: Str,
|
||||
category := Exception,
|
||||
stacklevel := Nat,
|
||||
source := Obj,
|
||||
skip_file_prefixes := Iterable(Str),
|
||||
) => NoneType
|
||||
.warn_explicit!: (
|
||||
message: Str,
|
||||
category: Exception,
|
||||
filename: Str,
|
||||
lineno: Nat,
|
||||
module := Str,
|
||||
registry := GenericDict,
|
||||
module_globals := GenericDict,
|
||||
source := Obj,
|
||||
) => NoneType
|
||||
.showwarning!: (
|
||||
message: Str,
|
||||
category: Exception,
|
||||
filename: Str,
|
||||
lineno: Nat,
|
||||
file := FileLike!,
|
||||
line := Str,
|
||||
) => NoneType
|
||||
.formatwarning!: (
|
||||
message: Str,
|
||||
category: Exception,
|
||||
filename: Str,
|
||||
lineno: Nat,
|
||||
line := Str,
|
||||
) => Str
|
||||
.filterwarnings!: (
|
||||
action: Str,
|
||||
message := Str,
|
||||
category := Exception,
|
||||
module := Str,
|
||||
lineno := Nat,
|
||||
append := Bool,
|
||||
) => NoneType
|
||||
.simplefilter!: (
|
||||
action: Str,
|
||||
category := Exception,
|
||||
lineno := Nat,
|
||||
append := Bool,
|
||||
) => NoneType
|
||||
.resetwarnings!: () => NoneType
|
Loading…
Add table
Add a link
Reference in a new issue