Rename all ParseSess
variables/fields/lifetimes as psess
.
Existing names for values of this type are `sess`, `parse_sess`, `parse_session`, and `ps`. `sess` is particularly annoying because that's also used for `Session` values, which are often co-located, and it can be difficult to know which type a value named `sess` refers to. (That annoyance is the main motivation for this change.) `psess` is nice and short, which is good for a name used this much. The commit also renames some `parse_sess_created` values as `psess_created`.
This commit is contained in:
parent
4260f7ec67
commit
80d2bdb619
98 changed files with 653 additions and 687 deletions
|
@ -590,7 +590,7 @@ impl<'a, 'tcx> Resolver<'a, 'tcx> {
|
|||
_ => unreachable!(),
|
||||
};
|
||||
if soft_custom_inner_attributes_gate {
|
||||
self.tcx.sess.parse_sess.buffer_lint(SOFT_UNSTABLE, path.span, node_id, msg);
|
||||
self.tcx.sess.psess.buffer_lint(SOFT_UNSTABLE, path.span, node_id, msg);
|
||||
} else {
|
||||
feature_err(&self.tcx.sess, sym::custom_inner_attributes, path.span, msg).emit();
|
||||
}
|
||||
|
@ -601,7 +601,7 @@ impl<'a, 'tcx> Resolver<'a, 'tcx> {
|
|||
&& path.segments[0].ident.name == sym::diagnostic
|
||||
&& path.segments[1].ident.name != sym::on_unimplemented
|
||||
{
|
||||
self.tcx.sess.parse_sess.buffer_lint(
|
||||
self.tcx.sess.psess.buffer_lint(
|
||||
UNKNOWN_OR_MALFORMED_DIAGNOSTIC_ATTRIBUTES,
|
||||
path.segments[1].span(),
|
||||
node_id,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue