diff --git a/src/libcore/option.rs b/src/libcore/option.rs index 09d4076c7fbc7..9eb29eae7f75a 100644 --- a/src/libcore/option.rs +++ b/src/libcore/option.rs @@ -395,10 +395,10 @@ impl Option { /// ``` #[inline] #[stable(feature = "rust1", since = "1.0.0")] - pub fn unwrap_or(self, def: T) -> T { + pub fn unwrap_or(self, default: T) -> T { match self { Some(x) => x, - None => def, + None => default, } }