comp.lang.ada
 help / color / mirror / Atom feed
* Storage_Error with parameterized records
@ 1998-07-03  0:00 Markus Kuhn
  1998-07-04  0:00 ` Pascal MALAISE
                   ` (3 more replies)
  0 siblings, 4 replies; 8+ messages in thread
From: Markus Kuhn @ 1998-07-03  0:00 UTC (permalink / raw)



May be I have something severely missunderstood, but I have no idea,
why the declaration

   subtype Correlation_Coefficient is Float;

   type CMatrix is
      array (Natural range <>, Natural range <>) of
        Correlation_Coefficient;

   type Correlation_Matrix(Last_Line : Natural := 0) is
      record
	 Mat : CMatrix(0 .. Last_Line, 0 .. Last_Line);
      end record;

causes the following warnings (and at runtime the promised
Storage_Error):

  warning: Storage_Error will be raised at run-time
  warning: creation of object of this type may raise Storage_Error

I had hoped this code was sufficiently close to John Barnes
Square example in chapter 16 of Programming in Ada 95 and I also
didn't find a restriction in the RM that explained this warning.

And idea?

Markus

-- 
Markus G. Kuhn, Security Group, Computer Lab, Cambridge University, UK
email: mkuhn at acm.org,  home page: <http://www.cl.cam.ac.uk/~mgk25/>




^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~1998-07-13  0:00 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1998-07-03  0:00 Storage_Error with parameterized records Markus Kuhn
1998-07-04  0:00 ` Pascal MALAISE
1998-07-05  0:00 ` david.c.hoos.sr
1998-07-08  0:00   ` Robert A Duff
1998-07-08  0:00     ` Robert Dewar
     [not found] ` <dewar.899586342@merv>
     [not found]   ` <359F50D9.5126DEE1@cl.cam.ac.uk>
1998-07-07  0:00     ` Robert Dewar
1998-07-10  0:00 ` Samuel Mize
1998-07-13  0:00   ` Robert Dewar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox