Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

postfix-match

postfix-match adds the feature for matching upon values postfix the expressions that generate the values.

The tracking issue for this feature is: #121618.


#![allow(unused)] #![feature(postfix_match)] fn main() { enum Foo { Bar, Baz } fn get_foo() -> Foo { Foo::Bar } get_foo().match { Foo::Bar => {}, Foo::Baz => panic!(), } }