Auto merge of #91957 - nnethercote:rm-SymbolStr, r=oli-obk
Remove `SymbolStr` This was originally proposed in https://github.com/rust-lang/rust/pull/74554#discussion_r466203544. As well as removing the icky `SymbolStr` type, it allows the removal of a lot of `&` and `*` occurrences. Best reviewed one commit at a time. r? `@oli-obk`
This commit is contained in:
commit
a41a6925ba
140 changed files with 354 additions and 415 deletions
|
@ -416,7 +416,7 @@ impl<'cx, 'tcx> MirBorrowckCtxt<'cx, 'tcx> {
|
|||
tcx,
|
||||
generics,
|
||||
&mut err,
|
||||
¶m.name.as_str(),
|
||||
param.name.as_str(),
|
||||
"Copy",
|
||||
None,
|
||||
);
|
||||
|
|
|
@ -206,7 +206,7 @@ impl<'cx, 'tcx> MirBorrowckCtxt<'cx, 'tcx> {
|
|||
{
|
||||
let local_info = &self.body.local_decls[local].local_info;
|
||||
if let Some(box LocalInfo::StaticRef { def_id, .. }) = *local_info {
|
||||
buf.push_str(&self.infcx.tcx.item_name(def_id).as_str());
|
||||
buf.push_str(self.infcx.tcx.item_name(def_id).as_str());
|
||||
} else {
|
||||
unreachable!();
|
||||
}
|
||||
|
@ -318,7 +318,7 @@ impl<'cx, 'tcx> MirBorrowckCtxt<'cx, 'tcx> {
|
|||
let decl = &self.body.local_decls[local];
|
||||
match self.local_names[local] {
|
||||
Some(name) if !decl.from_compiler_desugaring() => {
|
||||
buf.push_str(&name.as_str());
|
||||
buf.push_str(name.as_str());
|
||||
Ok(())
|
||||
}
|
||||
_ => Err(()),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue