Bug 14640 – Special grammar for skipping unittest blocks

Status
NEW
Severity
enhancement
Priority
P4
Component
dmd
Product
D
Version
D2
Platform
All
OS
All
Creation time
2015-06-01T19:31:08Z
Last change time
2024-12-13T18:43:06Z
Assigned to
No Owner
Creator
Walter Bright
Moved to GitHub: dmd#18996 →

Comments

Comment #0 by bugzilla — 2015-06-01T19:31:08Z
A recent pull request: https://github.com/D-Programming-Language/dmd/pull/4704 reduces memory consumed by parsing unittest blocks that are subsequently ignored. A further refinement to that suggested by Andrei was to switch to a specialized grammar for it, that only recognizes: . { . } . comments . string literals . anything else so it can lex much faster, i.e. it won't need to enter identifiers into the stringtable or convert integer literals to integers. The idea is we wish to encourage extensive unit tests, but not punish users for having them with slower compile times.
Comment #1 by robert.schadek — 2024-12-13T18:43:06Z
THIS ISSUE HAS BEEN MOVED TO GITHUB https://github.com/dlang/dmd/issues/18996 DO NOT COMMENT HERE ANYMORE, NOBODY WILL SEE IT, THIS ISSUE HAS BEEN MOVED TO GITHUB