We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 77939d2 commit b864e5dCopy full SHA for b864e5d
vm/src/stdlib/imp.rs
@@ -155,8 +155,14 @@ mod _imp {
155
}
156
157
#[pyfunction]
158
- fn _frozen_module_names(_code: PyObjectRef) {
159
- // TODO:
+ fn _frozen_module_names(vm: &VirtualMachine) -> PyResult<Vec<PyObjectRef>> {
+ let names = vm
160
+ .state
161
+ .frozen
162
+ .keys()
163
+ .map(|&name| vm.ctx.new_str(name).into())
164
+ .collect();
165
+ Ok(names)
166
167
168
#[allow(clippy::type_complexity)]
0 commit comments