D issues are now tracked on GitHub. This Bugzilla instance remains as a read-only archive.
Issue 4871 - ICE(mtype.c 875) const alias
Summary: ICE(mtype.c 875) const alias
Status: RESOLVED DUPLICATE of issue 4434
Alias: None
Product: D
Classification: Unclassified
Component: dmd (show other issues)
Version: D2
Hardware: Other Linux
: P2 minor
Assignee: No Owner
URL:
Keywords: ice-on-valid-code
Depends on:
Blocks:
 
Reported: 2010-09-14 22:47 UTC by AdamB
Modified: 2010-11-07 12:29 UTC (History)
4 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this issue.
Description AdamB 2010-09-14 22:47:30 UTC
Running dmd v2.048 the compiler seems to crash on code like this:

  alias ubyte foo;
  alias const foo * const_fooP;

  void main()
  {
  }

The error is:

dmd: mtype.c:875: void Type::check(): Assertion `tn->mod & 4 || tn->mod & 1' failed.
Aborted


I'm new to D so this might be invalid syntax but it shouldn't crash the compiler.
Comment 1 Don 2010-09-20 08:13:35 UTC
(In reply to comment #0)
> I'm new to D so this might be invalid syntax but it shouldn't crash the
> compiler.

Yes. Thanks for the excellent reduced test case.
Comment 2 Walter Bright 2010-11-07 12:29:29 UTC

*** This issue has been marked as a duplicate of issue 4434 ***