From: Michael Andersson <a98mican@ida.his.se>
Subject: Iterator trouble??
Date: Sun, 27 May 2001 21:44:18 -0400
Date: 2001-05-27T19:39:38+00:00 [thread overview]
Message-ID: <3B11AD72.DC475A32@ida.his.se> (raw)
Hi!
Why do I get the following compiler error?
access discriminats allowed only for limited types
My code looks like this:
with Spline_Pkg; use Spline_Pkg;
package Spline_Pkg.SplineIterator_Pkg is
type SplineIterator(S : access Spline) is limited private;
function Next(Si : SplineIterator) return Point3;
private
type SplineIterator(S : access Spline) is
record
Index : Natural;
end record;
end Spline_Pkg.SplineIterator_Pkg;
with Point3_Pkg; use Point3_Pkg;
package Spline_Pkg is
type Spline is limited private;
type Point3Vector is array(NATURAL range <>) of Point3;
type IntVector is array(NATURAL range <> ) of Integer;
procedure Create(S : out Spline; Points : in Point3Vector; Steps : in
IntVector);
private
type Spline is array(0 .. INTEGER'Last) of Point3;
end Spline_Pkg;
Thanks!
/Michael
next reply other threads:[~2001-05-28 1:44 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2001-05-28 1:44 Michael Andersson [this message]
2001-05-28 6:44 ` Iterator trouble?? Jeffrey Carter
replies disabled
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox