You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: list.rs
    path of file: ./repos/trezor-firmware/core/embed/rust/src/micropython
    
    the code of the file until where you have to start completion: use core::{convert::TryFrom, ptr};

use crate::error::Error;

use super::{ffi, gc::Gc, obj::Obj, runtime::catch_exception};

pub type List = ffi::mp_obj_list_t;

impl List {
    pub fn alloc(values: &[Obj]) -> Result<Gc<Self>, Err
    
    pub fn append(&mut self, value: Obj) -> Result<(), Error> {
        unsafe {
            // SAFETY: self is borrowed mutably.
            let list = self.as_mut_obj();
            // EXCEPTION: Will raise if allocation fails.
            catch_exception(|| {
                ffi::mp_obj_list_append(list, value);
            })
        }
    }