File tree Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -132,15 +132,11 @@ macro_rules! int_impl {
132
132
///
133
133
/// Leading and trailing whitespace represent an error.
134
134
///
135
- /// # Arguments
136
- ///
137
- /// * src - A string slice
138
- /// * radix - The base to use. Must lie in the range [2 .. 36]
139
- ///
140
- /// # Return value
135
+ /// # Examples
141
136
///
142
- /// `Err(ParseIntError)` if the string did not represent a valid number.
143
- /// Otherwise, `Ok(n)` where `n` is the integer represented by `src`.
137
+ /// ```
138
+ /// assert_eq!(u32::from_str_radix("A", 16), Some(10));
139
+ /// ```
144
140
#[ stable( feature = "rust1" , since = "1.0.0" ) ]
145
141
#[ allow( deprecated) ]
146
142
pub fn from_str_radix( src: & str , radix: u32 ) -> Result <$T, ParseIntError > {
You can’t perform that action at this time.
0 commit comments