Watch, Follow, &
Connect with Us
Public Report
Report From: Delphi-BCB/Compiler/Delphi/Generics    [ Add a report in this area ]  
Report #:  108063   Status: Closed
[XE ICE REGRESSION] SizeOf and dereferenced generic pointers
Project:  Delphi Build #:  17.0.4625.53395
Version:    17.0 Submitted By:   Blaise Thorn
Report Type:  Crash / Data loss / Total failure Date Reported:  8/19/2012 12:15:21 PM
Severity:    Commonly encountered problem Last Updated: 4/15/2014 6:46:55 PM
Platform:    All platforms Internal Tracking #:   31141
Resolution: Fixed (Resolution Comments) Resolved in Build: : XE6
Duplicate of:  None
Voting and Rating
Overall Rating: No Ratings Yet
0.00 out of 5
Total Votes: None
Description
Same bug, three hypostases. Note that the second case actually worked in Weaver, hence -- regression.

Tags: F2084 ICE Gxxxx E2005
Steps to Reproduce:
All three test programs are expected to be compiled without errors, internal or otherwise.
----------8<----------
type G<T> = class

type R = record F: Integer end;

procedure Test;
end;

procedure G<T>.Test;
var
X: ^R;
begin

writeln( sizeof(X^) )

// ^-- F2084 Internal Error: G9413
end;

end.
----------8<----------
type G<T> = class

type R = record F: Integer end;

type PR = ^R;

procedure Test;
end;

procedure G<T>.Test;
var
X: PR;
begin

writeln( sizeof(X^) )

// Tiburon: BOGUS E2005 'G<>.R' is not a type identifier

// Weaver: PASS

// Others: F2084 Internal Error: Gxxxx
end;

end.
----------8<----------
type G<T> = class

type R = record F: Integer end;

procedure Test;
end;

procedure G<T>.Test;
type PR = ^R;
var
X: PR;
begin

writeln( sizeof(X^) )

// ^-- BOGUS E2005 'G<>.R' is not a type identifier
end;

end.
----------8<----------
Workarounds
None
Attachment
None
Comments

None

Server Response from: ETNACODE01