Rollup merge of #64255 - varkor:bool-to-option, r=Centril

Add methods for converting `bool` to `Option<T>`

This provides a reference implementation for https://github.com/rust-lang/rfcs/pull/2757.
This commit is contained in:
Mazdak Farrokhzad 2019-09-08 00:07:36 +02:00 committed by GitHub
commit cd3cb281da
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
10 changed files with 71 additions and 1 deletions

View file

@ -244,6 +244,7 @@ pub fn collect<'tcx>(tcx: TyCtxt<'tcx>) -> LanguageItems {
language_item_table! {
// Variant name, Name, Method name, Target;
BoolImplItem, "bool", bool_impl, Target::Impl;
CharImplItem, "char", char_impl, Target::Impl;
StrImplItem, "str", str_impl, Target::Impl;
SliceImplItem, "slice", slice_impl, Target::Impl;