#[noop_returns]Expand description
Makes the tagged function/method a no-op that returns the given expression.
#[noop_returns(EXPR)] replaces the function or method body with { EXPR }.
It can be applied to:
- a free function or a single method, whose body becomes
{ EXPR }, or - an entire
implblock, where every method returnsEXPR, except for methods carrying their own#[noop_returns(OTHER)], which returnOTHER.
Applying it to anything else is an error.
Inside a #[make_noop] impl block this attribute overrides the default
Default::default() return for that method; used anywhere else it stands on
its own.