mirror of
https://github.com/RustPython/RustPython.git
synced 2026-10-28 18:59:04 +08:00
Rename builtin io to _io
This commit is contained in:
1 parent
fbaff7fd50
commit
a57f38b07f
3 files changed
+3
-2
No files matched your search
+1
-1
@@ -471,7 +471,7 @@ pub fn make_module(vm: &VirtualMachine) -> PyObjectRef {
|
||||
"getvalue" => ctx.new_rustfunc(bytes_io_getvalue)
|
||||
});
|
||||
|
||||
py_module!(vm, "io", {
|
||||
py_module!(vm, "_io", {
|
||||
"open" => ctx.new_rustfunc(io_open),
|
||||
"IOBase" => io_base,
|
||||
"RawIOBase" => raw_io_base,
|
||||
|
||||
@@ -61,7 +61,7 @@ pub fn get_module_inits() -> HashMap<String, StdlibInitFunc> {
|
||||
// disable some modules on WASM
|
||||
#[cfg(not(target_arch = "wasm32"))]
|
||||
{
|
||||
modules.insert("io".to_string(), Box::new(io::make_module));
|
||||
modules.insert("_io".to_string(), Box::new(io::make_module));
|
||||
modules.insert("_os".to_string(), Box::new(os::make_module));
|
||||
modules.insert("socket".to_string(), Box::new(socket::make_module));
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user