Skip to content

documentation buglet in Traits section #26287

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
tromey opened this issue Jun 14, 2015 · 3 comments
Closed

documentation buglet in Traits section #26287

tromey opened this issue Jun 14, 2015 · 3 comments

Comments

@tromey
Copy link
Contributor

tromey commented Jun 14, 2015

I am reading here:

http://doc.rust-lang.org/stable/book/traits.html#where-clause

I also checked the nightly docs, which are the same.

The example says:

// can be called with T == i64
fn inverse<T>() -> T
        // this is using ConvertTo as if it were "ConvertFrom<i32>"
        where i32: ConvertTo<T> {
    1i32.convert()
}

However, I did not see any other mention of li32. It seems like it should probably be the name of a formal argument to inverse.

@Stebalien
Copy link
Contributor

1i32 = one i32. Fonts...

@tromey
Copy link
Contributor Author

tromey commented Jun 15, 2015

Ouch, I did not see that at all. How about making it "79i32" or something like that?

@Stebalien
Copy link
Contributor

Alternatively, we could ditch the serifed font.

steveklabnik added a commit to steveklabnik/rust that referenced this issue Jun 15, 2015
The font can make this hard to read, and we don't even strictly need
the annotation, so let's just remove it

Fixes rust-lang#26287
bors added a commit that referenced this issue Jun 17, 2015
The font can make this hard to read, and we don't even strictly need
the annotation, so let's just remove it

Fixes #26287
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants