Visitar URL original
Update vm/src/builtins/list.rs · RustPython/RustPython@ce73615 · GitHub
Skip to content

Commit ce73615

Browse files
authored
Update vm/src/builtins/list.rs
1 parent eea1a1f commit ce73615

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

‎vm/src/builtins/list.rs‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ impl ToPyObject for Vec<PyObjectRef> {
6565
impl PyList {
6666
#[deprecated(note = "use PyList::from(...).into_ref() instead")]
6767
pub fn new_ref(elements: Vec<PyObjectRef>, ctx: &Context) -> PyRef<Self> {
68-
PyRef::new_ref(Self::from(elements), ctx.types.list_type.to_owned(), None)
68+
Self::from(elements).into_ref(ctx)
6969
}
7070

7171
pub fn borrow_vec(&self) -> PyMappedRwLockReadGuard<'_, [PyObjectRef]> {

0 commit comments

Comments
 (0)