about summary refs log tree commit diff
path: root/src/rustllvm/RustWrapper.cpp
diff options
context:
space:
mode:
authorbors <bors@rust-lang.org>2017-02-02 07:39:07 +0000
committerbors <bors@rust-lang.org>2017-02-02 07:39:07 +0000
commit6abe64871e6e9c034d2541ee731fbe7b45893f7a (patch)
treed5bfc60a3d5dceb5eeff66e85524e8f3dcf72c0c /src/rustllvm/RustWrapper.cpp
parent1b6b20ac173eeb9ee50077a3e7614b37299cdbb7 (diff)
parentb54f593cffc40e9d07650b36629e60c48da6b11d (diff)
downloadrust-6abe64871e6e9c034d2541ee731fbe7b45893f7a.tar.gz
rust-6abe64871e6e9c034d2541ee731fbe7b45893f7a.zip
Auto merge of #39116 - mgattozzi:better-string-message, r=nrc
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.
Diffstat (limited to 'src/rustllvm/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions