Summary: Type resolution issue during extra inlining semantic
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD

--- Comment #0 from klickverbot <> 2012-06-23 03:02:35 PDT 
This bug was originally reported by David Simcha as a LDC issue
(, but it occurs with DMD as

--- a.d
import b;

--- b.d
import hash;

void fun() {
    alias StackSet!(string) SS;

--- hash.d
struct HashRange(K, S, ) {
    size_t _length;

    this(S* set) {
        this._length = set.length;

struct StackSet(K) {
    HashRange!(K, typeof(this)) elems() {

    @property size_t length() {

With DMD 2.059, dmd -release -inline -noboundscheck a.d yields:
hash.d(5): Error: cannot implicitly convert expression ((*set).length()) of
type size_t to ulong
hash.d(11): Error: template instance hash.HashRange!(string,StackSet!(string))
error instantiating
b.d(4):        instantiated from here: StackSet!(string)
b.d(4): Error: template instance hash.StackSet!(string) error instantiating

With DMD 2.060 Git (ad7637f), it instead segfaults in

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

Reply via email to