ARMANRIAZIRUSTERROR [E0782]: Merkmalobjekte müssen das Schlüsselwort "Dyn" enthalten

fn main() -> Result<(), Error> {
    let f = File::open("hello.txt")?;
      Ok(())
}
//folowing is not error exist
use std::error::Error;
use std::fs::File;

fn main() -> Result<(), Box<dyn Error>> {
    let f = File::open("hello.txt")?;

    Ok(())
}

    
ArmanRiazi