Make FuncEnvironment::return_mode() default to NormalReturns.
`NormalReturns` is what we expect most users will normally want.
This commit is contained in:
committed by
Benjamin Bouvier
parent
a19c6088f0
commit
2de5542139
@@ -230,7 +230,9 @@ pub trait FuncEnvironment {
|
|||||||
/// Should the code be structured to use a single `fallthrough_return` instruction at the end
|
/// Should the code be structured to use a single `fallthrough_return` instruction at the end
|
||||||
/// of the function body, rather than `return` instructions as needed? This is used by VMs
|
/// of the function body, rather than `return` instructions as needed? This is used by VMs
|
||||||
/// to append custom epilogues.
|
/// to append custom epilogues.
|
||||||
fn return_mode(&self) -> ReturnMode;
|
fn return_mode(&self) -> ReturnMode {
|
||||||
|
ReturnMode::NormalReturns
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
/// An object satisfying the `ModuleEnvironment` trait can be passed as argument to the
|
/// An object satisfying the `ModuleEnvironment` trait can be passed as argument to the
|
||||||
|
|||||||
Reference in New Issue
Block a user