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:
commit
cd3cb281da
10 changed files with 71 additions and 1 deletions
|
|
@ -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;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue