]> git.lizzy.rs Git - rust.git/commitdiff
Auto merge of #42155 - seanmonstar:unimplemented, r=sfackler
authorbors <bors@rust-lang.org>
Sun, 11 Jun 2017 18:56:27 +0000 (18:56 +0000)
committerbors <bors@rust-lang.org>
Sun, 11 Jun 2017 18:56:27 +0000 (18:56 +0000)
core: allow messages in unimplemented!() macro

This makes `unimplemented!()` match `unreachable!()`, allowing a message and possible formatting to be provided to better explain what and/or why something is not implemented.

I've used this myself in hyper for a while, include the type and method name, to better help while prototyping new modules, like `unimplemented!("Conn::poll_complete")`, or `unimplemented!("Conn::poll; state={:?}", state)`.

1  2 
src/libcore/macros.rs

Simple merge