Probably related to https://issues.dlang.org/show_bug.cgi?id=15855, though it apparently applies to more than just the for keyword. Example file contents (one file per line): o[{scope(x o[{template d(={for typeof){for p[{alias p(={alias Similar to the linked issue, DMD spits out some error messages and then terminates with a segfault. DMD v2.070.2
(In reply to Alex Parrill from comment #0) > d(={for > typeof){for These two don't segfault anymore with git master (6199fd3).
none of these segfault anymore
Reopening. I still get segfaults. Tested with git master (DMD64 D Compiler v2.083.0-326-g1e902fc61). Remember to test one line at a time, not all at once.
pull : https://github.com/dlang/dmd/pull/9007
Commits pushed to master at https://github.com/dlang/dmd https://github.com/dlang/dmd/commit/866c0a3f3ac21d506140b4806bb9134334683f21 fix issue 15876 - various cases of SEGFAULT when formatting parser errors https://github.com/dlang/dmd/commit/da15e2f2e21c7a81dea8022dfbe61d0bdec18258 Merge pull request #9007 from BBasile/hdrgen-unsafe-accesses fix issue 15876 - various cases of SEGFAULT when formatting parser errors merged-on-behalf-of: Nicholas Wilson <thewilsonator@users.noreply.github.com>