diff --git a/src/libcore/str.rs b/src/libcore/str.rs index 419455e2399..50005c7b486 100644 --- a/src/libcore/str.rs +++ b/src/libcore/str.rs @@ -1783,6 +1783,9 @@ impl extensions for str { "] #[inline] fn is_whitespace() -> bool { is_whitespace(self) } + #[inline] + #[doc ="Returns the size in bytes not counting the null terminator"] + fn len() -> uint { len(self) } #[doc = " Returns a slice of the given string from the byte range [`begin`..`end`)