Skip to content

Commit d9da347

Browse files
committed
Change from and to to _from and _to
This to avoid warning: unused variable: `from`, #[warn(unused_variable)] on by default.
1 parent 62b48bd commit d9da347

File tree

1 file changed

+6
-6
lines changed

1 file changed

+6
-6
lines changed

src/libcore/ops.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -692,15 +692,15 @@ pub trait IndexMut<Index, Result> {
692692
* println!("Slicing!");
693693
* self
694694
* }
695-
* fn slice_from_or_fail<'a>(&'a self, from: &Foo) -> &'a Foo {
695+
* fn slice_from_or_fail<'a>(&'a self, _from: &Foo) -> &'a Foo {
696696
* println!("Slicing!");
697697
* self
698698
* }
699-
* fn slice_to_or_fail<'a>(&'a self, to: &Foo) -> &'a Foo {
699+
* fn slice_to_or_fail<'a>(&'a self, _to: &Foo) -> &'a Foo {
700700
* println!("Slicing!");
701701
* self
702702
* }
703-
* fn slice_or_fail<'a>(&'a self, from: &Foo, to: &Foo) -> &'a Foo {
703+
* fn slice_or_fail<'a>(&'a self, _from: &Foo, _to: &Foo) -> &'a Foo {
704704
* println!("Slicing!");
705705
* self
706706
* }
@@ -741,15 +741,15 @@ pub trait Slice<Idx, Sized? Result> for Sized? {
741741
* println!("Slicing!");
742742
* self
743743
* }
744-
* fn slice_from_or_fail_mut<'a>(&'a mut self, from: &Foo) -> &'a mut Foo {
744+
* fn slice_from_or_fail_mut<'a>(&'a mut self, _from: &Foo) -> &'a mut Foo {
745745
* println!("Slicing!");
746746
* self
747747
* }
748-
* fn slice_to_or_fail_mut<'a>(&'a mut self, to: &Foo) -> &'a mut Foo {
748+
* fn slice_to_or_fail_mut<'a>(&'a mut self, _to: &Foo) -> &'a mut Foo {
749749
* println!("Slicing!");
750750
* self
751751
* }
752-
* fn slice_or_fail_mut<'a>(&'a mut self, from: &Foo, to: &Foo) -> &'a mut Foo {
752+
* fn slice_or_fail_mut<'a>(&'a mut self, _from: &Foo, _to: &Foo) -> &'a mut Foo {
753753
* println!("Slicing!");
754754
* self
755755
* }

0 commit comments

Comments
 (0)