Thread overview | ||||||||
---|---|---|---|---|---|---|---|---|
|
June 23, 2006 Strange DMD Assertion failure | ||||
---|---|---|---|---|
| ||||
Compiling code that worked fine with DMD 0.160 now fails on DMD 0.161 with the following compiler error: Assertion failure: 'next' on line 2226 in file 'mtype.c' Looking at mtype.c I notice the assert makes sure 'next' is not null, but on the next line it checks 'next' for null and acts appropriately; also, in the same function of DMD 0.160 this null check is not there, only the assert, so it leads me to believe that perhaps the new compiler now allows a null 'next' but the assert was left accidentally. I tried simplifying my code to make a small reproducable example, but this project is huge and the changes were causing template mixin forward reference errors. Compiling with -v shows it fails on the first semantic pass. - Chris |
June 23, 2006 Re: Strange DMD Assertion failure | ||||
---|---|---|---|---|
| ||||
Posted in reply to Chris Miller | Chris Miller wrote:
> Compiling code that worked fine with DMD 0.160 now fails on DMD 0.161 with the following compiler error:
> Assertion failure: 'next' on line 2226 in file 'mtype.c'
>
> Looking at mtype.c I notice the assert makes sure 'next' is not null, but on the next line it checks 'next' for null and acts appropriately; also, in the same function of DMD 0.160 this null check is not there, only the assert, so it leads me to believe that perhaps the new compiler now allows a null 'next' but the assert was left accidentally.
>
> I tried simplifying my code to make a small reproducable example, but this project is huge and the changes were causing template mixin forward reference errors. Compiling with -v shows it fails on the first semantic pass.
There's no way to track this down without a reproducible test case.
|
June 23, 2006 Re: Strange DMD Assertion failure | ||||
---|---|---|---|---|
| ||||
Posted in reply to Walter Bright | Walter Bright wrote:
> Chris Miller wrote:
>> Compiling code that worked fine with DMD 0.160 now fails on DMD 0.161
>> with the following compiler error:
>> Assertion failure: 'next' on line 2226 in file 'mtype.c'
>>
>> Looking at mtype.c I notice the assert makes sure 'next' is not null, but on the next line it checks 'next' for null and acts appropriately; also, in the same function of DMD 0.160 this null check is not there, only the assert, so it leads me to believe that perhaps the new compiler now allows a null 'next' but the assert was left accidentally.
>>
>> I tried simplifying my code to make a small reproducable example, but this project is huge and the changes were causing template mixin forward reference errors. Compiling with -v shows it fails on the first semantic pass.
>
> There's no way to track this down without a reproducible test case.
Have a look at Carlos Santander's post "ice returning a delegate".
|
June 23, 2006 Re: Strange DMD Assertion failure | ||||
---|---|---|---|---|
| ||||
Posted in reply to Walter Bright | Walter Bright wrote: > Chris Miller wrote: >> Compiling code that worked fine with DMD 0.160 now fails on DMD 0.161 with the following compiler error: >> Assertion failure: 'next' on line 2226 in file 'mtype.c' >> >> Looking at mtype.c I notice the assert makes sure 'next' is not null, but on the next line it checks 'next' for null and acts appropriately; also, in the same function of DMD 0.160 this null check is not there, only the assert, so it leads me to believe that perhaps the new compiler now allows a null 'next' but the assert was left accidentally. >> >> I tried simplifying my code to make a small reproducable example, but this project is huge and the changes were causing template mixin forward reference errors. Compiling with -v shows it fails on the first semantic pass. > > There's no way to track this down without a reproducible test case. template tpl() { typeof( {} ) foo; } int main(char[][] args) { tpl!(); return 0; } » Assertion failure: 'next' on line 2226 in file 'mtype.c' Not sure if this is the same as bug 220, since that one asserts on a different line (altough on the same file), and the test case seems different. -- Bruno Medeiros - CS/E student http://www.prowiki.org/wiki4d/wiki.cgi?BrunoMedeiros#D |
June 29, 2006 Re: Strange DMD Assertion failure | ||||
---|---|---|---|---|
| ||||
Posted in reply to Bruno Medeiros Attachments: | Bruno Medeiros schrieb am 2006-06-23: > [snip] > template tpl() { > typeof( {} ) foo; > } > > int main(char[][] args) > { > tpl!(); > return 0; > } > > » Assertion failure: 'next' on line 2226 in file 'mtype.c' > > Not sure if this is the same as bug 220, since that one asserts on a different line (altough on the same file), and the test case seems different. Added to DStress as http://dstress.kuehne.cn/run/b/bug_mtype_2226_A.d http://dstress.kuehne.cn/run/b/bug_mtype_2226_B.d Thomas |
July 01, 2006 Re: Strange DMD Assertion failure | ||||
---|---|---|---|---|
| ||||
Posted in reply to Thomas Kuehne | Thomas Kuehne wrote: > -----BEGIN PGP SIGNED MESSAGE----- > Hash: SHA1 > > Bruno Medeiros schrieb am 2006-06-23: > > [snip] > >> template tpl() { >> typeof( {} ) foo; >> } >> >> int main(char[][] args) >> { >> tpl!(); >> return 0; >> } >> >> � Assertion failure: 'next' on line 2226 in file 'mtype.c' >> >> Not sure if this is the same as bug 220, since that one asserts on a different line (altough on the same file), and the test case seems different. > > Added to DStress as > http://dstress.kuehne.cn/run/b/bug_mtype_2226_A.d > http://dstress.kuehne.cn/run/b/bug_mtype_2226_B.d > > Thomas > > > -----BEGIN PGP SIGNATURE----- > > iD8DBQFEo7ja3w+/yD4P9tIRApoZAKCkzviTOmEau6ZnPqYwlHVKtnwqfACfbqbh > apH8t/ytCqHn2K2//Ens2JU= > =oPTq > -----END PGP SIGNATURE----- Seems this was fixed in DMD 162. -- Bruno Medeiros - CS/E student http://www.prowiki.org/wiki4d/wiki.cgi?BrunoMedeiros#D |
Copyright © 1999-2021 by the D Language Foundation