<feed xmlns='http://www.w3.org/2005/Atom'>
<title>rust/src/libsyntax, branch perf-tmp</title>
<subtitle>https://github.com/rust-lang/rust
</subtitle>
<id>http://git.dreamy.place/mirrors/rust/atom?h=perf-tmp</id>
<link rel='self' href='http://git.dreamy.place/mirrors/rust/atom?h=perf-tmp'/>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/'/>
<updated>2020-02-29T17:47:10+00:00</updated>
<entry>
<title>Move directory `libsyntax` -&gt; `librustc_ast`</title>
<updated>2020-02-29T17:47:10+00:00</updated>
<author>
<name>Vadim Petrochenkov</name>
<email>vadim.petrochenkov@gmail.com</email>
</author>
<published>2020-02-29T17:10:08+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=e94d3b70cb495df83230cff9ef5bb00f235883e4'/>
<id>urn:sha1:e94d3b70cb495df83230cff9ef5bb00f235883e4</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Rollup merge of #69384 - petrochenkov:nounnorm, r=Centril</title>
<updated>2020-02-28T16:17:26+00:00</updated>
<author>
<name>Mazdak Farrokhzad</name>
<email>twingoow@gmail.com</email>
</author>
<published>2020-02-28T16:17:26+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=3828fa2852bf5e622267b24c4eda74e4fa6cb5f9'/>
<id>urn:sha1:3828fa2852bf5e622267b24c4eda74e4fa6cb5f9</id>
<content type='text'>
parser: `token` -&gt; `normalized_token`, `nonnormalized_token` -&gt; `token`

So, after https://github.com/rust-lang/rust/pull/69006, its follow-ups and an attempt to remove `Parser::prev_span` I came to the conclusion that the unnormalized token and its span is what you want in most cases, so it should be default.

Normalization only makes difference in few cases where we are checking against `token::Ident` or `token::Lifetime` specifically.
This PR uses `normalized_token` for those cases.

Using normalization explicitly means that people writing code should remember about `NtIdent` and `NtLifetime` in general. (That is alleviated by the fact that `token.ident()` and `fn parse_ident_*` are already written.)
Remembering about `NtIdent`, was, however, already the case, kind of, because the implicit normalization was performed only for the current/previous token, but not for things like `look_ahead`.
As a result, most of token classification methods in `token.rs` already take `NtIdent` into account (this PR fixes a few pre-existing minor mistakes though).

The next step is removing `normalized(_prev)_token` entirely and replacing it with `token.ident()` (mostly) and `token.normalize()` (occasionally).
I want to make it a separate PR for that and run it though perf.
`normalized_token` filled on every bump has both a potential to avoid repeated normalization, and to do unnecessary work in advance (it probably doesn't matter anyway, the normalization is very cheap).

r? @Centril
</content>
</entry>
<entry>
<title>don't use .into() to convert types into identical types.</title>
<updated>2020-02-27T22:32:46+00:00</updated>
<author>
<name>Matthias Krüger</name>
<email>matthias.krueger@famsik.de</email>
</author>
<published>2020-02-25T17:10:34+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=7be94a8a958750cf57c0fa41ad7797a2cd1630de'/>
<id>urn:sha1:7be94a8a958750cf57c0fa41ad7797a2cd1630de</id>
<content type='text'>
example:
    let s: String = format!("hello").into();
</content>
</entry>
<entry>
<title>syntax: Remove `Nt(Impl,Trait,Foreign)Item`</title>
<updated>2020-02-24T17:25:32+00:00</updated>
<author>
<name>Vadim Petrochenkov</name>
<email>vadim.petrochenkov@gmail.com</email>
</author>
<published>2020-02-24T09:06:45+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=d134385823525255546deaa930af2d5b1eada0df'/>
<id>urn:sha1:d134385823525255546deaa930af2d5b1eada0df</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Add some missing support for `NtIdent`</title>
<updated>2020-02-24T10:03:58+00:00</updated>
<author>
<name>Vadim Petrochenkov</name>
<email>vadim.petrochenkov@gmail.com</email>
</author>
<published>2020-02-22T17:19:49+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=59261f0a7cf264f16e2b6a4e87d4249b212e920e'/>
<id>urn:sha1:59261f0a7cf264f16e2b6a4e87d4249b212e920e</id>
<content type='text'>
</content>
</entry>
<entry>
<title>parse/ast: move `Defaultness` into variants.</title>
<updated>2020-02-23T23:59:38+00:00</updated>
<author>
<name>Mazdak Farrokhzad</name>
<email>twingoow@gmail.com</email>
</author>
<published>2020-02-23T09:24:30+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=62930d31514d6d9b4b0df3755d643f06f0d4212a'/>
<id>urn:sha1:62930d31514d6d9b4b0df3755d643f06f0d4212a</id>
<content type='text'>
</content>
</entry>
<entry>
<title>parser: tweak item kind wording</title>
<updated>2020-02-23T23:59:38+00:00</updated>
<author>
<name>Mazdak Farrokhzad</name>
<email>twingoow@gmail.com</email>
</author>
<published>2020-02-23T05:04:37+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=b01c1e2092b0d3c4e86aedf1e0875898fbde21e3'/>
<id>urn:sha1:b01c1e2092b0d3c4e86aedf1e0875898fbde21e3</id>
<content type='text'>
</content>
</entry>
<entry>
<title>ast: add `Defaultness` to `Item`, making `AssocItem` an alias.</title>
<updated>2020-02-23T23:59:38+00:00</updated>
<author>
<name>Mazdak Farrokhzad</name>
<email>twingoow@gmail.com</email>
</author>
<published>2020-02-22T02:29:17+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=7017058e6b289ea6253e62b9ffdae5dea036855f'/>
<id>urn:sha1:7017058e6b289ea6253e62b9ffdae5dea036855f</id>
<content type='text'>
</content>
</entry>
<entry>
<title>add `Span` to `ast::Defaultness::Default`.</title>
<updated>2020-02-23T23:59:38+00:00</updated>
<author>
<name>Mazdak Farrokhzad</name>
<email>twingoow@gmail.com</email>
</author>
<published>2020-02-22T01:01:53+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=fa2a792491ed28530146ee55a46128c05a8026ad'/>
<id>urn:sha1:fa2a792491ed28530146ee55a46128c05a8026ad</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Rollup merge of #69376 - petrochenkov:bumpwith, r=Centril</title>
<updated>2020-02-23T08:57:45+00:00</updated>
<author>
<name>Dylan DPC</name>
<email>dylan.dpc@gmail.com</email>
</author>
<published>2020-02-23T08:57:45+00:00</published>
<link rel='alternate' type='text/html' href='http://git.dreamy.place/mirrors/rust/commit/?id=d6414f5f8c30593cd250fddf315e6f0098c3239a'/>
<id>urn:sha1:d6414f5f8c30593cd250fddf315e6f0098c3239a</id>
<content type='text'>
parser: Cleanup `Parser::bump_with` and its uses

Follow-up to https://github.com/rust-lang/rust/pull/69006.
r? @Centril
</content>
</entry>
</feed>
