Skip to content
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

Add clearer error message using &str + &str #39116

Merged
merged 1 commit into from
Feb 2, 2017
Merged

Add clearer error message using &str + &str #39116

merged 1 commit into from
Feb 2, 2017

Commits on Jan 28, 2017

  1. Add clearer error message using &str + &str

    This is the first part of #39018. One of the common things for new users
    coming from more dynamic languages like JavaScript, Python or Ruby is to
    use `+` to concatenate strings. However, this doesn't work that way in
    Rust unless the first type is a `String`. This commit adds a check for
    this use case and outputs a new error as well as a suggestion to guide
    the user towards the desired behavior. It also adds a new test case to
    test the output of the error.
    mgattozzi committed Jan 28, 2017
    Configuration menu
    Copy the full SHA
    b54f593 View commit details
    Browse the repository at this point in the history