]> git.lizzy.rs Git - rust.git/commit
Lazily construct panic messages in char_lit().
authorNicholas Nethercote <nnethercote@mozilla.com>
Mon, 12 Sep 2016 04:31:51 +0000 (14:31 +1000)
committerNicholas Nethercote <nnethercote@mozilla.com>
Mon, 12 Sep 2016 07:33:02 +0000 (17:33 +1000)
commit826f673664023e79e86409296d3d67527c9b0a5a
tree2ab7f985fc87275a6c48a174a7160a4d58898622
parent4c274b6aea00c2327211e8295f4d97ee6e624a2b
Lazily construct panic messages in char_lit().

This reduces the time taken to run
`rustc -Zparse-only rustc-benchmarks/issue-32278-big-array-of-strings`
from 0.18s to 0.15s on my machine, and reduces the number of
instructions (as measured by Cachegrind) from 1.34B to 1.01B.

With the change applied, the time to fully compile that benchmark is
1.96s, so this is a 1.5% improvement.
src/libsyntax/parse/mod.rs