Remove unnecessary sigils around Symbol::as_str()
calls.
This commit is contained in:
parent
8cddcd39ba
commit
056d48a2c9
104 changed files with 189 additions and 192 deletions
|
@ -236,7 +236,7 @@ where
|
|||
|
||||
// These unwraps are safe because `get` ensures the meta item
|
||||
// is a name/value pair string literal.
|
||||
issue_num = match &*issue.unwrap().as_str() {
|
||||
issue_num = match issue.unwrap().as_str() {
|
||||
"none" => None,
|
||||
issue => {
|
||||
let emit_diag = |msg: &str| {
|
||||
|
@ -301,7 +301,7 @@ where
|
|||
|
||||
match (feature, reason, issue) {
|
||||
(Some(feature), reason, Some(_)) => {
|
||||
if !rustc_lexer::is_ident(&feature.as_str()) {
|
||||
if !rustc_lexer::is_ident(feature.as_str()) {
|
||||
handle_errors(
|
||||
&sess.parse_sess,
|
||||
attr.span,
|
||||
|
@ -535,7 +535,7 @@ pub fn eval_condition(
|
|||
return false;
|
||||
}
|
||||
};
|
||||
let min_version = match parse_version(&min_version.as_str(), false) {
|
||||
let min_version = match parse_version(min_version.as_str(), false) {
|
||||
Some(ver) => ver,
|
||||
None => {
|
||||
sess.span_diagnostic
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue