Parser assertion

Andrea Fontana via Digitalmars-d digitalmars-d at puremagic.com
Tue Sep 29 02:01:51 PDT 2015


On Tuesday, 29 September 2015 at 08:59:35 UTC, Jonathan M Davis 
wrote:
> On Tuesday, 29 September 2015 at 08:51:42 UTC, Andrea Fontana 
> wrote:
>> This (wrong!) code:
>>
>> struct ExampleStruct(S) { }
>>
>> template ExampleTemplate(K)
>> {
>> 	enum ExampleTemplate(struct ExampleStruct(K)) = K;
>> }
>>
>> void main()
>> {
>> 	
>> }
>>
>> Trigger a parser error:
>>
>> dmd: parse.c:4226: Dsymbols* 
>> Parser::parseAutoDeclarations(StorageClass, const utf8_t*): 
>> Assertion `token.value == TOKassign' failed.
>>
>>
>> Should I fill a bug?
>
> You should always file a bug when the compiler fails an 
> assertion, segfaults, or otherwise crashes.
>
> - Jonathan M Davis

Done: https://issues.dlang.org/show_bug.cgi?id=15127




More information about the Digitalmars-d mailing list