Skip to content

Commit 2a5c31c

Browse files
committed
Rename the default argument 'def' to 'default'
Fixes: #65492
1 parent 89e645a commit 2a5c31c

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/libcore/option.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -395,10 +395,10 @@ impl<T> Option<T> {
395395
/// ```
396396
#[inline]
397397
#[stable(feature = "rust1", since = "1.0.0")]
398-
pub fn unwrap_or(self, def: T) -> T {
398+
pub fn unwrap_or(self, default: T) -> T {
399399
match self {
400400
Some(x) => x,
401-
None => def,
401+
None => default,
402402
}
403403
}
404404

0 commit comments

Comments
 (0)