From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,d285346fda2e2f85,start X-Google-NewGroupId: yes X-Google-Attributes: gida07f3367d7,domainid0,public,usenet X-Google-Language: ENGLISH,ASCII-7-bit Received: by 10.204.152.89 with SMTP id f25mr1135339bkw.0.1325024980628; Tue, 27 Dec 2011 14:29:40 -0800 (PST) Path: jh9ni60748bkb.0!nntp.google.com!news2.google.com!newsfeed2.dallas1.level3.net!news.level3.com!newsfeed-00.mathworks.com!nntp.TheWorld.com!not-for-mail From: Robert A Duff Newsgroups: comp.lang.ada Subject: Re: Access to function causes "access check failed" Date: Tue, 27 Dec 2011 17:29:39 -0500 Organization: The World Public Access UNIX, Brookline, MA Message-ID: References: <32495535.655.1325020811299.JavaMail.geo-discussion-forums@vbls16> NNTP-Posting-Host: shell01.theworld.com Mime-Version: 1.0 X-Trace: pcls6.std.com 1325024980 6624 192.74.137.71 (27 Dec 2011 22:29:40 GMT) X-Complaints-To: abuse@TheWorld.com NNTP-Posting-Date: Tue, 27 Dec 2011 22:29:40 +0000 (UTC) User-Agent: Gnus/5.1008 (Gnus v5.10.8) Emacs/21.3 (irix) Cancel-Lock: sha1:UOaPGUIgBfZgwTcbylgfPH/f2xw= Content-Type: text/plain; charset=us-ascii Date: 2011-12-27T17:29:39-05:00 List-Id: Alex writes: > The My_T : T1 declaration in t.adb caused the check failed error on > line of "type T1 is record". I wonder why I have such an error, if > it's normal or not. Any ideas ? Access values are default-initialized to null, and you declared the thing "not null", so it raises C_E when initialized. Try a subtype predicate (Ada 2012 feature); they're better behaved in this regard. - Bob