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,FREEMAIL_FROM autolearn=unavailable autolearn_force=no version=3.4.4 X-Received: by 10.224.64.202 with SMTP id f10mr16032390qai.2.1376574132674; Thu, 15 Aug 2013 06:42:12 -0700 (PDT) X-Received: by 10.50.30.9 with SMTP id o9mr128683igh.11.1376574132635; Thu, 15 Aug 2013 06:42:12 -0700 (PDT) Path: border1.nntp.dca3.giganews.com!border3.nntp.dca.giganews.com!border1.nntp.dca.giganews.com!nntp.giganews.com!f7no2450173qan.0!news-out.google.com!he10ni1979qab.0!nntp.google.com!fx3no2571377qab.0!postnews.google.com!glegroupsg2000goo.googlegroups.com!not-for-mail Newsgroups: comp.lang.ada Date: Thu, 15 Aug 2013 06:42:12 -0700 (PDT) In-Reply-To: <86395c3d-e0e2-41f1-8286-08a64125fd2e@googlegroups.com> Complaints-To: groups-abuse@google.com Injection-Info: glegroupsg2000goo.googlegroups.com; posting-host=69.20.190.126; posting-account=lJ3JNwoAAAAQfH3VV9vttJLkThaxtTfC NNTP-Posting-Host: 69.20.190.126 References: <86395c3d-e0e2-41f1-8286-08a64125fd2e@googlegroups.com> User-Agent: G2/1.0 MIME-Version: 1.0 Message-ID: <2bb56177-ff86-4d54-bceb-ed57a5a90411@googlegroups.com> Subject: Re: (GNADE) Access attribute not allowed in generic body From: Shark8 Injection-Date: Thu, 15 Aug 2013 13:42:12 +0000 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Original-Bytes: 2957 Xref: number.nntp.dca.giganews.com comp.lang.ada:183037 Date: 2013-08-15T06:42:12-07:00 List-Id: On Thursday, August 15, 2013 1:27:58 AM UTC-6, Dwiki wrote: > hello again, >=20 > im trying to compile app using gnade (1.5.3a) in windows, but it show err= or message=20 >=20 >=20 >=20 > gnu-db-sqlcli-dispatch-a_string.adb:62:40: 'Access attribute not allowed = in gene >=20 > ric body >=20 > gnu-db-sqlcli-dispatch-a_string.adb:62:40: because access type "Attr_Get_= Func" i >=20 > s declared outside generic unit (RM 3.10.2(32)) >=20 > gnu-db-sqlcli-dispatch-a_string.adb:62:40: move 'Access to private part, = or (Ada >=20 > 2005) use anonymous access type instead of "Attr_Get_Func" >=20 > gnu-db-sqlcli-dispatch-a_string.adb:63:40: 'Access attribute not allowed = in gene >=20 > ric body >=20 > gnu-db-sqlcli-dispatch-a_string.adb:63:40: because access type "Attr_Set_= Proc" i >=20 > s declared outside generic unit (RM 3.10.2(32)) >=20 > gnu-db-sqlcli-dispatch-a_string.adb:63:40: move 'Access to private part, = or (Ada >=20 > 2005) use anonymous access type instead of "Attr_Set_Proc" >=20 > completed 1 out of 1 (100%)... >=20 > gprbuild: *** compilation phase failed >=20 >=20 >=20 > any clue? >=20 >=20 >=20 > thank you.... If it's a Ada 2005/2012 incompatibility as Dmitry suggests you can try thro= wing "pragma Ada_2005;" as the first-line in the body. And, if you're using= GNAT, you can use different Ada versions for the spec and body... which me= ans you can add the pre/post condition aspects [and an Ada_2012 pragma] to = the spec and keep your working Ada 2005 (or 95, or possibly 83*) and add th= e appropriate pragma. * Ada 83 doesn't allow child-packages to be with/used, this can be alleviat= ed by creating a library-level rename and using that.