Summary: OPTLINK ruins the day yet again
           Product: D
           Version: future
          Platform: Other
        OS/Version: Windows
            Status: NEW
          Severity: regression
          Priority: P2
         Component: Optlink

--- Comment #0 from 2010-03-26 04:27:51 PDT ---
Compile the following source code with dmd x.d -g

OPTLINK will crash:

Unexpected OPTLINK Termination at EIP=0041338F

EAX=6F733231 EBX=6F733231 ECX=00000000 EDX=1D8CC66F
ESI=0033FE7C EDI=1D8CC66F EBP=0033FED4 ESP=0033FD60

(copied by hand)

It doesn't crash without -g. It doesn't crash when you reduce the number of
template instantiations, or reduce the references to instantiated templates
(you can vary these by changing the numbers in the program).

Bug 3870 is probably the same bug, but I can't possibly know (the register
contents are completely different).

The test case works perfectly fine on Linux.

---- this is file x.d:
template Tuple(T...) {
    alias T Tuple;

template Repeat(int count) {
    static if (!count) {
        alias Tuple!() Repeat;
    } else {
        alias Tuple!(count-1, Repeat!(count-1)) Repeat;

void sometemplate(int T)() {
    foreach (x; Repeat!(62)) {

void main() {
    foreach (x; Repeat!(298)) {

Configure issuemail:
------- You are receiving this mail because: -------

Reply via email to