danielpclark / rutie

“The Tie Between Ruby and Rust.”

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Issue in docstring for Array::to_enum

jhwiig opened this issue · comments

rutie/src/class/array.rs

Lines 507 to 527 in 8b95535

/// Sorts the array in place.
///
/// # Examples
///
/// ```
/// use rutie::{Array, Fixnum, Object, VM, VerifiedObject, Enumerator};
/// # VM::init();
///
/// let enumerator = Array::new().push(Fixnum::new(2)).push(Fixnum::new(1)).to_enum();
///
/// assert!(Enumerator::is_correct_type(&enumerator), "incorrect type!");
/// ```
///
/// Ruby:
///
/// ```ruby
/// enumerator = [2, 1].to_enum
///
/// Enumerator === enumerator
/// ```
pub fn to_enum(&self) -> Enumerator {

Currently the overview says Sorts the array in place. for Array::to_enum.

Looks like it is copy/pasted from above.

Thanks for reporting this! 👍