Add importlib, io, socket, sys, time

This commit is contained in:
Shunsuke Shibayama 2022-08-31 14:19:25 +09:00
parent 8454e079af
commit a8e4658c67
9 changed files with 196 additions and 0 deletions

View file

@ -196,8 +196,13 @@ fn convert_to_python_attr(class: &str, uniq_obj_name: Option<&str>, name: Str) -
("Array!", _, "push!") => Str::ever("append"),
("Complex" | "Real" | "Int" | "Nat" | "Float", _, "Real") => Str::ever("real"),
("Complex" | "Real" | "Int" | "Nat" | "Float", _, "Imag") => Str::ever("imag"),
("StringIO!", _, "getvalue!") => Str::ever("getvalue"),
("Module", Some("importlib"), "reload!") => Str::ever("reload"),
("Module", Some("random"), "randint!") => Str::ever("randint"),
("Module", Some("random"), "choice!") => Str::ever("choice"),
("Module", Some("sys"), "setrecurtionlimit!") => Str::ever("setrecurtionlimit"),
("Module", Some("time"), "sleep!") => Str::ever("sleep"),
("Module", Some("time"), "time!") => Str::ever("time"),
_ => name,
}
}