From d90e94c7f76e9dcff8f225e3b86ce61e4124a422 Mon Sep 17 00:00:00 2001 From: Javier Miranda Date: Fri, 6 Apr 2007 11:13:42 +0200 Subject: [PATCH] a-coprnu.ads, a-cohata.ads, a-chtgop.ads, a-chtgop.adb, a-cgcaso.ads, a-cgarso.ads, a-secain.ads, a-slcain.ads, a-shcain.ads, a-chtgke.ads, a-chtgke.ads, a-coprnu.ads, a-contai.ads, a-chtgke.ads, a-chtgke.adb, a-stwiha.ads, a-strhas.ads, a-lfztio.ads, a-liztio.ads, a-llfzti.ads, a-llizti.ads, a-sfztio.ads, a-siztio.ads, a-ssizti.ads, a-stzfix.ads, a-stzhas.ads, a-szuzha.ads, a-tiunio.ads, a-wwunio.ads, a-ztcoio.ads, a-ztinio.ads, a-zttest.ads, a-zzunio.ads, a-astaco.ads, a-charac.ads, a-chlat1.ads, ada.ads, a-dynpri.ads, a-flteio.ads, a-fwteio.ads, a-inteio.ads, a-intnam.ads, a-ioexce.ads, a-iwteio.ads, a-lfteio.ads, a-lfwtio.ads, a-liteio.ads, a-liwtio.ads, a-llftio.ads, a-llfwti.ads, a-llitio.ads, a-lliwti.ads, a-ncelfu.ads, a-ngcefu.ads, a-ngelfu.ads, a-nlcefu.ads, a-nlcoty.ads, a-nlelfu.ads, a-nllcef.ads, a-nllcty.ads, a-nllefu.ads, a-nscefu.ads, a-nscoty.ads, a-nselfu.ads, a-nucoty.ads, a-nuelfu.ads, a-numeri.ads, a-sfteio.ads, a-sfwtio.ads, a-siteio.ads, a-siwtio.ads, a-ssitio.ads, a-ssiwti.ads, a-storio.ads, a-strfix.ads, a-string.ads, a-stwifi.ads, a-titest.ads, a-unccon.ads, a-uncdea.ads, a-wtcoio.ads, a-wtinio.ads, a-wttest.ads, calendar.ads, directio.ads, i-c.ads, ioexcept.ads, machcode.ads, sequenio.ads, text_io.ads, unchconv.ads, unchdeal.ads, a-widcha.ads, a-zchara.ads, a-stboha.ads, a-stfiha.ads, a-coteio.ads, a-envvar.ads, a-lcteio.ads, a-llctio.ads, a-scteio.ads, a-swbwha.ads, a-swfwha.ads, a-szbzha.ads, a-szfzha.ads, a-tiboio.ads, a-wwboio.ads, a-zzboio.ads, a-dispat.ads, a-tgdico.ads, expander.adb, g-socket.ads, par-labl.adb, sinput-c.adb, s-tarest.ads, s-stchop.ads, g-expect-vms.adb, s-taprop-lynxos.adb, s-taprop-tru64.adb, s-taprop-irix.adb, s-taprop-hpux-dce.adb, s-traceb-hpux.adb, s-taprop-linux.adb, s-taprop-dummy.adb, s-osprim-unix.adb, s-osprim-solaris.adb, s-taprop-solaris.adb, s-taprop-vms.adb, s-osprim-mingw.adb, s-taprop-mingw.adb, s-osprim-posix.adb, s-taprop-posix.adb, a-exexpr-gcc.adb, a-ststio.adb, a-ststio.ads, a-textio.adb, a-textio.ads, a-tideau.adb, a-tideau.ads, a-witeio.adb, a-witeio.ads, a-wtdeau.adb, a-wtdeau.ads, g-calend.adb, g-calend.ads, g-dirope.adb, g-expect.ads, gnatchop.adb, g-spipat.adb, g-spipat.ads, s-direio.adb, s-direio.ads, s-fatgen.adb, s-fatgen.ads, s-parint.adb, s-sequio.adb, s-sequio.ads, s-taprop.ads, s-valdec.adb, s-valdec.ads, s-valint.adb, s-valint.ads, s-vallld.adb, s-vallld.ads, s-vallli.adb, s-vallli.ads, s-valllu.adb, s-valllu.ads, s-valrea.adb, s-valrea.ads, s-valuns.adb, s-valuns.ads, s-valuti.adb, s-valuti.ads, xref_lib.adb, s-stchop.adb, i-vxwork-x86.ads, a-crbtgo.ads, a-crbtgo.adb, a-coorse.ads, a-coorse.adb, a-cohama.ads, a-cohama.adb, a-ciorse.ads, a-ciorse.adb, a-cihama.ads, a-cihama.adb, a-chtgop.ads, a-chtgop.ads, a-coormu.adb, a-ciormu.adb, a-cihase.adb, a-cihase.ads, a-cohase.adb, a-cohase.ads, a-swuwha.ads, a-ciormu.ads, a-coormu.ads, a-rbtgso.ads, a-stunha.ads, a-ciorma.adb, a-coorma.adb, a-ztdeau.adb, a-ztdeau.ads, a-ztexio.adb, a-ztexio.ads... 2007-04-06 Javier Miranda Matt Heaney Robert Dewar a-coprnu.ads, a-cohata.ads, a-chtgop.ads, a-chtgop.adb, a-cgcaso.ads, a-cgarso.ads, a-secain.ads, a-slcain.ads, a-shcain.ads, a-chtgke.ads, a-chtgke.ads, a-coprnu.ads, a-contai.ads, a-chtgke.ads, a-chtgke.adb, a-stwiha.ads, a-strhas.ads, a-lfztio.ads, a-liztio.ads, a-llfzti.ads, a-llizti.ads, a-sfztio.ads, a-siztio.ads, a-ssizti.ads, a-stzfix.ads, a-stzhas.ads, a-szuzha.ads, a-tiunio.ads, a-wwunio.ads, a-ztcoio.ads, a-ztinio.ads, a-zttest.ads, a-zzunio.ads, a-astaco.ads, a-charac.ads, a-chlat1.ads, ada.ads, a-dynpri.ads, a-flteio.ads, a-fwteio.ads, a-inteio.ads, a-intnam.ads, a-ioexce.ads, a-iwteio.ads, a-lfteio.ads, a-lfwtio.ads, a-liteio.ads, a-liwtio.ads, a-llftio.ads, a-llfwti.ads, a-llitio.ads, a-lliwti.ads, a-ncelfu.ads, a-ngcefu.ads, a-ngelfu.ads, a-nlcefu.ads, a-nlcoty.ads, a-nlelfu.ads, a-nllcef.ads, a-nllcty.ads, a-nllefu.ads, a-nscefu.ads, a-nscoty.ads, a-nselfu.ads, a-nucoty.ads, a-nuelfu.ads, a-numeri.ads, a-sfteio.ads, a-sfwtio.ads, a-siteio.ads, a-siwtio.ads, a-ssitio.ads, a-ssiwti.ads, a-storio.ads, a-strfix.ads, a-string.ads, a-stwifi.ads, a-titest.ads, a-unccon.ads, a-uncdea.ads, a-wtcoio.ads, a-wtinio.ads, a-wttest.ads, calendar.ads, directio.ads, i-c.ads, ioexcept.ads, machcode.ads, sequenio.ads, text_io.ads, unchconv.ads, unchdeal.ads, a-widcha.ads, a-zchara.ads, a-stboha.ads, a-stfiha.ads, a-coteio.ads, a-envvar.ads, a-lcteio.ads, a-llctio.ads, a-scteio.ads, a-swbwha.ads, a-swfwha.ads, a-szbzha.ads, a-szfzha.ads, a-tiboio.ads, a-wwboio.ads, a-zzboio.ads, a-dispat.ads, a-tgdico.ads, expander.adb, g-socket.ads, par-labl.adb, sinput-c.adb, s-tarest.ads, s-stchop.ads, g-expect-vms.adb, s-taprop-lynxos.adb, s-taprop-tru64.adb, s-taprop-irix.adb, s-taprop-hpux-dce.adb, s-traceb-hpux.adb, s-taprop-linux.adb, s-taprop-dummy.adb, s-osprim-unix.adb, s-osprim-solaris.adb, s-taprop-solaris.adb, s-taprop-vms.adb, s-osprim-mingw.adb, s-taprop-mingw.adb, s-osprim-posix.adb, s-taprop-posix.adb, a-exexpr-gcc.adb, a-ststio.adb, a-ststio.ads, a-textio.adb, a-textio.ads, a-tideau.adb, a-tideau.ads, a-witeio.adb, a-witeio.ads, a-wtdeau.adb, a-wtdeau.ads, g-calend.adb, g-calend.ads, g-dirope.adb, g-expect.ads, gnatchop.adb, g-spipat.adb, g-spipat.ads, s-direio.adb, s-direio.ads, s-fatgen.adb, s-fatgen.ads, s-parint.adb, s-sequio.adb, s-sequio.ads, s-taprop.ads, s-valdec.adb, s-valdec.ads, s-valint.adb, s-valint.ads, s-vallld.adb, s-vallld.ads, s-vallli.adb, s-vallli.ads, s-valllu.adb, s-valllu.ads, s-valrea.adb, s-valrea.ads, s-valuns.adb, s-valuns.ads, s-valuti.adb, s-valuti.ads, xref_lib.adb, s-stchop.adb, i-vxwork-x86.ads, a-crbtgo.ads, a-crbtgo.adb, a-coorse.ads, a-coorse.adb, a-cohama.ads, a-cohama.adb, a-ciorse.ads, a-ciorse.adb, a-cihama.ads, a-cihama.adb, a-chtgop.ads, a-chtgop.ads, a-coormu.adb, a-ciormu.adb, a-cihase.adb, a-cihase.ads, a-cohase.adb, a-cohase.ads, a-swuwha.ads, a-ciormu.ads, a-coormu.ads, a-rbtgso.ads, a-stunha.ads, a-ciorma.adb, a-coorma.adb, a-ztdeau.adb, a-ztdeau.ads, a-ztexio.adb, a-ztexio.ads: Addition of null-exclusion to anonymous access types. Update documentation. Minor rewording. From-SVN: r123538 --- gcc/ada/a-astaco.ads | 2 +- gcc/ada/a-cgarso.ads | 2 +- gcc/ada/a-charac.ads | 2 +- gcc/ada/a-chlat1.ads | 2 +- gcc/ada/a-chtgke.adb | 156 +++++++++++++++++++++------------- gcc/ada/a-chtgke.ads | 33 +++++-- gcc/ada/a-chtgop.ads | 77 +++++++++++++++-- gcc/ada/a-cihama.adb | 16 ++-- gcc/ada/a-cihama.ads | 8 +- gcc/ada/a-cihase.adb | 16 ++-- gcc/ada/a-cihase.ads | 8 +- gcc/ada/a-ciorma.adb | 8 +- gcc/ada/a-ciormu.adb | 16 ++-- gcc/ada/a-ciormu.ads | 10 ++- gcc/ada/a-ciorse.adb | 16 ++-- gcc/ada/a-ciorse.ads | 8 +- gcc/ada/a-cohama.adb | 16 ++-- gcc/ada/a-cohama.ads | 8 +- gcc/ada/a-cohase.adb | 18 ++-- gcc/ada/a-cohase.ads | 8 +- gcc/ada/a-contai.ads | 2 +- gcc/ada/a-coorma.adb | 8 +- gcc/ada/a-coormu.adb | 16 ++-- gcc/ada/a-coormu.ads | 8 +- gcc/ada/a-coorse.adb | 16 ++-- gcc/ada/a-coorse.ads | 8 +- gcc/ada/a-coprnu.ads | 30 ++++++- gcc/ada/a-coteio.ads | 2 +- gcc/ada/a-crbtgo.adb | 4 +- gcc/ada/a-crbtgo.ads | 8 +- gcc/ada/a-dispat.ads | 4 +- gcc/ada/a-dynpri.ads | 2 +- gcc/ada/a-envvar.ads | 6 +- gcc/ada/a-exexpr-gcc.adb | 8 +- gcc/ada/a-flteio.ads | 2 +- gcc/ada/a-fwteio.ads | 2 +- gcc/ada/a-inteio.ads | 2 +- gcc/ada/a-intnam.ads | 2 +- gcc/ada/a-ioexce.ads | 2 +- gcc/ada/a-iwteio.ads | 2 +- gcc/ada/a-lcteio.ads | 2 +- gcc/ada/a-lfteio.ads | 2 +- gcc/ada/a-lfwtio.ads | 2 +- gcc/ada/a-lfztio.ads | 2 +- gcc/ada/a-liteio.ads | 2 +- gcc/ada/a-liwtio.ads | 2 +- gcc/ada/a-liztio.ads | 2 +- gcc/ada/a-llctio.ads | 2 +- gcc/ada/a-llftio.ads | 2 +- gcc/ada/a-llfwti.ads | 2 +- gcc/ada/a-llfzti.ads | 2 +- gcc/ada/a-llitio.ads | 2 +- gcc/ada/a-lliwti.ads | 2 +- gcc/ada/a-llizti.ads | 2 +- gcc/ada/a-ncelfu.ads | 2 +- gcc/ada/a-ngcefu.ads | 2 +- gcc/ada/a-ngelfu.ads | 2 +- gcc/ada/a-nlcefu.ads | 2 +- gcc/ada/a-nlcoty.ads | 2 +- gcc/ada/a-nlelfu.ads | 2 +- gcc/ada/a-nllcef.ads | 2 +- gcc/ada/a-nllcty.ads | 2 +- gcc/ada/a-nllefu.ads | 2 +- gcc/ada/a-nscefu.ads | 2 +- gcc/ada/a-nscoty.ads | 2 +- gcc/ada/a-nselfu.ads | 2 +- gcc/ada/a-nucoty.ads | 2 +- gcc/ada/a-nuelfu.ads | 2 +- gcc/ada/a-numeri.ads | 2 +- gcc/ada/a-rbtgso.ads | 26 ++++++ gcc/ada/a-scteio.ads | 2 +- gcc/ada/a-secain.ads | 2 +- gcc/ada/a-sfteio.ads | 2 +- gcc/ada/a-sfwtio.ads | 2 +- gcc/ada/a-sfztio.ads | 2 +- gcc/ada/a-shcain.ads | 2 +- gcc/ada/a-siteio.ads | 2 +- gcc/ada/a-siwtio.ads | 2 +- gcc/ada/a-siztio.ads | 2 +- gcc/ada/a-slcain.ads | 2 +- gcc/ada/a-ssitio.ads | 2 +- gcc/ada/a-ssiwti.ads | 2 +- gcc/ada/a-ssizti.ads | 2 +- gcc/ada/a-stboha.ads | 2 +- gcc/ada/a-stfiha.ads | 2 +- gcc/ada/a-storio.ads | 2 +- gcc/ada/a-strfix.ads | 2 +- gcc/ada/a-strhas.ads | 2 +- gcc/ada/a-string.ads | 2 +- gcc/ada/a-ststio.adb | 4 +- gcc/ada/a-ststio.ads | 4 +- gcc/ada/a-stunha.ads | 2 +- gcc/ada/a-stwifi.ads | 2 +- gcc/ada/a-stwiha.ads | 2 +- gcc/ada/a-stzfix.ads | 2 +- gcc/ada/a-stzhas.ads | 2 +- gcc/ada/a-swbwha.ads | 2 +- gcc/ada/a-swfwha.ads | 2 +- gcc/ada/a-swuwha.ads | 2 +- gcc/ada/a-szbzha.ads | 2 +- gcc/ada/a-szfzha.ads | 2 +- gcc/ada/a-szuzha.ads | 2 +- gcc/ada/a-textio.adb | 4 +- gcc/ada/a-textio.ads | 6 +- gcc/ada/a-tgdico.ads | 8 +- gcc/ada/a-tiboio.ads | 4 +- gcc/ada/a-tideau.adb | 4 +- gcc/ada/a-tideau.ads | 4 +- gcc/ada/a-titest.ads | 2 +- gcc/ada/a-tiunio.ads | 2 +- gcc/ada/a-unccon.ads | 2 +- gcc/ada/a-uncdea.ads | 2 +- gcc/ada/a-widcha.ads | 2 +- gcc/ada/a-witeio.adb | 4 +- gcc/ada/a-witeio.ads | 6 +- gcc/ada/a-wtcoio.ads | 2 +- gcc/ada/a-wtdeau.adb | 4 +- gcc/ada/a-wtdeau.ads | 4 +- gcc/ada/a-wtinio.ads | 2 +- gcc/ada/a-wttest.ads | 2 +- gcc/ada/a-wwboio.ads | 4 +- gcc/ada/a-wwunio.ads | 2 +- gcc/ada/a-zchara.ads | 2 +- gcc/ada/a-ztcoio.ads | 2 +- gcc/ada/a-ztdeau.adb | 6 +- gcc/ada/a-ztdeau.ads | 6 +- gcc/ada/a-ztexio.adb | 4 +- gcc/ada/a-ztexio.ads | 6 +- gcc/ada/a-ztinio.ads | 2 +- gcc/ada/a-zttest.ads | 2 +- gcc/ada/a-zzboio.ads | 4 +- gcc/ada/a-zzunio.ads | 2 +- gcc/ada/ada.ads | 2 +- gcc/ada/calendar.ads | 2 +- gcc/ada/directio.ads | 2 +- gcc/ada/expander.adb | 48 +++++------ gcc/ada/g-calend.adb | 71 ++++++++-------- gcc/ada/g-calend.ads | 4 +- gcc/ada/g-dirope.adb | 2 +- gcc/ada/g-expect-vms.adb | 10 +-- gcc/ada/g-expect.ads | 12 +-- gcc/ada/g-socket.ads | 9 +- gcc/ada/g-spipat.adb | 24 +++--- gcc/ada/g-spipat.ads | 26 +++--- gcc/ada/gnatchop.adb | 28 +++--- gcc/ada/i-c.ads | 2 +- gcc/ada/i-vxwork-x86.ads | 10 +-- gcc/ada/ioexcept.ads | 2 +- gcc/ada/machcode.ads | 7 +- gcc/ada/par-labl.adb | 1 - gcc/ada/s-direio.adb | 4 +- gcc/ada/s-direio.ads | 4 +- gcc/ada/s-fatgen.adb | 2 +- gcc/ada/s-fatgen.ads | 4 +- gcc/ada/s-osprim-mingw.adb | 35 ++++++-- gcc/ada/s-osprim-posix.adb | 6 +- gcc/ada/s-osprim-solaris.adb | 6 +- gcc/ada/s-osprim-unix.adb | 6 +- gcc/ada/s-parint.adb | 6 +- gcc/ada/s-sequio.adb | 4 +- gcc/ada/s-sequio.ads | 4 +- gcc/ada/s-stchop.adb | 9 +- gcc/ada/s-stchop.ads | 24 +++--- gcc/ada/s-taprop-dummy.adb | 26 +++--- gcc/ada/s-taprop-hpux-dce.adb | 24 ++++-- gcc/ada/s-taprop-irix.adb | 25 ++++-- gcc/ada/s-taprop-linux.adb | 25 ++++-- gcc/ada/s-taprop-lynxos.adb | 27 +++--- gcc/ada/s-taprop-mingw.adb | 51 ++++++----- gcc/ada/s-taprop-posix.adb | 42 ++++++--- gcc/ada/s-taprop-solaris.adb | 31 ++++--- gcc/ada/s-taprop-tru64.adb | 25 ++++-- gcc/ada/s-taprop-vms.adb | 27 ++++-- gcc/ada/s-taprop.ads | 33 ++++--- gcc/ada/s-tarest.ads | 59 ++++++------- gcc/ada/s-traceb-hpux.adb | 31 ++++--- gcc/ada/s-valdec.adb | 4 +- gcc/ada/s-valdec.ads | 4 +- gcc/ada/s-valint.adb | 2 +- gcc/ada/s-valint.ads | 4 +- gcc/ada/s-vallld.adb | 4 +- gcc/ada/s-vallld.ads | 4 +- gcc/ada/s-vallli.adb | 2 +- gcc/ada/s-vallli.ads | 4 +- gcc/ada/s-valllu.adb | 4 +- gcc/ada/s-valllu.ads | 4 +- gcc/ada/s-valrea.adb | 4 +- gcc/ada/s-valrea.ads | 4 +- gcc/ada/s-valuns.adb | 4 +- gcc/ada/s-valuns.ads | 4 +- gcc/ada/s-valuti.adb | 8 +- gcc/ada/s-valuti.ads | 8 +- gcc/ada/sequenio.ads | 2 +- gcc/ada/sinput-c.adb | 7 +- gcc/ada/text_io.ads | 2 +- gcc/ada/unchconv.ads | 2 +- gcc/ada/unchdeal.ads | 2 +- gcc/ada/xref_lib.adb | 12 +-- 198 files changed, 994 insertions(+), 725 deletions(-) diff --git a/gcc/ada/a-astaco.ads b/gcc/ada/a-astaco.ads index dad55e0b623..3200c7ecdaf 100644 --- a/gcc/ada/a-astaco.ads +++ b/gcc/ada/a-astaco.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-cgarso.ads b/gcc/ada/a-cgarso.ads index 40056361127..77281b5ef45 100644 --- a/gcc/ada/a-cgarso.ads +++ b/gcc/ada/a-cgarso.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-charac.ads b/gcc/ada/a-charac.ads index 87889587754..30af8b812e1 100644 --- a/gcc/ada/a-charac.ads +++ b/gcc/ada/a-charac.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-chlat1.ads b/gcc/ada/a-chlat1.ads index 2d8a8bc7a3f..634d295b272 100644 --- a/gcc/ada/a-chlat1.ads +++ b/gcc/ada/a-chlat1.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-chtgke.adb b/gcc/ada/a-chtgke.adb index ba6ae2376f4..4aa9ed3b22e 100644 --- a/gcc/ada/a-chtgke.adb +++ b/gcc/ada/a-chtgke.adb @@ -37,9 +37,9 @@ package body Ada.Containers.Hash_Tables.Generic_Keys is -------------------------- procedure Delete_Key_Sans_Free - (HT : in out Hash_Table_Type; - Key : Key_Type; - X : out Node_Access) + (HT : in out Hash_Table_Type; + Key : Key_Type; + X : out Node_Access) is Indx : Hash_Type; Prev : Node_Access; @@ -59,7 +59,8 @@ package body Ada.Containers.Hash_Tables.Generic_Keys is if Equivalent_Keys (Key, X) then if HT.Busy > 0 then - raise Program_Error; + raise Program_Error with + "attempt to tamper with elements (container is busy)"; end if; HT.Buckets (Indx) := Next (X); HT.Length := HT.Length - 1; @@ -76,7 +77,8 @@ package body Ada.Containers.Hash_Tables.Generic_Keys is if Equivalent_Keys (Key, X) then if HT.Busy > 0 then - raise Program_Error; + raise Program_Error with + "attempt to tamper with elements (container is busy)"; end if; Set_Next (Node => Prev, Next => Next (X)); HT.Length := HT.Length - 1; @@ -130,7 +132,8 @@ package body Ada.Containers.Hash_Tables.Generic_Keys is begin if B = null then if HT.Busy > 0 then - raise Program_Error; + raise Program_Error with + "attempt to tamper with elements (container is busy)"; end if; if HT.Length = Count_Type'Last then @@ -159,7 +162,8 @@ package body Ada.Containers.Hash_Tables.Generic_Keys is end loop; if HT.Busy > 0 then - raise Program_Error; + raise Program_Error with + "attempt to tamper with elements (container is busy)"; end if; if HT.Length = Count_Type'Last then @@ -184,91 +188,129 @@ package body Ada.Containers.Hash_Tables.Generic_Keys is return Hash (Key) mod HT.Buckets'Length; end Index; - --------------------- - -- Replace_Element -- - --------------------- + ----------------------------- + -- Generic_Replace_Element -- + ----------------------------- procedure Generic_Replace_Element (HT : in out Hash_Table_Type; Node : Node_Access; Key : Key_Type) is - begin pragma Assert (HT.Length > 0); + pragma Assert (Node /= null); + + Old_Hash : constant Hash_Type := Hash (Node); + Old_Indx : constant Hash_Type := Old_Hash mod HT.Buckets'Length; + + New_Hash : constant Hash_Type := Hash (Key); + New_Indx : constant Hash_Type := New_Hash mod HT.Buckets'Length; + New_Bucket : Node_Access renames HT.Buckets (New_Indx); + N, M : Node_Access; + + begin if Equivalent_Keys (Key, Node) then - pragma Assert (Hash (Key) = Hash (Node)); + pragma Assert (New_Hash = Old_Hash); if HT.Lock > 0 then raise Program_Error with "attempt to tamper with cursors (container is locked)"; end if; + -- We can change a node's key to Key (that's what Assign is for), but + -- only if Key is not already in the hash table. (In a unique-key + -- hash table as this one a key is mapped to exactly one node only.) + -- The exception is when Key is mapped to Node, in which case the + -- change is allowed. + Assign (Node, Key); + pragma Assert (Hash (Node) = New_Hash); + pragma Assert (Equivalent_Keys (Key, Node)); return; end if; - declare - J : Hash_Type; - K : constant Hash_Type := Index (HT, Key); - B : Node_Access renames HT.Buckets (K); - N : Node_Access := B; - M : Node_Access; + -- Key is not equivalent to Node, so we now have to determine if it's + -- equivalent to some other node in the hash table. This is the case + -- irrespective of whether Key is in the same or a different bucket from + -- Node. - begin - while N /= null loop - if Equivalent_Keys (Key, N) then - raise Program_Error with - "attempt to replace existing element"; - end if; - - N := Next (N); - end loop; + N := New_Bucket; + while N /= null loop + if Equivalent_Keys (Key, N) then + pragma Assert (N /= Node); + raise Program_Error with + "attempt to replace existing element"; + end if; - J := Hash (Node); + N := Next (N); + end loop; - if J = K then - if HT.Lock > 0 then - raise Program_Error with - "attempt to tamper with cursors (container is locked)"; - end if; + -- We have determined that Key is not already in the hash table, so + -- the change is tenatively allowed. We now perform the standard + -- checks to determine whether the hash table is locked (because you + -- cannot change an element while it's in use by Query_Element or + -- Update_Element), or if the container is busy (because moving a + -- node to a different bucket would interfere with iteration). - Assign (Node, Key); - return; - end if; + if Old_Indx = New_Indx then + -- The node is already in the bucket implied by Key. In this case + -- we merely change its value without moving it. - if HT.Busy > 0 then + if HT.Lock > 0 then raise Program_Error with - "attempt to tamper with elements (container is busy)"; + "attempt to tamper with cursors (container is locked)"; end if; Assign (Node, Key); + pragma Assert (Hash (Node) = New_Hash); + pragma Assert (Equivalent_Keys (Key, Node)); + return; + end if; - N := HT.Buckets (J); - pragma Assert (N /= null); + -- The node is a bucket different from the bucket implied by Key. - if N = Node then - HT.Buckets (J) := Next (Node); + if HT.Busy > 0 then + raise Program_Error with + "attempt to tamper with elements (container is busy)"; + end if; - else - pragma Assert (HT.Length > 1); + -- Do the assignment first, before moving the node, so that if Assign + -- propagates an exception, then the hash table will not have been + -- modified (except for any possible side-effect Assign had on Node). - loop - M := Next (N); - pragma Assert (M /= null); + Assign (Node, Key); + pragma Assert (Hash (Node) = New_Hash); + pragma Assert (Equivalent_Keys (Key, Node)); - if M = Node then - Set_Next (Node => N, Next => Next (Node)); - exit; - end if; + -- Now we can safely remove the node from its current bucket - N := M; - end loop; - end if; + N := HT.Buckets (Old_Indx); + pragma Assert (N /= null); - Set_Next (Node => Node, Next => B); - B := Node; - end; + if N = Node then + HT.Buckets (Old_Indx) := Next (Node); + + else + pragma Assert (HT.Length > 1); + + loop + M := Next (N); + pragma Assert (M /= null); + + if M = Node then + Set_Next (Node => N, Next => Next (Node)); + exit; + end if; + + N := M; + end loop; + end if; + + -- Now we link the node into its new bucket (corresponding to Key) + + Set_Next (Node => Node, Next => New_Bucket); + New_Bucket := Node; end Generic_Replace_Element; end Ada.Containers.Hash_Tables.Generic_Keys; diff --git a/gcc/ada/a-chtgke.ads b/gcc/ada/a-chtgke.ads index 259b0126df2..833976acace 100644 --- a/gcc/ada/a-chtgke.ads +++ b/gcc/ada/a-chtgke.ads @@ -9,10 +9,6 @@ -- -- -- Copyright (C) 2004-2006, Free Software Foundation, Inc. -- -- -- --- This specification is derived from the Ada Reference Manual for use with -- --- GNAT. The copyright notice above, and the license provisions that follow -- --- apply solely to the contents of the part following the private keyword. -- --- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 2, or (at your option) any later ver- -- @@ -34,6 +30,9 @@ -- This unit was originally developed by Matthew J Heaney. -- ------------------------------------------------------------------------------ +-- Hash_Table_Type is used to implement hashed containers. This package +-- declares hash-table operations that depend on keys. + generic with package HT_Types is new Generic_Hash_Table_Types (<>); @@ -61,13 +60,18 @@ package Ada.Containers.Hash_Tables.Generic_Keys is (HT : Hash_Table_Type; Key : Key_Type) return Hash_Type; pragma Inline (Index); + -- Returns the bucket number (array index value) for the given key procedure Delete_Key_Sans_Free - (HT : in out Hash_Table_Type; - Key : Key_Type; - X : out Node_Access); + (HT : in out Hash_Table_Type; + Key : Key_Type; + X : out Node_Access); + -- Removes the node (if any) with the given key from the hash table, + -- without deallocating it. Program_Error is raised if the hash + -- table is busy. function Find (HT : Hash_Table_Type; Key : Key_Type) return Node_Access; + -- Returns the node (if any) corresponding to the given key generic with function New_Node (Next : Node_Access) return Node_Access; @@ -76,6 +80,11 @@ package Ada.Containers.Hash_Tables.Generic_Keys is Key : Key_Type; Node : out Node_Access; Inserted : out Boolean); + -- Attempts to insert a new node with the given key into the hash table. + -- If a node with that key already exists in the table, then that node + -- is returned and Inserted returns False. Otherwise New_Node is called + -- to allocate a new node, and Inserted returns True. Program_Error is + -- raised if the hash table is busy. generic with function Hash (Node : Node_Access) return Hash_Type; @@ -84,5 +93,15 @@ package Ada.Containers.Hash_Tables.Generic_Keys is (HT : in out Hash_Table_Type; Node : Node_Access; Key : Key_Type); + -- Assigns Key to Node, possibly changing its equivalence class. If Node + -- is in the same equivalence class as Key (that is, it's already in the + -- bucket implied by Key), then if the hash table is locked then + -- Program_Error is raised; otherwise Assign is called to assign Key to + -- Node. If Node is in a different bucket from Key, then Program_Error is + -- raised if the hash table is busy. Otherwise it Assigns Key to Node and + -- moves the Node from its current bucket to the bucket implied by Key. + -- Note that it is never proper to assign to Node a key value already + -- in the map, and so if Key is equivalent to some other node then + -- Program_Error is raised. end Ada.Containers.Hash_Tables.Generic_Keys; diff --git a/gcc/ada/a-chtgop.ads b/gcc/ada/a-chtgop.ads index 7d6e545e271..03154219be6 100644 --- a/gcc/ada/a-chtgop.ads +++ b/gcc/ada/a-chtgop.ads @@ -7,13 +7,32 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- --- GNAT. In accordance with the copyright of that document, you can freely -- --- copy and modify this specification, provided that if you redistribute a -- --- modified version, any changes that you have made are clearly indicated. -- +-- Copyright (C) 2004-2006, Free Software Foundation, Inc. -- -- -- +-- GNAT is free software; you can redistribute it and/or modify it under -- +-- terms of the GNU General Public License as published by the Free Soft- -- +-- ware Foundation; either version 2, or (at your option) any later ver- -- +-- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- +-- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- +-- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -- +-- for more details. You should have received a copy of the GNU General -- +-- Public License distributed with GNAT; see file COPYING. If not, write -- +-- to the Free Software Foundation, 51 Franklin Street, Fifth Floor, -- +-- Boston, MA 02110-1301, USA. -- +-- -- +-- As a special exception, if other files instantiate generics from this -- +-- unit, or you link this unit with other files to produce an executable, -- +-- this unit does not by itself cause the resulting executable to be -- +-- covered by the GNU General Public License. This exception does not -- +-- however invalidate any other reasons why the executable file might be -- +-- covered by the GNU Public License. -- +-- -- +-- This unit was originally developed by Matthew J Heaney. -- ------------------------------------------------------------------------------ +-- Hash_Table_Type is used to implement hashed containers. This package +-- declares hash-table operations that do not depend on keys. + with Ada.Streams; generic @@ -39,20 +58,31 @@ package Ada.Containers.Hash_Tables.Generic_Operations is pragma Preelaborate; procedure Free_Hash_Table (Buckets : in out Buckets_Access); + -- First frees the nodes in all non-null buckets of Buckets, and then frees + -- the Buckets array itself. function Index (Buckets : Buckets_Type; Node : Node_Access) return Hash_Type; pragma Inline (Index); + -- Uses the hash value of Node to compute its Buckets array index function Index (Hash_Table : Hash_Table_Type; Node : Node_Access) return Hash_Type; pragma Inline (Index); + -- Uses the hash value of Node to compute its Hash_Table buckets array + -- index. procedure Adjust (HT : in out Hash_Table_Type); + -- Used to implement controlled Adjust. It is assumed that HT has the value + -- of the bit-wise copy that immediately follows controlled Finalize. + -- Adjust first allocates a new buckets array for HT (having the same + -- length as the source), and then allocates a copy of each node of source. procedure Finalize (HT : in out Hash_Table_Type); + -- Used to implement controlled Finalize. It first calls Clear to + -- deallocate any remaining nodes, and then deallocates the buckets array. generic with function Find @@ -60,46 +90,77 @@ package Ada.Containers.Hash_Tables.Generic_Operations is Key : Node_Access) return Boolean; function Generic_Equal (L, R : Hash_Table_Type) return Boolean; + -- Used to implement hashed container equality. For each node in hash table + -- L, it calls Find to search for an equivalent item in hash table R. If + -- Find returns False for any node then Generic_Equal terminates + -- immediately and returns False. Otherwise if Find returns True for every + -- node then Generic_Equal returns True. procedure Clear (HT : in out Hash_Table_Type); + -- Deallocates each node in hash table HT. (Note that it only deallocates + -- the nodes, not the buckets array.) Program_Error is raised if the hash + -- table is busy. procedure Move (Target, Source : in out Hash_Table_Type); + -- Moves (not copies) the buckets array and nodes from Source to + -- Target. Program_Error is raised if Source is busy. The Target is first + -- cleared to deallocate its nodes (implying that Program_Error is also + -- raised if Target is busy). Source is empty following the move. function Capacity (HT : Hash_Table_Type) return Count_Type; + -- Returns the length of the buckets array procedure Reserve_Capacity (HT : in out Hash_Table_Type; N : Count_Type); + -- If N is greater than the current capacity, then it expands the buckets + -- array to at least the value N. If N is less than the current capacity, + -- then it contracts the buckets array. In either case existing nodes are + -- rehashed onto the new buckets array, and the old buckets array is + -- deallocated. Program_Error is raised if the hash table is busy. procedure Delete_Node_Sans_Free (HT : in out Hash_Table_Type; X : Node_Access); + -- Removes node X from the hash table without deallocating the node function First (HT : Hash_Table_Type) return Node_Access; + -- Returns the head of the list in the first (lowest-index) non-empty + -- bucket. function Next (HT : Hash_Table_Type; Node : Node_Access) return Node_Access; + -- Returns the node that immediately follows Node. This corresponds to + -- either the next node in the same bucket, or (if Node is the last node in + -- its bucket) the head of the list in the first non-empty bucket that + -- follows. generic with procedure Process (Node : Node_Access); procedure Generic_Iteration (HT : Hash_Table_Type); + -- Calls Process for each node in hash table HT generic use Ada.Streams; with procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access); procedure Generic_Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; HT : Hash_Table_Type); + -- Used to implement the streaming attribute for hashed containers. It + -- calls Write for each node to write its value into Stream. generic use Ada.Streams; - with function New_Node (Stream : access Root_Stream_Type'Class) + with function New_Node (Stream : not null access Root_Stream_Type'Class) return Node_Access; procedure Generic_Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; HT : out Hash_Table_Type); + -- Used to implement the streaming attribute for hashed containers. It + -- first clears hash table HT, then populates the hash table by calling + -- New_Node for each item in Stream. end Ada.Containers.Hash_Tables.Generic_Operations; diff --git a/gcc/ada/a-cihama.adb b/gcc/ada/a-cihama.adb index 24ca33bdb2c..8b9c545422c 100644 --- a/gcc/ada/a-cihama.adb +++ b/gcc/ada/a-cihama.adb @@ -72,7 +72,7 @@ package body Ada.Containers.Indefinite_Hashed_Maps is pragma Inline (Next); function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access; + (Stream : not null access Root_Stream_Type'Class) return Node_Access; procedure Set_Next (Node : Node_Access; Next : Node_Access); pragma Inline (Set_Next); @@ -80,7 +80,7 @@ package body Ada.Containers.Indefinite_Hashed_Maps is function Vet (Position : Cursor) return Boolean; procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access); -------------------------- @@ -772,7 +772,7 @@ package body Ada.Containers.Indefinite_Hashed_Maps is procedure Read_Nodes is new HT_Ops.Generic_Read (Read_Node); procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : out Map) is begin @@ -780,7 +780,7 @@ package body Ada.Containers.Indefinite_Hashed_Maps is end Read; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : out Cursor) is begin @@ -792,7 +792,7 @@ package body Ada.Containers.Indefinite_Hashed_Maps is --------------- function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access + (Stream : not null access Root_Stream_Type'Class) return Node_Access is Node : Node_Access := new Node_Type; @@ -1050,7 +1050,7 @@ package body Ada.Containers.Indefinite_Hashed_Maps is procedure Write_Nodes is new HT_Ops.Generic_Write (Write_Node); procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : Map) is begin @@ -1058,7 +1058,7 @@ package body Ada.Containers.Indefinite_Hashed_Maps is end Write; procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : Cursor) is begin @@ -1070,7 +1070,7 @@ package body Ada.Containers.Indefinite_Hashed_Maps is ---------------- procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access) is begin diff --git a/gcc/ada/a-cihama.ads b/gcc/ada/a-cihama.ads index b1b4630376a..6d0e883fd1d 100644 --- a/gcc/ada/a-cihama.ads +++ b/gcc/ada/a-cihama.ads @@ -198,13 +198,13 @@ private end record; procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : Cursor); for Cursor'Write use Write; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : out Cursor); for Cursor'Read use Read; @@ -214,13 +214,13 @@ private Node => null); procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : Map); for Map'Write use Write; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : out Map); for Map'Read use Read; diff --git a/gcc/ada/a-cihase.adb b/gcc/ada/a-cihase.adb index 1731ea708d1..12acb459eb5 100644 --- a/gcc/ada/a-cihase.adb +++ b/gcc/ada/a-cihase.adb @@ -84,7 +84,7 @@ package body Ada.Containers.Indefinite_Hashed_Sets is function Next (Node : Node_Access) return Node_Access; pragma Inline (Next); - function Read_Node (Stream : access Root_Stream_Type'Class) + function Read_Node (Stream : not null access Root_Stream_Type'Class) return Node_Access; pragma Inline (Read_Node); @@ -94,7 +94,7 @@ package body Ada.Containers.Indefinite_Hashed_Sets is function Vet (Position : Cursor) return Boolean; procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access); pragma Inline (Write_Node); @@ -1094,7 +1094,7 @@ package body Ada.Containers.Indefinite_Hashed_Sets is ---------- procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : out Set) is begin @@ -1102,7 +1102,7 @@ package body Ada.Containers.Indefinite_Hashed_Sets is end Read; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : out Cursor) is begin @@ -1114,7 +1114,7 @@ package body Ada.Containers.Indefinite_Hashed_Sets is --------------- function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access + (Stream : not null access Root_Stream_Type'Class) return Node_Access is X : Element_Access := new Element_Type'(Element_Type'Input (Stream)); @@ -1730,7 +1730,7 @@ package body Ada.Containers.Indefinite_Hashed_Sets is ----------- procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : Set) is begin @@ -1738,7 +1738,7 @@ package body Ada.Containers.Indefinite_Hashed_Sets is end Write; procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : Cursor) is begin @@ -1750,7 +1750,7 @@ package body Ada.Containers.Indefinite_Hashed_Sets is ---------------- procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access) is begin diff --git a/gcc/ada/a-cihase.ads b/gcc/ada/a-cihase.ads index 0d36adfe609..6dab3bfdcdb 100644 --- a/gcc/ada/a-cihase.ads +++ b/gcc/ada/a-cihase.ads @@ -241,13 +241,13 @@ private end record; procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : Cursor); for Cursor'Write use Write; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : out Cursor); for Cursor'Read use Read; @@ -257,13 +257,13 @@ private Node => null); procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : Set); for Set'Write use Write; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : out Set); for Set'Read use Read; diff --git a/gcc/ada/a-ciorma.adb b/gcc/ada/a-ciorma.adb index dc806bc32fb..794fc44771b 100644 --- a/gcc/ada/a-ciorma.adb +++ b/gcc/ada/a-ciorma.adb @@ -1048,7 +1048,7 @@ package body Ada.Containers.Indefinite_Ordered_Maps is Container : out Map) is function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access; + (Stream : not null access Root_Stream_Type'Class) return Node_Access; pragma Inline (Read_Node); procedure Read is @@ -1059,7 +1059,7 @@ package body Ada.Containers.Indefinite_Ordered_Maps is --------------- function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access + (Stream : not null access Root_Stream_Type'Class) return Node_Access is Node : Node_Access := new Node_Type; begin @@ -1326,7 +1326,7 @@ package body Ada.Containers.Indefinite_Ordered_Maps is Container : Map) is procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access); pragma Inline (Write_Node); @@ -1338,7 +1338,7 @@ package body Ada.Containers.Indefinite_Ordered_Maps is ---------------- procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access) is begin diff --git a/gcc/ada/a-ciormu.adb b/gcc/ada/a-ciormu.adb index f3af12e2785..f097fdc833b 100644 --- a/gcc/ada/a-ciormu.adb +++ b/gcc/ada/a-ciormu.adb @@ -1508,11 +1508,11 @@ package body Ada.Containers.Indefinite_Ordered_Multisets is ---------- procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : out Set) is function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access; + (Stream : not null access Root_Stream_Type'Class) return Node_Access; pragma Inline (Read_Node); procedure Read is @@ -1523,7 +1523,7 @@ package body Ada.Containers.Indefinite_Ordered_Multisets is --------------- function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access + (Stream : not null access Root_Stream_Type'Class) return Node_Access is Node : Node_Access := new Node_Type; begin @@ -1542,7 +1542,7 @@ package body Ada.Containers.Indefinite_Ordered_Multisets is end Read; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : out Cursor) is begin @@ -1823,11 +1823,11 @@ package body Ada.Containers.Indefinite_Ordered_Multisets is ----------- procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : Set) is procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access); pragma Inline (Write_Node); @@ -1839,7 +1839,7 @@ package body Ada.Containers.Indefinite_Ordered_Multisets is ---------------- procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access) is begin @@ -1853,7 +1853,7 @@ package body Ada.Containers.Indefinite_Ordered_Multisets is end Write; procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : Cursor) is begin diff --git a/gcc/ada/a-ciormu.ads b/gcc/ada/a-ciormu.ads index 0bcf19c440b..518ab351072 100644 --- a/gcc/ada/a-ciormu.ads +++ b/gcc/ada/a-ciormu.ads @@ -277,25 +277,27 @@ private end record; procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : Cursor); for Cursor'Write use Write; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : out Cursor); for Cursor'Read use Read; No_Element : constant Cursor := Cursor'(null, null); - procedure Write (Stream : access Root_Stream_Type'Class; Container : Set); + procedure Write + (Stream : not null access Root_Stream_Type'Class; + Container : Set); for Set'Write use Write; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : out Set); for Set'Read use Read; diff --git a/gcc/ada/a-ciorse.adb b/gcc/ada/a-ciorse.adb index adc34abf950..51a882a93ab 100644 --- a/gcc/ada/a-ciorse.adb +++ b/gcc/ada/a-ciorse.adb @@ -1382,11 +1382,11 @@ package body Ada.Containers.Indefinite_Ordered_Sets is ---------- procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : out Set) is function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access; + (Stream : not null access Root_Stream_Type'Class) return Node_Access; pragma Inline (Read_Node); procedure Read is @@ -1397,7 +1397,7 @@ package body Ada.Containers.Indefinite_Ordered_Sets is --------------- function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access + (Stream : not null access Root_Stream_Type'Class) return Node_Access is Node : Node_Access := new Node_Type; @@ -1418,7 +1418,7 @@ package body Ada.Containers.Indefinite_Ordered_Sets is end Read; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : out Cursor) is begin @@ -1717,11 +1717,11 @@ package body Ada.Containers.Indefinite_Ordered_Sets is ----------- procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : Set) is procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access); pragma Inline (Write_Node); @@ -1733,7 +1733,7 @@ package body Ada.Containers.Indefinite_Ordered_Sets is ---------------- procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access) is begin @@ -1747,7 +1747,7 @@ package body Ada.Containers.Indefinite_Ordered_Sets is end Write; procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : Cursor) is begin diff --git a/gcc/ada/a-ciorse.ads b/gcc/ada/a-ciorse.ads index 3fc5f452752..895a31796cf 100644 --- a/gcc/ada/a-ciorse.ads +++ b/gcc/ada/a-ciorse.ads @@ -281,13 +281,13 @@ private end record; procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : Cursor); for Cursor'Write use Write; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : out Cursor); for Cursor'Read use Read; @@ -295,13 +295,13 @@ private No_Element : constant Cursor := Cursor'(null, null); procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : Set); for Set'Write use Write; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : out Set); for Set'Read use Read; diff --git a/gcc/ada/a-cohama.adb b/gcc/ada/a-cohama.adb index 01058cd2fc6..b00e9770fc8 100644 --- a/gcc/ada/a-cohama.adb +++ b/gcc/ada/a-cohama.adb @@ -65,7 +65,7 @@ package body Ada.Containers.Hashed_Maps is pragma Inline (Next); function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access; + (Stream : not null access Root_Stream_Type'Class) return Node_Access; pragma Inline (Read_Node); procedure Set_Next (Node : Node_Access; Next : Node_Access); @@ -74,7 +74,7 @@ package body Ada.Containers.Hashed_Maps is function Vet (Position : Cursor) return Boolean; procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access); pragma Inline (Write_Node); @@ -703,7 +703,7 @@ package body Ada.Containers.Hashed_Maps is ---------- procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : out Map) is begin @@ -711,7 +711,7 @@ package body Ada.Containers.Hashed_Maps is end Read; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : out Cursor) is begin @@ -723,7 +723,7 @@ package body Ada.Containers.Hashed_Maps is --------------- function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access + (Stream : not null access Root_Stream_Type'Class) return Node_Access is Node : Node_Access := new Node_Type; @@ -924,7 +924,7 @@ package body Ada.Containers.Hashed_Maps is ----------- procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : Map) is begin @@ -932,7 +932,7 @@ package body Ada.Containers.Hashed_Maps is end Write; procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : Cursor) is begin @@ -944,7 +944,7 @@ package body Ada.Containers.Hashed_Maps is ---------------- procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access) is begin diff --git a/gcc/ada/a-cohama.ads b/gcc/ada/a-cohama.ads index f090c82f99e..a0bbad4e955 100644 --- a/gcc/ada/a-cohama.ads +++ b/gcc/ada/a-cohama.ads @@ -192,13 +192,13 @@ private use Ada.Streams; procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : Map); for Map'Write use Write; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : out Map); for Map'Read use Read; @@ -215,13 +215,13 @@ private end record; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : out Cursor); for Cursor'Read use Read; procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : Cursor); for Cursor'Write use Write; diff --git a/gcc/ada/a-cohase.adb b/gcc/ada/a-cohase.adb index 0f0552a941d..2328e3f3365 100644 --- a/gcc/ada/a-cohase.adb +++ b/gcc/ada/a-cohase.adb @@ -85,7 +85,7 @@ package body Ada.Containers.Hashed_Sets is function Next (Node : Node_Access) return Node_Access; pragma Inline (Next); - function Read_Node (Stream : access Root_Stream_Type'Class) + function Read_Node (Stream : not null access Root_Stream_Type'Class) return Node_Access; pragma Inline (Read_Node); @@ -95,7 +95,7 @@ package body Ada.Containers.Hashed_Sets is function Vet (Position : Cursor) return Boolean; procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access); pragma Inline (Write_Node); @@ -1009,15 +1009,15 @@ package body Ada.Containers.Hashed_Sets is ---------- procedure Read - (Stream : access Root_Stream_Type'Class; - Container : out Set) + (Stream : not null access Root_Stream_Type'Class; + Container : out Set) is begin Read_Nodes (Stream, Container.HT); end Read; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : out Cursor) is begin @@ -1028,7 +1028,7 @@ package body Ada.Containers.Hashed_Sets is -- Read_Node -- --------------- - function Read_Node (Stream : access Root_Stream_Type'Class) + function Read_Node (Stream : not null access Root_Stream_Type'Class) return Node_Access is Node : Node_Access := new Node_Type; @@ -1561,7 +1561,7 @@ package body Ada.Containers.Hashed_Sets is ----------- procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : Set) is begin @@ -1569,7 +1569,7 @@ package body Ada.Containers.Hashed_Sets is end Write; procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : Cursor) is begin @@ -1581,7 +1581,7 @@ package body Ada.Containers.Hashed_Sets is ---------------- procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access) is begin diff --git a/gcc/ada/a-cohase.ads b/gcc/ada/a-cohase.ads index b0eb14cc290..5c32f51b53e 100644 --- a/gcc/ada/a-cohase.ads +++ b/gcc/ada/a-cohase.ads @@ -238,13 +238,13 @@ private end record; procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : Cursor); for Cursor'Write use Write; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : out Cursor); for Cursor'Read use Read; @@ -252,13 +252,13 @@ private No_Element : constant Cursor := (Container => null, Node => null); procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : Set); for Set'Write use Write; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : out Set); for Set'Read use Read; diff --git a/gcc/ada/a-contai.ads b/gcc/ada/a-contai.ads index 41d99b1f628..a453d6bacad 100644 --- a/gcc/ada/a-contai.ads +++ b/gcc/ada/a-contai.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-coorma.adb b/gcc/ada/a-coorma.adb index 81e0d4eb246..f6823d4f7b2 100644 --- a/gcc/ada/a-coorma.adb +++ b/gcc/ada/a-coorma.adb @@ -962,7 +962,7 @@ package body Ada.Containers.Ordered_Maps is Container : out Map) is function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access; + (Stream : not null access Root_Stream_Type'Class) return Node_Access; pragma Inline (Read_Node); procedure Read is @@ -973,7 +973,7 @@ package body Ada.Containers.Ordered_Maps is --------------- function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access + (Stream : not null access Root_Stream_Type'Class) return Node_Access is Node : Node_Access := new Node_Type; begin @@ -1206,7 +1206,7 @@ package body Ada.Containers.Ordered_Maps is Container : Map) is procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access); pragma Inline (Write_Node); @@ -1218,7 +1218,7 @@ package body Ada.Containers.Ordered_Maps is ---------------- procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access) is begin diff --git a/gcc/ada/a-coormu.adb b/gcc/ada/a-coormu.adb index 912bde39025..8000c991110 100644 --- a/gcc/ada/a-coormu.adb +++ b/gcc/ada/a-coormu.adb @@ -1425,11 +1425,11 @@ package body Ada.Containers.Ordered_Multisets is ---------- procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : out Set) is function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access; + (Stream : not null access Root_Stream_Type'Class) return Node_Access; pragma Inline (Read_Node); procedure Read is @@ -1440,7 +1440,7 @@ package body Ada.Containers.Ordered_Multisets is --------------- function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access + (Stream : not null access Root_Stream_Type'Class) return Node_Access is Node : Node_Access := new Node_Type; begin @@ -1459,7 +1459,7 @@ package body Ada.Containers.Ordered_Multisets is end Read; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : out Cursor) is begin @@ -1729,11 +1729,11 @@ package body Ada.Containers.Ordered_Multisets is ----------- procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : Set) is procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access); pragma Inline (Write_Node); @@ -1745,7 +1745,7 @@ package body Ada.Containers.Ordered_Multisets is ---------------- procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access) is begin @@ -1759,7 +1759,7 @@ package body Ada.Containers.Ordered_Multisets is end Write; procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : Cursor) is begin diff --git a/gcc/ada/a-coormu.ads b/gcc/ada/a-coormu.ads index ff32f8c1559..df300130e76 100644 --- a/gcc/ada/a-coormu.ads +++ b/gcc/ada/a-coormu.ads @@ -282,13 +282,13 @@ private end record; procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : Cursor); for Cursor'Write use Write; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : out Cursor); for Cursor'Read use Read; @@ -296,13 +296,13 @@ private No_Element : constant Cursor := Cursor'(null, null); procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : Set); for Set'Write use Write; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : out Set); for Set'Read use Read; diff --git a/gcc/ada/a-coorse.adb b/gcc/ada/a-coorse.adb index d407feadfd1..3cd02332c3c 100644 --- a/gcc/ada/a-coorse.adb +++ b/gcc/ada/a-coorse.adb @@ -1297,11 +1297,11 @@ package body Ada.Containers.Ordered_Sets is ---------- procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : out Set) is function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access; + (Stream : not null access Root_Stream_Type'Class) return Node_Access; pragma Inline (Read_Node); procedure Read is @@ -1312,7 +1312,7 @@ package body Ada.Containers.Ordered_Sets is --------------- function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access + (Stream : not null access Root_Stream_Type'Class) return Node_Access is Node : Node_Access := new Node_Type; @@ -1333,7 +1333,7 @@ package body Ada.Containers.Ordered_Sets is end Read; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : out Cursor) is begin @@ -1618,11 +1618,11 @@ package body Ada.Containers.Ordered_Sets is ----------- procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : Set) is procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access); pragma Inline (Write_Node); @@ -1634,7 +1634,7 @@ package body Ada.Containers.Ordered_Sets is ---------------- procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access) is begin @@ -1648,7 +1648,7 @@ package body Ada.Containers.Ordered_Sets is end Write; procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : Cursor) is begin diff --git a/gcc/ada/a-coorse.ads b/gcc/ada/a-coorse.ads index 2cc8accad53..47208653ef4 100644 --- a/gcc/ada/a-coorse.ads +++ b/gcc/ada/a-coorse.ads @@ -270,13 +270,13 @@ private end record; procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : Cursor); for Cursor'Write use Write; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Item : out Cursor); for Cursor'Read use Read; @@ -284,13 +284,13 @@ private No_Element : constant Cursor := Cursor'(null, null); procedure Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : Set); for Set'Write use Write; procedure Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Container : out Set); for Set'Read use Read; diff --git a/gcc/ada/a-coprnu.ads b/gcc/ada/a-coprnu.ads index 20e49d87996..0f832d125e6 100644 --- a/gcc/ada/a-coprnu.ads +++ b/gcc/ada/a-coprnu.ads @@ -6,13 +6,34 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- --- GNAT. In accordance with the copyright of that document, you can freely -- --- copy and modify this specification, provided that if you redistribute a -- --- modified version, any changes that you have made are clearly indicated. -- +-- Copyright (C) 2004-2006, Free Software Foundation, Inc. -- -- -- +-- GNAT is free software; you can redistribute it and/or modify it under -- +-- terms of the GNU General Public License as published by the Free Soft- -- +-- ware Foundation; either version 2, or (at your option) any later ver- -- +-- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- +-- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- +-- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -- +-- for more details. You should have received a copy of the GNU General -- +-- Public License distributed with GNAT; see file COPYING. If not, write -- +-- to the Free Software Foundation, 51 Franklin Street, Fifth Floor, -- +-- Boston, MA 02110-1301, USA. -- +-- -- +-- As a special exception, if other files instantiate generics from this -- +-- unit, or you link this unit with other files to produce an executable, -- +-- this unit does not by itself cause the resulting executable to be -- +-- covered by the GNU General Public License. This exception does not -- +-- however invalidate any other reasons why the executable file might be -- +-- covered by the GNU Public License. -- +-- -- +-- This unit was originally developed by Matthew J Heaney. -- ------------------------------------------------------------------------------ +-- This package declares the prime numbers array used to implement hashed +-- containers. Bucket arrays are always allocated with a prime-number +-- length (computed using To_Prime below), as this produces better scatter +-- when hash values are folded. + package Ada.Containers.Prime_Numbers is pragma Pure; @@ -27,5 +48,6 @@ package Ada.Containers.Prime_Numbers is 1610612741, 3221225473, 4294967291); function To_Prime (Length : Count_Type) return Hash_Type; + -- Returns the smallest value in Primes not less than Length end Ada.Containers.Prime_Numbers; diff --git a/gcc/ada/a-coteio.ads b/gcc/ada/a-coteio.ads index 72fc34c16e5..abba889ecdf 100755 --- a/gcc/ada/a-coteio.ads +++ b/gcc/ada/a-coteio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-crbtgo.adb b/gcc/ada/a-crbtgo.adb index a9f63942fe1..4afce91a4f3 100644 --- a/gcc/ada/a-crbtgo.adb +++ b/gcc/ada/a-crbtgo.adb @@ -698,7 +698,7 @@ package body Ada.Containers.Red_Black_Trees.Generic_Operations is ------------------ procedure Generic_Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Tree : in out Tree_Type) is N : Count_Type'Base; @@ -776,7 +776,7 @@ package body Ada.Containers.Red_Black_Trees.Generic_Operations is ------------------- procedure Generic_Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Tree : Tree_Type) is procedure Process (Node : Node_Access); diff --git a/gcc/ada/a-crbtgo.ads b/gcc/ada/a-crbtgo.ads index 0415f5be2de..a55e65f8e89 100644 --- a/gcc/ada/a-crbtgo.ads +++ b/gcc/ada/a-crbtgo.ads @@ -137,10 +137,10 @@ package Ada.Containers.Red_Black_Trees.Generic_Operations is generic with procedure Write_Node - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Node : Node_Access); procedure Generic_Write - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Tree : Tree_Type); -- Used to implement stream attribute T'Write. Generic_Write -- first writes the number of nodes into Stream, then calls @@ -149,9 +149,9 @@ package Ada.Containers.Red_Black_Trees.Generic_Operations is generic with procedure Clear (Tree : in out Tree_Type); with function Read_Node - (Stream : access Root_Stream_Type'Class) return Node_Access; + (Stream : not null access Root_Stream_Type'Class) return Node_Access; procedure Generic_Read - (Stream : access Root_Stream_Type'Class; + (Stream : not null access Root_Stream_Type'Class; Tree : in out Tree_Type); -- Used to implement stream attribute T'Read. Generic_Read -- first clears Tree. It then reads the number of nodes out of diff --git a/gcc/ada/a-dispat.ads b/gcc/ada/a-dispat.ads index 5403653cafb..b350ae0eb61 100644 --- a/gcc/ada/a-dispat.ads +++ b/gcc/ada/a-dispat.ads @@ -6,9 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 2006, Free Software Foundation, Inc. -- --- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-dynpri.ads b/gcc/ada/a-dynpri.ads index e179f46ea40..03e02d63547 100644 --- a/gcc/ada/a-dynpri.ads +++ b/gcc/ada/a-dynpri.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-envvar.ads b/gcc/ada/a-envvar.ads index 2b0229c5069..a2415603e4e 100755 --- a/gcc/ada/a-envvar.ads +++ b/gcc/ada/a-envvar.ads @@ -6,13 +6,11 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 2005-2006, Free Software Foundation, Inc. -- --- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- ---- -- +-- -- ------------------------------------------------------------------------------ package Ada.Environment_Variables is diff --git a/gcc/ada/a-exexpr-gcc.adb b/gcc/ada/a-exexpr-gcc.adb index fdec8d03995..4b6f904c2e7 100644 --- a/gcc/ada/a-exexpr-gcc.adb +++ b/gcc/ada/a-exexpr-gcc.adb @@ -179,7 +179,7 @@ package body Exception_Propagation is (UW_Version : Integer; UW_Phases : Unwind_Action; UW_Eclass : Exception_Class; - UW_Exception : access GNAT_GCC_Exception; + UW_Exception : not null access GNAT_GCC_Exception; UW_Context : System.Address; UW_Argument : System.Address) return Unwind_Reason_Code; -- Hook called at each step of the forced unwinding we perform to @@ -191,11 +191,11 @@ package body Exception_Propagation is -- __gnat stubs for these. procedure Unwind_RaiseException - (UW_Exception : access GNAT_GCC_Exception); + (UW_Exception : not null access GNAT_GCC_Exception); pragma Import (C, Unwind_RaiseException, "__gnat_Unwind_RaiseException"); procedure Unwind_ForcedUnwind - (UW_Exception : access GNAT_GCC_Exception; + (UW_Exception : not null access GNAT_GCC_Exception; UW_Handler : System.Address; UW_Argument : System.Address); pragma Import (C, Unwind_ForcedUnwind, "__gnat_Unwind_ForcedUnwind"); @@ -353,7 +353,7 @@ package body Exception_Propagation is (UW_Version : Integer; UW_Phases : Unwind_Action; UW_Eclass : Exception_Class; - UW_Exception : access GNAT_GCC_Exception; + UW_Exception : not null access GNAT_GCC_Exception; UW_Context : System.Address; UW_Argument : System.Address) return Unwind_Reason_Code is diff --git a/gcc/ada/a-flteio.ads b/gcc/ada/a-flteio.ads index 4c3bdc1ec91..caf4e9b7534 100644 --- a/gcc/ada/a-flteio.ads +++ b/gcc/ada/a-flteio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-fwteio.ads b/gcc/ada/a-fwteio.ads index 118d0064b80..e87e08a9ca3 100644 --- a/gcc/ada/a-fwteio.ads +++ b/gcc/ada/a-fwteio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-inteio.ads b/gcc/ada/a-inteio.ads index f8340dce0a4..b2b3867a5bd 100644 --- a/gcc/ada/a-inteio.ads +++ b/gcc/ada/a-inteio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-intnam.ads b/gcc/ada/a-intnam.ads index 2969d558e66..e055d6aa17e 100644 --- a/gcc/ada/a-intnam.ads +++ b/gcc/ada/a-intnam.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-ioexce.ads b/gcc/ada/a-ioexce.ads index d4c6ee5d294..43239ddb066 100644 --- a/gcc/ada/a-ioexce.ads +++ b/gcc/ada/a-ioexce.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-iwteio.ads b/gcc/ada/a-iwteio.ads index 34d7b62584f..dc53046eab7 100644 --- a/gcc/ada/a-iwteio.ads +++ b/gcc/ada/a-iwteio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-lcteio.ads b/gcc/ada/a-lcteio.ads index 8db0c0e9f40..f9da97c8da0 100755 --- a/gcc/ada/a-lcteio.ads +++ b/gcc/ada/a-lcteio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-lfteio.ads b/gcc/ada/a-lfteio.ads index 1b577cf6611..1477047e3ad 100644 --- a/gcc/ada/a-lfteio.ads +++ b/gcc/ada/a-lfteio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-lfwtio.ads b/gcc/ada/a-lfwtio.ads index 3190443564c..86361414e46 100644 --- a/gcc/ada/a-lfwtio.ads +++ b/gcc/ada/a-lfwtio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-lfztio.ads b/gcc/ada/a-lfztio.ads index bbdcbae7e23..f1719b148a7 100644 --- a/gcc/ada/a-lfztio.ads +++ b/gcc/ada/a-lfztio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-liteio.ads b/gcc/ada/a-liteio.ads index da7b442f74a..535f6b0d57b 100644 --- a/gcc/ada/a-liteio.ads +++ b/gcc/ada/a-liteio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-liwtio.ads b/gcc/ada/a-liwtio.ads index 477959375da..56fad9a67a8 100644 --- a/gcc/ada/a-liwtio.ads +++ b/gcc/ada/a-liwtio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-liztio.ads b/gcc/ada/a-liztio.ads index 9ce4383f08b..100ef0a6a9e 100644 --- a/gcc/ada/a-liztio.ads +++ b/gcc/ada/a-liztio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-llctio.ads b/gcc/ada/a-llctio.ads index 70947a11782..3b53bf7c76d 100755 --- a/gcc/ada/a-llctio.ads +++ b/gcc/ada/a-llctio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-llftio.ads b/gcc/ada/a-llftio.ads index 669c1b59c68..589232d0240 100644 --- a/gcc/ada/a-llftio.ads +++ b/gcc/ada/a-llftio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-llfwti.ads b/gcc/ada/a-llfwti.ads index 76b47a30f40..b26aecdb94c 100644 --- a/gcc/ada/a-llfwti.ads +++ b/gcc/ada/a-llfwti.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-llfzti.ads b/gcc/ada/a-llfzti.ads index 1c03246b1f8..fa92ef40a65 100644 --- a/gcc/ada/a-llfzti.ads +++ b/gcc/ada/a-llfzti.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-llitio.ads b/gcc/ada/a-llitio.ads index 8788c68c089..e1537276d1a 100644 --- a/gcc/ada/a-llitio.ads +++ b/gcc/ada/a-llitio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-lliwti.ads b/gcc/ada/a-lliwti.ads index d4064c81ca6..13a0f21436b 100644 --- a/gcc/ada/a-lliwti.ads +++ b/gcc/ada/a-lliwti.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-llizti.ads b/gcc/ada/a-llizti.ads index 9ab6d41a0cb..09d3219f350 100644 --- a/gcc/ada/a-llizti.ads +++ b/gcc/ada/a-llizti.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-ncelfu.ads b/gcc/ada/a-ncelfu.ads index 0f8e585a3bd..e81730f08cd 100644 --- a/gcc/ada/a-ncelfu.ads +++ b/gcc/ada/a-ncelfu.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-ngcefu.ads b/gcc/ada/a-ngcefu.ads index a60f668f278..576c84ab267 100644 --- a/gcc/ada/a-ngcefu.ads +++ b/gcc/ada/a-ngcefu.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-ngelfu.ads b/gcc/ada/a-ngelfu.ads index c115411ca89..d84828a7ccb 100644 --- a/gcc/ada/a-ngelfu.ads +++ b/gcc/ada/a-ngelfu.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-nlcefu.ads b/gcc/ada/a-nlcefu.ads index df3e4916acc..9e985dfca6a 100644 --- a/gcc/ada/a-nlcefu.ads +++ b/gcc/ada/a-nlcefu.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-nlcoty.ads b/gcc/ada/a-nlcoty.ads index 7e021ae66b9..6eb4fc3b992 100644 --- a/gcc/ada/a-nlcoty.ads +++ b/gcc/ada/a-nlcoty.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-nlelfu.ads b/gcc/ada/a-nlelfu.ads index db0bd25a815..10b33e9cb3c 100644 --- a/gcc/ada/a-nlelfu.ads +++ b/gcc/ada/a-nlelfu.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-nllcef.ads b/gcc/ada/a-nllcef.ads index 54b5b39af9e..2867e1dbb03 100644 --- a/gcc/ada/a-nllcef.ads +++ b/gcc/ada/a-nllcef.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-nllcty.ads b/gcc/ada/a-nllcty.ads index 371b757dc66..a6081c28b21 100644 --- a/gcc/ada/a-nllcty.ads +++ b/gcc/ada/a-nllcty.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-nllefu.ads b/gcc/ada/a-nllefu.ads index 55d55ffdbab..7089fc3efb0 100644 --- a/gcc/ada/a-nllefu.ads +++ b/gcc/ada/a-nllefu.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-nscefu.ads b/gcc/ada/a-nscefu.ads index f7d17c6ffda..ac89d051c87 100644 --- a/gcc/ada/a-nscefu.ads +++ b/gcc/ada/a-nscefu.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-nscoty.ads b/gcc/ada/a-nscoty.ads index b4e3f500e22..e58b0b56e58 100644 --- a/gcc/ada/a-nscoty.ads +++ b/gcc/ada/a-nscoty.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-nselfu.ads b/gcc/ada/a-nselfu.ads index 3ad54aef629..10b04acdeb9 100644 --- a/gcc/ada/a-nselfu.ads +++ b/gcc/ada/a-nselfu.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-nucoty.ads b/gcc/ada/a-nucoty.ads index 97e224bb7f3..3b04a2712d0 100644 --- a/gcc/ada/a-nucoty.ads +++ b/gcc/ada/a-nucoty.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-nuelfu.ads b/gcc/ada/a-nuelfu.ads index 57fdb1c6eec..149939babea 100644 --- a/gcc/ada/a-nuelfu.ads +++ b/gcc/ada/a-nuelfu.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-numeri.ads b/gcc/ada/a-numeri.ads index 4d25bce476b..998e24bc28f 100644 --- a/gcc/ada/a-numeri.ads +++ b/gcc/ada/a-numeri.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-rbtgso.ads b/gcc/ada/a-rbtgso.ads index 4c3d668f719..c39dc6e3fce 100644 --- a/gcc/ada/a-rbtgso.ads +++ b/gcc/ada/a-rbtgso.ads @@ -59,25 +59,51 @@ package Ada.Containers.Red_Black_Trees.Generic_Set_Operations is pragma Pure; procedure Union (Target : in out Tree_Type; Source : Tree_Type); + -- Attempts to insert each element of Source in Target. If Target is + -- busy then Program_Error is raised. We say "attempts" here because + -- if these are unique-element sets, then the insertion should fail + -- (not insert a new item) when the insertion item from Source is + -- equivalent to an item already in Target. If these are multisets + -- then of course the attempt should always succeed. function Union (Left, Right : Tree_Type) return Tree_Type; + -- Makes a copy of Left, and attempts to insert each element of + -- Right into the copy, then returns the copy. procedure Intersection (Target : in out Tree_Type; Source : Tree_Type); + -- Removes elements from Target that are not equivalent to items in + -- Source. If Target is busy then Program_Error is raised. function Intersection (Left, Right : Tree_Type) return Tree_Type; + -- Returns a set comprising all the items in Left equivalent to items in + -- Right. procedure Difference (Target : in out Tree_Type; Source : Tree_Type); + -- Removes elements from Target that are equivalent to items in Source. If + -- Target is busy then Program_Error is raised. function Difference (Left, Right : Tree_Type) return Tree_Type; + -- Returns a set comprising all the items in Left not equivalent to items + -- in Right. procedure Symmetric_Difference (Target : in out Tree_Type; Source : Tree_Type); + -- Removes from Target elements that are equivalent to items in Source, and + -- inserts into Target items from Source not equivalent elements in + -- Target. If Target is busy then Program_Error is raised. function Symmetric_Difference (Left, Right : Tree_Type) return Tree_Type; + -- Returns a set comprising the union of the elements in Left not + -- equivalent to items in Right, and the elements in Right not equivalent + -- to items in Left. function Is_Subset (Subset : Tree_Type; Of_Set : Tree_Type) return Boolean; + -- Returns False if Subset contains at least one element not equivalent to + -- any item in Of_Set; returns True otherwise. function Overlap (Left, Right : Tree_Type) return Boolean; + -- Returns True if at least one element of Left is equivalent to an item in + -- Right; returns False otherwise. end Ada.Containers.Red_Black_Trees.Generic_Set_Operations; diff --git a/gcc/ada/a-scteio.ads b/gcc/ada/a-scteio.ads index f8623d82963..d9ceb2f9c27 100755 --- a/gcc/ada/a-scteio.ads +++ b/gcc/ada/a-scteio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-secain.ads b/gcc/ada/a-secain.ads index 3a4b4d8bc0b..38f2ef04f57 100644 --- a/gcc/ada/a-secain.ads +++ b/gcc/ada/a-secain.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-sfteio.ads b/gcc/ada/a-sfteio.ads index 15ab2a76ad5..a1f18cd8555 100644 --- a/gcc/ada/a-sfteio.ads +++ b/gcc/ada/a-sfteio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-sfwtio.ads b/gcc/ada/a-sfwtio.ads index d6136d565c2..3ac134e939e 100644 --- a/gcc/ada/a-sfwtio.ads +++ b/gcc/ada/a-sfwtio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-sfztio.ads b/gcc/ada/a-sfztio.ads index 24458458a12..bc34e5d5a82 100644 --- a/gcc/ada/a-sfztio.ads +++ b/gcc/ada/a-sfztio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-shcain.ads b/gcc/ada/a-shcain.ads index a6e083c1e47..c7263b602fe 100644 --- a/gcc/ada/a-shcain.ads +++ b/gcc/ada/a-shcain.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-siteio.ads b/gcc/ada/a-siteio.ads index 9f3e5e1c585..de45c22cce1 100644 --- a/gcc/ada/a-siteio.ads +++ b/gcc/ada/a-siteio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-siwtio.ads b/gcc/ada/a-siwtio.ads index 618a01658b7..aa1a2d4562b 100644 --- a/gcc/ada/a-siwtio.ads +++ b/gcc/ada/a-siwtio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-siztio.ads b/gcc/ada/a-siztio.ads index 4d4107769ef..3d6f5cdf17c 100644 --- a/gcc/ada/a-siztio.ads +++ b/gcc/ada/a-siztio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-slcain.ads b/gcc/ada/a-slcain.ads index c54c6f24ec4..2bb2d1ad4c7 100644 --- a/gcc/ada/a-slcain.ads +++ b/gcc/ada/a-slcain.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-ssitio.ads b/gcc/ada/a-ssitio.ads index a323230023d..98b0540889e 100644 --- a/gcc/ada/a-ssitio.ads +++ b/gcc/ada/a-ssitio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-ssiwti.ads b/gcc/ada/a-ssiwti.ads index af5d1abde10..5f6934ba60d 100644 --- a/gcc/ada/a-ssiwti.ads +++ b/gcc/ada/a-ssiwti.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-ssizti.ads b/gcc/ada/a-ssizti.ads index d200170c273..13bfda84666 100644 --- a/gcc/ada/a-ssizti.ads +++ b/gcc/ada/a-ssizti.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-stboha.ads b/gcc/ada/a-stboha.ads index 999850e9ef1..876af2a5df3 100644 --- a/gcc/ada/a-stboha.ads +++ b/gcc/ada/a-stboha.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-stfiha.ads b/gcc/ada/a-stfiha.ads index 23380034625..aba42e7c678 100644 --- a/gcc/ada/a-stfiha.ads +++ b/gcc/ada/a-stfiha.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-storio.ads b/gcc/ada/a-storio.ads index e5268c80399..db0a70bbe4f 100644 --- a/gcc/ada/a-storio.ads +++ b/gcc/ada/a-storio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-strfix.ads b/gcc/ada/a-strfix.ads index 04087925f7d..875219a1c9b 100644 --- a/gcc/ada/a-strfix.ads +++ b/gcc/ada/a-strfix.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-strhas.ads b/gcc/ada/a-strhas.ads index cb11fc056f3..7d33bf7d019 100644 --- a/gcc/ada/a-strhas.ads +++ b/gcc/ada/a-strhas.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-string.ads b/gcc/ada/a-string.ads index a599c2be8c4..51ca1024721 100644 --- a/gcc/ada/a-string.ads +++ b/gcc/ada/a-string.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-ststio.adb b/gcc/ada/a-ststio.adb index 7091d5d9f7b..d1084d64b5b 100644 --- a/gcc/ada/a-ststio.adb +++ b/gcc/ada/a-ststio.adb @@ -76,7 +76,7 @@ package body Ada.Streams.Stream_IO is -- No special processing required for closing Stream_IO file - procedure AFCB_Close (File : access Stream_AFCB) is + procedure AFCB_Close (File : not null access Stream_AFCB) is pragma Warnings (Off, File); begin null; @@ -86,7 +86,7 @@ package body Ada.Streams.Stream_IO is -- AFCB_Free -- --------------- - procedure AFCB_Free (File : access Stream_AFCB) is + procedure AFCB_Free (File : not null access Stream_AFCB) is type FCB_Ptr is access all Stream_AFCB; FT : FCB_Ptr := FCB_Ptr (File); diff --git a/gcc/ada/a-ststio.ads b/gcc/ada/a-ststio.ads index 232672985d5..edcec9a139a 100644 --- a/gcc/ada/a-ststio.ads +++ b/gcc/ada/a-ststio.ads @@ -176,8 +176,8 @@ private function AFCB_Allocate (Control_Block : Stream_AFCB) return FCB.AFCB_Ptr; - procedure AFCB_Close (File : access Stream_AFCB); - procedure AFCB_Free (File : access Stream_AFCB); + procedure AFCB_Close (File : not null access Stream_AFCB); + procedure AFCB_Free (File : not null access Stream_AFCB); procedure Read (File : in out Stream_AFCB; diff --git a/gcc/ada/a-stunha.ads b/gcc/ada/a-stunha.ads index acf04716762..1e45bdb5abc 100644 --- a/gcc/ada/a-stunha.ads +++ b/gcc/ada/a-stunha.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-stwifi.ads b/gcc/ada/a-stwifi.ads index be2e03803fb..5d9ea3f584d 100644 --- a/gcc/ada/a-stwifi.ads +++ b/gcc/ada/a-stwifi.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-stwiha.ads b/gcc/ada/a-stwiha.ads index 3b0af1fc751..f8f0b52fb94 100644 --- a/gcc/ada/a-stwiha.ads +++ b/gcc/ada/a-stwiha.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-stzfix.ads b/gcc/ada/a-stzfix.ads index 1670b381ce4..4c3f80b4bdb 100644 --- a/gcc/ada/a-stzfix.ads +++ b/gcc/ada/a-stzfix.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-stzhas.ads b/gcc/ada/a-stzhas.ads index 8a8436c33df..dea0ff14670 100644 --- a/gcc/ada/a-stzhas.ads +++ b/gcc/ada/a-stzhas.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-swbwha.ads b/gcc/ada/a-swbwha.ads index 59479527c30..6a4fba76ffe 100644 --- a/gcc/ada/a-swbwha.ads +++ b/gcc/ada/a-swbwha.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-swfwha.ads b/gcc/ada/a-swfwha.ads index ebabe865b70..c42d54cd56a 100644 --- a/gcc/ada/a-swfwha.ads +++ b/gcc/ada/a-swfwha.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-swuwha.ads b/gcc/ada/a-swuwha.ads index 1fcb41007f8..69cf76227a4 100644 --- a/gcc/ada/a-swuwha.ads +++ b/gcc/ada/a-swuwha.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-szbzha.ads b/gcc/ada/a-szbzha.ads index b368d793414..42c6452d4f1 100644 --- a/gcc/ada/a-szbzha.ads +++ b/gcc/ada/a-szbzha.ads @@ -7,7 +7,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-szfzha.ads b/gcc/ada/a-szfzha.ads index 1753fc7462c..fbc6e87908b 100644 --- a/gcc/ada/a-szfzha.ads +++ b/gcc/ada/a-szfzha.ads @@ -7,7 +7,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-szuzha.ads b/gcc/ada/a-szuzha.ads index 1e07fbdbd2b..94bed28eb90 100644 --- a/gcc/ada/a-szuzha.ads +++ b/gcc/ada/a-szuzha.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-textio.adb b/gcc/ada/a-textio.adb index 0e6dd3240c1..aa566dac230 100644 --- a/gcc/ada/a-textio.adb +++ b/gcc/ada/a-textio.adb @@ -69,7 +69,7 @@ package body Ada.Text_IO is -- AFCB_Close -- ---------------- - procedure AFCB_Close (File : access Text_AFCB) is + procedure AFCB_Close (File : not null access Text_AFCB) is begin -- If the file being closed is one of the current files, then close -- the corresponding current file. It is not clear that this action @@ -91,7 +91,7 @@ package body Ada.Text_IO is -- AFCB_Free -- --------------- - procedure AFCB_Free (File : access Text_AFCB) is + procedure AFCB_Free (File : not null access Text_AFCB) is type FCB_Ptr is access all Text_AFCB; FT : FCB_Ptr := FCB_Ptr (File); diff --git a/gcc/ada/a-textio.ads b/gcc/ada/a-textio.ads index 50ba549285a..dec8ee7f891 100644 --- a/gcc/ada/a-textio.ads +++ b/gcc/ada/a-textio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1992-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2006, Free Software Foundation, Inc. -- -- -- -- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. The copyright notice above, and the license provisions that follow -- @@ -370,8 +370,8 @@ private function AFCB_Allocate (Control_Block : Text_AFCB) return FCB.AFCB_Ptr; - procedure AFCB_Close (File : access Text_AFCB); - procedure AFCB_Free (File : access Text_AFCB); + procedure AFCB_Close (File : not null access Text_AFCB); + procedure AFCB_Free (File : not null access Text_AFCB); procedure Read (File : in out Text_AFCB; diff --git a/gcc/ada/a-tgdico.ads b/gcc/ada/a-tgdico.ads index 51e3d80df05..d1150fd5991 100644 --- a/gcc/ada/a-tgdico.ads +++ b/gcc/ada/a-tgdico.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- @@ -19,10 +19,12 @@ pragma Warnings (Off); generic type T (<>) is abstract tagged limited private; type Parameters (<>) is limited private; - with function Constructor (Params : access Parameters) return T is abstract; + with function Constructor (Params : not null access Parameters) return T + is abstract; function Ada.Tags.Generic_Dispatching_Constructor - (The_Tag : Tag; Params : access Parameters) return T'Class; + (The_Tag : Tag; + Params : not null access Parameters) return T'Class; pragma Preelaborate_05 (Generic_Dispatching_Constructor); pragma Import (Intrinsic, Generic_Dispatching_Constructor); -- Note: the reason that we use Preelaborate_05 here is so that this will diff --git a/gcc/ada/a-tiboio.ads b/gcc/ada/a-tiboio.ads index 4f23c7ed92c..1824c1d2c50 100644 --- a/gcc/ada/a-tiboio.ads +++ b/gcc/ada/a-tiboio.ads @@ -6,9 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1997-2005, Free Software Foundation, Inc. -- --- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-tideau.adb b/gcc/ada/a-tideau.adb index 5be5f66f074..06a41ee791d 100644 --- a/gcc/ada/a-tideau.adb +++ b/gcc/ada/a-tideau.adb @@ -103,7 +103,7 @@ package body Ada.Text_IO.Decimal_Aux is function Gets_Dec (From : String; - Last : access Positive; + Last : not null access Positive; Scale : Integer) return Integer is Pos : aliased Integer; @@ -127,7 +127,7 @@ package body Ada.Text_IO.Decimal_Aux is function Gets_LLD (From : String; - Last : access Positive; + Last : not null access Positive; Scale : Integer) return Long_Long_Integer is Pos : aliased Integer; diff --git a/gcc/ada/a-tideau.ads b/gcc/ada/a-tideau.ads index 9855e5b4237..7d513aee55a 100644 --- a/gcc/ada/a-tideau.ads +++ b/gcc/ada/a-tideau.ads @@ -69,12 +69,12 @@ private package Ada.Text_IO.Decimal_Aux is function Gets_Dec (From : String; - Last : access Positive; + Last : not null access Positive; Scale : Integer) return Integer; function Gets_LLD (From : String; - Last : access Positive; + Last : not null access Positive; Scale : Integer) return Long_Long_Integer; procedure Puts_Dec diff --git a/gcc/ada/a-titest.ads b/gcc/ada/a-titest.ads index d2fa2e7b3f6..93cf47aad7b 100644 --- a/gcc/ada/a-titest.ads +++ b/gcc/ada/a-titest.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-tiunio.ads b/gcc/ada/a-tiunio.ads index 68f8a17ebeb..ea5caecf599 100644 --- a/gcc/ada/a-tiunio.ads +++ b/gcc/ada/a-tiunio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-unccon.ads b/gcc/ada/a-unccon.ads index 3306c3bbca9..ffa84d9fad2 100644 --- a/gcc/ada/a-unccon.ads +++ b/gcc/ada/a-unccon.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-uncdea.ads b/gcc/ada/a-uncdea.ads index 66b64dd1590..d566b4b343f 100644 --- a/gcc/ada/a-uncdea.ads +++ b/gcc/ada/a-uncdea.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-widcha.ads b/gcc/ada/a-widcha.ads index 371c1c16599..a5dde73f43c 100755 --- a/gcc/ada/a-widcha.ads +++ b/gcc/ada/a-widcha.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-witeio.adb b/gcc/ada/a-witeio.adb index 7f72c1cec9d..07e3fd26871 100644 --- a/gcc/ada/a-witeio.adb +++ b/gcc/ada/a-witeio.adb @@ -96,7 +96,7 @@ package body Ada.Wide_Text_IO is -- AFCB_Close -- ---------------- - procedure AFCB_Close (File : access Wide_Text_AFCB) is + procedure AFCB_Close (File : not null access Wide_Text_AFCB) is begin -- If the file being closed is one of the current files, then close -- the corresponding current file. It is not clear that this action @@ -118,7 +118,7 @@ package body Ada.Wide_Text_IO is -- AFCB_Free -- --------------- - procedure AFCB_Free (File : access Wide_Text_AFCB) is + procedure AFCB_Free (File : not null access Wide_Text_AFCB) is type FCB_Ptr is access all Wide_Text_AFCB; FT : FCB_Ptr := FCB_Ptr (File); diff --git a/gcc/ada/a-witeio.ads b/gcc/ada/a-witeio.ads index 9430187ca98..70636a711d5 100644 --- a/gcc/ada/a-witeio.ads +++ b/gcc/ada/a-witeio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1992-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2006, Free Software Foundation, Inc. -- -- -- -- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. The copyright notice above, and the license provisions that follow -- @@ -393,8 +393,8 @@ private function AFCB_Allocate (Control_Block : Wide_Text_AFCB) return FCB.AFCB_Ptr; - procedure AFCB_Close (File : access Wide_Text_AFCB); - procedure AFCB_Free (File : access Wide_Text_AFCB); + procedure AFCB_Close (File : not null access Wide_Text_AFCB); + procedure AFCB_Free (File : not null access Wide_Text_AFCB); procedure Read (File : in out Wide_Text_AFCB; diff --git a/gcc/ada/a-wtcoio.ads b/gcc/ada/a-wtcoio.ads index 84a5f1405f1..31fab2b6f22 100644 --- a/gcc/ada/a-wtcoio.ads +++ b/gcc/ada/a-wtcoio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-wtdeau.adb b/gcc/ada/a-wtdeau.adb index 6b6286537f0..fd6cc2eea42 100644 --- a/gcc/ada/a-wtdeau.adb +++ b/gcc/ada/a-wtdeau.adb @@ -103,7 +103,7 @@ package body Ada.Wide_Text_IO.Decimal_Aux is function Gets_Dec (From : String; - Last : access Positive; + Last : not null access Positive; Scale : Integer) return Integer is Pos : aliased Integer; @@ -128,7 +128,7 @@ package body Ada.Wide_Text_IO.Decimal_Aux is function Gets_LLD (From : String; - Last : access Positive; + Last : not null access Positive; Scale : Integer) return Long_Long_Integer is Pos : aliased Integer; diff --git a/gcc/ada/a-wtdeau.ads b/gcc/ada/a-wtdeau.ads index f8983ebd83d..b469a3574e3 100644 --- a/gcc/ada/a-wtdeau.ads +++ b/gcc/ada/a-wtdeau.ads @@ -54,12 +54,12 @@ private package Ada.Wide_Text_IO.Decimal_Aux is function Gets_Dec (From : String; - Last : access Positive; + Last : not null access Positive; Scale : Integer) return Integer; function Gets_LLD (From : String; - Last : access Positive; + Last : not null access Positive; Scale : Integer) return Long_Long_Integer; procedure Put_Dec diff --git a/gcc/ada/a-wtinio.ads b/gcc/ada/a-wtinio.ads index 257ba23ac96..b078ee379bb 100644 --- a/gcc/ada/a-wtinio.ads +++ b/gcc/ada/a-wtinio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-wttest.ads b/gcc/ada/a-wttest.ads index c209e0e401d..7c180ff182f 100644 --- a/gcc/ada/a-wttest.ads +++ b/gcc/ada/a-wttest.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-wwboio.ads b/gcc/ada/a-wwboio.ads index 634a265facf..2b8dd2a16a6 100644 --- a/gcc/ada/a-wwboio.ads +++ b/gcc/ada/a-wwboio.ads @@ -6,9 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1997-2005, Free Software Foundation, Inc. -- --- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-wwunio.ads b/gcc/ada/a-wwunio.ads index ed7c31b805f..de044c580e0 100644 --- a/gcc/ada/a-wwunio.ads +++ b/gcc/ada/a-wwunio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-zchara.ads b/gcc/ada/a-zchara.ads index 0802bfc62f4..d8d5f9f50bb 100755 --- a/gcc/ada/a-zchara.ads +++ b/gcc/ada/a-zchara.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-ztcoio.ads b/gcc/ada/a-ztcoio.ads index 641065b760c..866fd879c64 100644 --- a/gcc/ada/a-ztcoio.ads +++ b/gcc/ada/a-ztcoio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-ztdeau.adb b/gcc/ada/a-ztdeau.adb index b6b9b94c440..d36d34fb8bd 100644 --- a/gcc/ada/a-ztdeau.adb +++ b/gcc/ada/a-ztdeau.adb @@ -6,7 +6,7 @@ -- -- -- B o d y -- -- -- --- Copyright (C) 1992-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2006, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -103,7 +103,7 @@ package body Ada.Wide_Wide_Text_IO.Decimal_Aux is function Gets_Dec (From : String; - Last : access Positive; + Last : not null access Positive; Scale : Integer) return Integer is Pos : aliased Integer; @@ -128,7 +128,7 @@ package body Ada.Wide_Wide_Text_IO.Decimal_Aux is function Gets_LLD (From : String; - Last : access Positive; + Last : not null access Positive; Scale : Integer) return Long_Long_Integer is Pos : aliased Integer; diff --git a/gcc/ada/a-ztdeau.ads b/gcc/ada/a-ztdeau.ads index ba9ffcb42d3..e61bc93ffc5 100644 --- a/gcc/ada/a-ztdeau.ads +++ b/gcc/ada/a-ztdeau.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1992-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2006, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -54,12 +54,12 @@ private package Ada.Wide_Wide_Text_IO.Decimal_Aux is function Gets_Dec (From : String; - Last : access Positive; + Last : not null access Positive; Scale : Integer) return Integer; function Gets_LLD (From : String; - Last : access Positive; + Last : not null access Positive; Scale : Integer) return Long_Long_Integer; procedure Put_Dec diff --git a/gcc/ada/a-ztexio.adb b/gcc/ada/a-ztexio.adb index daadd54b4de..47de699ba70 100644 --- a/gcc/ada/a-ztexio.adb +++ b/gcc/ada/a-ztexio.adb @@ -96,7 +96,7 @@ package body Ada.Wide_Wide_Text_IO is -- AFCB_Close -- ---------------- - procedure AFCB_Close (File : access Wide_Wide_Text_AFCB) is + procedure AFCB_Close (File : not null access Wide_Wide_Text_AFCB) is begin -- If the file being closed is one of the current files, then close -- the corresponding current file. It is not clear that this action @@ -118,7 +118,7 @@ package body Ada.Wide_Wide_Text_IO is -- AFCB_Free -- --------------- - procedure AFCB_Free (File : access Wide_Wide_Text_AFCB) is + procedure AFCB_Free (File : not null access Wide_Wide_Text_AFCB) is type FCB_Ptr is access all Wide_Wide_Text_AFCB; FT : FCB_Ptr := FCB_Ptr (File); diff --git a/gcc/ada/a-ztexio.ads b/gcc/ada/a-ztexio.ads index 000d104e16b..e200b17c32e 100644 --- a/gcc/ada/a-ztexio.ads +++ b/gcc/ada/a-ztexio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1992-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2006, Free Software Foundation, Inc. -- -- -- -- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. The copyright notice above, and the license provisions that follow -- @@ -395,8 +395,8 @@ private function AFCB_Allocate (Control_Block : Wide_Wide_Text_AFCB) return FCB.AFCB_Ptr; - procedure AFCB_Close (File : access Wide_Wide_Text_AFCB); - procedure AFCB_Free (File : access Wide_Wide_Text_AFCB); + procedure AFCB_Close (File : not null access Wide_Wide_Text_AFCB); + procedure AFCB_Free (File : not null access Wide_Wide_Text_AFCB); procedure Read (File : in out Wide_Wide_Text_AFCB; diff --git a/gcc/ada/a-ztinio.ads b/gcc/ada/a-ztinio.ads index 4efd6841ade..4358e7b1e68 100644 --- a/gcc/ada/a-ztinio.ads +++ b/gcc/ada/a-ztinio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-zttest.ads b/gcc/ada/a-zttest.ads index b417ecac925..1599253d20f 100644 --- a/gcc/ada/a-zttest.ads +++ b/gcc/ada/a-zttest.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-zzboio.ads b/gcc/ada/a-zzboio.ads index 83b4ed9f10f..68157e965d7 100644 --- a/gcc/ada/a-zzboio.ads +++ b/gcc/ada/a-zzboio.ads @@ -6,9 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1997-2005, Free Software Foundation, Inc. -- --- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/a-zzunio.ads b/gcc/ada/a-zzunio.ads index f54d515ec27..1695b06298a 100644 --- a/gcc/ada/a-zzunio.ads +++ b/gcc/ada/a-zzunio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/ada.ads b/gcc/ada/ada.ads index 2e9f35c8cd2..8c860110f92 100644 --- a/gcc/ada/ada.ads +++ b/gcc/ada/ada.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/calendar.ads b/gcc/ada/calendar.ads index 92e93cfca4c..7b13a6f2389 100644 --- a/gcc/ada/calendar.ads +++ b/gcc/ada/calendar.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/directio.ads b/gcc/ada/directio.ads index c8239ec6004..b69ca4467e1 100644 --- a/gcc/ada/directio.ads +++ b/gcc/ada/directio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/expander.adb b/gcc/ada/expander.adb index 91191941b16..103716a98b3 100644 --- a/gcc/ada/expander.adb +++ b/gcc/ada/expander.adb @@ -55,10 +55,10 @@ package body Expander is -- Local Data -- ---------------- - -- The following table is used to save values of the Expander_Active - -- flag when they are saved by Expander_Mode_Save_And_Set. We use an - -- extendible table (which is a bit of overkill) because it is easier - -- than figuring out a maximum value or bothering with range checks! + -- The following table is used to save values of the Expander_Active flag + -- when they are saved by Expander_Mode_Save_And_Set. We use an extendible + -- table (which is a bit of overkill) because it is easier than figuring + -- out a maximum value or bothering with range checks! package Expander_Flags is new Table.Table ( Table_Component_Type => Boolean, @@ -74,17 +74,16 @@ package body Expander is procedure Expand (N : Node_Id) is begin - -- If we were analyzing a default expression the Full_Analysis flag - -- must be off. If we are in expansion mode then we must be - -- performing a full analysis. If we are analyzing a generic then - -- Expansion must be off. + -- If we were analyzing a default expression the Full_Analysis flag must + -- be off. If we are in expansion mode then we must be performing a full + -- analysis. If we are analyzing a generic then Expansion must be off. pragma Assert (not (Full_Analysis and then In_Default_Expression) - and then (Full_Analysis or else not Expander_Active) - and then not (Inside_A_Generic and then Expander_Active)); + and then (Full_Analysis or else not Expander_Active) + and then not (Inside_A_Generic and then Expander_Active)); - -- There are three reasons for the Expander_Active flag to be false. + -- There are three reasons for the Expander_Active flag to be false -- -- The first is when are not generating code. In this mode the -- Full_Analysis flag indicates whether we are performing a complete @@ -93,19 +92,18 @@ package body Expander is -- info on this. -- -- The second reason for the Expander_Active flag to be False is that - -- we are performing a pre-analysis. During pre-analysis all - -- expansion activity is turned off to make sure nodes are - -- semantically decorated but no extra nodes are generated. This is - -- for instance needed for the first pass of aggregate semantic - -- processing. Note that in this case the Full_Analysis flag is set - -- to False because the node will subsequently be re-analyzed with - -- expansion on (see the spec of sem). + -- we are performing a pre-analysis. During pre-analysis all expansion + -- activity is turned off to make sure nodes are semantically decorated + -- but no extra nodes are generated. This is for instance needed for + -- the first pass of aggregate semantic processing. Note that in this + -- case the Full_Analysis flag is set to False because the node will + -- subsequently be re-analyzed with expansion on (see the spec of sem). -- Finally, expansion is turned off in a regular compilation if there -- are serious errors. In that case there will be no further expansion, -- but one cleanup action may be required: if a transient scope was - -- created (e.g. for a function that returns an unconstrained type) - -- the scope may still be on the stack, and must be removed explicitly, + -- created (e.g. for a function that returns an unconstrained type) the + -- scope may still be on the stack, and must be removed explicitly, -- given that the expansion actions that would normally process it will -- not take place. This prevents cascaded errors due to stack mismatch. @@ -129,8 +127,8 @@ package body Expander is Debug_A_Entry ("expanding ", N); -- Processing depends on node kind. For full details on the expansion - -- activity required in each case, see bodies of corresponding - -- expand routines + -- activity required in each case, see bodies of corresponding expand + -- routines. begin case Nkind (N) is @@ -490,9 +488,9 @@ package body Expander is Expander_Active := Expander_Flags.Table (Expander_Flags.Last); Expander_Flags.Decrement_Last; - -- Keep expander off if serious errors detected. In this case we do - -- not need expansion, and continued expansion may cause cascaded - -- errors or compiler bombs. + -- Keep expander off if serious errors detected. In this case we do not + -- need expansion, and continued expansion may cause cascaded errors or + -- compiler bombs. if Serious_Errors_Detected /= 0 then Expander_Active := False; diff --git a/gcc/ada/g-calend.adb b/gcc/ada/g-calend.adb index ea8f28a3a68..3fec4a093e8 100644 --- a/gcc/ada/g-calend.adb +++ b/gcc/ada/g-calend.adb @@ -6,7 +6,7 @@ -- -- -- B o d y -- -- -- --- Copyright (C) 1999-2005, AdaCore -- +-- Copyright (C) 1999-2006, AdaCore -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -41,13 +41,13 @@ package body GNAT.Calendar is ----------------- function Day_In_Year (Date : Time) return Day_In_Year_Number is - Year : Year_Number; - Month : Month_Number; - Day : Day_Number; - Dsecs : Day_Duration; + Year : Year_Number; + Month : Month_Number; + Day : Day_Number; + Day_Secs : Day_Duration; begin - Split (Date, Year, Month, Day, Dsecs); + Split (Date, Year, Month, Day, Day_Secs); return Julian_Day (Year, Month, Day) - Julian_Day (Year, 1, 1) + 1; end Day_In_Year; @@ -57,13 +57,13 @@ package body GNAT.Calendar is ----------------- function Day_Of_Week (Date : Time) return Day_Name is - Year : Year_Number; - Month : Month_Number; - Day : Day_Number; - Dsecs : Day_Duration; + Year : Year_Number; + Month : Month_Number; + Day : Day_Number; + Day_Secs : Day_Duration; begin - Split (Date, Year, Month, Day, Dsecs); + Split (Date, Year, Month, Day, Day_Secs); return Day_Name'Val ((Julian_Day (Year, Month, Day)) mod 7); end Day_Of_Week; @@ -90,8 +90,8 @@ package body GNAT.Calendar is -- Julian_Day -- ---------------- - -- Julian_Day is used to by Day_Of_Week and Day_In_Year. Note - -- that this implementation is not expensive. + -- Julian_Day is used to by Day_Of_Week and Day_In_Year. Note that this + -- implementation is not expensive. function Julian_Day (Year : Year_Number; @@ -178,21 +178,21 @@ package body GNAT.Calendar is Second : out Second_Number; Sub_Second : out Second_Duration) is - Dsecs : Day_Duration; - Secs : Natural; + Day_Secs : Day_Duration; + Secs : Natural; begin - Split (Date, Year, Month, Day, Dsecs); + Split (Date, Year, Month, Day, Day_Secs); - if Dsecs = 0.0 then + if Day_Secs = 0.0 then Secs := 0; else - Secs := Natural (Dsecs - 0.5); + Secs := Natural (Day_Secs - 0.5); end if; - Sub_Second := Second_Duration (Dsecs - Day_Duration (Secs)); - Hour := Hour_Number (Secs / 3600); - Secs := Secs mod 3600; + Sub_Second := Second_Duration (Day_Secs - Day_Duration (Secs)); + Hour := Hour_Number (Secs / 3_600); + Secs := Secs mod 3_600; Minute := Minute_Number (Secs / 60); Second := Second_Number (Secs mod 60); end Split; @@ -228,23 +228,25 @@ package body GNAT.Calendar is Second : Second_Number; Sub_Second : Second_Duration := 0.0) return Time is - Dsecs : constant Day_Duration := - Day_Duration (Hour * 3600 + Minute * 60 + Second) + - Sub_Second; + Day_Secs : constant Day_Duration := + Day_Duration (Hour * 3_600) + + Day_Duration (Minute * 60) + + Day_Duration (Second) + + Sub_Second; begin - return Time_Of (Year, Month, Day, Dsecs); + return Time_Of (Year, Month, Day, Day_Secs); end Time_Of; ----------------- -- To_Duration -- ----------------- - function To_Duration (T : access timeval) return Duration is + function To_Duration (T : not null access timeval) return Duration is procedure timeval_to_duration - (T : access timeval; - sec : access C.long; - usec : access C.long); + (T : not null access timeval; + sec : not null access C.long; + usec : not null access C.long); pragma Import (C, timeval_to_duration, "__gnat_timeval_to_duration"); Micro : constant := 10**6; @@ -260,9 +262,12 @@ package body GNAT.Calendar is -- To_Timeval -- ---------------- - function To_Timeval (D : Duration) return timeval is + function To_Timeval (D : Duration) return timeval is - procedure duration_to_timeval (Sec, Usec : C.long; T : access timeval); + procedure duration_to_timeval + (Sec : C.long; + Usec : C.long; + T : not null access timeval); pragma Import (C, duration_to_timeval, "__gnat_duration_to_timeval"); Micro : constant := 10**6; @@ -288,9 +293,7 @@ package body GNAT.Calendar is -- Week_In_Year -- ------------------ - function Week_In_Year - (Date : Ada.Calendar.Time) return Week_In_Year_Number - is + function Week_In_Year (Date : Time) return Week_In_Year_Number is Year : Year_Number; Month : Month_Number; Day : Day_Number; diff --git a/gcc/ada/g-calend.ads b/gcc/ada/g-calend.ads index 8288635da74..e8b43456371 100644 --- a/gcc/ada/g-calend.ads +++ b/gcc/ada/g-calend.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1999-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1999-2006, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -106,7 +106,7 @@ package GNAT.Calendar is type timeval is private; - function To_Duration (T : access timeval) return Duration; + function To_Duration (T : not null access timeval) return Duration; function To_Timeval (D : Duration) return timeval; private diff --git a/gcc/ada/g-dirope.adb b/gcc/ada/g-dirope.adb index 5302969ac71..99ce7ea349e 100644 --- a/gcc/ada/g-dirope.adb +++ b/gcc/ada/g-dirope.adb @@ -661,7 +661,7 @@ package body GNAT.Directory_Operations is function readdir_gnat (Directory : System.Address; Buffer : System.Address; - Last : access Integer) return System.Address; + Last : not null access Integer) return System.Address; pragma Import (C, readdir_gnat, "__gnat_readdir"); begin diff --git a/gcc/ada/g-expect-vms.adb b/gcc/ada/g-expect-vms.adb index 2381c66c45a..55ede6536c9 100644 --- a/gcc/ada/g-expect-vms.adb +++ b/gcc/ada/g-expect-vms.adb @@ -95,7 +95,7 @@ package body GNAT.Expect is procedure Kill (Pid : Process_Id; Sig_Num : Integer); pragma Import (C, Kill, "decc$kill"); - function Create_Pipe (Pipe : access Pipe_Type) return Integer; + function Create_Pipe (Pipe : not null access Pipe_Type) return Integer; pragma Import (C, Create_Pipe, "__gnat_pipe"); function Poll @@ -769,7 +769,7 @@ package body GNAT.Expect is (Command : String; Arguments : GNAT.OS_Lib.Argument_List; Input : String; - Status : access Integer; + Status : not null access Integer; Err_To_Out : Boolean := False) return String is use GNAT.Expect; @@ -1096,9 +1096,9 @@ package body GNAT.Expect is procedure Set_Up_Communications (Pid : in out Process_Descriptor; Err_To_Out : Boolean; - Pipe1 : access Pipe_Type; - Pipe2 : access Pipe_Type; - Pipe3 : access Pipe_Type) + Pipe1 : not null access Pipe_Type; + Pipe2 : not null access Pipe_Type; + Pipe3 : not null access Pipe_Type) is begin -- Create the pipes diff --git a/gcc/ada/g-expect.ads b/gcc/ada/g-expect.ads index b47a3a487d7..7cc1bad531f 100644 --- a/gcc/ada/g-expect.ads +++ b/gcc/ada/g-expect.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 2000-2005, AdaCore -- +-- Copyright (C) 2000-2006, AdaCore -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -229,7 +229,7 @@ package GNAT.Expect is (Command : String; Arguments : GNAT.OS_Lib.Argument_List; Input : String; - Status : access Integer; + Status : not null access Integer; Err_To_Out : Boolean := False) return String; -- Execute Command with the specified Arguments and Input, and return the -- generated standard output data as a single string. If Err_To_Out is @@ -555,9 +555,9 @@ private procedure Set_Up_Communications (Pid : in out Process_Descriptor; Err_To_Out : Boolean; - Pipe1 : access Pipe_Type; - Pipe2 : access Pipe_Type; - Pipe3 : access Pipe_Type); + Pipe1 : not null access Pipe_Type; + Pipe2 : not null access Pipe_Type; + Pipe3 : not null access Pipe_Type); -- Set up all the communication pipes and file descriptors prior to -- spawning the child process. @@ -601,7 +601,7 @@ private -- possibly in future child units providing extensions to this package. procedure Portable_Execvp - (Pid : access Process_Id; + (Pid : not null access Process_Id; Cmd : String; Args : System.Address); pragma Import (C, Portable_Execvp, "__gnat_expect_portable_execvp"); diff --git a/gcc/ada/g-socket.ads b/gcc/ada/g-socket.ads index 3e974a213ab..b585a216420 100644 --- a/gcc/ada/g-socket.ads +++ b/gcc/ada/g-socket.ads @@ -881,8 +881,7 @@ package GNAT.Sockets is type Stream_Access is access all Ada.Streams.Root_Stream_Type'Class; -- Same interface as Ada.Streams.Stream_IO - function Stream - (Socket : Socket_Type) return Stream_Access; + function Stream (Socket : Socket_Type) return Stream_Access; -- Create a stream associated with a stream-based socket that is -- already connected. @@ -892,8 +891,7 @@ package GNAT.Sockets is -- Create a stream associated with a datagram-based socket that is already -- bound. Send_To is the socket address to which messages are being sent. - function Get_Address - (Stream : Stream_Access) return Sock_Addr_Type; + function Get_Address (Stream : Stream_Access) return Sock_Addr_Type; -- Return the socket address from which the last message was received procedure Free is new Ada.Unchecked_Deallocation @@ -921,8 +919,7 @@ package GNAT.Sockets is -- Extract a Socket from socket set Item. Socket is set to -- No_Socket when the set is empty. - function Is_Empty - (Item : Socket_Set_Type) return Boolean; + function Is_Empty (Item : Socket_Set_Type) return Boolean; -- Return True iff Item is empty function Is_Set diff --git a/gcc/ada/g-spipat.adb b/gcc/ada/g-spipat.adb index a7a3af690e4..af6afc233f3 100644 --- a/gcc/ada/g-spipat.adb +++ b/gcc/ada/g-spipat.adb @@ -1646,7 +1646,7 @@ package body GNAT.Spitbol.Patterns is return (AFC with 0, new PE'(PC_Any_CS, 1, EOP, Str)); end Any; - function Any (Str : access VString) return Pattern is + function Any (Str : not null access VString) return Pattern is begin return (AFC with 0, new PE'(PC_Any_VP, 1, EOP, VString_Ptr (Str))); end Any; @@ -1825,7 +1825,7 @@ package body GNAT.Spitbol.Patterns is return (AFC with 0, new PE'(PC_Break_CS, 1, EOP, Str)); end Break; - function Break (Str : access VString) return Pattern is + function Break (Str : not null access VString) return Pattern is begin return (AFC with 0, new PE'(PC_Break_VP, 1, EOP, VString_Ptr (Str))); end Break; @@ -1859,7 +1859,7 @@ package body GNAT.Spitbol.Patterns is return BreakX_Make (new PE'(PC_BreakX_CS, 3, N, Str)); end BreakX; - function BreakX (Str : access VString) return Pattern is + function BreakX (Str : not null access VString) return Pattern is begin return BreakX_Make (new PE'(PC_BreakX_VP, 3, N, VString_Ptr (Str))); end BreakX; @@ -2779,7 +2779,7 @@ package body GNAT.Spitbol.Patterns is return (AFC with 0, new PE'(PC_Len_NF, 1, EOP, Count)); end Len; - function Len (Count : access Natural) return Pattern is + function Len (Count : not null access Natural) return Pattern is begin return (AFC with 0, new PE'(PC_Len_NP, 1, EOP, Natural_Ptr (Count))); end Len; @@ -3266,7 +3266,7 @@ package body GNAT.Spitbol.Patterns is return (AFC with 0, new PE'(PC_NotAny_CS, 1, EOP, Str)); end NotAny; - function NotAny (Str : access VString) return Pattern is + function NotAny (Str : not null access VString) return Pattern is begin return (AFC with 0, new PE'(PC_NotAny_VP, 1, EOP, VString_Ptr (Str))); end NotAny; @@ -3300,7 +3300,7 @@ package body GNAT.Spitbol.Patterns is return (AFC with 0, new PE'(PC_NSpan_CS, 1, EOP, Str)); end NSpan; - function NSpan (Str : access VString) return Pattern is + function NSpan (Str : not null access VString) return Pattern is begin return (AFC with 0, new PE'(PC_NSpan_VP, 1, EOP, VString_Ptr (Str))); end NSpan; @@ -3324,7 +3324,7 @@ package body GNAT.Spitbol.Patterns is return (AFC with 0, new PE'(PC_Pos_NF, 1, EOP, Count)); end Pos; - function Pos (Count : access Natural) return Pattern is + function Pos (Count : not null access Natural) return Pattern is begin return (AFC with 0, new PE'(PC_Pos_NP, 1, EOP, Natural_Ptr (Count))); end Pos; @@ -3394,7 +3394,7 @@ package body GNAT.Spitbol.Patterns is return (AFC with 0, new PE'(PC_RPos_NF, 1, EOP, Count)); end Rpos; - function Rpos (Count : access Natural) return Pattern is + function Rpos (Count : not null access Natural) return Pattern is begin return (AFC with 0, new PE'(PC_RPos_NP, 1, EOP, Natural_Ptr (Count))); end Rpos; @@ -3413,7 +3413,7 @@ package body GNAT.Spitbol.Patterns is return (AFC with 0, new PE'(PC_RTab_NF, 1, EOP, Count)); end Rtab; - function Rtab (Count : access Natural) return Pattern is + function Rtab (Count : not null access Natural) return Pattern is begin return (AFC with 0, new PE'(PC_RTab_NP, 1, EOP, Natural_Ptr (Count))); end Rtab; @@ -3500,7 +3500,7 @@ package body GNAT.Spitbol.Patterns is -- Setcur -- ------------ - function Setcur (Var : access Natural) return Pattern is + function Setcur (Var : not null access Natural) return Pattern is begin return (AFC with 0, new PE'(PC_Setcur, 1, EOP, Natural_Ptr (Var))); end Setcur; @@ -3529,7 +3529,7 @@ package body GNAT.Spitbol.Patterns is return (AFC with 0, new PE'(PC_Span_CS, 1, EOP, Str)); end Span; - function Span (Str : access VString) return Pattern is + function Span (Str : not null access VString) return Pattern is begin return (AFC with 0, new PE'(PC_Span_VP, 1, EOP, VString_Ptr (Str))); end Span; @@ -3628,7 +3628,7 @@ package body GNAT.Spitbol.Patterns is return (AFC with 0, new PE'(PC_Tab_NF, 1, EOP, Count)); end Tab; - function Tab (Count : access Natural) return Pattern is + function Tab (Count : not null access Natural) return Pattern is begin return (AFC with 0, new PE'(PC_Tab_NP, 1, EOP, Natural_Ptr (Count))); end Tab; diff --git a/gcc/ada/g-spipat.ads b/gcc/ada/g-spipat.ads index 31cbef67d6b..fd1281c8ce7 100644 --- a/gcc/ada/g-spipat.ads +++ b/gcc/ada/g-spipat.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1997-2005, AdaCore -- +-- Copyright (C) 1997-2006, AdaCore -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -782,7 +782,7 @@ package GNAT.Spitbol.Patterns is function Any (Str : VString) return Pattern; function Any (Str : Character) return Pattern; function Any (Str : Character_Set) return Pattern; - function Any (Str : access VString) return Pattern; + function Any (Str : not null access VString) return Pattern; function Any (Str : VString_Func) return Pattern; -- Constructs a pattern that matches a single character that is one of -- the characters in the given argument. The pattern fails if the current @@ -797,7 +797,7 @@ package GNAT.Spitbol.Patterns is function Break (Str : VString) return Pattern; function Break (Str : Character) return Pattern; function Break (Str : Character_Set) return Pattern; - function Break (Str : access VString) return Pattern; + function Break (Str : not null access VString) return Pattern; function Break (Str : VString_Func) return Pattern; -- Constructs a pattern that matches a (possibly null) string which -- is immediately followed by a character in the given argument. This @@ -809,7 +809,7 @@ package GNAT.Spitbol.Patterns is function BreakX (Str : VString) return Pattern; function BreakX (Str : Character) return Pattern; function BreakX (Str : Character_Set) return Pattern; - function BreakX (Str : access VString) return Pattern; + function BreakX (Str : not null access VString) return Pattern; function BreakX (Str : VString_Func) return Pattern; -- Like Break, but the pattern attempts to extend on a failure to find -- the next occurrence of a character in Str, and only fails when the @@ -833,7 +833,7 @@ package GNAT.Spitbol.Patterns is -- one attempt is made to match P, without trying alternatives. function Len (Count : Natural) return Pattern; - function Len (Count : access Natural) return Pattern; + function Len (Count : not null access Natural) return Pattern; function Len (Count : Natural_Func) return Pattern; -- Constructs a pattern that matches exactly the given number of -- characters. The pattern fails if fewer than this number of characters @@ -843,7 +843,7 @@ package GNAT.Spitbol.Patterns is function NotAny (Str : VString) return Pattern; function NotAny (Str : Character) return Pattern; function NotAny (Str : Character_Set) return Pattern; - function NotAny (Str : access VString) return Pattern; + function NotAny (Str : not null access VString) return Pattern; function NotAny (Str : VString_Func) return Pattern; -- Constructs a pattern that matches a single character that is not -- one of the characters in the given argument. The pattern Fails if @@ -853,14 +853,14 @@ package GNAT.Spitbol.Patterns is function NSpan (Str : VString) return Pattern; function NSpan (Str : Character) return Pattern; function NSpan (Str : Character_Set) return Pattern; - function NSpan (Str : access VString) return Pattern; + function NSpan (Str : not null access VString) return Pattern; function NSpan (Str : VString_Func) return Pattern; -- Constructs a pattern that matches the longest possible string -- consisting entirely of characters from the given argument. The -- string may be empty, so this pattern always succeeds. function Pos (Count : Natural) return Pattern; - function Pos (Count : access Natural) return Pattern; + function Pos (Count : not null access Natural) return Pattern; function Pos (Count : Natural_Func) return Pattern; -- Constructs a pattern that matches the null string if exactly Count -- characters have already been matched, and otherwise fails. @@ -870,19 +870,19 @@ package GNAT.Spitbol.Patterns is -- unmatched characters in the pattern. function Rpos (Count : Natural) return Pattern; - function Rpos (Count : access Natural) return Pattern; + function Rpos (Count : not null access Natural) return Pattern; function Rpos (Count : Natural_Func) return Pattern; -- Constructs a pattern that matches the null string if exactly Count -- characters remain to be matched in the string, and otherwise fails. function Rtab (Count : Natural) return Pattern; - function Rtab (Count : access Natural) return Pattern; + function Rtab (Count : not null access Natural) return Pattern; function Rtab (Count : Natural_Func) return Pattern; -- Constructs a pattern that matches from the current location until -- exactly Count characters remain to be matched in the string. The -- pattern fails if fewer than Count characters remain to be matched. - function Setcur (Var : access Natural) return Pattern; + function Setcur (Var : not null access Natural) return Pattern; -- Constructs a pattern that matches the null string, and assigns the -- current cursor position in the string. This value is the number of -- characters matched so far. So it is zero at the start of the match. @@ -891,7 +891,7 @@ package GNAT.Spitbol.Patterns is function Span (Str : VString) return Pattern; function Span (Str : Character) return Pattern; function Span (Str : Character_Set) return Pattern; - function Span (Str : access VString) return Pattern; + function Span (Str : not null access VString) return Pattern; function Span (Str : VString_Func) return Pattern; -- Constructs a pattern that matches the longest possible string -- consisting entirely of characters from the given argument. The @@ -904,7 +904,7 @@ package GNAT.Spitbol.Patterns is -- infinite alternation of null strings. function Tab (Count : Natural) return Pattern; - function Tab (Count : access Natural) return Pattern; + function Tab (Count : not null access Natural) return Pattern; function Tab (Count : Natural_Func) return Pattern; -- Constructs a pattern that from the current location until Count -- characters have been matched. The pattern fails if more than Count diff --git a/gcc/ada/gnatchop.adb b/gcc/ada/gnatchop.adb index eab7063253e..086548c5b81 100644 --- a/gcc/ada/gnatchop.adb +++ b/gcc/ada/gnatchop.adb @@ -6,7 +6,7 @@ -- -- -- B o d y -- -- -- --- Copyright (C) 1998-2005, AdaCore -- +-- Copyright (C) 1998-2006, AdaCore -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -240,12 +240,14 @@ procedure Gnatchop is end record; function Get_EOL - (Source : access String; + (Source : not null access String; Start : Positive) return EOL_String; -- Return the line terminator used in the passed string - procedure Parse_EOL (Source : access String; Ptr : in out Positive); + procedure Parse_EOL + (Source : not null access String; + Ptr : in out Positive); -- On return Source (Ptr) is the first character of the next line -- or EOF. Source.all must be terminated by EOF. @@ -255,12 +257,14 @@ procedure Gnatchop is -- completes, False if some system error (e.g. failure to read the -- offset information) occurs. - procedure Parse_Offset_Info (Chop_File : File_Num; Source : access String); + procedure Parse_Offset_Info + (Chop_File : File_Num; + Source : not null access String); -- Parses the output of the compiler indicating the offsets -- and names of the compilation units in Chop_File. procedure Parse_Token - (Source : access String; + (Source : not null access String; Ptr : in out Positive; Token_Ptr : out Positive); -- Skips any separators and stores the start of the token in Token_Ptr. @@ -324,7 +328,7 @@ procedure Gnatchop is -- of line sequence to be written at the end of the pragma. procedure Write_Unit - (Source : access String; + (Source : not null access String; Num : Unit_Num; TS_Time : OS_Time; Success : out Boolean); @@ -462,7 +466,7 @@ procedure Gnatchop is ------------- function Get_EOL - (Source : access String; + (Source : not null access String; Start : Positive) return EOL_String is @@ -576,7 +580,9 @@ procedure Gnatchop is -- Parse_EOL -- --------------- - procedure Parse_EOL (Source : access String; Ptr : in out Positive) is + procedure Parse_EOL + (Source : not null access String; + Ptr : in out Positive) is begin -- Skip to end of line @@ -705,7 +711,7 @@ procedure Gnatchop is procedure Parse_Offset_Info (Chop_File : File_Num; - Source : access String) + Source : not null access String) is First_Unit : constant Unit_Num := Unit.Last + 1; Bufferg : String_Access := null; @@ -944,7 +950,7 @@ procedure Gnatchop is ----------------- procedure Parse_Token - (Source : access String; + (Source : not null access String; Ptr : in out Positive; Token_Ptr : out Positive) is @@ -1607,7 +1613,7 @@ procedure Gnatchop is ---------------- procedure Write_Unit - (Source : access String; + (Source : not null access String; Num : Unit_Num; TS_Time : OS_Time; Success : out Boolean) diff --git a/gcc/ada/i-c.ads b/gcc/ada/i-c.ads index 54dbd457b92..1882e8fa40b 100644 --- a/gcc/ada/i-c.ads +++ b/gcc/ada/i-c.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/i-vxwork-x86.ads b/gcc/ada/i-vxwork-x86.ads index 360c6fce710..3c317b8d50b 100644 --- a/gcc/ada/i-vxwork-x86.ads +++ b/gcc/ada/i-vxwork-x86.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1999-2005, AdaCore -- +-- Copyright (C) 1999-2006, AdaCore -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -155,16 +155,16 @@ package Interfaces.VxWorks is procedure intVecGet2 (vector : Interrupt_Vector; pFunction : out VOIDFUNCPTR; - pIdtGate : access int; - pIdtSelector : access int); + pIdtGate : not null access int; + pIdtSelector : not null access int); -- Binding to the C routine intVecGet2. Use this to get the -- existing handler for later restoral procedure intVecSet2 (vector : Interrupt_Vector; pFunction : VOIDFUNCPTR; - pIdtGate : access int; - pIdtSelector : access int); + pIdtGate : not null access int; + pIdtSelector : not null access int); -- Binding to the C routine intVecSet2. Use this to restore a -- handler obtained using intVecGet2 diff --git a/gcc/ada/ioexcept.ads b/gcc/ada/ioexcept.ads index 548fd37fd66..0473ff32bdf 100644 --- a/gcc/ada/ioexcept.ads +++ b/gcc/ada/ioexcept.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/machcode.ads b/gcc/ada/machcode.ads index b920d8196a3..55e1ae594d8 100644 --- a/gcc/ada/machcode.ads +++ b/gcc/ada/machcode.ads @@ -6,12 +6,13 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- -- -- ------------------------------------------------------------------------------ - with System.Machine_Code; - package Machine_Code renames System.Machine_Code; +with System.Machine_Code; + +package Machine_Code renames System.Machine_Code; diff --git a/gcc/ada/par-labl.adb b/gcc/ada/par-labl.adb index 7147c36040a..fe50b7b0611 100644 --- a/gcc/ada/par-labl.adb +++ b/gcc/ada/par-labl.adb @@ -477,7 +477,6 @@ procedure Labl is begin Next_Label_Elmt := First_Elmt (Label_List); - while Present (Next_Label_Elmt) loop Label_Node := Node (Next_Label_Elmt); diff --git a/gcc/ada/s-direio.adb b/gcc/ada/s-direio.adb index 7bb3e52142a..33c94985f8c 100644 --- a/gcc/ada/s-direio.adb +++ b/gcc/ada/s-direio.adb @@ -74,7 +74,7 @@ package body System.Direct_IO is -- No special processing required for Direct_IO close - procedure AFCB_Close (File : access Direct_AFCB) is + procedure AFCB_Close (File : not null access Direct_AFCB) is pragma Unreferenced (File); begin @@ -85,7 +85,7 @@ package body System.Direct_IO is -- AFCB_Free -- --------------- - procedure AFCB_Free (File : access Direct_AFCB) is + procedure AFCB_Free (File : not null access Direct_AFCB) is type FCB_Ptr is access all Direct_AFCB; diff --git a/gcc/ada/s-direio.ads b/gcc/ada/s-direio.ads index 756bcb25281..a43ebb67fc7 100644 --- a/gcc/ada/s-direio.ads +++ b/gcc/ada/s-direio.ads @@ -66,8 +66,8 @@ package System.Direct_IO is function AFCB_Allocate (Control_Block : Direct_AFCB) return FCB.AFCB_Ptr; - procedure AFCB_Close (File : access Direct_AFCB); - procedure AFCB_Free (File : access Direct_AFCB); + procedure AFCB_Close (File : not null access Direct_AFCB); + procedure AFCB_Free (File : not null access Direct_AFCB); procedure Read (File : in out Direct_AFCB; diff --git a/gcc/ada/s-fatgen.adb b/gcc/ada/s-fatgen.adb index f6a9327e663..f591a699250 100644 --- a/gcc/ada/s-fatgen.adb +++ b/gcc/ada/s-fatgen.adb @@ -759,7 +759,7 @@ package body System.Fat_Gen is -- in Exp_Attr by using the Valid functions in Vax_Float_Operations rather -- than the corresponding instantiation of this function. - function Valid (X : access T) return Boolean is + function Valid (X : not null access T) return Boolean is IEEE_Emin : constant Integer := T'Machine_Emin - 1; IEEE_Emax : constant Integer := T'Machine_Emax - 1; diff --git a/gcc/ada/s-fatgen.ads b/gcc/ada/s-fatgen.ads index 83b6f064461..748e5170a02 100644 --- a/gcc/ada/s-fatgen.ads +++ b/gcc/ada/s-fatgen.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1992-2005 Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2006 Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -89,7 +89,7 @@ package System.Fat_Gen is function Unbiased_Rounding (X : T) return T; - function Valid (X : access T) return Boolean; + function Valid (X : not null access T) return Boolean; -- This function checks if the object of type T referenced by X -- is valid, and returns True/False accordingly. The parameter is -- passed by reference (access) here, as the object of type T may diff --git a/gcc/ada/s-osprim-mingw.adb b/gcc/ada/s-osprim-mingw.adb index eb38ac8852f..41e3033418f 100644 --- a/gcc/ada/s-osprim-mingw.adb +++ b/gcc/ada/s-osprim-mingw.adb @@ -4,9 +4,9 @@ -- -- -- S Y S T E M . O S _ P R I M I T I V E S -- -- -- --- B o d y -- +-- B o d y -- -- -- --- Copyright (C) 1998-2005 Free Software Foundation, Inc. -- +-- Copyright (C) 1998-2006, Free Software Foundation, Inc. -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -51,16 +51,17 @@ package body System.OS_Primitives is type BOOL is new Boolean; for BOOL'Size use Interfaces.C.unsigned_long'Size; - procedure GetSystemTimeAsFileTime (lpFileTime : access Long_Long_Integer); + procedure GetSystemTimeAsFileTime + (lpFileTime : not null access Long_Long_Integer); pragma Import (Stdcall, GetSystemTimeAsFileTime, "GetSystemTimeAsFileTime"); function QueryPerformanceCounter - (lpPerformanceCount : access LARGE_INTEGER) return BOOL; + (lpPerformanceCount : not null access LARGE_INTEGER) return BOOL; pragma Import (Stdcall, QueryPerformanceCounter, "QueryPerformanceCounter"); function QueryPerformanceFrequency - (lpFrequency : access LARGE_INTEGER) return BOOL; + (lpFrequency : not null access LARGE_INTEGER) return BOOL; pragma Import (Stdcall, QueryPerformanceFrequency, "QueryPerformanceFrequency"); @@ -241,9 +242,29 @@ package body System.OS_Primitives is ----------------- procedure Timed_Delay (Time : Duration; Mode : Integer) is + + function Mode_Clock return Duration; + pragma Inline (Mode_Clock); + -- Return the current clock value using either the monotonic clock or + -- standard clock depending on the Mode value. + + ---------------- + -- Mode_Clock -- + ---------------- + + function Mode_Clock return Duration is + begin + case Mode is + when Absolute_RT => + return Monotonic_Clock; + when others => + return Clock; + end case; + end Mode_Clock; + Rel_Time : Duration; Abs_Time : Duration; - Check_Time : Duration := Monotonic_Clock; + Check_Time : Duration := Mode_Clock; begin if Mode = Relative then @@ -257,7 +278,7 @@ package body System.OS_Primitives is if Rel_Time > 0.0 then loop Sleep (DWORD (Rel_Time * 1000.0)); - Check_Time := Monotonic_Clock; + Check_Time := Mode_Clock; exit when Abs_Time <= Check_Time; diff --git a/gcc/ada/s-osprim-posix.adb b/gcc/ada/s-osprim-posix.adb index 6d4431c6c8c..59a72374d52 100644 --- a/gcc/ada/s-osprim-posix.adb +++ b/gcc/ada/s-osprim-posix.adb @@ -6,7 +6,7 @@ -- -- -- B o d y -- -- -- --- Copyright (C) 1998-2005 Free Software Foundation, Inc. -- +-- Copyright (C) 1998-2006 Free Software Foundation, Inc. -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -56,7 +56,7 @@ package body System.OS_Primitives is pragma Convention (C, struct_timeval); function gettimeofday - (tv : access struct_timeval; + (tv : not null access struct_timeval; tz : struct_timezone_ptr) return Integer; pragma Import (C, gettimeofday, "gettimeofday"); @@ -66,7 +66,7 @@ package body System.OS_Primitives is end record; pragma Convention (C, timespec); - function nanosleep (rqtp, rmtp : access timespec) return Integer; + function nanosleep (rqtp, rmtp : not null access timespec) return Integer; pragma Import (C, nanosleep, "nanosleep"); ----------- diff --git a/gcc/ada/s-osprim-solaris.adb b/gcc/ada/s-osprim-solaris.adb index 6e7436f7a01..b9709335782 100644 --- a/gcc/ada/s-osprim-solaris.adb +++ b/gcc/ada/s-osprim-solaris.adb @@ -6,7 +6,7 @@ -- -- -- B o d y -- -- -- --- Copyright (C) 1998-2005 Free Software Foundation, Inc. -- +-- Copyright (C) 1998-2006 Free Software Foundation, Inc. -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -48,7 +48,7 @@ package body System.OS_Primitives is pragma Convention (C, struct_timeval); procedure gettimeofday - (tv : access struct_timeval; + (tv : not null access struct_timeval; tz : Address := Null_Address); pragma Import (C, gettimeofday, "gettimeofday"); @@ -57,7 +57,7 @@ package body System.OS_Primitives is readfds, writefds, exceptfds : Address := Null_Address; - timeout : access struct_timeval); + timeout : not null access struct_timeval); pragma Import (C, C_select, "select"); ----------- diff --git a/gcc/ada/s-osprim-unix.adb b/gcc/ada/s-osprim-unix.adb index 75110346914..719551f9dfa 100644 --- a/gcc/ada/s-osprim-unix.adb +++ b/gcc/ada/s-osprim-unix.adb @@ -6,7 +6,7 @@ -- -- -- B o d y -- -- -- --- Copyright (C) 1998-2005 Free Software Foundation, Inc. -- +-- Copyright (C) 1998-2006 Free Software Foundation, Inc. -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -48,7 +48,7 @@ package body System.OS_Primitives is pragma Convention (C, struct_timeval); procedure gettimeofday - (tv : access struct_timeval; + (tv : not null access struct_timeval; tz : Address := Null_Address); pragma Import (C, gettimeofday, "gettimeofday"); @@ -57,7 +57,7 @@ package body System.OS_Primitives is readfds, writefds, exceptfds : Address := Null_Address; - timeout : access struct_timeval); + timeout : not null access struct_timeval); pragma Import (C, C_select, "select"); ----------- diff --git a/gcc/ada/s-parint.adb b/gcc/ada/s-parint.adb index 6091f3d1db6..f8bcdcc0bb8 100644 --- a/gcc/ada/s-parint.adb +++ b/gcc/ada/s-parint.adb @@ -7,7 +7,7 @@ -- B o d y -- -- (Dummy body for non-distributed case) -- -- -- --- Copyright (C) 1995-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1995-2006, Free Software Foundation, Inc. -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -311,8 +311,8 @@ package body System.Partition_Interface is -------------------- function Same_Partition - (Left : access RACW_Stub_Type; - Right : access RACW_Stub_Type) return Boolean + (Left : not null access RACW_Stub_Type; + Right : not null access RACW_Stub_Type) return Boolean is pragma Unreferenced (Left); pragma Unreferenced (Right); diff --git a/gcc/ada/s-sequio.adb b/gcc/ada/s-sequio.adb index 50e568211ba..72f2e2b3bf2 100644 --- a/gcc/ada/s-sequio.adb +++ b/gcc/ada/s-sequio.adb @@ -59,7 +59,7 @@ package body System.Sequential_IO is -- No special processing required for Sequential_IO close - procedure AFCB_Close (File : access Sequential_AFCB) is + procedure AFCB_Close (File : not null access Sequential_AFCB) is pragma Warnings (Off, File); begin @@ -70,7 +70,7 @@ package body System.Sequential_IO is -- AFCB_Free -- --------------- - procedure AFCB_Free (File : access Sequential_AFCB) is + procedure AFCB_Free (File : not null access Sequential_AFCB) is type FCB_Ptr is access all Sequential_AFCB; diff --git a/gcc/ada/s-sequio.ads b/gcc/ada/s-sequio.ads index 09c41aeb2c2..d263ec33f45 100644 --- a/gcc/ada/s-sequio.ads +++ b/gcc/ada/s-sequio.ads @@ -48,8 +48,8 @@ package System.Sequential_IO is function AFCB_Allocate (Control_Block : Sequential_AFCB) return FCB.AFCB_Ptr; - procedure AFCB_Close (File : access Sequential_AFCB); - procedure AFCB_Free (File : access Sequential_AFCB); + procedure AFCB_Close (File : not null access Sequential_AFCB); + procedure AFCB_Free (File : not null access Sequential_AFCB); procedure Read (File : in out Sequential_AFCB; diff --git a/gcc/ada/s-stchop.adb b/gcc/ada/s-stchop.adb index f1478f357c8..c0577afe7fe 100644 --- a/gcc/ada/s-stchop.adb +++ b/gcc/ada/s-stchop.adb @@ -6,7 +6,7 @@ -- -- -- B o d y -- -- -- --- Copyright (C) 1999-2006 Free Software Foundation, Inc. -- +-- Copyright (C) 1999-2006, Free Software Foundation, Inc. -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -32,7 +32,7 @@ ------------------------------------------------------------------------------ -- This is the general implementation of this package. There is a VxWorks --- specific version of this package (5zstchop.adb). This file should +-- specific version of this package (s-stchop-vxworks.adb). This file should -- be kept synchronized with it. pragma Restrictions (No_Elaboration_Code); @@ -50,7 +50,8 @@ package body System.Stack_Checking.Operations is Kilobyte : constant := 1024; - function Set_Stack_Info (Stack : access Stack_Access) return Stack_Access; + function Set_Stack_Info + (Stack : not null access Stack_Access) return Stack_Access; -- The function Set_Stack_Info is the actual function that updates -- the cache containing a pointer to the Stack_Info. It may also @@ -90,7 +91,7 @@ package body System.Stack_Checking.Operations is -------------------- function Set_Stack_Info - (Stack : access Stack_Access) return Stack_Access + (Stack : not null access Stack_Access) return Stack_Access is type Frame_Mark is null record; Frame_Location : Frame_Mark; diff --git a/gcc/ada/s-stchop.ads b/gcc/ada/s-stchop.ads index cd56ac272ec..1c2f2a7ef91 100644 --- a/gcc/ada/s-stchop.ads +++ b/gcc/ada/s-stchop.ads @@ -31,12 +31,12 @@ -- -- ------------------------------------------------------------------------------ --- This package provides a implementation of stack checking operations --- using comparison with stack base and limit. +-- This package provides a implementation of stack checking operations using +-- comparison with stack base and limit. pragma Restrictions (No_Elaboration_Code); --- We want to guarantee the absence of elaboration code because the --- binder does not handle references to this package. +-- We want to guarantee the absence of elaboration code because the binder +-- does not handle references to this package. pragma Polling (Off); -- Turn off polling, we do not want polling to take place during stack @@ -46,22 +46,20 @@ package System.Stack_Checking.Operations is pragma Preelaborate; procedure Update_Stack_Cache (Stack : Stack_Access); - -- Set the stack cache for the current task. Note that this is only - -- for optimization purposes, nothing can be assumed about the - -- contents of the cache at any time, see Set_Stack_Info. + -- Set the stack cache for the current task. Note that this is only for + -- optimization purposes, nothing can be assumed about the contents of the + -- cache at any time, see Set_Stack_Info. procedure Invalidate_Stack_Cache (Any_Stack : Stack_Access); - -- Invalidate cache entries for the task T that owns Any_Stack. - -- This causes the Set_Stack_Info function to be called during - -- the next stack check done by T. This can be used to interrupt - -- task T asynchronously. + -- Invalidate cache entries for the task T that owns Any_Stack. This causes + -- the Set_Stack_Info function to be called during the next stack check + -- done by T. This can be used to interrupt task T asynchronously. -- Stack_Check should be called in loops for this to work reliably. function Stack_Check (Stack_Address : System.Address) return Stack_Access; - -- This version of Stack_Check should not be inlined. + -- This version of Stack_Check should not be inlined private - Cache : aliased Stack_Access := Null_Stack; pragma Export (C, Cache, "_gnat_stack_cache"); diff --git a/gcc/ada/s-taprop-dummy.adb b/gcc/ada/s-taprop-dummy.adb index 873b1fd78ae..894ec292dae 100644 --- a/gcc/ada/s-taprop-dummy.adb +++ b/gcc/ada/s-taprop-dummy.adb @@ -6,7 +6,7 @@ -- -- -- B o d y -- -- -- --- Copyright (C) 1992-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2006, Free Software Foundation, Inc. -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -144,12 +144,12 @@ package body System.Task_Primitives.Operations is -- Finalize_Lock -- ------------------- - procedure Finalize_Lock (L : access Lock) is + procedure Finalize_Lock (L : not null access Lock) is begin null; end Finalize_Lock; - procedure Finalize_Lock (L : access RTS_Lock) is + procedure Finalize_Lock (L : not null access RTS_Lock) is begin null; end Finalize_Lock; @@ -204,13 +204,14 @@ package body System.Task_Primitives.Operations is procedure Initialize_Lock (Prio : System.Any_Priority; - L : access Lock) + L : not null access Lock) is begin null; end Initialize_Lock; - procedure Initialize_Lock (L : access RTS_Lock; Level : Lock_Level) is + procedure Initialize_Lock + (L : not null access RTS_Lock; Level : Lock_Level) is begin null; end Initialize_Lock; @@ -264,7 +265,8 @@ package body System.Task_Primitives.Operations is -- Read_Lock -- --------------- - procedure Read_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Read_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) is begin Ceiling_Violation := False; end Read_Lock; @@ -343,7 +345,7 @@ package body System.Task_Primitives.Operations is -- Sleep -- ----------- - procedure Sleep (Self_ID : Task_Id; Reason : System.Tasking.Task_States) is + procedure Sleep (Self_ID : Task_Id; Reason : System.Tasking.Task_States) is begin null; end Sleep; @@ -412,12 +414,13 @@ package body System.Task_Primitives.Operations is -- Unlock -- ------------ - procedure Unlock (L : access Lock) is + procedure Unlock (L : not null access Lock) is begin null; end Unlock; - procedure Unlock (L : access RTS_Lock; Global_Lock : Boolean := False) is + procedure Unlock + (L : not null access RTS_Lock; Global_Lock : Boolean := False) is begin null; end Unlock; @@ -448,13 +451,14 @@ package body System.Task_Primitives.Operations is -- Write_Lock -- ---------------- - procedure Write_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Write_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) is begin Ceiling_Violation := False; end Write_Lock; procedure Write_Lock - (L : access RTS_Lock; + (L : not null access RTS_Lock; Global_Lock : Boolean := False) is begin diff --git a/gcc/ada/s-taprop-hpux-dce.adb b/gcc/ada/s-taprop-hpux-dce.adb index f463d8f90d6..4b43f1cde5c 100644 --- a/gcc/ada/s-taprop-hpux-dce.adb +++ b/gcc/ada/s-taprop-hpux-dce.adb @@ -239,7 +239,7 @@ package body System.Task_Primitives.Operations is procedure Initialize_Lock (Prio : System.Any_Priority; - L : access Lock) + L : not null access Lock) is Attributes : aliased pthread_mutexattr_t; Result : Interfaces.C.int; @@ -265,7 +265,8 @@ package body System.Task_Primitives.Operations is pragma Assert (Result = 0); end Initialize_Lock; - procedure Initialize_Lock (L : access RTS_Lock; Level : Lock_Level) is + procedure Initialize_Lock + (L : not null access RTS_Lock; Level : Lock_Level) is pragma Unreferenced (Level); Attributes : aliased pthread_mutexattr_t; @@ -295,14 +296,14 @@ package body System.Task_Primitives.Operations is -- Finalize_Lock -- ------------------- - procedure Finalize_Lock (L : access Lock) is + procedure Finalize_Lock (L : not null access Lock) is Result : Interfaces.C.int; begin Result := pthread_mutex_destroy (L.L'Access); pragma Assert (Result = 0); end Finalize_Lock; - procedure Finalize_Lock (L : access RTS_Lock) is + procedure Finalize_Lock (L : not null access RTS_Lock) is Result : Interfaces.C.int; begin Result := pthread_mutex_destroy (L); @@ -313,7 +314,9 @@ package body System.Task_Primitives.Operations is -- Write_Lock -- ---------------- - procedure Write_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Write_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) + is Result : Interfaces.C.int; begin @@ -330,7 +333,7 @@ package body System.Task_Primitives.Operations is end Write_Lock; procedure Write_Lock - (L : access RTS_Lock; Global_Lock : Boolean := False) + (L : not null access RTS_Lock; Global_Lock : Boolean := False) is Result : Interfaces.C.int; begin @@ -353,7 +356,8 @@ package body System.Task_Primitives.Operations is -- Read_Lock -- --------------- - procedure Read_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Read_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) is begin Write_Lock (L, Ceiling_Violation); end Read_Lock; @@ -362,14 +366,16 @@ package body System.Task_Primitives.Operations is -- Unlock -- ------------ - procedure Unlock (L : access Lock) is + procedure Unlock (L : not null access Lock) is Result : Interfaces.C.int; begin Result := pthread_mutex_unlock (L.L'Access); pragma Assert (Result = 0); end Unlock; - procedure Unlock (L : access RTS_Lock; Global_Lock : Boolean := False) is + procedure Unlock + (L : not null access RTS_Lock; Global_Lock : Boolean := False) + is Result : Interfaces.C.int; begin if not Single_Lock or else Global_Lock then diff --git a/gcc/ada/s-taprop-irix.adb b/gcc/ada/s-taprop-irix.adb index a1bc9f09478..4b7b170ebc1 100644 --- a/gcc/ada/s-taprop-irix.adb +++ b/gcc/ada/s-taprop-irix.adb @@ -238,7 +238,7 @@ package body System.Task_Primitives.Operations is procedure Initialize_Lock (Prio : System.Any_Priority; - L : access Lock) + L : not null access Lock) is Attributes : aliased pthread_mutexattr_t; Result : Interfaces.C.int; @@ -273,7 +273,9 @@ package body System.Task_Primitives.Operations is pragma Assert (Result = 0); end Initialize_Lock; - procedure Initialize_Lock (L : access RTS_Lock; Level : Lock_Level) is + procedure Initialize_Lock + (L : not null access RTS_Lock; Level : Lock_Level) + is pragma Unreferenced (Level); Attributes : aliased pthread_mutexattr_t; @@ -314,14 +316,14 @@ package body System.Task_Primitives.Operations is -- Finalize_Lock -- ------------------- - procedure Finalize_Lock (L : access Lock) is + procedure Finalize_Lock (L : not null access Lock) is Result : Interfaces.C.int; begin Result := pthread_mutex_destroy (L); pragma Assert (Result = 0); end Finalize_Lock; - procedure Finalize_Lock (L : access RTS_Lock) is + procedure Finalize_Lock (L : not null access RTS_Lock) is Result : Interfaces.C.int; begin Result := pthread_mutex_destroy (L); @@ -332,7 +334,9 @@ package body System.Task_Primitives.Operations is -- Write_Lock -- ---------------- - procedure Write_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Write_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) + is Result : Interfaces.C.int; begin Result := pthread_mutex_lock (L); @@ -344,7 +348,7 @@ package body System.Task_Primitives.Operations is end Write_Lock; procedure Write_Lock - (L : access RTS_Lock; + (L : not null access RTS_Lock; Global_Lock : Boolean := False) is Result : Interfaces.C.int; @@ -368,7 +372,8 @@ package body System.Task_Primitives.Operations is -- Read_Lock -- --------------- - procedure Read_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Read_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) is begin Write_Lock (L, Ceiling_Violation); end Read_Lock; @@ -377,14 +382,16 @@ package body System.Task_Primitives.Operations is -- Unlock -- ------------ - procedure Unlock (L : access Lock) is + procedure Unlock (L : not null access Lock) is Result : Interfaces.C.int; begin Result := pthread_mutex_unlock (L); pragma Assert (Result = 0); end Unlock; - procedure Unlock (L : access RTS_Lock; Global_Lock : Boolean := False) is + procedure Unlock + (L : not null access RTS_Lock; Global_Lock : Boolean := False) + is Result : Interfaces.C.int; begin diff --git a/gcc/ada/s-taprop-linux.adb b/gcc/ada/s-taprop-linux.adb index a41eb3f5570..c945f5c9d7e 100644 --- a/gcc/ada/s-taprop-linux.adb +++ b/gcc/ada/s-taprop-linux.adb @@ -267,7 +267,7 @@ package body System.Task_Primitives.Operations is procedure Initialize_Lock (Prio : System.Any_Priority; - L : access Lock) + L : not null access Lock) is pragma Unreferenced (Prio); @@ -283,7 +283,9 @@ package body System.Task_Primitives.Operations is end if; end Initialize_Lock; - procedure Initialize_Lock (L : access RTS_Lock; Level : Lock_Level) is + procedure Initialize_Lock + (L : not null access RTS_Lock; Level : Lock_Level) + is pragma Unreferenced (Level); Result : Interfaces.C.int; @@ -302,14 +304,14 @@ package body System.Task_Primitives.Operations is -- Finalize_Lock -- ------------------- - procedure Finalize_Lock (L : access Lock) is + procedure Finalize_Lock (L : not null access Lock) is Result : Interfaces.C.int; begin Result := pthread_mutex_destroy (L); pragma Assert (Result = 0); end Finalize_Lock; - procedure Finalize_Lock (L : access RTS_Lock) is + procedure Finalize_Lock (L : not null access RTS_Lock) is Result : Interfaces.C.int; begin Result := pthread_mutex_destroy (L); @@ -320,7 +322,9 @@ package body System.Task_Primitives.Operations is -- Write_Lock -- ---------------- - procedure Write_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Write_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) + is Result : Interfaces.C.int; begin Result := pthread_mutex_lock (L); @@ -332,7 +336,7 @@ package body System.Task_Primitives.Operations is end Write_Lock; procedure Write_Lock - (L : access RTS_Lock; + (L : not null access RTS_Lock; Global_Lock : Boolean := False) is Result : Interfaces.C.int; @@ -356,7 +360,8 @@ package body System.Task_Primitives.Operations is -- Read_Lock -- --------------- - procedure Read_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Read_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) is begin Write_Lock (L, Ceiling_Violation); end Read_Lock; @@ -365,14 +370,16 @@ package body System.Task_Primitives.Operations is -- Unlock -- ------------ - procedure Unlock (L : access Lock) is + procedure Unlock (L : not null access Lock) is Result : Interfaces.C.int; begin Result := pthread_mutex_unlock (L); pragma Assert (Result = 0); end Unlock; - procedure Unlock (L : access RTS_Lock; Global_Lock : Boolean := False) is + procedure Unlock + (L : not null access RTS_Lock; Global_Lock : Boolean := False) + is Result : Interfaces.C.int; begin if not Single_Lock or else Global_Lock then diff --git a/gcc/ada/s-taprop-lynxos.adb b/gcc/ada/s-taprop-lynxos.adb index 881a0cea4ef..272d8981aa6 100644 --- a/gcc/ada/s-taprop-lynxos.adb +++ b/gcc/ada/s-taprop-lynxos.adb @@ -256,7 +256,7 @@ package body System.Task_Primitives.Operations is procedure Initialize_Lock (Prio : System.Any_Priority; - L : access Lock) + L : not null access Lock) is Attributes : aliased pthread_mutexattr_t; Result : Interfaces.C.int; @@ -284,7 +284,9 @@ package body System.Task_Primitives.Operations is pragma Assert (Result = 0); end Initialize_Lock; - procedure Initialize_Lock (L : access RTS_Lock; Level : Lock_Level) is + procedure Initialize_Lock + (L : not null access RTS_Lock; Level : Lock_Level) + is pragma Unreferenced (Level); Attributes : aliased pthread_mutexattr_t; @@ -314,14 +316,14 @@ package body System.Task_Primitives.Operations is -- Finalize_Lock -- ------------------- - procedure Finalize_Lock (L : access Lock) is + procedure Finalize_Lock (L : not null access Lock) is Result : Interfaces.C.int; begin Result := pthread_mutex_destroy (L.Mutex'Access); pragma Assert (Result = 0); end Finalize_Lock; - procedure Finalize_Lock (L : access RTS_Lock) is + procedure Finalize_Lock (L : not null access RTS_Lock) is Result : Interfaces.C.int; begin Result := pthread_mutex_destroy (L); @@ -332,7 +334,9 @@ package body System.Task_Primitives.Operations is -- Write_Lock -- ---------------- - procedure Write_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Write_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) + is Result : Interfaces.C.int; T : constant Task_Id := Self; @@ -361,7 +365,7 @@ package body System.Task_Primitives.Operations is -- No tricks on RTS_Locks procedure Write_Lock - (L : access RTS_Lock; Global_Lock : Boolean := False) + (L : not null access RTS_Lock; Global_Lock : Boolean := False) is Result : Interfaces.C.int; begin @@ -384,7 +388,8 @@ package body System.Task_Primitives.Operations is -- Read_Lock -- --------------- - procedure Read_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Read_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) is begin Write_Lock (L, Ceiling_Violation); end Read_Lock; @@ -393,7 +398,7 @@ package body System.Task_Primitives.Operations is -- Unlock -- ------------ - procedure Unlock (L : access Lock) is + procedure Unlock (L : not null access Lock) is Result : Interfaces.C.int; T : constant Task_Id := Self; @@ -408,7 +413,9 @@ package body System.Task_Primitives.Operations is end if; end Unlock; - procedure Unlock (L : access RTS_Lock; Global_Lock : Boolean := False) is + procedure Unlock + (L : not null access RTS_Lock; Global_Lock : Boolean := False) + is Result : Interfaces.C.int; begin if not Single_Lock or else Global_Lock then @@ -432,7 +439,7 @@ package body System.Task_Primitives.Operations is procedure Sleep (Self_ID : Task_Id; - Reason : System.Tasking.Task_States) + Reason : System.Tasking.Task_States) is pragma Unreferenced (Reason); Result : Interfaces.C.int; diff --git a/gcc/ada/s-taprop-mingw.adb b/gcc/ada/s-taprop-mingw.adb index 6a6cd17a75e..5656932face 100644 --- a/gcc/ada/s-taprop-mingw.adb +++ b/gcc/ada/s-taprop-mingw.adb @@ -168,23 +168,23 @@ package body System.Task_Primitives.Operations is -- Condition Variable Functions -- ---------------------------------- - procedure Initialize_Cond (Cond : access Condition_Variable); + procedure Initialize_Cond (Cond : not null access Condition_Variable); -- Initialize given condition variable Cond - procedure Finalize_Cond (Cond : access Condition_Variable); + procedure Finalize_Cond (Cond : not null access Condition_Variable); -- Finalize given condition variable Cond - procedure Cond_Signal (Cond : access Condition_Variable); + procedure Cond_Signal (Cond : not null access Condition_Variable); -- Signal condition variable Cond procedure Cond_Wait - (Cond : access Condition_Variable; - L : access RTS_Lock); + (Cond : not null access Condition_Variable; + L : not null access RTS_Lock); -- Wait on conditional variable Cond, using lock L procedure Cond_Timed_Wait - (Cond : access Condition_Variable; - L : access RTS_Lock; + (Cond : not null access Condition_Variable; + L : not null access RTS_Lock; Rel_Time : Duration; Timed_Out : out Boolean; Status : out Integer); @@ -198,7 +198,7 @@ package body System.Task_Primitives.Operations is -- Initialize_Cond -- --------------------- - procedure Initialize_Cond (Cond : access Condition_Variable) is + procedure Initialize_Cond (Cond : not null access Condition_Variable) is hEvent : HANDLE; begin @@ -214,7 +214,7 @@ package body System.Task_Primitives.Operations is -- No such problem here, DosCloseEventSem has been derived. -- What does such refer to in above comment??? - procedure Finalize_Cond (Cond : access Condition_Variable) is + procedure Finalize_Cond (Cond : not null access Condition_Variable) is Result : BOOL; begin Result := CloseHandle (HANDLE (Cond.all)); @@ -225,7 +225,7 @@ package body System.Task_Primitives.Operations is -- Cond_Signal -- ----------------- - procedure Cond_Signal (Cond : access Condition_Variable) is + procedure Cond_Signal (Cond : not null access Condition_Variable) is Result : BOOL; begin Result := SetEvent (HANDLE (Cond.all)); @@ -243,8 +243,8 @@ package body System.Task_Primitives.Operations is -- L is locked. procedure Cond_Wait - (Cond : access Condition_Variable; - L : access RTS_Lock) + (Cond : not null access Condition_Variable; + L : not null access RTS_Lock) is Result : DWORD; Result_Bool : BOOL; @@ -276,8 +276,8 @@ package body System.Task_Primitives.Operations is -- L is locked. procedure Cond_Timed_Wait - (Cond : access Condition_Variable; - L : access RTS_Lock; + (Cond : not null access Condition_Variable; + L : not null access RTS_Lock; Rel_Time : Duration; Timed_Out : out Boolean; Status : out Integer) @@ -385,7 +385,7 @@ package body System.Task_Primitives.Operations is procedure Initialize_Lock (Prio : System.Any_Priority; - L : access Lock) + L : not null access Lock) is begin InitializeCriticalSection (L.Mutex'Access); @@ -393,7 +393,9 @@ package body System.Task_Primitives.Operations is L.Priority := Prio; end Initialize_Lock; - procedure Initialize_Lock (L : access RTS_Lock; Level : Lock_Level) is + procedure Initialize_Lock + (L : not null access RTS_Lock; Level : Lock_Level) + is pragma Unreferenced (Level); begin InitializeCriticalSection (CRITICAL_SECTION (L.all)'Unrestricted_Access); @@ -403,12 +405,12 @@ package body System.Task_Primitives.Operations is -- Finalize_Lock -- ------------------- - procedure Finalize_Lock (L : access Lock) is + procedure Finalize_Lock (L : not null access Lock) is begin DeleteCriticalSection (L.Mutex'Access); end Finalize_Lock; - procedure Finalize_Lock (L : access RTS_Lock) is + procedure Finalize_Lock (L : not null access RTS_Lock) is begin DeleteCriticalSection (CRITICAL_SECTION (L.all)'Unrestricted_Access); end Finalize_Lock; @@ -417,7 +419,8 @@ package body System.Task_Primitives.Operations is -- Write_Lock -- ---------------- - procedure Write_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Write_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) is begin L.Owner_Priority := Get_Priority (Self); @@ -432,7 +435,7 @@ package body System.Task_Primitives.Operations is end Write_Lock; procedure Write_Lock - (L : access RTS_Lock; + (L : not null access RTS_Lock; Global_Lock : Boolean := False) is begin @@ -453,7 +456,8 @@ package body System.Task_Primitives.Operations is -- Read_Lock -- --------------- - procedure Read_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Read_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) is begin Write_Lock (L, Ceiling_Violation); end Read_Lock; @@ -462,12 +466,13 @@ package body System.Task_Primitives.Operations is -- Unlock -- ------------ - procedure Unlock (L : access Lock) is + procedure Unlock (L : not null access Lock) is begin LeaveCriticalSection (L.Mutex'Access); end Unlock; - procedure Unlock (L : access RTS_Lock; Global_Lock : Boolean := False) is + procedure Unlock + (L : not null access RTS_Lock; Global_Lock : Boolean := False) is begin if not Single_Lock or else Global_Lock then LeaveCriticalSection (CRITICAL_SECTION (L.all)'Unrestricted_Access); diff --git a/gcc/ada/s-taprop-posix.adb b/gcc/ada/s-taprop-posix.adb index f8d1f0db90d..315db0e8e56 100644 --- a/gcc/ada/s-taprop-posix.adb +++ b/gcc/ada/s-taprop-posix.adb @@ -287,7 +287,7 @@ package body System.Task_Primitives.Operations is procedure Initialize_Lock (Prio : System.Any_Priority; - L : access Lock) + L : not null access Lock) is Attributes : aliased pthread_mutexattr_t; Result : Interfaces.C.int; @@ -327,7 +327,9 @@ package body System.Task_Primitives.Operations is pragma Assert (Result = 0); end Initialize_Lock; - procedure Initialize_Lock (L : access RTS_Lock; Level : Lock_Level) is + procedure Initialize_Lock + (L : not null access RTS_Lock; Level : Lock_Level) + is pragma Warnings (Off, Level); Attributes : aliased pthread_mutexattr_t; @@ -372,7 +374,7 @@ package body System.Task_Primitives.Operations is -- Finalize_Lock -- ------------------- - procedure Finalize_Lock (L : access Lock) is + procedure Finalize_Lock (L : not null access Lock) is Result : Interfaces.C.int; begin @@ -380,7 +382,7 @@ package body System.Task_Primitives.Operations is pragma Assert (Result = 0); end Finalize_Lock; - procedure Finalize_Lock (L : access RTS_Lock) is + procedure Finalize_Lock (L : not null access RTS_Lock) is Result : Interfaces.C.int; begin @@ -392,7 +394,9 @@ package body System.Task_Primitives.Operations is -- Write_Lock -- ---------------- - procedure Write_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Write_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) + is Result : Interfaces.C.int; begin @@ -405,7 +409,7 @@ package body System.Task_Primitives.Operations is end Write_Lock; procedure Write_Lock - (L : access RTS_Lock; + (L : not null access RTS_Lock; Global_Lock : Boolean := False) is Result : Interfaces.C.int; @@ -431,7 +435,8 @@ package body System.Task_Primitives.Operations is -- Read_Lock -- --------------- - procedure Read_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Read_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) is begin Write_Lock (L, Ceiling_Violation); end Read_Lock; @@ -440,7 +445,7 @@ package body System.Task_Primitives.Operations is -- Unlock -- ------------ - procedure Unlock (L : access Lock) is + procedure Unlock (L : not null access Lock) is Result : Interfaces.C.int; begin @@ -448,7 +453,9 @@ package body System.Task_Primitives.Operations is pragma Assert (Result = 0); end Unlock; - procedure Unlock (L : access RTS_Lock; Global_Lock : Boolean := False) is + procedure Unlock + (L : not null access RTS_Lock; Global_Lock : Boolean := False) + is Result : Interfaces.C.int; begin @@ -474,7 +481,7 @@ package body System.Task_Primitives.Operations is procedure Sleep (Self_ID : Task_Id; - Reason : System.Tasking.Task_States) + Reason : System.Tasking.Task_States) is pragma Warnings (Off, Reason); @@ -949,12 +956,19 @@ package body System.Task_Primitives.Operations is pragma Assert (Result = 0); if T.Common.Task_Info /= Default_Scope then + case T.Common.Task_Info is + when System.Task_Info.Process_Scope => + Result := pthread_attr_setscope + (Attributes'Access, PTHREAD_SCOPE_PROCESS); + + when System.Task_Info.System_Scope => + Result := pthread_attr_setscope + (Attributes'Access, PTHREAD_SCOPE_SYSTEM); - -- We are assuming that Scope_Type has the same values than the - -- corresponding C macros + when System.Task_Info.Default_Scope => + Result := 0; + end case; - Result := pthread_attr_setscope - (Attributes'Access, Task_Info_Type'Pos (T.Common.Task_Info)); pragma Assert (Result = 0); end if; diff --git a/gcc/ada/s-taprop-solaris.adb b/gcc/ada/s-taprop-solaris.adb index 9da267ec477..c17bf6d958f 100644 --- a/gcc/ada/s-taprop-solaris.adb +++ b/gcc/ada/s-taprop-solaris.adb @@ -168,8 +168,8 @@ package body System.Task_Primitives.Operations is procedure Abort_Handler (Sig : Signal; - Code : access siginfo_t; - Context : access ucontext_t); + Code : not null access siginfo_t; + Context : not null access ucontext_t); -- Target-dependent binding of inter-thread Abort signal to -- the raising of the Abort_Signal exception. -- See also comments in 7staprop.adb @@ -259,8 +259,8 @@ package body System.Task_Primitives.Operations is procedure Abort_Handler (Sig : Signal; - Code : access siginfo_t; - Context : access ucontext_t) + Code : not null access siginfo_t; + Context : not null access ucontext_t) is pragma Unreferenced (Sig); pragma Unreferenced (Code); @@ -535,7 +535,7 @@ package body System.Task_Primitives.Operations is procedure Initialize_Lock (Prio : System.Any_Priority; - L : access Lock) + L : not null access Lock) is Result : Interfaces.C.int; @@ -555,7 +555,7 @@ package body System.Task_Primitives.Operations is end Initialize_Lock; procedure Initialize_Lock - (L : access RTS_Lock; + (L : not null access RTS_Lock; Level : Lock_Level) is Result : Interfaces.C.int; @@ -575,7 +575,7 @@ package body System.Task_Primitives.Operations is -- Finalize_Lock -- ------------------- - procedure Finalize_Lock (L : access Lock) is + procedure Finalize_Lock (L : not null access Lock) is Result : Interfaces.C.int; begin @@ -584,7 +584,7 @@ package body System.Task_Primitives.Operations is pragma Assert (Result = 0); end Finalize_Lock; - procedure Finalize_Lock (L : access RTS_Lock) is + procedure Finalize_Lock (L : not null access RTS_Lock) is Result : Interfaces.C.int; begin @@ -597,7 +597,9 @@ package body System.Task_Primitives.Operations is -- Write_Lock -- ---------------- - procedure Write_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Write_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) + is Result : Interfaces.C.int; begin @@ -637,7 +639,7 @@ package body System.Task_Primitives.Operations is end Write_Lock; procedure Write_Lock - (L : access RTS_Lock; + (L : not null access RTS_Lock; Global_Lock : Boolean := False) is Result : Interfaces.C.int; @@ -667,7 +669,8 @@ package body System.Task_Primitives.Operations is -- Read_Lock -- --------------- - procedure Read_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Read_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) is begin Write_Lock (L, Ceiling_Violation); end Read_Lock; @@ -676,7 +679,7 @@ package body System.Task_Primitives.Operations is -- Unlock -- ------------ - procedure Unlock (L : access Lock) is + procedure Unlock (L : not null access Lock) is Result : Interfaces.C.int; begin @@ -700,7 +703,9 @@ package body System.Task_Primitives.Operations is end if; end Unlock; - procedure Unlock (L : access RTS_Lock; Global_Lock : Boolean := False) is + procedure Unlock + (L : not null access RTS_Lock; Global_Lock : Boolean := False) + is Result : Interfaces.C.int; begin if not Single_Lock or else Global_Lock then diff --git a/gcc/ada/s-taprop-tru64.adb b/gcc/ada/s-taprop-tru64.adb index 28e1a4a30c1..cf959e35e12 100644 --- a/gcc/ada/s-taprop-tru64.adb +++ b/gcc/ada/s-taprop-tru64.adb @@ -242,7 +242,7 @@ package body System.Task_Primitives.Operations is procedure Initialize_Lock (Prio : System.Any_Priority; - L : access Lock) + L : not null access Lock) is Attributes : aliased pthread_mutexattr_t; Result : Interfaces.C.int; @@ -271,7 +271,9 @@ package body System.Task_Primitives.Operations is pragma Assert (Result = 0); end Initialize_Lock; - procedure Initialize_Lock (L : access RTS_Lock; Level : Lock_Level) is + procedure Initialize_Lock + (L : not null access RTS_Lock; Level : Lock_Level) + is pragma Unreferenced (Level); Attributes : aliased pthread_mutexattr_t; @@ -301,14 +303,14 @@ package body System.Task_Primitives.Operations is -- Finalize_Lock -- ------------------- - procedure Finalize_Lock (L : access Lock) is + procedure Finalize_Lock (L : not null access Lock) is Result : Interfaces.C.int; begin Result := pthread_mutex_destroy (L.L'Access); pragma Assert (Result = 0); end Finalize_Lock; - procedure Finalize_Lock (L : access RTS_Lock) is + procedure Finalize_Lock (L : not null access RTS_Lock) is Result : Interfaces.C.int; begin Result := pthread_mutex_destroy (L); @@ -319,7 +321,9 @@ package body System.Task_Primitives.Operations is -- Write_Lock -- ---------------- - procedure Write_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Write_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) + is Result : Interfaces.C.int; Self_ID : Task_Id; All_Tasks_Link : Task_Id; @@ -350,7 +354,7 @@ package body System.Task_Primitives.Operations is end Write_Lock; procedure Write_Lock - (L : access RTS_Lock; Global_Lock : Boolean := False) + (L : not null access RTS_Lock; Global_Lock : Boolean := False) is Result : Interfaces.C.int; begin @@ -373,7 +377,8 @@ package body System.Task_Primitives.Operations is -- Read_Lock -- --------------- - procedure Read_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Read_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) is begin Write_Lock (L, Ceiling_Violation); end Read_Lock; @@ -382,14 +387,16 @@ package body System.Task_Primitives.Operations is -- Unlock -- ------------ - procedure Unlock (L : access Lock) is + procedure Unlock (L : not null access Lock) is Result : Interfaces.C.int; begin Result := pthread_mutex_unlock (L.L'Access); pragma Assert (Result = 0); end Unlock; - procedure Unlock (L : access RTS_Lock; Global_Lock : Boolean := False) is + procedure Unlock + (L : not null access RTS_Lock; Global_Lock : Boolean := False) + is Result : Interfaces.C.int; begin if not Single_Lock or else Global_Lock then diff --git a/gcc/ada/s-taprop-vms.adb b/gcc/ada/s-taprop-vms.adb index 7509236e1e1..f96534b45eb 100644 --- a/gcc/ada/s-taprop-vms.adb +++ b/gcc/ada/s-taprop-vms.adb @@ -197,7 +197,9 @@ package body System.Task_Primitives.Operations is -- Therefore rasing Storage_Error in the following routines -- should be able to be handled safely. - procedure Initialize_Lock (Prio : System.Any_Priority; L : access Lock) is + procedure Initialize_Lock + (Prio : System.Any_Priority; L : not null access Lock) + is Attributes : aliased pthread_mutexattr_t; Result : Interfaces.C.int; @@ -223,7 +225,9 @@ package body System.Task_Primitives.Operations is pragma Assert (Result = 0); end Initialize_Lock; - procedure Initialize_Lock (L : access RTS_Lock; Level : Lock_Level) is + procedure Initialize_Lock + (L : not null access RTS_Lock; Level : Lock_Level) + is pragma Unreferenced (Level); Attributes : aliased pthread_mutexattr_t; @@ -266,14 +270,14 @@ package body System.Task_Primitives.Operations is -- Finalize_Lock -- ------------------- - procedure Finalize_Lock (L : access Lock) is + procedure Finalize_Lock (L : not null access Lock) is Result : Interfaces.C.int; begin Result := pthread_mutex_destroy (L.L'Access); pragma Assert (Result = 0); end Finalize_Lock; - procedure Finalize_Lock (L : access RTS_Lock) is + procedure Finalize_Lock (L : not null access RTS_Lock) is Result : Interfaces.C.int; begin Result := pthread_mutex_destroy (L); @@ -284,7 +288,9 @@ package body System.Task_Primitives.Operations is -- Write_Lock -- ---------------- - procedure Write_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Write_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) + is Self_ID : constant Task_Id := Self; All_Tasks_Link : constant Task_Id := Self.Common.All_Tasks_Link; Current_Prio : System.Any_Priority; @@ -312,7 +318,7 @@ package body System.Task_Primitives.Operations is end Write_Lock; procedure Write_Lock - (L : access RTS_Lock; + (L : not null access RTS_Lock; Global_Lock : Boolean := False) is Result : Interfaces.C.int; @@ -336,7 +342,8 @@ package body System.Task_Primitives.Operations is -- Read_Lock -- --------------- - procedure Read_Lock (L : access Lock; Ceiling_Violation : out Boolean) is + procedure Read_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean) is begin Write_Lock (L, Ceiling_Violation); end Read_Lock; @@ -345,14 +352,16 @@ package body System.Task_Primitives.Operations is -- Unlock -- ------------ - procedure Unlock (L : access Lock) is + procedure Unlock (L : not null access Lock) is Result : Interfaces.C.int; begin Result := pthread_mutex_unlock (L.L'Access); pragma Assert (Result = 0); end Unlock; - procedure Unlock (L : access RTS_Lock; Global_Lock : Boolean := False) is + procedure Unlock + (L : not null access RTS_Lock; Global_Lock : Boolean := False) + is Result : Interfaces.C.int; begin if not Single_Lock or else Global_Lock then diff --git a/gcc/ada/s-taprop.ads b/gcc/ada/s-taprop.ads index bf98c5cbba2..aca25c3cd2f 100644 --- a/gcc/ada/s-taprop.ads +++ b/gcc/ada/s-taprop.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1992-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2006, Free Software Foundation, Inc. -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -137,8 +137,10 @@ package System.Task_Primitives.Operations is -- call specified below. See locking rules in System.Tasking (spec) for -- more details. - procedure Initialize_Lock (Prio : System.Any_Priority; L : access Lock); - procedure Initialize_Lock (L : access RTS_Lock; Level : Lock_Level); + procedure Initialize_Lock + (Prio : System.Any_Priority; L : not null access Lock); + procedure Initialize_Lock + (L : not null access RTS_Lock; Level : Lock_Level); pragma Inline (Initialize_Lock); -- Initialize a lock object. -- @@ -160,15 +162,18 @@ package System.Task_Primitives.Operations is -- -- These operations raise Storage_Error if a lack of storage is detected. - procedure Finalize_Lock (L : access Lock); - procedure Finalize_Lock (L : access RTS_Lock); + procedure Finalize_Lock (L : not null access Lock); + procedure Finalize_Lock (L : not null access RTS_Lock); pragma Inline (Finalize_Lock); -- Finalize a lock object, freeing any resources allocated by the -- corresponding Initialize_Lock operation. - procedure Write_Lock (L : access Lock; Ceiling_Violation : out Boolean); - procedure Write_Lock (L : access RTS_Lock; Global_Lock : Boolean := False); - procedure Write_Lock (T : ST.Task_Id); + procedure Write_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean); + procedure Write_Lock + (L : not null access RTS_Lock; Global_Lock : Boolean := False); + procedure Write_Lock + (T : ST.Task_Id); pragma Inline (Write_Lock); -- Lock a lock object for write access. After this operation returns, -- the calling task holds write permission for the lock object. No other @@ -192,7 +197,8 @@ package System.Task_Primitives.Operations is -- holds T's lock, or has interrupt-level priority. Finalization of the -- per-task lock is implicit in Exit_Task. - procedure Read_Lock (L : access Lock; Ceiling_Violation : out Boolean); + procedure Read_Lock + (L : not null access Lock; Ceiling_Violation : out Boolean); pragma Inline (Read_Lock); -- Lock a lock object for read access. After this operation returns, -- the calling task has non-exclusive read permission for the logical @@ -214,9 +220,12 @@ package System.Task_Primitives.Operations is -- potential write access, and (3) implementations of priority ceiling -- locking that make a reader-writer distinction have higher overhead. - procedure Unlock (L : access Lock); - procedure Unlock (L : access RTS_Lock; Global_Lock : Boolean := False); - procedure Unlock (T : ST.Task_Id); + procedure Unlock + (L : not null access Lock); + procedure Unlock + (L : not null access RTS_Lock; Global_Lock : Boolean := False); + procedure Unlock + (T : ST.Task_Id); pragma Inline (Unlock); -- Unlock a locked lock object. -- diff --git a/gcc/ada/s-tarest.ads b/gcc/ada/s-tarest.ads index 3a6b7c5fef6..1525bd9ea1e 100644 --- a/gcc/ada/s-tarest.ads +++ b/gcc/ada/s-tarest.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1992-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2006, Free Software Foundation, Inc. -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -144,10 +144,10 @@ package System.Tasking.Restricted.Stages is -- Priority is the task's priority (assumed to be in the -- System.Any_Priority'Range) -- - -- Stack_Address is the start address of the stack associated to the - -- task, in case it has been preallocated by the compiler; it is equal - -- to Null_Address when the stack needs to be allocated by the - -- underlying operating system. + -- Stack_Address is the start address of the stack associated to the task, + -- in case it has been preallocated by the compiler; it is equal to + -- Null_Address when the stack needs to be allocated by the underlying + -- operating system. -- -- Size is the stack size of the task to create -- @@ -156,21 +156,19 @@ package System.Tasking.Restricted.Stages is -- -- State is the compiler generated task's procedure body -- - -- Discriminants is a pointer to a limited record whose discriminants - -- are those of the task to create. This parameter should be passed as - -- the single argument to State. + -- Discriminants is a pointer to a limited record whose discriminants are + -- those of the task to create. This parameter should be passed as the + -- single argument to State. -- -- Elaborated is a pointer to a Boolean that must be set to true on exit -- if the task could be sucessfully elaborated. -- -- Chain is a linked list of task that needs to be created. On exit, - -- Created_Task.Activation_Link will be Chain.T_ID, and Chain.T_ID - -- will be Created_Task (e.g the created task will be linked at the front - -- of Chain). + -- Created_Task.Activation_Link will be Chain.T_ID, and Chain.T_ID will be + -- Created_Task (the created task will be linked at the front of Chain). -- - -- Task_Image is a string created by the compiler that the - -- run time can store to ease the debugging and the - -- Ada.Task_Identification facility. + -- Task_Image is a string created by the compiler that the run time can + -- store to ease the debugging and the Ada.Task_Identification facility. -- -- Created_Task is the resulting task. -- @@ -188,29 +186,28 @@ package System.Tasking.Restricted.Stages is -- version of this procedure had code to reverse the chain, so as to -- activate the tasks in the order of declaration. This might be nice, but -- it is not needed if priority-based scheduling is supported, since all - -- the activated tasks synchronize on the activators lock before they - -- start activating and so they should start activating in priority order. + -- the activated tasks synchronize on the activators lock before they start + -- activating and so they should start activating in priority order. procedure Complete_Restricted_Activation; - -- Compiler interface only. Do not call from within the RTS. - -- This should be called from the task body at the end of - -- the elaboration code for its declarative part. - -- Decrement the count of tasks to be activated by the activator and - -- wake it up so it can check to see if all tasks have been activated. - -- Except for the environment task, which should never call this procedure, - -- T.Activator should only be null iff T has completed activation. + -- Compiler interface only. Do not call from within the RTS. This should be + -- called from the task body at the end of the elaboration code for its + -- declarative part. Decrement the count of tasks to be activated by the + -- activator and wake it up so it can check to see if all tasks have been + -- activated. Except for the environment task, which should never call this + -- procedure, T.Activator should only be null iff T has completed + -- activation. procedure Complete_Restricted_Task; - -- Compiler interface only. Do not call from within the RTS. - -- This should be called from an implicit at-end handler - -- associated with the task body, when it completes. - -- From this point, the current task will become not callable. - -- If the current task have not completed activation, this should be done - -- now in order to wake up the activator (the environment task). + -- Compiler interface only. Do not call from within the RTS. This should be + -- called from an implicit at-end handler associated with the task body, + -- when it completes. From this point, the current task will become not + -- callable. If the current task have not completed activation, this should + -- be done now in order to wake up the activator (the environment task). function Restricted_Terminated (T : Task_Id) return Boolean; - -- Compiler interface only. Do not call from within the RTS. - -- This is called by the compiler to implement the 'Terminated attribute. + -- Compiler interface only. Do not call from within the RTS. This is called + -- by the compiler to implement the 'Terminated attribute. -- -- source code: -- T1'Terminated diff --git a/gcc/ada/s-traceb-hpux.adb b/gcc/ada/s-traceb-hpux.adb index 5457cb1d0ee..c2718af3f60 100644 --- a/gcc/ada/s-traceb-hpux.adb +++ b/gcc/ada/s-traceb-hpux.adb @@ -7,7 +7,7 @@ -- -- -- B o d y -- -- -- --- Copyright (C) 1999-2005, AdaCore -- +-- Copyright (C) 1999-2006, AdaCore -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -228,17 +228,18 @@ package body System.Traceback is -- of shared library code, the offset from the beginning of the library -- is expected as Pc. - procedure U_init_frame_record (Frame : access CFD); + procedure U_init_frame_record (Frame : not null access CFD); pragma Import (C, U_init_frame_record, "U_init_frame_record"); - procedure U_prep_frame_rec_for_unwind (Frame : access CFD); + procedure U_prep_frame_rec_for_unwind (Frame : not null access CFD); pragma Import (C, U_prep_frame_rec_for_unwind, "U_prep_frame_rec_for_unwind"); -- Fetch the description data of the frame in which these two procedures -- are called. - function U_get_u_rlo (Cur : access CFD; Prev : access PFD) return Integer; + function U_get_u_rlo + (Cur : not null access CFD; Prev : not null access PFD) return Integer; pragma Import (C, U_get_u_rlo, "U_IS_STUB_OR_CALLX"); -- From a complete current frame with a return location possibly located -- into a linker generated stub, and basic information about the previous @@ -251,8 +252,8 @@ package body System.Traceback is -- in a shared library, or something non null otherwise. function U_get_previous_frame_x - (current_frame : access CFD; - previous_frame : access PFD; + (current_frame : not null access CFD; + previous_frame : not null access PFD; previous_size : Integer) return Integer; pragma Import (C, U_get_previous_frame_x, "U_get_previous_frame_x"); -- Fetch the data describing the "previous" frame relatively to the @@ -316,15 +317,15 @@ package body System.Traceback is -- The backtracing process needs a set of subprograms : - function UWD_For_RLO_Of (Frame : access CFD) return UWD_Ptr; + function UWD_For_RLO_Of (Frame : not null access CFD) return UWD_Ptr; -- Return an access to the unwind descriptor for the caller of -- a given frame, using only the provided return location. - function UWD_For_Caller_Of (Frame : access CFD) return UWD_Ptr; + function UWD_For_Caller_Of (Frame : not null access CFD) return UWD_Ptr; -- Return an access to the unwind descriptor for the user code caller -- of a given frame, or null if the information is not available. - function Pop_Frame (Frame : access CFD) return Boolean; + function Pop_Frame (Frame : not null access CFD) return Boolean; -- Update the provided machine state structure so that it reflects -- the state one call frame "above" the initial one. -- @@ -332,7 +333,8 @@ package body System.Traceback is -- Failure typically occurs when the top of the call stack has been -- reached. - function Prepare_For_Unwind_Of (Frame : access CFD) return Boolean; + function Prepare_For_Unwind_Of + (Frame : not null access CFD) return Boolean; -- Perform the necessary adaptations to the machine state before -- calling the unwinder. Currently used for the specific case of -- dynamically sized previous frames. @@ -345,7 +347,7 @@ package body System.Traceback is -- Pop_Frame -- --------------- - function Pop_Frame (Frame : access CFD) return Boolean is + function Pop_Frame (Frame : not null access CFD) return Boolean is Up_Frame : aliased PFD; State_Ready : Boolean; @@ -391,7 +393,8 @@ package body System.Traceback is -- Prepare_State_For_Unwind_Of -- --------------------------------- - function Prepare_For_Unwind_Of (Frame : access CFD) return Boolean + function Prepare_For_Unwind_Of + (Frame : not null access CFD) return Boolean is Caller_UWD : UWD_Ptr; FP_Adjustment : Integer; @@ -453,7 +456,7 @@ package body System.Traceback is -- UWD_For_Caller_Of -- ----------------------- - function UWD_For_Caller_Of (Frame : access CFD) return UWD_Ptr + function UWD_For_Caller_Of (Frame : not null access CFD) return UWD_Ptr is UWD_Access : UWD_Ptr; @@ -499,7 +502,7 @@ package body System.Traceback is -- UWD_For_RLO_Of -- -------------------- - function UWD_For_RLO_Of (Frame : access CFD) return UWD_Ptr + function UWD_For_RLO_Of (Frame : not null access CFD) return UWD_Ptr is UWD_Address : Address; diff --git a/gcc/ada/s-valdec.adb b/gcc/ada/s-valdec.adb index dbac049edef..3af5cad34a0 100644 --- a/gcc/ada/s-valdec.adb +++ b/gcc/ada/s-valdec.adb @@ -6,7 +6,7 @@ -- -- -- B o d y -- -- -- --- Copyright (C) 1992-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2006, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -46,7 +46,7 @@ package body System.Val_Dec is function Scan_Decimal (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer; Scale : Integer) return Integer is diff --git a/gcc/ada/s-valdec.ads b/gcc/ada/s-valdec.ads index df36ebd9007..61d9c076cd0 100644 --- a/gcc/ada/s-valdec.ads +++ b/gcc/ada/s-valdec.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1992-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2006, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -40,7 +40,7 @@ package System.Val_Dec is function Scan_Decimal (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer; Scale : Integer) return Integer; -- This function scans the string starting at Str (Ptr.all) for a valid diff --git a/gcc/ada/s-valint.adb b/gcc/ada/s-valint.adb index 60c761fdfd3..1e2524b390c 100644 --- a/gcc/ada/s-valint.adb +++ b/gcc/ada/s-valint.adb @@ -43,7 +43,7 @@ package body System.Val_Int is function Scan_Integer (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer) return Integer is Uval : Unsigned; diff --git a/gcc/ada/s-valint.ads b/gcc/ada/s-valint.ads index 6413a349272..8b8a4c7a5ca 100644 --- a/gcc/ada/s-valint.ads +++ b/gcc/ada/s-valint.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1992-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2006, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -39,7 +39,7 @@ package System.Val_Int is function Scan_Integer (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer) return Integer; -- This function scans the string starting at Str (Ptr.all) for a valid -- integer according to the syntax described in (RM 3.5(43)). The substring diff --git a/gcc/ada/s-vallld.adb b/gcc/ada/s-vallld.adb index 958fb96aa6d..95a7271c0bb 100644 --- a/gcc/ada/s-vallld.adb +++ b/gcc/ada/s-vallld.adb @@ -6,7 +6,7 @@ -- -- -- B o d y -- -- -- --- Copyright (C) 1992-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2006, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -45,7 +45,7 @@ package body System.Val_LLD is function Scan_Long_Long_Decimal (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer; Scale : Integer) return Long_Long_Integer is diff --git a/gcc/ada/s-vallld.ads b/gcc/ada/s-vallld.ads index 7022669dfcd..caed56e21b5 100644 --- a/gcc/ada/s-vallld.ads +++ b/gcc/ada/s-vallld.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1992-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2006, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -40,7 +40,7 @@ package System.Val_LLD is function Scan_Long_Long_Decimal (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer; Scale : Integer) return Long_Long_Integer; -- This function scans the string starting at Str (Ptr.all) for a valid diff --git a/gcc/ada/s-vallli.adb b/gcc/ada/s-vallli.adb index 850bdf1b7a9..20f160c939f 100644 --- a/gcc/ada/s-vallli.adb +++ b/gcc/ada/s-vallli.adb @@ -43,7 +43,7 @@ package body System.Val_LLI is function Scan_Long_Long_Integer (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer) return Long_Long_Integer is Uval : Long_Long_Unsigned; diff --git a/gcc/ada/s-vallli.ads b/gcc/ada/s-vallli.ads index e83fd8f710b..c5c1bf9f856 100644 --- a/gcc/ada/s-vallli.ads +++ b/gcc/ada/s-vallli.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1992-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2006, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -39,7 +39,7 @@ package System.Val_LLI is function Scan_Long_Long_Integer (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer) return Long_Long_Integer; -- This function scans the string starting at Str (Ptr.all) for a valid -- integer according to the syntax described in (RM 3.5(43)). The substring diff --git a/gcc/ada/s-valllu.adb b/gcc/ada/s-valllu.adb index ab5752f4c7c..abbbaa440f0 100644 --- a/gcc/ada/s-valllu.adb +++ b/gcc/ada/s-valllu.adb @@ -42,7 +42,7 @@ package body System.Val_LLU is function Scan_Raw_Long_Long_Unsigned (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer) return Long_Long_Unsigned is P : Integer; @@ -271,7 +271,7 @@ package body System.Val_LLU is function Scan_Long_Long_Unsigned (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer) return Long_Long_Unsigned is Start : Positive; diff --git a/gcc/ada/s-valllu.ads b/gcc/ada/s-valllu.ads index e6c740f8a50..88a6e4cd915 100644 --- a/gcc/ada/s-valllu.ads +++ b/gcc/ada/s-valllu.ads @@ -41,7 +41,7 @@ package System.Val_LLU is function Scan_Raw_Long_Long_Unsigned (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer) return System.Unsigned_Types.Long_Long_Unsigned; -- This function scans the string starting at Str (Ptr.all) for a valid -- integer according to the syntax described in (RM 3.5(43)). The substring @@ -71,7 +71,7 @@ package System.Val_LLU is function Scan_Long_Long_Unsigned (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer) return System.Unsigned_Types.Long_Long_Unsigned; -- Same as Scan_Raw_Long_Long_Unsigned, except scans optional leading -- blanks, and an optional leading plus sign. diff --git a/gcc/ada/s-valrea.adb b/gcc/ada/s-valrea.adb index e277e380991..60f48739dab 100644 --- a/gcc/ada/s-valrea.adb +++ b/gcc/ada/s-valrea.adb @@ -6,7 +6,7 @@ -- -- -- B o d y -- -- -- --- Copyright (C) 1992-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2006, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -42,7 +42,7 @@ package body System.Val_Real is function Scan_Real (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer) return Long_Long_Float is procedure Reset; diff --git a/gcc/ada/s-valrea.ads b/gcc/ada/s-valrea.ads index d3b0e33d90b..0c3510dc323 100644 --- a/gcc/ada/s-valrea.ads +++ b/gcc/ada/s-valrea.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- Copyright (C) 1992-2005, Free Software Foundation, Inc. -- +-- Copyright (C) 1992-2006, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- @@ -36,7 +36,7 @@ package System.Val_Real is function Scan_Real (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer) return Long_Long_Float; -- This function scans the string starting at Str (Ptr.all) for a valid -- real literal according to the syntax described in (RM 3.5(43)). The diff --git a/gcc/ada/s-valuns.adb b/gcc/ada/s-valuns.adb index d9d7940a356..3d09321f210 100644 --- a/gcc/ada/s-valuns.adb +++ b/gcc/ada/s-valuns.adb @@ -42,7 +42,7 @@ package body System.Val_Uns is function Scan_Raw_Unsigned (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer) return Unsigned is P : Integer; @@ -268,7 +268,7 @@ package body System.Val_Uns is function Scan_Unsigned (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer) return Unsigned is Start : Positive; diff --git a/gcc/ada/s-valuns.ads b/gcc/ada/s-valuns.ads index 7503ca4b720..80695dd386c 100644 --- a/gcc/ada/s-valuns.ads +++ b/gcc/ada/s-valuns.ads @@ -41,7 +41,7 @@ package System.Val_Uns is function Scan_Raw_Unsigned (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer) return System.Unsigned_Types.Unsigned; -- This function scans the string starting at Str (Ptr.all) for a valid -- integer according to the syntax described in (RM 3.5(43)). The substring @@ -71,7 +71,7 @@ package System.Val_Uns is function Scan_Unsigned (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer) return System.Unsigned_Types.Unsigned; -- Same as Scan_Raw_Unsigned, except scans optional leading -- blanks, and an optional leading plus sign. diff --git a/gcc/ada/s-valuti.adb b/gcc/ada/s-valuti.adb index 258620e24b6..f2ed3217e2b 100644 --- a/gcc/ada/s-valuti.adb +++ b/gcc/ada/s-valuti.adb @@ -81,7 +81,7 @@ package body System.Val_Util is function Scan_Exponent (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer; Real : Boolean := False) return Integer is @@ -165,7 +165,7 @@ package body System.Val_Util is procedure Scan_Plus_Sign (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer; Start : out Positive) is @@ -209,7 +209,7 @@ package body System.Val_Util is procedure Scan_Sign (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer; Minus : out Boolean; Start : out Positive) @@ -286,7 +286,7 @@ package body System.Val_Util is procedure Scan_Underscore (Str : String; P : in out Natural; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer; Ext : Boolean) is diff --git a/gcc/ada/s-valuti.ads b/gcc/ada/s-valuti.ads index 944b945a2ae..90422e88816 100644 --- a/gcc/ada/s-valuti.ads +++ b/gcc/ada/s-valuti.ads @@ -49,7 +49,7 @@ package System.Val_Util is procedure Scan_Sign (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer; Minus : out Boolean; Start : out Positive); @@ -72,7 +72,7 @@ package System.Val_Util is procedure Scan_Plus_Sign (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer; Start : out Positive); -- Same as Scan_Sign, but allows only plus, not minus. @@ -80,7 +80,7 @@ package System.Val_Util is function Scan_Exponent (Str : String; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer; Real : Boolean := False) return Integer; -- Called to scan a possible exponent. Str, Ptr, Max are as described above @@ -101,7 +101,7 @@ package System.Val_Util is procedure Scan_Underscore (Str : String; P : in out Natural; - Ptr : access Integer; + Ptr : not null access Integer; Max : Integer; Ext : Boolean); -- Called if an underscore is encountered while scanning digits. Str (P) diff --git a/gcc/ada/sequenio.ads b/gcc/ada/sequenio.ads index 8ea18905851..7fdf72d782f 100644 --- a/gcc/ada/sequenio.ads +++ b/gcc/ada/sequenio.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/sinput-c.adb b/gcc/ada/sinput-c.adb index 39e2332fbbf..f762602778e 100644 --- a/gcc/ada/sinput-c.adb +++ b/gcc/ada/sinput-c.adb @@ -24,12 +24,13 @@ -- -- ------------------------------------------------------------------------------ +with Namet; use Namet; +with Opt; use Opt; +with System; use System; + with Ada.Unchecked_Conversion; with GNAT.OS_Lib; use GNAT.OS_Lib; -with Namet; use Namet; -with Opt; use Opt; -with System; use System; package body Sinput.C is diff --git a/gcc/ada/text_io.ads b/gcc/ada/text_io.ads index f51e1c22da9..9c213e9a4fd 100644 --- a/gcc/ada/text_io.ads +++ b/gcc/ada/text_io.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/unchconv.ads b/gcc/ada/unchconv.ads index 3ffd43182d5..7937020874a 100644 --- a/gcc/ada/unchconv.ads +++ b/gcc/ada/unchconv.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/unchdeal.ads b/gcc/ada/unchdeal.ads index 663e5e52152..4735a520791 100644 --- a/gcc/ada/unchdeal.ads +++ b/gcc/ada/unchdeal.ads @@ -6,7 +6,7 @@ -- -- -- S p e c -- -- -- --- This specification is adapted from the Ada Reference Manual for use with -- +-- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- diff --git a/gcc/ada/xref_lib.adb b/gcc/ada/xref_lib.adb index 004b2773ec9..d48a99480fe 100644 --- a/gcc/ada/xref_lib.adb +++ b/gcc/ada/xref_lib.adb @@ -53,7 +53,7 @@ package body Xref_Lib is -- the .ali files procedure Parse_EOL - (Source : access String; + (Source : not null access String; Ptr : in out Positive; Skip_Continuation_Line : Boolean := False); -- On return Source (Ptr) is the first character of the next line @@ -98,7 +98,7 @@ package body Xref_Lib is -- The entity will never be reported as unreferenced by gnatxref -u procedure Parse_Token - (Source : access String; + (Source : not null access String; Ptr : in out Positive; Token_Ptr : out Positive); -- Skips any separators and stores the start of the token in Token_Ptr. @@ -107,7 +107,7 @@ package body Xref_Lib is -- and ASCII.HT. Parse_Token will never skip to the next line. procedure Parse_Number - (Source : access String; + (Source : not null access String; Ptr : in out Positive; Number : out Natural); -- Skips any separators and parses Source upto the first character that @@ -694,7 +694,7 @@ package body Xref_Lib is --------------- procedure Parse_EOL - (Source : access String; + (Source : not null access String; Ptr : in out Positive; Skip_Continuation_Line : Boolean := False) is @@ -1143,7 +1143,7 @@ package body Xref_Lib is ------------------ procedure Parse_Number - (Source : access String; + (Source : not null access String; Ptr : in out Positive; Number : out Natural) is @@ -1167,7 +1167,7 @@ package body Xref_Lib is ----------------- procedure Parse_Token - (Source : access String; + (Source : not null access String; Ptr : in out Positive; Token_Ptr : out Positive) is -- 2.30.2