Opened 4 years ago

Closed 4 years ago

#61 closed defect (fixed)

Polymorphic type disallowed in structure definition

Reported by: pabuhr Owned by: Rob
Priority: minor Component: cfa-cc
Version: 1.0 Keywords:
Cc:

Description (last modified by Rob Schluntz)

forall( otype T )
int foo( T i ) {
	struct S { T j; };  // T disallowed
	S s;
}

cfa test.c
CFA Version 1.0.0 (debug)
test.c:32:1 error: No reasonable alternatives for expression Applying untyped: 
  Name: ?{}
...to: 
  Cast of:
    Variable Expression: s: instance of struct S with body 1 
  ... to:
    reference to instance of struct S with body 1 

Change History (2)

comment:1 Changed 4 years ago by Rob Schluntz

Description: modified (diff)

comment:2 Changed 4 years ago by Rob Schluntz <rschlunt@…>

Resolution: fixed
Status: assignedclosed

In 8dceeb7:

Monomorphize polymorphic aggregate (but not generic) members [fixes #61]

Note: See TracTickets for help on using tickets.