gcc/gcc/ada/par-labl.adb

544 lines
18 KiB
Ada
Raw Normal View History

2001-10-02 16:23:52 +02:00
------------------------------------------------------------------------------
-- --
-- GNAT COMPILER COMPONENTS --
-- --
-- P A R . L A B L --
-- --
-- B o d y --
-- --
a-except-2005.adb, [...]: Minor reformatting. 2014-01-29 Robert Dewar <dewar@adacore.com> * a-except-2005.adb, a-except.adb, a-excpol-abort.adb, a-exstat.adb, ali.adb, a-numaux.ads, a-numaux-darwin.ads, a-numaux-libc-x86.ads, a-numaux-vms.ads, a-numaux-vxworks.ads, a-numaux-x86.ads, aspects.ads, a-taside.adb, a-teioed.adb, a-textio.adb, a-textio.ads, atree.adb, atree.ads, a-witeio.adb, a-witeio.ads, a-wtedit.adb, a-ztedit.adb, a-ztexio.adb, bcheck.adb, binde.adb, checks.adb, comperr.adb, cstand.adb, debug_a.adb, einfo.ads, errout.adb, erroutc.adb, eval_fat.adb, exp_aggr.adb, exp_attr.adb, exp_ch11.adb, exp_ch3.adb, exp_ch4.adb, exp_ch5.adb, exp_ch6.adb, exp_ch9.adb, exp_dbug.adb, exp_disp.adb, exp_fixd.adb, exp_imgv.adb, exp_intr.adb, exp_util.adb, freeze.adb, frontend.adb, g-comlin.ads, g-mbdira.adb, gnat1drv.adb, gprep.adb, g-spipat.adb, i-cpp.ads, i-vxwork.ads, i-vxwork-x86.ads, krunch.ads, layout.adb, lib-load.adb, lib-writ.adb, lib-writ.ads, live.adb, namet.ads, osint.adb, osint-c.adb, output.ads, par.adb, par-ch10.adb, par-ch13.adb, par-ch3.adb, par-ch4.adb, par-ch5.adb, par-ch6.adb, par-ch9.adb, par-endh.adb, par-labl.adb, par-prag.adb, par-sync.adb, par-tchk.adb, par-util.adb, prj.adb, repinfo.adb, rtsfind.adb, s-arit64.adb, s-asthan-vms-alpha.adb, s-asthan-vms-ia64.adb, s-bignum.adb, scans.adb, scng.adb, s-dimmks.ads, sem_aggr.adb, sem_attr.adb, sem_aux.adb, sem_cat.adb, sem_ch10.adb, sem_ch12.adb, sem_ch13.adb, sem_ch13.ads, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb, sem_ch8.adb, sem_disp.adb, sem_elab.adb, sem_elim.adb, sem_eval.adb, sem_intr.adb, sem_prag.adb, sem_res.adb, sem_type.adb, sem_util.adb, sem_warn.adb, set_targ.adb, s-fatgen.adb, s-fatgen.ads, s-fileio.adb, s-imgcha.adb, s-imgrea.adb, sinfo.ads, sinput-c.adb, snames.ads-tmpl, s-os_lib.adb, sprint.adb, s-regpat.adb, s-secsta.adb, s-stalib.ads, s-stchop.adb, s-stoele.ads, stand.ads, s-taprop-solaris.adb, s-tasdeb-vms.adb, s-tasini.adb, s-tassta.adb, s-valdec.adb, s-valuti.adb, s-wchjis.adb, s-wchwts.adb, system.ads, system-vms_64.ads, system-vms-ia64.ads, treepr.adb, types.ads, uintp.adb, uname.adb, urealp.adb, usage.adb, vxaddr2line.adb: Minor reformatting. From-SVN: r207260
2014-01-29 16:53:48 +01:00
-- Copyright (C) 1992-2013, Free Software Foundation, Inc. --
2001-10-02 16:23:52 +02:00
-- --
-- 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- --
exp_atag.ads, [...]: Replace headers with GPL v3 headers. 2007-09-10 Robert Dewar <dewar@adacore.com> * exp_atag.ads, exp_atag.adb, mlib-tgt-tru64.adb, mlib-tgt-aix.adb, mlib-tgt-irix.adb, mlib-tgt-hpux.adb, mlib-tgt-linux.adb, mlib-tgt-solaris.adb, mlib-tgt-vms-alpha.adb, mlib-tgt-vms-ia64.adb, mlib-tgt-mingw.adb, mlib-tgt-vxworks.adb, ali.adb, ali.ads, ali-util.adb, ali-util.ads, atree.h, back_end.adb, back_end.ads, bcheck.adb, bcheck.ads, binde.adb, binde.ads, binderr.adb, binderr.ads, bindgen.adb, bindgen.ads, bindusg.adb, bindusg.ads, butil.adb, butil.ads, checks.adb, checks.ads, clean.adb, clean.ads, comperr.adb, comperr.ads, cstand.adb, cstand.ads, debug_a.adb, debug_a.ads, elists.h, errout.adb, erroutc.ads, errutil.adb, errutil.ads, err_vars.ads, eval_fat.adb, eval_fat.ads, exp_sel.ads, exp_sel.adb, exp_aggr.adb, exp_aggr.ads, expander.adb, expander.ads, exp_attr.ads, exp_ch10.ads, exp_ch11.adb, exp_ch12.adb, exp_ch12.ads, exp_ch13.adb, exp_ch13.ads, exp_ch2.adb, exp_ch2.ads, exp_ch3.ads, exp_ch4.adb, exp_ch4.ads, exp_ch5.adb, exp_ch5.ads, exp_ch6.adb, exp_ch6.ads, exp_ch7.adb, exp_ch7.ads, exp_ch8.adb, exp_ch8.ads, exp_ch9.adb, exp_ch9.ads, exp_code.adb, exp_code.ads, exp_dbug.adb, exp_dbug.ads, exp_disp.ads, exp_dist.adb, exp_dist.ads, exp_fixd.adb, exp_fixd.ads, exp_imgv.adb, exp_imgv.ads, exp_intr.adb, exp_intr.ads, exp_pakd.adb, exp_pakd.ads, exp_prag.adb, exp_prag.ads, exp_smem.adb, exp_strm.adb, exp_strm.ads, exp_tss.adb, exp_tss.ads, exp_util.adb, exp_util.ads, exp_vfpt.adb, exp_vfpt.ads, fmap.adb, fmap.ads, fname-sf.adb, fname-sf.ads, fname-uf.adb, fname-uf.ads, frontend.adb, frontend.ads, get_targ.adb, get_targ.ads, gnat1drv.adb, gnat1drv.ads, gnatbind.adb, gnatbind.ads, gnatbl.c, gnatchop.adb, gnatclean.adb, gnatcmd.adb, gnatcmd.ads, gnatdll.adb, gnatfind.adb, gnatkr.adb, gnatkr.ads, gnatlbr.adb, gnatlink.adb, gnatlink.ads, gnatls.adb, gnatls.ads, gnatmake.adb, gnatmake.ads, gnatmem.adb, gnatname.adb, gnatname.ads, gnatprep.adb, gnatprep.ads, gnatsym.adb, gnatxref.adb, gprep.adb, gprep.ads, hlo.adb, hlo.ads, impunit.adb, impunit.ads, inline.adb, inline.ads, itypes.adb, itypes.ads, layout.adb, layout.ads, lib-load.adb, lib-load.ads, lib-util.adb, lib-util.ads, lib-writ.adb, lib-writ.ads, lib-xref.adb, lib-xref.ads, live.adb, live.ads, make.adb, make.ads, makeutl.ads, makeutl.adb, makeusg.adb, makeusg.ads, mdll.adb, mdll.ads, mdll-fil.adb, mdll-fil.ads, mdll-utl.adb, mdll-utl.ads, memroot.adb, memroot.ads, mlib.adb, mlib.ads, mlib-fil.adb, mlib-fil.ads, mlib-prj.adb, mlib-prj.ads, mlib-tgt.adb, mlib-tgt.ads, mlib-utl.adb, mlib-utl.ads, namet.h, nmake.adt, osint.adb, osint.ads, osint-b.adb, osint-b.ads, osint-c.adb, osint-c.ads, osint-l.adb, osint-l.ads, osint-m.adb, osint-m.ads, par.adb, par.ads, par-ch10.adb, par-ch11.adb, par-ch12.adb, par-ch13.adb, par-ch2.adb, par-ch3.adb, par-ch4.adb, par-ch5.adb, par-ch6.adb, par-ch7.adb, par-ch8.adb, par-ch9.adb, par-endh.adb, par-labl.adb, par-load.adb, par-prag.adb, par-sync.adb, par-tchk.adb, par-util.adb, prep.adb, prep.ads, prepcomp.adb, prepcomp.ads, prj.adb, prj.ads, prj-attr.adb, prj-attr.ads, prj-com.ads, prj-dect.adb, prj-dect.ads, prj-err.adb, prj-err.ads, prj-ext.adb, prj-ext.ads, prj-makr.adb, prj-makr.ads, prj-nmsc.adb, prj-nmsc.ads, prj-pars.adb, prj-pars.ads, prj-part.adb, prj-part.ads, prj-pp.adb, prj-pp.ads, prj-proc.adb, prj-proc.ads, prj-strt.adb, prj-strt.ads, prj-tree.adb, prj-tree.ads, prj-util.adb, prj-util.ads, restrict.adb, restrict.ads, rtsfind.adb, rtsfind.ads, scn.adb, scn.ads, scng.adb, scng.ads, sdefault.ads, sem.ads, sem_aggr.ads, sem_attr.adb, sem_case.adb, sem_case.ads, sem_cat.adb, sem_cat.ads, sem_ch10.adb, sem_ch10.ads, sem_ch11.adb, sem_ch11.ads, sem_ch12.ads, sem_ch13.adb, sem_ch13.ads, sem_ch2.adb, sem_ch2.ads, sem_ch3.adb, sem_ch3.ads, sem_ch4.ads, sem_ch5.adb, sem_ch5.ads, sem_ch6.adb, sem_ch6.ads, sem_ch7.adb, sem_ch7.ads, sem_ch8.adb, sem_ch8.ads, sem_ch9.adb, sem_ch9.ads, sem_disp.adb, sem_disp.ads, sem_dist.adb, sem_dist.ads, sem_elab.adb, sem_elab.ads, sem_elim.adb, sem_elim.ads, sem_eval.adb, sem_eval.ads, sem_intr.adb, sem_intr.ads, sem_maps.adb, sem_maps.ads, sem_mech.adb, sem_mech.ads, sem_prag.adb, sem_prag.ads, sem_res.adb, sem_res.ads, sem_smem.adb, sem_smem.ads, sem_type.adb, sem_type.ads, sem_util.adb, sem_util.ads, sem_vfpt.adb, sem_vfpt.ads, sem_warn.adb, sem_warn.ads, sfn_scan.ads, sinfo-cn.adb, sinfo-cn.ads, sinput-c.adb, sinput-c.ads, sinput-d.adb, sinput-d.ads, sinput-l.adb, sinput-l.ads, sinput-p.adb, sinput-p.ads, snames.h, sprint.adb, sprint.ads, stringt.h, style.ads, styleg.adb, styleg.ads, styleg-c.adb, styleg-c.ads, stylesw.adb, stylesw.ads, switch.adb, switch.ads, switch-b.adb, switch-b.ads, switch-c.adb, switch-c.ads, switch-m.adb, switch-m.ads, symbols.adb, symbols.ads, targparm.adb, tbuild.adb, tbuild.ads, tempdir.adb, tempdir.ads, tree_gen.adb, tree_gen.ads, treepr.adb, treepr.ads, treeprs.adt, ttypef.ads, ttypes.ads, types.h, uintp.h, urealp.h, usage.adb, usage.ads, validsw.adb, validsw.ads, vxaddr2line.adb, xeinfo.adb, xnmake.adb, xref_lib.adb, xref_lib.ads, xr_tabls.adb, xr_tabls.ads, xsinfo.adb, xtreeprs.adb, xsnames.adb, vms_conv.ads, vms_conv.adb, xgnatugn.adb, gprmake.adb, makegpr.ads, makegpr.adb, prj-attr-pm.ads, prj-attr-pm.adb, mlib-tgt-lynxos.adb, mlib-tgt-darwin.adb, symbols-vms.adb, symbols-processing-vms-alpha.adb, symbols-processing-vms-ia64.adb, mlib-tgt-specific.adb, mlib-tgt-specific.ads, mlib-tgt-vms.adb, mlib-tgt-vms.ads: Replace headers with GPL v3 headers. From-SVN: r128332
2007-09-10 14:47:10 +02:00
-- ware Foundation; either version 3, or (at your option) any later ver- --
2001-10-02 16:23:52 +02:00
-- 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 --
exp_atag.ads, [...]: Replace headers with GPL v3 headers. 2007-09-10 Robert Dewar <dewar@adacore.com> * exp_atag.ads, exp_atag.adb, mlib-tgt-tru64.adb, mlib-tgt-aix.adb, mlib-tgt-irix.adb, mlib-tgt-hpux.adb, mlib-tgt-linux.adb, mlib-tgt-solaris.adb, mlib-tgt-vms-alpha.adb, mlib-tgt-vms-ia64.adb, mlib-tgt-mingw.adb, mlib-tgt-vxworks.adb, ali.adb, ali.ads, ali-util.adb, ali-util.ads, atree.h, back_end.adb, back_end.ads, bcheck.adb, bcheck.ads, binde.adb, binde.ads, binderr.adb, binderr.ads, bindgen.adb, bindgen.ads, bindusg.adb, bindusg.ads, butil.adb, butil.ads, checks.adb, checks.ads, clean.adb, clean.ads, comperr.adb, comperr.ads, cstand.adb, cstand.ads, debug_a.adb, debug_a.ads, elists.h, errout.adb, erroutc.ads, errutil.adb, errutil.ads, err_vars.ads, eval_fat.adb, eval_fat.ads, exp_sel.ads, exp_sel.adb, exp_aggr.adb, exp_aggr.ads, expander.adb, expander.ads, exp_attr.ads, exp_ch10.ads, exp_ch11.adb, exp_ch12.adb, exp_ch12.ads, exp_ch13.adb, exp_ch13.ads, exp_ch2.adb, exp_ch2.ads, exp_ch3.ads, exp_ch4.adb, exp_ch4.ads, exp_ch5.adb, exp_ch5.ads, exp_ch6.adb, exp_ch6.ads, exp_ch7.adb, exp_ch7.ads, exp_ch8.adb, exp_ch8.ads, exp_ch9.adb, exp_ch9.ads, exp_code.adb, exp_code.ads, exp_dbug.adb, exp_dbug.ads, exp_disp.ads, exp_dist.adb, exp_dist.ads, exp_fixd.adb, exp_fixd.ads, exp_imgv.adb, exp_imgv.ads, exp_intr.adb, exp_intr.ads, exp_pakd.adb, exp_pakd.ads, exp_prag.adb, exp_prag.ads, exp_smem.adb, exp_strm.adb, exp_strm.ads, exp_tss.adb, exp_tss.ads, exp_util.adb, exp_util.ads, exp_vfpt.adb, exp_vfpt.ads, fmap.adb, fmap.ads, fname-sf.adb, fname-sf.ads, fname-uf.adb, fname-uf.ads, frontend.adb, frontend.ads, get_targ.adb, get_targ.ads, gnat1drv.adb, gnat1drv.ads, gnatbind.adb, gnatbind.ads, gnatbl.c, gnatchop.adb, gnatclean.adb, gnatcmd.adb, gnatcmd.ads, gnatdll.adb, gnatfind.adb, gnatkr.adb, gnatkr.ads, gnatlbr.adb, gnatlink.adb, gnatlink.ads, gnatls.adb, gnatls.ads, gnatmake.adb, gnatmake.ads, gnatmem.adb, gnatname.adb, gnatname.ads, gnatprep.adb, gnatprep.ads, gnatsym.adb, gnatxref.adb, gprep.adb, gprep.ads, hlo.adb, hlo.ads, impunit.adb, impunit.ads, inline.adb, inline.ads, itypes.adb, itypes.ads, layout.adb, layout.ads, lib-load.adb, lib-load.ads, lib-util.adb, lib-util.ads, lib-writ.adb, lib-writ.ads, lib-xref.adb, lib-xref.ads, live.adb, live.ads, make.adb, make.ads, makeutl.ads, makeutl.adb, makeusg.adb, makeusg.ads, mdll.adb, mdll.ads, mdll-fil.adb, mdll-fil.ads, mdll-utl.adb, mdll-utl.ads, memroot.adb, memroot.ads, mlib.adb, mlib.ads, mlib-fil.adb, mlib-fil.ads, mlib-prj.adb, mlib-prj.ads, mlib-tgt.adb, mlib-tgt.ads, mlib-utl.adb, mlib-utl.ads, namet.h, nmake.adt, osint.adb, osint.ads, osint-b.adb, osint-b.ads, osint-c.adb, osint-c.ads, osint-l.adb, osint-l.ads, osint-m.adb, osint-m.ads, par.adb, par.ads, par-ch10.adb, par-ch11.adb, par-ch12.adb, par-ch13.adb, par-ch2.adb, par-ch3.adb, par-ch4.adb, par-ch5.adb, par-ch6.adb, par-ch7.adb, par-ch8.adb, par-ch9.adb, par-endh.adb, par-labl.adb, par-load.adb, par-prag.adb, par-sync.adb, par-tchk.adb, par-util.adb, prep.adb, prep.ads, prepcomp.adb, prepcomp.ads, prj.adb, prj.ads, prj-attr.adb, prj-attr.ads, prj-com.ads, prj-dect.adb, prj-dect.ads, prj-err.adb, prj-err.ads, prj-ext.adb, prj-ext.ads, prj-makr.adb, prj-makr.ads, prj-nmsc.adb, prj-nmsc.ads, prj-pars.adb, prj-pars.ads, prj-part.adb, prj-part.ads, prj-pp.adb, prj-pp.ads, prj-proc.adb, prj-proc.ads, prj-strt.adb, prj-strt.ads, prj-tree.adb, prj-tree.ads, prj-util.adb, prj-util.ads, restrict.adb, restrict.ads, rtsfind.adb, rtsfind.ads, scn.adb, scn.ads, scng.adb, scng.ads, sdefault.ads, sem.ads, sem_aggr.ads, sem_attr.adb, sem_case.adb, sem_case.ads, sem_cat.adb, sem_cat.ads, sem_ch10.adb, sem_ch10.ads, sem_ch11.adb, sem_ch11.ads, sem_ch12.ads, sem_ch13.adb, sem_ch13.ads, sem_ch2.adb, sem_ch2.ads, sem_ch3.adb, sem_ch3.ads, sem_ch4.ads, sem_ch5.adb, sem_ch5.ads, sem_ch6.adb, sem_ch6.ads, sem_ch7.adb, sem_ch7.ads, sem_ch8.adb, sem_ch8.ads, sem_ch9.adb, sem_ch9.ads, sem_disp.adb, sem_disp.ads, sem_dist.adb, sem_dist.ads, sem_elab.adb, sem_elab.ads, sem_elim.adb, sem_elim.ads, sem_eval.adb, sem_eval.ads, sem_intr.adb, sem_intr.ads, sem_maps.adb, sem_maps.ads, sem_mech.adb, sem_mech.ads, sem_prag.adb, sem_prag.ads, sem_res.adb, sem_res.ads, sem_smem.adb, sem_smem.ads, sem_type.adb, sem_type.ads, sem_util.adb, sem_util.ads, sem_vfpt.adb, sem_vfpt.ads, sem_warn.adb, sem_warn.ads, sfn_scan.ads, sinfo-cn.adb, sinfo-cn.ads, sinput-c.adb, sinput-c.ads, sinput-d.adb, sinput-d.ads, sinput-l.adb, sinput-l.ads, sinput-p.adb, sinput-p.ads, snames.h, sprint.adb, sprint.ads, stringt.h, style.ads, styleg.adb, styleg.ads, styleg-c.adb, styleg-c.ads, stylesw.adb, stylesw.ads, switch.adb, switch.ads, switch-b.adb, switch-b.ads, switch-c.adb, switch-c.ads, switch-m.adb, switch-m.ads, symbols.adb, symbols.ads, targparm.adb, tbuild.adb, tbuild.ads, tempdir.adb, tempdir.ads, tree_gen.adb, tree_gen.ads, treepr.adb, treepr.ads, treeprs.adt, ttypef.ads, ttypes.ads, types.h, uintp.h, urealp.h, usage.adb, usage.ads, validsw.adb, validsw.ads, vxaddr2line.adb, xeinfo.adb, xnmake.adb, xref_lib.adb, xref_lib.ads, xr_tabls.adb, xr_tabls.ads, xsinfo.adb, xtreeprs.adb, xsnames.adb, vms_conv.ads, vms_conv.adb, xgnatugn.adb, gprmake.adb, makegpr.ads, makegpr.adb, prj-attr-pm.ads, prj-attr-pm.adb, mlib-tgt-lynxos.adb, mlib-tgt-darwin.adb, symbols-vms.adb, symbols-processing-vms-alpha.adb, symbols-processing-vms-ia64.adb, mlib-tgt-specific.adb, mlib-tgt-specific.ads, mlib-tgt-vms.adb, mlib-tgt-vms.ads: Replace headers with GPL v3 headers. From-SVN: r128332
2007-09-10 14:47:10 +02:00
-- Public License distributed with GNAT; see file COPYING3. If not, go to --
-- http://www.gnu.org/licenses for a complete copy of the license. --
2001-10-02 16:23:52 +02:00
-- --
-- GNAT was originally developed by the GNAT team at New York University. --
Nathanael Nerode <neroden@gcc.gnu.org> PR ada/6919 (forward port of patch for PR ada/5904) Nathanael Nerode <neroden@gcc.gnu.org> PR ada/6919 (forward port of patch for PR ada/5904) * 1aexcept.adb 1aexcept.ads 41intnam.ads 42intnam.ads 4aintnam.ads 4cintnam.ads 4dintnam.ads 4hexcpol.adb 4lintnam.ads 4mintnam.ads 4nintnam.ads 4onumaux.ads 4pintnam.ads 4rintnam.ads 4sintnam.ads 4uintnam.ads 4vcalend.adb 4vintnam.ads 4wcalend.adb 4wexcpol.adb 4wintnam.ads 4zintnam.ads 4znumaux.ads 4zsytaco.adb 4zsytaco.ads 51osinte.adb 51osinte.ads 52osinte.adb 52osinte.ads 52system.ads 53osinte.ads 5aosinte.ads 5asystem.ads 5atasinf.ads 5ataspri.ads 5avxwork.ads 5bosinte.ads 5bsystem.ads 5cosinte.ads 5dosinte.ads 5esystem.ads 5fosinte.ads 5fsystem.ads 5ftasinf.ads 5ginterr.adb 5gmastop.adb 5gosinte.ads 5gproinf.adb 5gproinf.ads 5gsystem.ads 5gtasinf.adb 5gtasinf.ads 5gtpgetc.adb 5hparame.ads 5hsystem.ads 5htaspri.ads 5iosinte.ads 5itaspri.ads 5ksystem.ads 5kvxwork.ads 5losinte.ads 5lsystem.ads 5mosinte.ads 5mvxwork.ads 5ninmaop.adb 5nintman.adb 5nosinte.ads 5ntaspri.ads 5oosprim.adb 5oparame.adb 5osystem.ads 5posinte.ads 5posprim.adb 5pvxwork.ads 5rosinte.ads 5rparame.adb 5sintman.adb 5sosinte.ads 5sparame.adb 5ssystem.ads 5stasinf.adb 5stasinf.ads 5staspri.ads 5svxwork.ads 5tosinte.ads 5uosinte.ads 5vasthan.adb 5vinterr.adb 5vintman.ads 5vosinte.ads 5vosprim.adb 5vosprim.ads 5vparame.ads 5vsystem.ads 5vtaspri.ads 5vtpopde.adb 5vtpopde.ads 5vvaflop.adb 5wintman.adb 5wmemory.adb 5wosinte.ads 5wosprim.adb 5wsystem.ads 5wtaprop.adb 5wtaspri.ads 5ysystem.ads 5zinterr.adb 5zosinte.adb 5zosinte.ads 5zosprim.adb 5zsystem.ads 6vcpp.adb 6vcstrea.adb 7sosprim.adb 86numaux.adb 86numaux.ads 9drpc.adb a-astaco.adb a-caldel.ads a-calend.adb a-calend.ads a-chahan.adb a-chahan.ads a-colien.adb a-colien.ads a-colire.adb a-colire.ads a-comlin.adb a-comlin.ads a-cwila1.ads a-decima.adb a-decima.ads a-diocst.adb a-diocst.ads a-direio.adb a-direio.ads a-einuoc.adb a-einuoc.ads a-except.adb a-except.ads a-excpol.adb a-exctra.adb a-exctra.ads a-filico.adb a-filico.ads a-finali.adb a-finali.ads a-interr.ads a-intsig.adb a-intsig.ads a-ngcefu.adb a-ngcoty.adb a-ngcoty.ads a-ngelfu.adb a-nudira.adb a-nudira.ads a-nuflra.adb a-nuflra.ads a-numaux.ads a-reatim.ads a-retide.ads a-sequio.adb a-sequio.ads a-siocst.adb a-siocst.ads a-ssicst.adb a-ssicst.ads a-stmaco.ads a-storio.adb a-strbou.adb a-strbou.ads a-stream.ads a-strfix.adb a-strfix.ads a-strmap.adb a-strmap.ads a-strsea.adb a-strsea.ads a-strunb.adb a-strunb.ads a-ststio.adb a-ststio.ads a-stunau.adb a-stunau.ads a-stwibo.adb a-stwibo.ads a-stwifi.adb a-stwima.adb a-stwima.ads a-stwise.adb a-stwise.ads a-stwiun.adb a-stwiun.ads a-suteio.adb a-suteio.ads a-swmwco.ads a-swuwti.adb a-swuwti.ads a-sytaco.adb a-sytaco.ads a-tags.adb a-tags.ads a-tasatt.ads a-taside.adb a-taside.ads a-teioed.adb a-teioed.ads a-textio.adb a-textio.ads a-ticoau.adb a-ticoau.ads a-ticoio.adb a-ticoio.ads a-tideau.adb a-tideau.ads a-tideio.adb a-tideio.ads a-tienau.adb a-tienau.ads a-tienio.adb a-tienio.ads a-tifiio.adb a-tifiio.ads a-tiflau.adb a-tiflau.ads a-tiflio.adb a-tiflio.ads a-tigeau.adb a-tigeau.ads a-tiinau.adb a-tiinau.ads a-tiinio.adb a-tiinio.ads a-timoau.adb a-timoau.ads a-timoio.adb a-timoio.ads a-tiocst.adb a-tiocst.ads a-titest.adb a-witeio.adb a-witeio.ads a-wtcoau.adb a-wtcoau.ads a-wtcoio.adb a-wtcstr.adb a-wtcstr.ads a-wtdeau.adb a-wtdeau.ads a-wtdeio.adb a-wtdeio.ads a-wtedit.adb a-wtedit.ads a-wtenau.adb a-wtenau.ads a-wtenio.adb a-wtenio.ads a-wtfiio.adb a-wtfiio.ads a-wtflau.adb a-wtflau.ads a-wtflio.adb a-wtflio.ads a-wtgeau.adb a-wtgeau.ads a-wtinau.adb a-wtinau.ads a-wtinio.adb a-wtmoau.adb a-wtmoau.ads a-wtmoio.adb a-wtmoio.ads a-wttest.adb ada-tree.def ada-tree.h ada.h adaint.c adaint.h ali-util.adb ali-util.ads ali.adb ali.ads alloc.ads argv.c atree.adb atree.ads atree.h back_end.adb back_end.ads bcheck.adb bcheck.ads binde.adb binde.ads binderr.adb binderr.ads bindgen.adb bindgen.ads bindusg.adb bindusg.ads butil.adb butil.ads cal.c casing.adb casing.ads ceinfo.adb checks.adb checks.ads cio.c comperr.adb comperr.ads csets.adb csets.ads csinfo.adb cstand.adb cstand.ads cstreams.c cuintp.c debug.adb debug.ads debug_a.adb debug_a.ads dec-io.adb dec-io.ads dec.ads decl.c deftarg.c einfo.adb einfo.ads einfo.h elists.adb elists.ads elists.h errno.c errout.adb errout.ads eval_fat.adb eval_fat.ads exit.c exp_aggr.adb exp_aggr.ads exp_attr.adb exp_attr.ads exp_ch10.ads exp_ch11.adb exp_ch11.ads exp_ch12.adb exp_ch12.ads exp_ch13.adb exp_ch13.ads exp_ch2.adb exp_ch2.ads exp_ch3.adb exp_ch3.ads exp_ch4.adb exp_ch4.ads exp_ch5.adb exp_ch5.ads exp_ch6.adb exp_ch6.ads exp_ch7.adb exp_ch7.ads exp_ch8.adb exp_ch8.ads exp_ch9.adb exp_ch9.ads exp_code.adb exp_code.ads exp_dbug.adb exp_dbug.ads exp_disp.adb exp_disp.ads exp_dist.adb exp_dist.ads exp_fixd.adb exp_fixd.ads exp_imgv.adb exp_imgv.ads exp_intr.adb exp_intr.ads exp_pakd.adb exp_pakd.ads exp_prag.adb exp_prag.ads exp_smem.adb exp_smem.ads exp_strm.adb exp_strm.ads exp_tss.adb exp_tss.ads exp_util.adb exp_util.ads exp_vfpt.adb exp_vfpt.ads expander.adb expander.ads fe.h final.c fmap.adb fmap.ads fname-sf.adb fname-sf.ads fname-uf.adb fname-uf.ads fname.adb fname.ads freeze.adb freeze.ads frontend.adb frontend.ads g-calend.ads g-comlin.adb g-debpoo.adb g-debpoo.ads g-locfil.adb g-os_lib.ads g-regist.adb g-regist.ads get_targ.adb get_targ.ads gigi.h gmem.c gnat1drv.adb gnat1drv.ads gnat_ug.texi gnatbind.adb gnatbind.ads gnatbl.c gnatcmd.adb gnatcmd.ads gnatdll.adb gnatfind.adb gnatkr.adb gnatkr.ads gnatlbr.adb gnatlink.adb gnatlink.ads gnatls.adb gnatls.ads gnatmake.adb gnatmake.ads gnatmem.adb gnatprep.adb gnatprep.ads gnatpsta.adb gnatvsn.ads gnatxref.adb hlo.adb hlo.ads hostparm.ads i-c.adb i-cexten.ads i-cobol.adb i-cobol.ads i-cpoint.adb i-cpoint.ads i-cpp.adb i-cpp.ads i-cstrea.adb i-cstrea.ads i-cstrin.adb i-cstrin.ads i-fortra.adb i-os2err.ads i-os2lib.adb i-os2lib.ads i-os2syn.ads i-os2thr.ads i-pacdec.adb i-pacdec.ads impunit.adb impunit.ads init.c inline.adb inline.ads io-aux.c itypes.adb itypes.ads krunch.adb krunch.ads lang-options.h lang-specs.h layout.adb layout.ads lib-list.adb lib-load.adb lib-load.ads lib-sort.adb lib-util.adb lib-util.ads lib-writ.adb lib-writ.ads lib-xref.adb lib-xref.ads lib.adb lib.ads link.c live.adb live.ads make.adb make.ads makeusg.adb makeusg.ads math_lib.adb mdll.adb mdll.ads memtrack.adb misc.c namet.adb namet.ads namet.h nlists.adb nlists.ads nlists.h nmake.adb nmake.ads nmake.adt opt.adb opt.ads osint.adb osint.ads output.adb output.ads par-ch10.adb par-ch11.adb par-ch12.adb par-ch13.adb par-ch2.adb par-ch3.adb par-ch4.adb par-ch5.adb par-ch6.adb par-ch7.adb par-ch8.adb par-ch9.adb par-endh.adb par-labl.adb par-load.adb par-prag.adb par-sync.adb par-tchk.adb par-util.adb par.adb par.ads prj-attr.adb prj-attr.ads prj-com.adb prj-com.ads prj-dect.adb prj-dect.ads prj-env.adb prj-env.ads prj-ext.adb prj-ext.ads prj-nmsc.adb prj-nmsc.ads prj-pars.adb prj-pars.ads prj-part.adb prj-part.ads prj-proc.adb prj-proc.ads prj-strt.adb prj-strt.ads prj-tree.adb prj-tree.ads prj-util.adb prj-util.ads prj.adb prj.ads raise.c raise.h repinfo.adb repinfo.ads repinfo.h restrict.adb restrict.ads rident.ads rtsfind.adb rtsfind.ads s-addima.adb s-addima.ads s-arit64.adb s-arit64.ads s-assert.adb s-assert.ads s-asthan.adb s-asthan.ads s-atacco.adb s-auxdec.adb s-auxdec.ads s-bitops.adb s-bitops.ads s-chepoo.ads s-direio.adb s-direio.ads s-except.ads s-exctab.adb s-exctab.ads s-exnflt.ads s-exngen.adb s-exngen.ads s-exnint.ads s-exnlfl.ads s-exnlin.ads s-exnllf.ads s-exnlli.ads s-exnsfl.ads s-exnsin.ads s-exnssi.ads s-expflt.ads s-expgen.adb s-expgen.ads s-expint.ads s-explfl.ads s-explin.ads s-expllf.ads s-explli.ads s-expllu.adb s-expllu.ads s-expmod.adb s-expmod.ads s-expsfl.ads s-expsin.ads s-expssi.ads s-expuns.adb s-expuns.ads s-fatflt.ads s-fatgen.adb s-fatgen.ads s-fatlfl.ads s-fatllf.ads s-fatsfl.ads s-ficobl.ads s-fileio.adb s-fileio.ads s-finimp.adb s-finimp.ads s-finroo.adb s-finroo.ads s-fore.adb s-fore.ads s-imgbiu.adb s-imgbiu.ads s-imgboo.adb s-imgboo.ads s-imgcha.adb s-imgcha.ads s-imgdec.adb s-imgdec.ads s-imgenu.adb s-imgenu.ads s-imgint.adb s-imgint.ads s-imgllb.adb s-imgllb.ads s-imglld.adb s-imglld.ads s-imglli.adb s-imglli.ads s-imgllu.adb s-imgllu.ads s-imgllw.adb s-imgllw.ads s-imgrea.adb s-imgrea.ads s-imguns.adb s-imguns.ads s-imgwch.adb s-imgwch.ads s-imgwiu.adb s-imgwiu.ads s-inmaop.ads s-interr.adb s-interr.ads s-intman.ads s-io.adb s-io.ads s-maccod.ads s-mantis.adb s-mantis.ads s-memory.adb s-memory.ads s-osprim.ads s-pack03.adb s-pack03.ads s-pack05.adb s-pack05.ads s-pack06.adb s-pack06.ads s-pack07.adb s-pack07.ads s-pack09.adb s-pack09.ads s-pack10.adb s-pack10.ads s-pack11.adb s-pack11.ads s-pack12.adb s-pack12.ads s-pack13.adb s-pack13.ads s-pack14.adb s-pack14.ads s-pack15.adb s-pack15.ads s-pack17.adb s-pack17.ads s-pack18.adb s-pack18.ads s-pack19.adb s-pack19.ads s-pack20.adb s-pack20.ads s-pack21.adb s-pack21.ads s-pack22.adb s-pack22.ads s-pack23.adb s-pack23.ads s-pack24.adb s-pack24.ads s-pack25.adb s-pack25.ads s-pack26.adb s-pack26.ads s-pack27.adb s-pack27.ads s-pack28.adb s-pack28.ads s-pack29.adb s-pack29.ads s-pack30.adb s-pack30.ads s-pack31.adb s-pack31.ads s-pack33.adb s-pack33.ads s-pack34.adb s-pack34.ads s-pack35.adb s-pack35.ads s-pack36.adb s-pack36.ads s-pack37.adb s-pack37.ads s-pack38.adb s-pack38.ads s-pack39.adb s-pack39.ads s-pack40.adb s-pack40.ads s-pack41.adb s-pack41.ads s-pack42.adb s-pack42.ads s-pack43.adb s-pack43.ads s-pack44.adb s-pack44.ads s-pack45.adb s-pack45.ads s-pack46.adb s-pack46.ads s-pack47.adb s-pack47.ads s-pack48.adb s-pack48.ads s-pack49.adb s-pack49.ads s-pack50.adb s-pack50.ads s-pack51.adb s-pack51.ads s-pack52.adb s-pack52.ads s-pack53.adb s-pack53.ads s-pack54.adb s-pack54.ads s-pack55.adb s-pack55.ads s-pack56.adb s-pack56.ads s-pack57.adb s-pack57.ads s-pack58.adb s-pack58.ads s-pack59.adb s-pack59.ads s-pack60.adb s-pack60.ads s-pack61.adb s-pack61.ads s-pack62.adb s-pack62.ads s-pack63.adb s-pack63.ads s-parame.adb s-parame.ads s-parint.adb s-parint.ads s-pooglo.adb s-pooglo.ads s-pooloc.adb s-pooloc.ads s-poosiz.adb s-poosiz.ads s-powtab.ads s-proinf.adb s-proinf.ads s-rpc.adb s-rpc.ads s-scaval.ads s-secsta.adb s-secsta.ads s-sequio.adb s-sequio.ads s-shasto.adb s-shasto.ads s-soflin.adb s-soflin.ads s-sopco3.adb s-sopco3.ads s-sopco4.adb s-sopco4.ads s-sopco5.adb s-sopco5.ads s-stache.adb s-stache.ads s-stalib.adb s-stalib.ads s-stoele.adb s-stopoo.ads s-stratt.adb s-stratt.ads s-strops.adb s-strops.ads s-taprob.ads s-taprop.ads s-tarest.ads s-tasdeb.adb s-tasdeb.ads s-tasinf.adb s-tasinf.ads s-tasini.ads s-taskin.ads s-tasren.ads s-tasres.ads s-tassta.ads s-tpinop.adb s-tpinop.ads s-tpoben.ads s-tpobop.ads s-unstyp.ads s-vaflop.adb s-vaflop.ads s-valboo.adb s-valboo.ads s-valcha.adb s-valcha.ads s-valdec.adb s-valdec.ads s-valenu.adb s-valenu.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 s-valwch.adb s-valwch.ads s-vercon.adb s-vercon.ads s-vmexta.adb s-vmexta.ads s-wchcnv.adb s-wchcnv.ads s-wchcon.ads s-wchjis.adb s-wchjis.ads s-wchstw.adb s-wchstw.ads s-wchwts.adb s-wchwts.ads s-widboo.adb s-widboo.ads s-widcha.adb s-widcha.ads s-widenu.adb s-widenu.ads s-widlli.adb s-widlli.ads s-widllu.adb s-widllu.ads s-widwch.adb s-widwch.ads s-wwdcha.adb s-wwdcha.ads s-wwdenu.adb s-wwdenu.ads s-wwdwch.adb s-wwdwch.ads scans.adb scans.ads scn-nlit.adb scn-slit.adb scn.adb scn.ads sdefault.ads sem.adb sem.ads sem_aggr.adb sem_aggr.ads sem_attr.adb sem_attr.ads sem_case.adb sem_case.ads sem_cat.adb sem_cat.ads sem_ch10.adb sem_ch10.ads sem_ch11.adb sem_ch11.ads sem_ch12.adb sem_ch12.ads sem_ch13.adb sem_ch13.ads sem_ch2.adb sem_ch2.ads sem_ch3.adb sem_ch3.ads sem_ch4.adb sem_ch4.ads sem_ch5.adb sem_ch5.ads sem_ch6.adb sem_ch6.ads sem_ch7.adb sem_ch7.ads sem_ch8.adb sem_ch8.ads sem_ch9.adb sem_ch9.ads sem_disp.adb sem_disp.ads sem_dist.adb sem_dist.ads sem_elab.adb sem_elab.ads sem_elim.adb sem_elim.ads sem_eval.adb sem_eval.ads sem_intr.adb sem_intr.ads sem_maps.adb sem_maps.ads sem_mech.adb sem_mech.ads sem_prag.adb sem_prag.ads sem_res.adb sem_res.ads sem_smem.adb sem_smem.ads sem_type.adb sem_type.ads sem_util.adb sem_util.ads sem_vfpt.adb sem_vfpt.ads sem_warn.adb sem_warn.ads sfn_scan.adb sfn_scan.ads sinfo-cn.adb sinfo-cn.ads sinfo.adb sinfo.ads sinfo.h sinput-l.adb sinput-l.ads sinput-p.adb sinput-p.ads sinput.adb sinput.ads snames.adb snames.ads snames.h sprint.adb sprint.ads stand.adb stand.ads stringt.adb stringt.ads stringt.h style.adb style.ads stylesw.adb stylesw.ads switch.adb switch.ads sysdep.c system.ads table.adb table.ads targparm.adb targparm.ads targtyps.c tbuild.adb tbuild.ads trans.c tree_gen.adb tree_gen.ads tree_in.adb tree_in.ads tree_io.adb tree_io.ads treepr.adb treepr.ads treeprs.ads treeprs.adt ttypef.ads ttypes.ads types.adb types.ads types.h uintp.adb uintp.ads uintp.h uname.adb uname.ads urealp.adb urealp.ads urealp.h usage.adb usage.ads utils.c utils2.c validsw.adb validsw.ads widechar.adb widechar.ads xeinfo.adb xnmake.adb xr_tabls.adb xr_tabls.ads xref_lib.adb xref_lib.ads xsinfo.adb xsnames.adb xtreeprs.adb: Correct statements in comments about maintainership of GNAT. From-SVN: r58442
2002-10-23 09:33:35 +02:00
-- Extensive contributions were provided by Ada Core Technologies Inc. --
2001-10-02 16:23:52 +02:00
-- --
------------------------------------------------------------------------------
separate (Par)
procedure Labl is
Enclosing_Body_Or_Block : Node_Id;
-- Innermost enclosing body or block statement
Label_Decl_Node : Node_Id;
-- Implicit label declaration node
Defining_Ident_Node : Node_Id;
-- Defining identifier node for implicit label declaration
Next_Label_Elmt : Elmt_Id;
-- Next element on label element list
Label_Node : Node_Id;
-- Next label node to process
function Find_Enclosing_Body_Or_Block (N : Node_Id) return Node_Id;
a-secain.adb, [...]: Minor reformatting 2005-11-14 Robert Dewar <dewar@adacore.com> * a-secain.adb, a-slcain.adb, a-shcain.adb, a-chtgke.ads, a-chtgke.adb, a-stwiha.adb, a-strhas.adb, a-chzla1.ads, a-chzla9.ads, a-stzbou.adb, a-stzbou.ads, a-stzfix.adb, a-stzhas.adb, a-stzmap.adb, a-stzmap.ads, a-stzsea.adb, a-stzsea.ads, a-stzsup.adb, a-stzsup.ads, a-stzunb.adb, a-stzunb.ads, a-szuzha.adb, a-szuzha.ads, a-szuzti.adb, a-szuzti.ads, a-ztcoau.adb, a-ztcoau.ads, a-ztcoio.adb, a-ztcstr.adb, a-ztcstr.ads, a-ztdeau.adb, a-ztdeau.ads, a-ztdeio.adb, a-ztdeio.ads, a-ztedit.adb, a-ztedit.ads, a-ztenau.ads, a-ztenio.adb, a-ztenio.ads, a-ztexio.adb, a-ztexio.ads, a-ztfiio.adb, a-ztfiio.ads, a-ztflau.adb, a-ztflau.ads, a-ztflio.adb, a-ztflio.ads, a-ztgeau.adb, a-ztgeau.ads, a-ztinau.adb, a-ztinau.ads, a-ztinio.adb, a-ztmoau.ads, a-ztmoio.adb, a-ztmoio.ads, a-zttest.adb, g-enblsp-vms-alpha.adb, g-enblsp-vms-alpha.adb, g-enblsp-vms-ia64.adb, g-enblsp-vms-ia64.adb, system-linux-hppa.ads, a-chacon.adb, a-chacon.ads, a-wichun.adb, a-wichun.ads, a-zchuni.adb, a-zchuni.ads, g-trasym-vms-alpha.adb, g-trasym-vms-ia64.adb, system-hpux-ia64.ads, g-soccon-unixware.ads, g-soliop-unixware.ads, g-soccon-interix.ads, g-soliop-solaris.ads, g-eacodu-vms.adb, g-expect-vms.adb, g-socthi-vms.adb, g-soliop-mingw.ads, a-intnam-unixware.ads, a-intnam-lynxos.ads, a-intnam-tru64.ads, a-intnam-aix.ads, a-intnam-linux.ads, a-intnam-linux.ads, a-intnam-dummy.ads, a-numaux-libc-x86.ads, a-intnam-interix.ads, a-intnam-solaris.ads, a-calend-vms.adb, a-calend-vms.ads, a-intnam-vms.ads, a-calend-mingw.adb, a-intnam-mingw.ads, a-intnam-vxworks.ads, a-numaux-vxworks.ads, system-unixware.ads, system-linux-ia64.ads, a-intnam-freebsd.ads, system-freebsd-x86.ads, system-lynxos-ppc.ads, system-linux-x86_64.ads, a-stunha.adb, a-cgaaso.ads, a-cgaaso.adb, a-chtgop.adb, a-cgcaso.adb, a-cgarso.adb, a-cohata.ads, a-crbtgk.adb, a-crbltr.ads, a-coprnu.adb, a-rbtgso.adb, a-intnam-darwin.ads, system-darwin-ppc.ads, gprmake.adb, makegpr.ads, system-tru64.ads, system-aix.ads, system-solaris-x86.ads, system-irix-o32.ads, s-interr-sigaction.adb, system-irix-n32.ads, s-parame-mingw.adb, system-hpux.ads, s-traceb-hpux.adb, system-linux-x86.ads, s-inmaop-dummy.adb, system-os2.ads, system-interix.ads, system-solaris-sparc.ads, system-solaris-sparcv9.ads, s-inmaop-vms.adb, s-mastop-vms.adb, expander.adb, expander.ads, s-gloloc-mingw.adb, system-mingw.ads, system-vms-zcx.ads, s-osinte-fsu.adb, s-traceb-mastop.adb, a-exextr.adb, a-exstat.adb, a-filico.ads, a-finali.ads, a-interr.ads, a-intsig.adb, a-intsig.ads, a-except.ads, a-numaux-x86.ads, a-astaco.adb, a-calend.adb, a-calend.ads, a-chahan.adb, a-chahan.ads, a-chlat9.ads, a-colien.adb, a-colien.ads, a-colire.adb, a-colire.ads, a-comlin.adb, a-comlin.ads, a-cwila1.ads, a-cwila9.ads, a-elchha.adb, a-decima.adb, a-decima.ads, a-diocst.ads, a-direio.adb, a-direio.ads, a-excach.adb, a-excach.adb, a-exctra.ads, ali-util.adb, a-ngcefu.adb, a-ngcoty.adb, a-ngcoty.ads, a-nudira.adb, a-nudira.ads, a-nuflra.adb, a-numaux.ads, a-reatim.ads, a-sequio.adb, a-sequio.ads, a-siocst.ads, a-ssicst.ads, a-stmaco.ads, a-storio.adb, a-strbou.adb, a-strbou.ads, a-stream.ads, a-strfix.adb, a-strmap.adb, a-strmap.ads, a-strsea.adb, a-strsea.ads, a-strsup.adb, a-strsup.ads, a-strunb.adb, a-strunb.ads, a-stwibo.adb, a-stwibo.ads, a-stwifi.adb, a-stwima.adb, a-stwima.ads, a-stwise.adb, a-stwise.ads, a-stwisu.adb, a-stwisu.ads, a-stwiun.adb, a-stwiun.ads, a-suteio.adb, a-suteio.ads, a-swmwco.ads, a-swuwti.adb, a-swuwti.ads, a-sytaco.adb, a-sytaco.ads, a-tasatt.adb, a-taside.adb, a-taside.ads, a-teioed.adb, a-textio.adb, a-textio.ads, a-ticoau.adb, a-ticoau.ads, a-ticoio.adb, a-tideau.adb, a-tideio.adb, a-tienau.adb, a-tienio.adb, a-tifiio.adb, a-tiflio.adb, a-tigeau.adb, a-tigeau.ads, a-tiinau.adb, a-tiinio.adb, a-timoau.adb, a-timoio.adb, a-timoio.ads, a-tiocst.ads, a-titest.adb, atree.adb, a-witeio.adb, a-witeio.ads, a-wtcoau.adb, a-wtcoau.ads, a-wtcoio.adb, a-wtcstr.ads, a-wtdeau.adb, a-wtdeio.adb, a-wtedit.adb, a-wtedit.ads, a-wtenau.adb, a-wtenio.adb, a-wtfiio.adb, a-wtflio.adb, a-wtgeau.adb, a-wtinau.adb, a-wtinio.adb, a-wtmoau.adb, a-wtmoio.adb, a-wttest.adb, back_end.adb, bindgen.adb, butil.adb, butil.ads, checks.ads, cio.c, comperr.adb, csets.ads, cstand.adb, debug.ads, elists.ads, errno.c, errout.adb, errout.ads, erroutc.adb, erroutc.ads, errutil.adb, errutil.ads, errutil.ads, err_vars.ads, eval_fat.adb, exp_ch11.adb, exp_ch11.ads, exp_ch2.adb, exp_ch7.ads, exp_imgv.ads, exp_pakd.adb, exp_prag.adb, exp_prag.ads, exp_tss.adb, exp_tss.ads, exp_vfpt.ads, fe.h, fmap.adb, freeze.ads, frontend.adb, frontend.ads, g-arrspl.adb, g-arrspl.ads, g-awk.adb, g-awk.ads, g-boumai.ads, g-calend.adb, g-calend.ads, g-catiio.adb, g-comlin.adb, g-comlin.ads, g-comlin.ads, g-comlin.ads, g-comver.adb, g-crc32.adb, g-crc32.ads, g-ctrl_c.ads, g-curexc.ads, g-debpoo.ads, g-debuti.adb, g-diopit.adb, g-diopit.ads, g-dirope.adb, g-dirope.ads, g-dyntab.adb, g-dyntab.ads, g-excact.adb, g-excact.ads, g-except.ads, g-exctra.adb, g-exctra.ads, g-expect.ads, g-flocon.ads, g-hesorg.ads, g-io.adb, g-locfil.ads, g-md5.adb, g-md5.ads, g-md5.ads, g-moreex.adb, g-signal.ads, g-signal.adb, gnatbind.ads, gnatchop.adb, gnatcmd.adb, gnatfind.adb, gnatlbr.adb, gnatmake.ads, gnatmem.adb, gnatprep.adb, gnatprep.ads, gnatsym.adb, gnatxref.adb, g-os_lib.adb, g-os_lib.ads, g-pehage.adb, g-pehage.ads, gprep.ads, g-regexp.adb, g-regexp.ads, g-regist.adb, g-regist.ads, g-regpat.ads, g-semaph.adb, g-socthi.adb, g-soliop.ads, g-spipat.adb, g-spipat.ads, g-sptabo.ads, g-sptain.ads, g-sptavs.ads, g-string.ads, g-tasloc.adb, g-tasloc.ads, g-trasym.adb, g-trasym.ads, i-fortra.adb, i-fortra.ads, inline.adb, layout.adb, live.adb, make.ads, makeutl.ads, makeutl.adb, mdll-fil.adb, mdll-fil.ads, mdll-utl.ads, memroot.ads, memtrack.adb, mlib.ads, mlib-fil.adb, mlib-fil.ads, mlib-prj.ads, mlib-utl.adb, mlib-utl.ads, nlists.adb, nlists.ads, osint.adb, osint.ads, osint-c.adb, osint-l.adb, osint-l.ads, osint-m.ads, output.adb, par.adb, par.adb, par.ads, par-ch11.adb, par-ch12.adb, par-ch2.adb, par-ch4.adb, par-ch5.adb, par-ch6.adb, par-ch9.adb, par-endh.adb, par-labl.adb, par-load.adb, par-tchk.adb, prep.adb, prepcomp.adb, prepcomp.ads, prj-attr.ads, prj-com.ads, prj-dect.adb, prj-dect.ads, prj-env.ads, prj-err.ads, prj-ext.ads, prj-makr.adb, prj-makr.ads, prj-nmsc.ads, prj-pars.adb, prj-pars.ads, prj-part.ads, prj-pp.ads, prj-proc.ads, prj-strt.adb, prj-strt.ads, prj-tree.adb, prj-util.adb, prj-util.ads, rtsfind.adb, sem.adb, sem.ads, sem_case.adb, sem_case.ads, sem_ch11.adb, sem_ch4.adb, sem_ch6.ads, sem_ch7.ads, sem_dist.ads, sem_elab.ads, sem_elim.ads, sem_eval.ads, sem_intr.ads, sem_maps.adb, sem_maps.ads, sem_maps.ads, sem_res.ads, sem_type.ads, sfn_scan.adb, sfn_scan.ads, s-imgwch.ads, s-imgwiu.adb, s-imgwiu.ads, s-inmaop.ads, sinput.adb, sinput.ads, s-pack03.adb, s-pack03.ads, s-pack05.adb, s-pack05.ads, s-pack06.adb, s-pack06.ads, s-pack07.adb, s-pack07.ads, s-pack09.adb, s-pack09.ads, s-pack10.adb, s-pack10.ads, s-pack11.adb, s-pack11.ads, s-pack12.adb, s-pack12.ads, s-pack13.adb, s-pack13.ads, s-pack14.adb, s-pack14.ads, s-pack15.adb, s-pack15.ads, s-pack17.adb, s-pack17.ads, s-pack18.adb, s-pack18.ads, s-pack19.adb, s-pack19.ads, s-pack20.adb, s-pack20.ads, s-pack21.adb, s-pack21.ads, s-pack22.adb, s-pack22.ads, s-pack23.adb, s-pack23.ads, s-pack24.adb, s-pack24.ads, s-pack25.adb, s-pack25.ads, s-pack26.adb, s-pack26.ads, s-pack27.adb, s-pack27.ads, s-pack28.adb, s-pack28.ads, s-pack29.adb, s-pack29.ads, s-pack30.adb, s-pack30.ads, s-pack31.adb, s-pack31.ads, s-pack33.adb, s-pack33.ads, s-pack34.adb, s-pack34.ads, s-pack35.adb, s-pack35.ads, s-pack36.adb, s-pack36.ads, s-pack37.adb, s-pack37.ads, s-pack38.adb, s-pack38.ads, s-pack39.adb, s-pack39.ads, s-pack40.adb, s-pack40.ads, s-pack41.adb, s-pack41.ads, s-pack42.adb, s-pack42.ads, s-pack43.adb, s-pack43.ads, s-pack44.adb, s-pack44.ads, s-pack45.adb, s-pack45.ads, s-pack46.adb, s-pack46.ads, s-pack47.adb, s-pack47.ads, s-pack48.adb, s-pack48.ads, s-pack49.adb, s-pack49.ads, s-pack50.adb, s-pack50.ads, s-pack51.adb, s-pack51.ads, s-pack52.adb, s-pack52.ads, s-pack53.adb, s-pack53.ads, s-pack54.adb, s-pack54.ads, s-pack55.adb, s-pack55.ads, s-pack56.adb, s-pack56.ads, s-pack57.adb, s-pack57.ads, s-pack58.adb, s-pack58.ads, s-pack59.adb, s-pack59.ads, s-pack60.adb, s-pack60.adb, s-pack60.ads, s-pack61.adb, s-pack61.ads, s-pack62.adb, s-pack62.ads, s-pack63.adb, s-pack63.ads, s-parint.adb, s-parint.adb, s-parint.ads, sprint.ads, s-purexc.ads, s-restri.ads, s-restri.adb, s-scaval.adb, s-scaval.ads, s-secsta.adb, s-secsta.ads, s-sequio.adb, s-sequio.ads, stand.ads, s-tasuti.adb, s-traceb.adb, s-traceb.ads, stringt.adb, stringt.ads, styleg.ads, s-valboo.adb, s-valboo.ads, s-valcha.adb, s-valcha.ads, s-valdec.adb, s-valdec.ads, s-valint.adb, s-valint.ads, 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, s-valwch.ads, s-veboop.adb, s-veboop.ads, s-vercon.adb, s-vercon.ads, s-wchcnv.adb, s-wchcnv.ads, s-wchcon.ads, s-wchjis.adb, s-wchjis.ads, s-wchstw.adb, s-wchstw.adb, s-wchstw.ads, s-wchwts.adb, s-wchwts.ads, s-widboo.adb, s-widboo.ads, s-widcha.adb, s-widcha.ads, s-widenu.adb, s-widenu.ads, s-widlli.adb, s-widlli.ads, s-widllu.adb, s-widllu.ads, s-widwch.adb, s-widwch.ads, s-wwdcha.adb, s-wwdcha.ads, s-wwdenu.adb, s-wwdenu.ads, symbols.adb, symbols.ads, table.ads, targparm.adb, targparm.ads, tb-alvms.c, tb-alvxw.c, tbuild.adb, tree_io.ads, treepr.adb, treeprs.adt, ttypef.ads, ttypes.ads, types.adb, uintp.adb, uintp.ads, uname.ads, urealp.ads, usage.ads, validsw.ads, vxaddr2line.adb, widechar.adb, widechar.ads, xeinfo.adb, xnmake.adb, xref_lib.ads, xr_tabls.adb, xr_tabls.ads, xsinfo.adb, xtreeprs.adb, xsnames.adb, vms_conv.ads, vms_conv.adb, a-dirval.ads, a-dirval.adb, a-dirval-mingw.adb, a-direct.ads, a-direct.adb, indepsw.ads, prj-attr-pm.ads, system-linux-ppc.ads, a-numaux-darwin.ads, a-numaux-darwin.adb, a-swuwha.ads, a-stunha.ads: Minor reformatting From-SVN: r107016
2005-11-15 15:06:45 +01:00
-- Find the innermost body or block that encloses N
2001-10-02 16:23:52 +02:00
function Find_Enclosing_Body (N : Node_Id) return Node_Id;
a-secain.adb, [...]: Minor reformatting 2005-11-14 Robert Dewar <dewar@adacore.com> * a-secain.adb, a-slcain.adb, a-shcain.adb, a-chtgke.ads, a-chtgke.adb, a-stwiha.adb, a-strhas.adb, a-chzla1.ads, a-chzla9.ads, a-stzbou.adb, a-stzbou.ads, a-stzfix.adb, a-stzhas.adb, a-stzmap.adb, a-stzmap.ads, a-stzsea.adb, a-stzsea.ads, a-stzsup.adb, a-stzsup.ads, a-stzunb.adb, a-stzunb.ads, a-szuzha.adb, a-szuzha.ads, a-szuzti.adb, a-szuzti.ads, a-ztcoau.adb, a-ztcoau.ads, a-ztcoio.adb, a-ztcstr.adb, a-ztcstr.ads, a-ztdeau.adb, a-ztdeau.ads, a-ztdeio.adb, a-ztdeio.ads, a-ztedit.adb, a-ztedit.ads, a-ztenau.ads, a-ztenio.adb, a-ztenio.ads, a-ztexio.adb, a-ztexio.ads, a-ztfiio.adb, a-ztfiio.ads, a-ztflau.adb, a-ztflau.ads, a-ztflio.adb, a-ztflio.ads, a-ztgeau.adb, a-ztgeau.ads, a-ztinau.adb, a-ztinau.ads, a-ztinio.adb, a-ztmoau.ads, a-ztmoio.adb, a-ztmoio.ads, a-zttest.adb, g-enblsp-vms-alpha.adb, g-enblsp-vms-alpha.adb, g-enblsp-vms-ia64.adb, g-enblsp-vms-ia64.adb, system-linux-hppa.ads, a-chacon.adb, a-chacon.ads, a-wichun.adb, a-wichun.ads, a-zchuni.adb, a-zchuni.ads, g-trasym-vms-alpha.adb, g-trasym-vms-ia64.adb, system-hpux-ia64.ads, g-soccon-unixware.ads, g-soliop-unixware.ads, g-soccon-interix.ads, g-soliop-solaris.ads, g-eacodu-vms.adb, g-expect-vms.adb, g-socthi-vms.adb, g-soliop-mingw.ads, a-intnam-unixware.ads, a-intnam-lynxos.ads, a-intnam-tru64.ads, a-intnam-aix.ads, a-intnam-linux.ads, a-intnam-linux.ads, a-intnam-dummy.ads, a-numaux-libc-x86.ads, a-intnam-interix.ads, a-intnam-solaris.ads, a-calend-vms.adb, a-calend-vms.ads, a-intnam-vms.ads, a-calend-mingw.adb, a-intnam-mingw.ads, a-intnam-vxworks.ads, a-numaux-vxworks.ads, system-unixware.ads, system-linux-ia64.ads, a-intnam-freebsd.ads, system-freebsd-x86.ads, system-lynxos-ppc.ads, system-linux-x86_64.ads, a-stunha.adb, a-cgaaso.ads, a-cgaaso.adb, a-chtgop.adb, a-cgcaso.adb, a-cgarso.adb, a-cohata.ads, a-crbtgk.adb, a-crbltr.ads, a-coprnu.adb, a-rbtgso.adb, a-intnam-darwin.ads, system-darwin-ppc.ads, gprmake.adb, makegpr.ads, system-tru64.ads, system-aix.ads, system-solaris-x86.ads, system-irix-o32.ads, s-interr-sigaction.adb, system-irix-n32.ads, s-parame-mingw.adb, system-hpux.ads, s-traceb-hpux.adb, system-linux-x86.ads, s-inmaop-dummy.adb, system-os2.ads, system-interix.ads, system-solaris-sparc.ads, system-solaris-sparcv9.ads, s-inmaop-vms.adb, s-mastop-vms.adb, expander.adb, expander.ads, s-gloloc-mingw.adb, system-mingw.ads, system-vms-zcx.ads, s-osinte-fsu.adb, s-traceb-mastop.adb, a-exextr.adb, a-exstat.adb, a-filico.ads, a-finali.ads, a-interr.ads, a-intsig.adb, a-intsig.ads, a-except.ads, a-numaux-x86.ads, a-astaco.adb, a-calend.adb, a-calend.ads, a-chahan.adb, a-chahan.ads, a-chlat9.ads, a-colien.adb, a-colien.ads, a-colire.adb, a-colire.ads, a-comlin.adb, a-comlin.ads, a-cwila1.ads, a-cwila9.ads, a-elchha.adb, a-decima.adb, a-decima.ads, a-diocst.ads, a-direio.adb, a-direio.ads, a-excach.adb, a-excach.adb, a-exctra.ads, ali-util.adb, a-ngcefu.adb, a-ngcoty.adb, a-ngcoty.ads, a-nudira.adb, a-nudira.ads, a-nuflra.adb, a-numaux.ads, a-reatim.ads, a-sequio.adb, a-sequio.ads, a-siocst.ads, a-ssicst.ads, a-stmaco.ads, a-storio.adb, a-strbou.adb, a-strbou.ads, a-stream.ads, a-strfix.adb, a-strmap.adb, a-strmap.ads, a-strsea.adb, a-strsea.ads, a-strsup.adb, a-strsup.ads, a-strunb.adb, a-strunb.ads, a-stwibo.adb, a-stwibo.ads, a-stwifi.adb, a-stwima.adb, a-stwima.ads, a-stwise.adb, a-stwise.ads, a-stwisu.adb, a-stwisu.ads, a-stwiun.adb, a-stwiun.ads, a-suteio.adb, a-suteio.ads, a-swmwco.ads, a-swuwti.adb, a-swuwti.ads, a-sytaco.adb, a-sytaco.ads, a-tasatt.adb, a-taside.adb, a-taside.ads, a-teioed.adb, a-textio.adb, a-textio.ads, a-ticoau.adb, a-ticoau.ads, a-ticoio.adb, a-tideau.adb, a-tideio.adb, a-tienau.adb, a-tienio.adb, a-tifiio.adb, a-tiflio.adb, a-tigeau.adb, a-tigeau.ads, a-tiinau.adb, a-tiinio.adb, a-timoau.adb, a-timoio.adb, a-timoio.ads, a-tiocst.ads, a-titest.adb, atree.adb, a-witeio.adb, a-witeio.ads, a-wtcoau.adb, a-wtcoau.ads, a-wtcoio.adb, a-wtcstr.ads, a-wtdeau.adb, a-wtdeio.adb, a-wtedit.adb, a-wtedit.ads, a-wtenau.adb, a-wtenio.adb, a-wtfiio.adb, a-wtflio.adb, a-wtgeau.adb, a-wtinau.adb, a-wtinio.adb, a-wtmoau.adb, a-wtmoio.adb, a-wttest.adb, back_end.adb, bindgen.adb, butil.adb, butil.ads, checks.ads, cio.c, comperr.adb, csets.ads, cstand.adb, debug.ads, elists.ads, errno.c, errout.adb, errout.ads, erroutc.adb, erroutc.ads, errutil.adb, errutil.ads, errutil.ads, err_vars.ads, eval_fat.adb, exp_ch11.adb, exp_ch11.ads, exp_ch2.adb, exp_ch7.ads, exp_imgv.ads, exp_pakd.adb, exp_prag.adb, exp_prag.ads, exp_tss.adb, exp_tss.ads, exp_vfpt.ads, fe.h, fmap.adb, freeze.ads, frontend.adb, frontend.ads, g-arrspl.adb, g-arrspl.ads, g-awk.adb, g-awk.ads, g-boumai.ads, g-calend.adb, g-calend.ads, g-catiio.adb, g-comlin.adb, g-comlin.ads, g-comlin.ads, g-comlin.ads, g-comver.adb, g-crc32.adb, g-crc32.ads, g-ctrl_c.ads, g-curexc.ads, g-debpoo.ads, g-debuti.adb, g-diopit.adb, g-diopit.ads, g-dirope.adb, g-dirope.ads, g-dyntab.adb, g-dyntab.ads, g-excact.adb, g-excact.ads, g-except.ads, g-exctra.adb, g-exctra.ads, g-expect.ads, g-flocon.ads, g-hesorg.ads, g-io.adb, g-locfil.ads, g-md5.adb, g-md5.ads, g-md5.ads, g-moreex.adb, g-signal.ads, g-signal.adb, gnatbind.ads, gnatchop.adb, gnatcmd.adb, gnatfind.adb, gnatlbr.adb, gnatmake.ads, gnatmem.adb, gnatprep.adb, gnatprep.ads, gnatsym.adb, gnatxref.adb, g-os_lib.adb, g-os_lib.ads, g-pehage.adb, g-pehage.ads, gprep.ads, g-regexp.adb, g-regexp.ads, g-regist.adb, g-regist.ads, g-regpat.ads, g-semaph.adb, g-socthi.adb, g-soliop.ads, g-spipat.adb, g-spipat.ads, g-sptabo.ads, g-sptain.ads, g-sptavs.ads, g-string.ads, g-tasloc.adb, g-tasloc.ads, g-trasym.adb, g-trasym.ads, i-fortra.adb, i-fortra.ads, inline.adb, layout.adb, live.adb, make.ads, makeutl.ads, makeutl.adb, mdll-fil.adb, mdll-fil.ads, mdll-utl.ads, memroot.ads, memtrack.adb, mlib.ads, mlib-fil.adb, mlib-fil.ads, mlib-prj.ads, mlib-utl.adb, mlib-utl.ads, nlists.adb, nlists.ads, osint.adb, osint.ads, osint-c.adb, osint-l.adb, osint-l.ads, osint-m.ads, output.adb, par.adb, par.adb, par.ads, par-ch11.adb, par-ch12.adb, par-ch2.adb, par-ch4.adb, par-ch5.adb, par-ch6.adb, par-ch9.adb, par-endh.adb, par-labl.adb, par-load.adb, par-tchk.adb, prep.adb, prepcomp.adb, prepcomp.ads, prj-attr.ads, prj-com.ads, prj-dect.adb, prj-dect.ads, prj-env.ads, prj-err.ads, prj-ext.ads, prj-makr.adb, prj-makr.ads, prj-nmsc.ads, prj-pars.adb, prj-pars.ads, prj-part.ads, prj-pp.ads, prj-proc.ads, prj-strt.adb, prj-strt.ads, prj-tree.adb, prj-util.adb, prj-util.ads, rtsfind.adb, sem.adb, sem.ads, sem_case.adb, sem_case.ads, sem_ch11.adb, sem_ch4.adb, sem_ch6.ads, sem_ch7.ads, sem_dist.ads, sem_elab.ads, sem_elim.ads, sem_eval.ads, sem_intr.ads, sem_maps.adb, sem_maps.ads, sem_maps.ads, sem_res.ads, sem_type.ads, sfn_scan.adb, sfn_scan.ads, s-imgwch.ads, s-imgwiu.adb, s-imgwiu.ads, s-inmaop.ads, sinput.adb, sinput.ads, s-pack03.adb, s-pack03.ads, s-pack05.adb, s-pack05.ads, s-pack06.adb, s-pack06.ads, s-pack07.adb, s-pack07.ads, s-pack09.adb, s-pack09.ads, s-pack10.adb, s-pack10.ads, s-pack11.adb, s-pack11.ads, s-pack12.adb, s-pack12.ads, s-pack13.adb, s-pack13.ads, s-pack14.adb, s-pack14.ads, s-pack15.adb, s-pack15.ads, s-pack17.adb, s-pack17.ads, s-pack18.adb, s-pack18.ads, s-pack19.adb, s-pack19.ads, s-pack20.adb, s-pack20.ads, s-pack21.adb, s-pack21.ads, s-pack22.adb, s-pack22.ads, s-pack23.adb, s-pack23.ads, s-pack24.adb, s-pack24.ads, s-pack25.adb, s-pack25.ads, s-pack26.adb, s-pack26.ads, s-pack27.adb, s-pack27.ads, s-pack28.adb, s-pack28.ads, s-pack29.adb, s-pack29.ads, s-pack30.adb, s-pack30.ads, s-pack31.adb, s-pack31.ads, s-pack33.adb, s-pack33.ads, s-pack34.adb, s-pack34.ads, s-pack35.adb, s-pack35.ads, s-pack36.adb, s-pack36.ads, s-pack37.adb, s-pack37.ads, s-pack38.adb, s-pack38.ads, s-pack39.adb, s-pack39.ads, s-pack40.adb, s-pack40.ads, s-pack41.adb, s-pack41.ads, s-pack42.adb, s-pack42.ads, s-pack43.adb, s-pack43.ads, s-pack44.adb, s-pack44.ads, s-pack45.adb, s-pack45.ads, s-pack46.adb, s-pack46.ads, s-pack47.adb, s-pack47.ads, s-pack48.adb, s-pack48.ads, s-pack49.adb, s-pack49.ads, s-pack50.adb, s-pack50.ads, s-pack51.adb, s-pack51.ads, s-pack52.adb, s-pack52.ads, s-pack53.adb, s-pack53.ads, s-pack54.adb, s-pack54.ads, s-pack55.adb, s-pack55.ads, s-pack56.adb, s-pack56.ads, s-pack57.adb, s-pack57.ads, s-pack58.adb, s-pack58.ads, s-pack59.adb, s-pack59.ads, s-pack60.adb, s-pack60.adb, s-pack60.ads, s-pack61.adb, s-pack61.ads, s-pack62.adb, s-pack62.ads, s-pack63.adb, s-pack63.ads, s-parint.adb, s-parint.adb, s-parint.ads, sprint.ads, s-purexc.ads, s-restri.ads, s-restri.adb, s-scaval.adb, s-scaval.ads, s-secsta.adb, s-secsta.ads, s-sequio.adb, s-sequio.ads, stand.ads, s-tasuti.adb, s-traceb.adb, s-traceb.ads, stringt.adb, stringt.ads, styleg.ads, s-valboo.adb, s-valboo.ads, s-valcha.adb, s-valcha.ads, s-valdec.adb, s-valdec.ads, s-valint.adb, s-valint.ads, 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, s-valwch.ads, s-veboop.adb, s-veboop.ads, s-vercon.adb, s-vercon.ads, s-wchcnv.adb, s-wchcnv.ads, s-wchcon.ads, s-wchjis.adb, s-wchjis.ads, s-wchstw.adb, s-wchstw.adb, s-wchstw.ads, s-wchwts.adb, s-wchwts.ads, s-widboo.adb, s-widboo.ads, s-widcha.adb, s-widcha.ads, s-widenu.adb, s-widenu.ads, s-widlli.adb, s-widlli.ads, s-widllu.adb, s-widllu.ads, s-widwch.adb, s-widwch.ads, s-wwdcha.adb, s-wwdcha.ads, s-wwdenu.adb, s-wwdenu.ads, symbols.adb, symbols.ads, table.ads, targparm.adb, targparm.ads, tb-alvms.c, tb-alvxw.c, tbuild.adb, tree_io.ads, treepr.adb, treeprs.adt, ttypef.ads, ttypes.ads, types.adb, uintp.adb, uintp.ads, uname.ads, urealp.ads, usage.ads, validsw.ads, vxaddr2line.adb, widechar.adb, widechar.ads, xeinfo.adb, xnmake.adb, xref_lib.ads, xr_tabls.adb, xr_tabls.ads, xsinfo.adb, xtreeprs.adb, xsnames.adb, vms_conv.ads, vms_conv.adb, a-dirval.ads, a-dirval.adb, a-dirval-mingw.adb, a-direct.ads, a-direct.adb, indepsw.ads, prj-attr-pm.ads, system-linux-ppc.ads, a-numaux-darwin.ads, a-numaux-darwin.adb, a-swuwha.ads, a-stunha.ads: Minor reformatting From-SVN: r107016
2005-11-15 15:06:45 +01:00
-- Find the innermost body that encloses N
2001-10-02 16:23:52 +02:00
procedure Check_Distinct_Labels;
-- Checks the rule in RM-5.1(11), which requires distinct identifiers
-- for all the labels in a given body.
[multiple changes] 2004-07-15 Robert Dewar <dewar@gnat.com> * makegpr.adb, s-secsta.ads, sem_ch3.adb, sem_case.adb: Minor reformatting * gnat_ugn.texi: Add instantiation of direct_io or sequential_io with access values as an example of a warning. * gnat_rm.texi: Document new attribute Has_Access_Values * gnat-style.texi: Document that box comments belong on nested subprograms * sem_util.ads (Has_Access_Values): Improved documentation * s-finimp.ads, s-finimp.adb: Fix spelling error in comment * sem_prag.adb (Check_Duplicated_Export_Name): New procedure (Process_Interface_Name): Call to this new procedure (Set_Extended_Import_Export_External_Name): Call to this new procedure * s-mastop-x86.adb, 9drpc.adb: Fix spelling error in comment * a-direio.ads, a-sequio.ads: Warn if Element_Type has access values * einfo.ads: Minor comment typo fixed 2004-07-15 Jose Ruiz <ruiz@act-europe.fr> * snames.adb: Add _atcb. * snames.ads: Add Name_uATCB. * s-tarest.adb (Create_Restricted_Task): ATCBs are always preallocated (in the expanded code) when using the restricted run time. * s-tarest.ads (Create_Restricted_Task): Created_Task transformed into a in parameter in order to allow ATCBs to be preallocated (in the expanded code). * s-taskin.adb (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. In case of error, the ATCB is deallocated in System.Tasking.Stages. * s-taskin.ads (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. * s-tassta.adb (Create_Task): In case of error the ATCB is deallocated here. It was previously done in Initialize_ATCB. * rtsfind.ads: Make the Ada_Task_Control_Block visible. * exp_ch9.adb: Preallocate the Ada_Task_Control_Block when using the Restricted run time. * exp_ch3.adb: When using the Restricted run time, pass the preallocated Ada_Task_Control_Block when creating a task. 2004-07-15 Ed Schonberg <schonberg@gnat.com> * sem_util.adb (Normalize_Actuals): If there are no actuals on a function call that is itself an actual in an enclosing call, diagnose problem here rather than assuming that resolution will catch it. * sem_ch7.adb (Analyze_Package_Specification): If the specification is the local copy of a generic unit for a formal package, and the generic is a child unit, install private part of ancestors before compiling private part of spec. * sem_cat.adb (Validate_Categorization_Dependency): Simplify code to use scope entities rather than tree structures, to handle properly parent units that are instances rewritten as bodies for inlining purposes. * sem_ch10.adb (Get_Parent_Entity, Implicit_With_On_Parent, Remove_Parents): Handle properly a parent unit that is an instantiation, when the unit has been rewritten as a body for inlining purposes. * par.adb (Goto_List): Global variable to collect goto statements in a given unit, for use in detecting natural loops. * par-ch5.adb (P_Goto_Statement): Add goto to global Goto_List, for use in detecting natural loops. * par-labl.adb (Find_Natural_Loops): Recognize loops create by backwards goto's, and rewrite as a infinite loop, to improve locality of temporaries. * exp_util.adb (Force_Evaluation): Recognize a left-hand side subcomponent that includes an indexed reference, to prevent the generation of copies that would miscompile the desired assignment statement. (Build_Task_Image_Decls): Add a numeric suffix to generated name for string variable, to avoid spurious conflicts with the name of the type of a single protected object. * exp_ch4.adb (Expand_Array_Equality): If indices are distinct, use a loop with an explicit exit statement, to avoid generating an out-of-range value with 'Succ leading to spurious constraint_errors when compiling with -gnatVo. 2004-07-15 Thomas Quinot <quinot@act-europe.fr> * sem_ch4.adb (Analyze_Slice): Always call Analyze on the prefix: it might not be analyzed yet, even if its Etype is already set (case of an unchecked conversion built using Unchecked_Convert_To, for example). If the prefix has already been analyzed, this will be a nop anyway. * exp_ch5.adb (Make_Tag_Ctrl_Assignment): For an assignment of a controller type, or an assignment of a record type with controlled components, copy only user data, and leave the finalization chain pointers untouched. 2004-07-15 Vincent Celier <celier@gnat.com> * make.adb (Collect_Arguments): Improve error message when attempting to compile a source not part of any project, when -x is not used. * prj.ads: (Defined_Variable_Kind): New subtype * prj-attr.adb (Register_New_Package): Two new procedures to register a package with or without its attributes. (Register_New_Attribute): Mew procedure to register a new attribute in a package. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-attr.ads (Attribute_Node_Id): Now a private, self initialized type. (Package_Node_Id): Now a private, self initialized type (Register_New_Package): New procedure to register a package with its attributes. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-dect.adb (Parse_Attribute_Declaration, Parse_Package_Declaration): Adapt to new spec of Prj.Attr. * prj-makr.adb (Make): Parse existing project file before creating other files. Fail if there was an error during parsing. * prj-proc.adb (Add_Attributes, Process_Declarative_Items): Adapt to new spec of Prj.Attr. * prj-strt.adb (Attribute_Reference, Parse_Variable_Reference): Adapt to new spec of Prj.Attr. 2004-07-15 Richard Kenner <kenner@vlsi1.ultra.nyu.edu> * utils2.c: Fix typo in comment. From-SVN: r84774
2004-07-15 22:34:43 +02:00
procedure Find_Natural_Loops;
-- Recognizes loops created by backward gotos, and rewrites the
-- corresponding statements into a proper loop, for optimization
-- purposes (for example, to control reclaiming local storage).
2001-10-02 16:23:52 +02:00
---------------------------
-- Check_Distinct_Labels --
---------------------------
procedure Check_Distinct_Labels is
Label_Id : constant Node_Id := Identifier (Label_Node);
Enclosing_Body : constant Node_Id :=
Find_Enclosing_Body (Enclosing_Body_Or_Block);
-- Innermost enclosing body
Next_Other_Label_Elmt : Elmt_Id := First_Elmt (Label_List);
-- Next element on label element list
Other_Label : Node_Id;
-- Next label node to process
begin
-- Loop through all the labels, and if we find some other label
-- (i.e. not Label_Node) that has the same identifier,
-- and whose innermost enclosing body is the same,
-- then we have an error.
-- Note that in the worst case, this is quadratic in the number
-- of labels. However, labels are not all that common, and this
-- is only called for explicit labels.
2001-10-02 16:23:52 +02:00
-- ???Nonetheless, the efficiency could be improved. For example,
-- call Labl for each body, rather than once per compilation.
while Present (Next_Other_Label_Elmt) loop
Other_Label := Node (Next_Other_Label_Elmt);
exit when Label_Node = Other_Label;
if Chars (Label_Id) = Chars (Identifier (Other_Label))
and then Enclosing_Body = Find_Enclosing_Body (Other_Label)
then
Error_Msg_Sloc := Sloc (Other_Label);
Error_Msg_N ("& conflicts with label#", Label_Id);
exit;
end if;
Next_Elmt (Next_Other_Label_Elmt);
end loop;
end Check_Distinct_Labels;
-------------------------
-- Find_Enclosing_Body --
-------------------------
function Find_Enclosing_Body (N : Node_Id) return Node_Id is
Result : Node_Id := N;
begin
-- This is the same as Find_Enclosing_Body_Or_Block, except
-- that we skip block statements and accept statements, instead
-- of stopping at them.
while Present (Result)
and then Nkind (Result) /= N_Entry_Body
and then Nkind (Result) /= N_Task_Body
and then Nkind (Result) /= N_Package_Body
and then Nkind (Result) /= N_Subprogram_Body
loop
Result := Parent (Result);
end loop;
return Result;
end Find_Enclosing_Body;
----------------------------------
-- Find_Enclosing_Body_Or_Block --
----------------------------------
function Find_Enclosing_Body_Or_Block (N : Node_Id) return Node_Id is
Result : Node_Id := Parent (N);
begin
a-secain.adb, [...]: Minor reformatting 2005-11-14 Robert Dewar <dewar@adacore.com> * a-secain.adb, a-slcain.adb, a-shcain.adb, a-chtgke.ads, a-chtgke.adb, a-stwiha.adb, a-strhas.adb, a-chzla1.ads, a-chzla9.ads, a-stzbou.adb, a-stzbou.ads, a-stzfix.adb, a-stzhas.adb, a-stzmap.adb, a-stzmap.ads, a-stzsea.adb, a-stzsea.ads, a-stzsup.adb, a-stzsup.ads, a-stzunb.adb, a-stzunb.ads, a-szuzha.adb, a-szuzha.ads, a-szuzti.adb, a-szuzti.ads, a-ztcoau.adb, a-ztcoau.ads, a-ztcoio.adb, a-ztcstr.adb, a-ztcstr.ads, a-ztdeau.adb, a-ztdeau.ads, a-ztdeio.adb, a-ztdeio.ads, a-ztedit.adb, a-ztedit.ads, a-ztenau.ads, a-ztenio.adb, a-ztenio.ads, a-ztexio.adb, a-ztexio.ads, a-ztfiio.adb, a-ztfiio.ads, a-ztflau.adb, a-ztflau.ads, a-ztflio.adb, a-ztflio.ads, a-ztgeau.adb, a-ztgeau.ads, a-ztinau.adb, a-ztinau.ads, a-ztinio.adb, a-ztmoau.ads, a-ztmoio.adb, a-ztmoio.ads, a-zttest.adb, g-enblsp-vms-alpha.adb, g-enblsp-vms-alpha.adb, g-enblsp-vms-ia64.adb, g-enblsp-vms-ia64.adb, system-linux-hppa.ads, a-chacon.adb, a-chacon.ads, a-wichun.adb, a-wichun.ads, a-zchuni.adb, a-zchuni.ads, g-trasym-vms-alpha.adb, g-trasym-vms-ia64.adb, system-hpux-ia64.ads, g-soccon-unixware.ads, g-soliop-unixware.ads, g-soccon-interix.ads, g-soliop-solaris.ads, g-eacodu-vms.adb, g-expect-vms.adb, g-socthi-vms.adb, g-soliop-mingw.ads, a-intnam-unixware.ads, a-intnam-lynxos.ads, a-intnam-tru64.ads, a-intnam-aix.ads, a-intnam-linux.ads, a-intnam-linux.ads, a-intnam-dummy.ads, a-numaux-libc-x86.ads, a-intnam-interix.ads, a-intnam-solaris.ads, a-calend-vms.adb, a-calend-vms.ads, a-intnam-vms.ads, a-calend-mingw.adb, a-intnam-mingw.ads, a-intnam-vxworks.ads, a-numaux-vxworks.ads, system-unixware.ads, system-linux-ia64.ads, a-intnam-freebsd.ads, system-freebsd-x86.ads, system-lynxos-ppc.ads, system-linux-x86_64.ads, a-stunha.adb, a-cgaaso.ads, a-cgaaso.adb, a-chtgop.adb, a-cgcaso.adb, a-cgarso.adb, a-cohata.ads, a-crbtgk.adb, a-crbltr.ads, a-coprnu.adb, a-rbtgso.adb, a-intnam-darwin.ads, system-darwin-ppc.ads, gprmake.adb, makegpr.ads, system-tru64.ads, system-aix.ads, system-solaris-x86.ads, system-irix-o32.ads, s-interr-sigaction.adb, system-irix-n32.ads, s-parame-mingw.adb, system-hpux.ads, s-traceb-hpux.adb, system-linux-x86.ads, s-inmaop-dummy.adb, system-os2.ads, system-interix.ads, system-solaris-sparc.ads, system-solaris-sparcv9.ads, s-inmaop-vms.adb, s-mastop-vms.adb, expander.adb, expander.ads, s-gloloc-mingw.adb, system-mingw.ads, system-vms-zcx.ads, s-osinte-fsu.adb, s-traceb-mastop.adb, a-exextr.adb, a-exstat.adb, a-filico.ads, a-finali.ads, a-interr.ads, a-intsig.adb, a-intsig.ads, a-except.ads, a-numaux-x86.ads, a-astaco.adb, a-calend.adb, a-calend.ads, a-chahan.adb, a-chahan.ads, a-chlat9.ads, a-colien.adb, a-colien.ads, a-colire.adb, a-colire.ads, a-comlin.adb, a-comlin.ads, a-cwila1.ads, a-cwila9.ads, a-elchha.adb, a-decima.adb, a-decima.ads, a-diocst.ads, a-direio.adb, a-direio.ads, a-excach.adb, a-excach.adb, a-exctra.ads, ali-util.adb, a-ngcefu.adb, a-ngcoty.adb, a-ngcoty.ads, a-nudira.adb, a-nudira.ads, a-nuflra.adb, a-numaux.ads, a-reatim.ads, a-sequio.adb, a-sequio.ads, a-siocst.ads, a-ssicst.ads, a-stmaco.ads, a-storio.adb, a-strbou.adb, a-strbou.ads, a-stream.ads, a-strfix.adb, a-strmap.adb, a-strmap.ads, a-strsea.adb, a-strsea.ads, a-strsup.adb, a-strsup.ads, a-strunb.adb, a-strunb.ads, a-stwibo.adb, a-stwibo.ads, a-stwifi.adb, a-stwima.adb, a-stwima.ads, a-stwise.adb, a-stwise.ads, a-stwisu.adb, a-stwisu.ads, a-stwiun.adb, a-stwiun.ads, a-suteio.adb, a-suteio.ads, a-swmwco.ads, a-swuwti.adb, a-swuwti.ads, a-sytaco.adb, a-sytaco.ads, a-tasatt.adb, a-taside.adb, a-taside.ads, a-teioed.adb, a-textio.adb, a-textio.ads, a-ticoau.adb, a-ticoau.ads, a-ticoio.adb, a-tideau.adb, a-tideio.adb, a-tienau.adb, a-tienio.adb, a-tifiio.adb, a-tiflio.adb, a-tigeau.adb, a-tigeau.ads, a-tiinau.adb, a-tiinio.adb, a-timoau.adb, a-timoio.adb, a-timoio.ads, a-tiocst.ads, a-titest.adb, atree.adb, a-witeio.adb, a-witeio.ads, a-wtcoau.adb, a-wtcoau.ads, a-wtcoio.adb, a-wtcstr.ads, a-wtdeau.adb, a-wtdeio.adb, a-wtedit.adb, a-wtedit.ads, a-wtenau.adb, a-wtenio.adb, a-wtfiio.adb, a-wtflio.adb, a-wtgeau.adb, a-wtinau.adb, a-wtinio.adb, a-wtmoau.adb, a-wtmoio.adb, a-wttest.adb, back_end.adb, bindgen.adb, butil.adb, butil.ads, checks.ads, cio.c, comperr.adb, csets.ads, cstand.adb, debug.ads, elists.ads, errno.c, errout.adb, errout.ads, erroutc.adb, erroutc.ads, errutil.adb, errutil.ads, errutil.ads, err_vars.ads, eval_fat.adb, exp_ch11.adb, exp_ch11.ads, exp_ch2.adb, exp_ch7.ads, exp_imgv.ads, exp_pakd.adb, exp_prag.adb, exp_prag.ads, exp_tss.adb, exp_tss.ads, exp_vfpt.ads, fe.h, fmap.adb, freeze.ads, frontend.adb, frontend.ads, g-arrspl.adb, g-arrspl.ads, g-awk.adb, g-awk.ads, g-boumai.ads, g-calend.adb, g-calend.ads, g-catiio.adb, g-comlin.adb, g-comlin.ads, g-comlin.ads, g-comlin.ads, g-comver.adb, g-crc32.adb, g-crc32.ads, g-ctrl_c.ads, g-curexc.ads, g-debpoo.ads, g-debuti.adb, g-diopit.adb, g-diopit.ads, g-dirope.adb, g-dirope.ads, g-dyntab.adb, g-dyntab.ads, g-excact.adb, g-excact.ads, g-except.ads, g-exctra.adb, g-exctra.ads, g-expect.ads, g-flocon.ads, g-hesorg.ads, g-io.adb, g-locfil.ads, g-md5.adb, g-md5.ads, g-md5.ads, g-moreex.adb, g-signal.ads, g-signal.adb, gnatbind.ads, gnatchop.adb, gnatcmd.adb, gnatfind.adb, gnatlbr.adb, gnatmake.ads, gnatmem.adb, gnatprep.adb, gnatprep.ads, gnatsym.adb, gnatxref.adb, g-os_lib.adb, g-os_lib.ads, g-pehage.adb, g-pehage.ads, gprep.ads, g-regexp.adb, g-regexp.ads, g-regist.adb, g-regist.ads, g-regpat.ads, g-semaph.adb, g-socthi.adb, g-soliop.ads, g-spipat.adb, g-spipat.ads, g-sptabo.ads, g-sptain.ads, g-sptavs.ads, g-string.ads, g-tasloc.adb, g-tasloc.ads, g-trasym.adb, g-trasym.ads, i-fortra.adb, i-fortra.ads, inline.adb, layout.adb, live.adb, make.ads, makeutl.ads, makeutl.adb, mdll-fil.adb, mdll-fil.ads, mdll-utl.ads, memroot.ads, memtrack.adb, mlib.ads, mlib-fil.adb, mlib-fil.ads, mlib-prj.ads, mlib-utl.adb, mlib-utl.ads, nlists.adb, nlists.ads, osint.adb, osint.ads, osint-c.adb, osint-l.adb, osint-l.ads, osint-m.ads, output.adb, par.adb, par.adb, par.ads, par-ch11.adb, par-ch12.adb, par-ch2.adb, par-ch4.adb, par-ch5.adb, par-ch6.adb, par-ch9.adb, par-endh.adb, par-labl.adb, par-load.adb, par-tchk.adb, prep.adb, prepcomp.adb, prepcomp.ads, prj-attr.ads, prj-com.ads, prj-dect.adb, prj-dect.ads, prj-env.ads, prj-err.ads, prj-ext.ads, prj-makr.adb, prj-makr.ads, prj-nmsc.ads, prj-pars.adb, prj-pars.ads, prj-part.ads, prj-pp.ads, prj-proc.ads, prj-strt.adb, prj-strt.ads, prj-tree.adb, prj-util.adb, prj-util.ads, rtsfind.adb, sem.adb, sem.ads, sem_case.adb, sem_case.ads, sem_ch11.adb, sem_ch4.adb, sem_ch6.ads, sem_ch7.ads, sem_dist.ads, sem_elab.ads, sem_elim.ads, sem_eval.ads, sem_intr.ads, sem_maps.adb, sem_maps.ads, sem_maps.ads, sem_res.ads, sem_type.ads, sfn_scan.adb, sfn_scan.ads, s-imgwch.ads, s-imgwiu.adb, s-imgwiu.ads, s-inmaop.ads, sinput.adb, sinput.ads, s-pack03.adb, s-pack03.ads, s-pack05.adb, s-pack05.ads, s-pack06.adb, s-pack06.ads, s-pack07.adb, s-pack07.ads, s-pack09.adb, s-pack09.ads, s-pack10.adb, s-pack10.ads, s-pack11.adb, s-pack11.ads, s-pack12.adb, s-pack12.ads, s-pack13.adb, s-pack13.ads, s-pack14.adb, s-pack14.ads, s-pack15.adb, s-pack15.ads, s-pack17.adb, s-pack17.ads, s-pack18.adb, s-pack18.ads, s-pack19.adb, s-pack19.ads, s-pack20.adb, s-pack20.ads, s-pack21.adb, s-pack21.ads, s-pack22.adb, s-pack22.ads, s-pack23.adb, s-pack23.ads, s-pack24.adb, s-pack24.ads, s-pack25.adb, s-pack25.ads, s-pack26.adb, s-pack26.ads, s-pack27.adb, s-pack27.ads, s-pack28.adb, s-pack28.ads, s-pack29.adb, s-pack29.ads, s-pack30.adb, s-pack30.ads, s-pack31.adb, s-pack31.ads, s-pack33.adb, s-pack33.ads, s-pack34.adb, s-pack34.ads, s-pack35.adb, s-pack35.ads, s-pack36.adb, s-pack36.ads, s-pack37.adb, s-pack37.ads, s-pack38.adb, s-pack38.ads, s-pack39.adb, s-pack39.ads, s-pack40.adb, s-pack40.ads, s-pack41.adb, s-pack41.ads, s-pack42.adb, s-pack42.ads, s-pack43.adb, s-pack43.ads, s-pack44.adb, s-pack44.ads, s-pack45.adb, s-pack45.ads, s-pack46.adb, s-pack46.ads, s-pack47.adb, s-pack47.ads, s-pack48.adb, s-pack48.ads, s-pack49.adb, s-pack49.ads, s-pack50.adb, s-pack50.ads, s-pack51.adb, s-pack51.ads, s-pack52.adb, s-pack52.ads, s-pack53.adb, s-pack53.ads, s-pack54.adb, s-pack54.ads, s-pack55.adb, s-pack55.ads, s-pack56.adb, s-pack56.ads, s-pack57.adb, s-pack57.ads, s-pack58.adb, s-pack58.ads, s-pack59.adb, s-pack59.ads, s-pack60.adb, s-pack60.adb, s-pack60.ads, s-pack61.adb, s-pack61.ads, s-pack62.adb, s-pack62.ads, s-pack63.adb, s-pack63.ads, s-parint.adb, s-parint.adb, s-parint.ads, sprint.ads, s-purexc.ads, s-restri.ads, s-restri.adb, s-scaval.adb, s-scaval.ads, s-secsta.adb, s-secsta.ads, s-sequio.adb, s-sequio.ads, stand.ads, s-tasuti.adb, s-traceb.adb, s-traceb.ads, stringt.adb, stringt.ads, styleg.ads, s-valboo.adb, s-valboo.ads, s-valcha.adb, s-valcha.ads, s-valdec.adb, s-valdec.ads, s-valint.adb, s-valint.ads, 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, s-valwch.ads, s-veboop.adb, s-veboop.ads, s-vercon.adb, s-vercon.ads, s-wchcnv.adb, s-wchcnv.ads, s-wchcon.ads, s-wchjis.adb, s-wchjis.ads, s-wchstw.adb, s-wchstw.adb, s-wchstw.ads, s-wchwts.adb, s-wchwts.ads, s-widboo.adb, s-widboo.ads, s-widcha.adb, s-widcha.ads, s-widenu.adb, s-widenu.ads, s-widlli.adb, s-widlli.ads, s-widllu.adb, s-widllu.ads, s-widwch.adb, s-widwch.ads, s-wwdcha.adb, s-wwdcha.ads, s-wwdenu.adb, s-wwdenu.ads, symbols.adb, symbols.ads, table.ads, targparm.adb, targparm.ads, tb-alvms.c, tb-alvxw.c, tbuild.adb, tree_io.ads, treepr.adb, treeprs.adt, ttypef.ads, ttypes.ads, types.adb, uintp.adb, uintp.ads, uname.ads, urealp.ads, usage.ads, validsw.ads, vxaddr2line.adb, widechar.adb, widechar.ads, xeinfo.adb, xnmake.adb, xref_lib.ads, xr_tabls.adb, xr_tabls.ads, xsinfo.adb, xtreeprs.adb, xsnames.adb, vms_conv.ads, vms_conv.adb, a-dirval.ads, a-dirval.adb, a-dirval-mingw.adb, a-direct.ads, a-direct.adb, indepsw.ads, prj-attr-pm.ads, system-linux-ppc.ads, a-numaux-darwin.ads, a-numaux-darwin.adb, a-swuwha.ads, a-stunha.ads: Minor reformatting From-SVN: r107016
2005-11-15 15:06:45 +01:00
-- Climb up the parent chain until we find a body or block
2001-10-02 16:23:52 +02:00
while Present (Result)
and then Nkind (Result) /= N_Accept_Statement
and then Nkind (Result) /= N_Entry_Body
and then Nkind (Result) /= N_Task_Body
and then Nkind (Result) /= N_Package_Body
and then Nkind (Result) /= N_Subprogram_Body
and then Nkind (Result) /= N_Block_Statement
loop
Result := Parent (Result);
end loop;
return Result;
end Find_Enclosing_Body_Or_Block;
[multiple changes] 2004-07-15 Robert Dewar <dewar@gnat.com> * makegpr.adb, s-secsta.ads, sem_ch3.adb, sem_case.adb: Minor reformatting * gnat_ugn.texi: Add instantiation of direct_io or sequential_io with access values as an example of a warning. * gnat_rm.texi: Document new attribute Has_Access_Values * gnat-style.texi: Document that box comments belong on nested subprograms * sem_util.ads (Has_Access_Values): Improved documentation * s-finimp.ads, s-finimp.adb: Fix spelling error in comment * sem_prag.adb (Check_Duplicated_Export_Name): New procedure (Process_Interface_Name): Call to this new procedure (Set_Extended_Import_Export_External_Name): Call to this new procedure * s-mastop-x86.adb, 9drpc.adb: Fix spelling error in comment * a-direio.ads, a-sequio.ads: Warn if Element_Type has access values * einfo.ads: Minor comment typo fixed 2004-07-15 Jose Ruiz <ruiz@act-europe.fr> * snames.adb: Add _atcb. * snames.ads: Add Name_uATCB. * s-tarest.adb (Create_Restricted_Task): ATCBs are always preallocated (in the expanded code) when using the restricted run time. * s-tarest.ads (Create_Restricted_Task): Created_Task transformed into a in parameter in order to allow ATCBs to be preallocated (in the expanded code). * s-taskin.adb (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. In case of error, the ATCB is deallocated in System.Tasking.Stages. * s-taskin.ads (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. * s-tassta.adb (Create_Task): In case of error the ATCB is deallocated here. It was previously done in Initialize_ATCB. * rtsfind.ads: Make the Ada_Task_Control_Block visible. * exp_ch9.adb: Preallocate the Ada_Task_Control_Block when using the Restricted run time. * exp_ch3.adb: When using the Restricted run time, pass the preallocated Ada_Task_Control_Block when creating a task. 2004-07-15 Ed Schonberg <schonberg@gnat.com> * sem_util.adb (Normalize_Actuals): If there are no actuals on a function call that is itself an actual in an enclosing call, diagnose problem here rather than assuming that resolution will catch it. * sem_ch7.adb (Analyze_Package_Specification): If the specification is the local copy of a generic unit for a formal package, and the generic is a child unit, install private part of ancestors before compiling private part of spec. * sem_cat.adb (Validate_Categorization_Dependency): Simplify code to use scope entities rather than tree structures, to handle properly parent units that are instances rewritten as bodies for inlining purposes. * sem_ch10.adb (Get_Parent_Entity, Implicit_With_On_Parent, Remove_Parents): Handle properly a parent unit that is an instantiation, when the unit has been rewritten as a body for inlining purposes. * par.adb (Goto_List): Global variable to collect goto statements in a given unit, for use in detecting natural loops. * par-ch5.adb (P_Goto_Statement): Add goto to global Goto_List, for use in detecting natural loops. * par-labl.adb (Find_Natural_Loops): Recognize loops create by backwards goto's, and rewrite as a infinite loop, to improve locality of temporaries. * exp_util.adb (Force_Evaluation): Recognize a left-hand side subcomponent that includes an indexed reference, to prevent the generation of copies that would miscompile the desired assignment statement. (Build_Task_Image_Decls): Add a numeric suffix to generated name for string variable, to avoid spurious conflicts with the name of the type of a single protected object. * exp_ch4.adb (Expand_Array_Equality): If indices are distinct, use a loop with an explicit exit statement, to avoid generating an out-of-range value with 'Succ leading to spurious constraint_errors when compiling with -gnatVo. 2004-07-15 Thomas Quinot <quinot@act-europe.fr> * sem_ch4.adb (Analyze_Slice): Always call Analyze on the prefix: it might not be analyzed yet, even if its Etype is already set (case of an unchecked conversion built using Unchecked_Convert_To, for example). If the prefix has already been analyzed, this will be a nop anyway. * exp_ch5.adb (Make_Tag_Ctrl_Assignment): For an assignment of a controller type, or an assignment of a record type with controlled components, copy only user data, and leave the finalization chain pointers untouched. 2004-07-15 Vincent Celier <celier@gnat.com> * make.adb (Collect_Arguments): Improve error message when attempting to compile a source not part of any project, when -x is not used. * prj.ads: (Defined_Variable_Kind): New subtype * prj-attr.adb (Register_New_Package): Two new procedures to register a package with or without its attributes. (Register_New_Attribute): Mew procedure to register a new attribute in a package. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-attr.ads (Attribute_Node_Id): Now a private, self initialized type. (Package_Node_Id): Now a private, self initialized type (Register_New_Package): New procedure to register a package with its attributes. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-dect.adb (Parse_Attribute_Declaration, Parse_Package_Declaration): Adapt to new spec of Prj.Attr. * prj-makr.adb (Make): Parse existing project file before creating other files. Fail if there was an error during parsing. * prj-proc.adb (Add_Attributes, Process_Declarative_Items): Adapt to new spec of Prj.Attr. * prj-strt.adb (Attribute_Reference, Parse_Variable_Reference): Adapt to new spec of Prj.Attr. 2004-07-15 Richard Kenner <kenner@vlsi1.ultra.nyu.edu> * utils2.c: Fix typo in comment. From-SVN: r84774
2004-07-15 22:34:43 +02:00
------------------------
-- Find_Natural_Loops --
------------------------
procedure Find_Natural_Loops is
Node_List : constant Elist_Id := New_Elmt_List;
N : Elmt_Id;
Succ : Elmt_Id;
function Goto_Id (Goto_Node : Node_Id) return Name_Id;
a-secain.adb, [...]: Minor reformatting 2005-11-14 Robert Dewar <dewar@adacore.com> * a-secain.adb, a-slcain.adb, a-shcain.adb, a-chtgke.ads, a-chtgke.adb, a-stwiha.adb, a-strhas.adb, a-chzla1.ads, a-chzla9.ads, a-stzbou.adb, a-stzbou.ads, a-stzfix.adb, a-stzhas.adb, a-stzmap.adb, a-stzmap.ads, a-stzsea.adb, a-stzsea.ads, a-stzsup.adb, a-stzsup.ads, a-stzunb.adb, a-stzunb.ads, a-szuzha.adb, a-szuzha.ads, a-szuzti.adb, a-szuzti.ads, a-ztcoau.adb, a-ztcoau.ads, a-ztcoio.adb, a-ztcstr.adb, a-ztcstr.ads, a-ztdeau.adb, a-ztdeau.ads, a-ztdeio.adb, a-ztdeio.ads, a-ztedit.adb, a-ztedit.ads, a-ztenau.ads, a-ztenio.adb, a-ztenio.ads, a-ztexio.adb, a-ztexio.ads, a-ztfiio.adb, a-ztfiio.ads, a-ztflau.adb, a-ztflau.ads, a-ztflio.adb, a-ztflio.ads, a-ztgeau.adb, a-ztgeau.ads, a-ztinau.adb, a-ztinau.ads, a-ztinio.adb, a-ztmoau.ads, a-ztmoio.adb, a-ztmoio.ads, a-zttest.adb, g-enblsp-vms-alpha.adb, g-enblsp-vms-alpha.adb, g-enblsp-vms-ia64.adb, g-enblsp-vms-ia64.adb, system-linux-hppa.ads, a-chacon.adb, a-chacon.ads, a-wichun.adb, a-wichun.ads, a-zchuni.adb, a-zchuni.ads, g-trasym-vms-alpha.adb, g-trasym-vms-ia64.adb, system-hpux-ia64.ads, g-soccon-unixware.ads, g-soliop-unixware.ads, g-soccon-interix.ads, g-soliop-solaris.ads, g-eacodu-vms.adb, g-expect-vms.adb, g-socthi-vms.adb, g-soliop-mingw.ads, a-intnam-unixware.ads, a-intnam-lynxos.ads, a-intnam-tru64.ads, a-intnam-aix.ads, a-intnam-linux.ads, a-intnam-linux.ads, a-intnam-dummy.ads, a-numaux-libc-x86.ads, a-intnam-interix.ads, a-intnam-solaris.ads, a-calend-vms.adb, a-calend-vms.ads, a-intnam-vms.ads, a-calend-mingw.adb, a-intnam-mingw.ads, a-intnam-vxworks.ads, a-numaux-vxworks.ads, system-unixware.ads, system-linux-ia64.ads, a-intnam-freebsd.ads, system-freebsd-x86.ads, system-lynxos-ppc.ads, system-linux-x86_64.ads, a-stunha.adb, a-cgaaso.ads, a-cgaaso.adb, a-chtgop.adb, a-cgcaso.adb, a-cgarso.adb, a-cohata.ads, a-crbtgk.adb, a-crbltr.ads, a-coprnu.adb, a-rbtgso.adb, a-intnam-darwin.ads, system-darwin-ppc.ads, gprmake.adb, makegpr.ads, system-tru64.ads, system-aix.ads, system-solaris-x86.ads, system-irix-o32.ads, s-interr-sigaction.adb, system-irix-n32.ads, s-parame-mingw.adb, system-hpux.ads, s-traceb-hpux.adb, system-linux-x86.ads, s-inmaop-dummy.adb, system-os2.ads, system-interix.ads, system-solaris-sparc.ads, system-solaris-sparcv9.ads, s-inmaop-vms.adb, s-mastop-vms.adb, expander.adb, expander.ads, s-gloloc-mingw.adb, system-mingw.ads, system-vms-zcx.ads, s-osinte-fsu.adb, s-traceb-mastop.adb, a-exextr.adb, a-exstat.adb, a-filico.ads, a-finali.ads, a-interr.ads, a-intsig.adb, a-intsig.ads, a-except.ads, a-numaux-x86.ads, a-astaco.adb, a-calend.adb, a-calend.ads, a-chahan.adb, a-chahan.ads, a-chlat9.ads, a-colien.adb, a-colien.ads, a-colire.adb, a-colire.ads, a-comlin.adb, a-comlin.ads, a-cwila1.ads, a-cwila9.ads, a-elchha.adb, a-decima.adb, a-decima.ads, a-diocst.ads, a-direio.adb, a-direio.ads, a-excach.adb, a-excach.adb, a-exctra.ads, ali-util.adb, a-ngcefu.adb, a-ngcoty.adb, a-ngcoty.ads, a-nudira.adb, a-nudira.ads, a-nuflra.adb, a-numaux.ads, a-reatim.ads, a-sequio.adb, a-sequio.ads, a-siocst.ads, a-ssicst.ads, a-stmaco.ads, a-storio.adb, a-strbou.adb, a-strbou.ads, a-stream.ads, a-strfix.adb, a-strmap.adb, a-strmap.ads, a-strsea.adb, a-strsea.ads, a-strsup.adb, a-strsup.ads, a-strunb.adb, a-strunb.ads, a-stwibo.adb, a-stwibo.ads, a-stwifi.adb, a-stwima.adb, a-stwima.ads, a-stwise.adb, a-stwise.ads, a-stwisu.adb, a-stwisu.ads, a-stwiun.adb, a-stwiun.ads, a-suteio.adb, a-suteio.ads, a-swmwco.ads, a-swuwti.adb, a-swuwti.ads, a-sytaco.adb, a-sytaco.ads, a-tasatt.adb, a-taside.adb, a-taside.ads, a-teioed.adb, a-textio.adb, a-textio.ads, a-ticoau.adb, a-ticoau.ads, a-ticoio.adb, a-tideau.adb, a-tideio.adb, a-tienau.adb, a-tienio.adb, a-tifiio.adb, a-tiflio.adb, a-tigeau.adb, a-tigeau.ads, a-tiinau.adb, a-tiinio.adb, a-timoau.adb, a-timoio.adb, a-timoio.ads, a-tiocst.ads, a-titest.adb, atree.adb, a-witeio.adb, a-witeio.ads, a-wtcoau.adb, a-wtcoau.ads, a-wtcoio.adb, a-wtcstr.ads, a-wtdeau.adb, a-wtdeio.adb, a-wtedit.adb, a-wtedit.ads, a-wtenau.adb, a-wtenio.adb, a-wtfiio.adb, a-wtflio.adb, a-wtgeau.adb, a-wtinau.adb, a-wtinio.adb, a-wtmoau.adb, a-wtmoio.adb, a-wttest.adb, back_end.adb, bindgen.adb, butil.adb, butil.ads, checks.ads, cio.c, comperr.adb, csets.ads, cstand.adb, debug.ads, elists.ads, errno.c, errout.adb, errout.ads, erroutc.adb, erroutc.ads, errutil.adb, errutil.ads, errutil.ads, err_vars.ads, eval_fat.adb, exp_ch11.adb, exp_ch11.ads, exp_ch2.adb, exp_ch7.ads, exp_imgv.ads, exp_pakd.adb, exp_prag.adb, exp_prag.ads, exp_tss.adb, exp_tss.ads, exp_vfpt.ads, fe.h, fmap.adb, freeze.ads, frontend.adb, frontend.ads, g-arrspl.adb, g-arrspl.ads, g-awk.adb, g-awk.ads, g-boumai.ads, g-calend.adb, g-calend.ads, g-catiio.adb, g-comlin.adb, g-comlin.ads, g-comlin.ads, g-comlin.ads, g-comver.adb, g-crc32.adb, g-crc32.ads, g-ctrl_c.ads, g-curexc.ads, g-debpoo.ads, g-debuti.adb, g-diopit.adb, g-diopit.ads, g-dirope.adb, g-dirope.ads, g-dyntab.adb, g-dyntab.ads, g-excact.adb, g-excact.ads, g-except.ads, g-exctra.adb, g-exctra.ads, g-expect.ads, g-flocon.ads, g-hesorg.ads, g-io.adb, g-locfil.ads, g-md5.adb, g-md5.ads, g-md5.ads, g-moreex.adb, g-signal.ads, g-signal.adb, gnatbind.ads, gnatchop.adb, gnatcmd.adb, gnatfind.adb, gnatlbr.adb, gnatmake.ads, gnatmem.adb, gnatprep.adb, gnatprep.ads, gnatsym.adb, gnatxref.adb, g-os_lib.adb, g-os_lib.ads, g-pehage.adb, g-pehage.ads, gprep.ads, g-regexp.adb, g-regexp.ads, g-regist.adb, g-regist.ads, g-regpat.ads, g-semaph.adb, g-socthi.adb, g-soliop.ads, g-spipat.adb, g-spipat.ads, g-sptabo.ads, g-sptain.ads, g-sptavs.ads, g-string.ads, g-tasloc.adb, g-tasloc.ads, g-trasym.adb, g-trasym.ads, i-fortra.adb, i-fortra.ads, inline.adb, layout.adb, live.adb, make.ads, makeutl.ads, makeutl.adb, mdll-fil.adb, mdll-fil.ads, mdll-utl.ads, memroot.ads, memtrack.adb, mlib.ads, mlib-fil.adb, mlib-fil.ads, mlib-prj.ads, mlib-utl.adb, mlib-utl.ads, nlists.adb, nlists.ads, osint.adb, osint.ads, osint-c.adb, osint-l.adb, osint-l.ads, osint-m.ads, output.adb, par.adb, par.adb, par.ads, par-ch11.adb, par-ch12.adb, par-ch2.adb, par-ch4.adb, par-ch5.adb, par-ch6.adb, par-ch9.adb, par-endh.adb, par-labl.adb, par-load.adb, par-tchk.adb, prep.adb, prepcomp.adb, prepcomp.ads, prj-attr.ads, prj-com.ads, prj-dect.adb, prj-dect.ads, prj-env.ads, prj-err.ads, prj-ext.ads, prj-makr.adb, prj-makr.ads, prj-nmsc.ads, prj-pars.adb, prj-pars.ads, prj-part.ads, prj-pp.ads, prj-proc.ads, prj-strt.adb, prj-strt.ads, prj-tree.adb, prj-util.adb, prj-util.ads, rtsfind.adb, sem.adb, sem.ads, sem_case.adb, sem_case.ads, sem_ch11.adb, sem_ch4.adb, sem_ch6.ads, sem_ch7.ads, sem_dist.ads, sem_elab.ads, sem_elim.ads, sem_eval.ads, sem_intr.ads, sem_maps.adb, sem_maps.ads, sem_maps.ads, sem_res.ads, sem_type.ads, sfn_scan.adb, sfn_scan.ads, s-imgwch.ads, s-imgwiu.adb, s-imgwiu.ads, s-inmaop.ads, sinput.adb, sinput.ads, s-pack03.adb, s-pack03.ads, s-pack05.adb, s-pack05.ads, s-pack06.adb, s-pack06.ads, s-pack07.adb, s-pack07.ads, s-pack09.adb, s-pack09.ads, s-pack10.adb, s-pack10.ads, s-pack11.adb, s-pack11.ads, s-pack12.adb, s-pack12.ads, s-pack13.adb, s-pack13.ads, s-pack14.adb, s-pack14.ads, s-pack15.adb, s-pack15.ads, s-pack17.adb, s-pack17.ads, s-pack18.adb, s-pack18.ads, s-pack19.adb, s-pack19.ads, s-pack20.adb, s-pack20.ads, s-pack21.adb, s-pack21.ads, s-pack22.adb, s-pack22.ads, s-pack23.adb, s-pack23.ads, s-pack24.adb, s-pack24.ads, s-pack25.adb, s-pack25.ads, s-pack26.adb, s-pack26.ads, s-pack27.adb, s-pack27.ads, s-pack28.adb, s-pack28.ads, s-pack29.adb, s-pack29.ads, s-pack30.adb, s-pack30.ads, s-pack31.adb, s-pack31.ads, s-pack33.adb, s-pack33.ads, s-pack34.adb, s-pack34.ads, s-pack35.adb, s-pack35.ads, s-pack36.adb, s-pack36.ads, s-pack37.adb, s-pack37.ads, s-pack38.adb, s-pack38.ads, s-pack39.adb, s-pack39.ads, s-pack40.adb, s-pack40.ads, s-pack41.adb, s-pack41.ads, s-pack42.adb, s-pack42.ads, s-pack43.adb, s-pack43.ads, s-pack44.adb, s-pack44.ads, s-pack45.adb, s-pack45.ads, s-pack46.adb, s-pack46.ads, s-pack47.adb, s-pack47.ads, s-pack48.adb, s-pack48.ads, s-pack49.adb, s-pack49.ads, s-pack50.adb, s-pack50.ads, s-pack51.adb, s-pack51.ads, s-pack52.adb, s-pack52.ads, s-pack53.adb, s-pack53.ads, s-pack54.adb, s-pack54.ads, s-pack55.adb, s-pack55.ads, s-pack56.adb, s-pack56.ads, s-pack57.adb, s-pack57.ads, s-pack58.adb, s-pack58.ads, s-pack59.adb, s-pack59.ads, s-pack60.adb, s-pack60.adb, s-pack60.ads, s-pack61.adb, s-pack61.ads, s-pack62.adb, s-pack62.ads, s-pack63.adb, s-pack63.ads, s-parint.adb, s-parint.adb, s-parint.ads, sprint.ads, s-purexc.ads, s-restri.ads, s-restri.adb, s-scaval.adb, s-scaval.ads, s-secsta.adb, s-secsta.ads, s-sequio.adb, s-sequio.ads, stand.ads, s-tasuti.adb, s-traceb.adb, s-traceb.ads, stringt.adb, stringt.ads, styleg.ads, s-valboo.adb, s-valboo.ads, s-valcha.adb, s-valcha.ads, s-valdec.adb, s-valdec.ads, s-valint.adb, s-valint.ads, 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, s-valwch.ads, s-veboop.adb, s-veboop.ads, s-vercon.adb, s-vercon.ads, s-wchcnv.adb, s-wchcnv.ads, s-wchcon.ads, s-wchjis.adb, s-wchjis.ads, s-wchstw.adb, s-wchstw.adb, s-wchstw.ads, s-wchwts.adb, s-wchwts.ads, s-widboo.adb, s-widboo.ads, s-widcha.adb, s-widcha.ads, s-widenu.adb, s-widenu.ads, s-widlli.adb, s-widlli.ads, s-widllu.adb, s-widllu.ads, s-widwch.adb, s-widwch.ads, s-wwdcha.adb, s-wwdcha.ads, s-wwdenu.adb, s-wwdenu.ads, symbols.adb, symbols.ads, table.ads, targparm.adb, targparm.ads, tb-alvms.c, tb-alvxw.c, tbuild.adb, tree_io.ads, treepr.adb, treeprs.adt, ttypef.ads, ttypes.ads, types.adb, uintp.adb, uintp.ads, uname.ads, urealp.ads, usage.ads, validsw.ads, vxaddr2line.adb, widechar.adb, widechar.ads, xeinfo.adb, xnmake.adb, xref_lib.ads, xr_tabls.adb, xr_tabls.ads, xsinfo.adb, xtreeprs.adb, xsnames.adb, vms_conv.ads, vms_conv.adb, a-dirval.ads, a-dirval.adb, a-dirval-mingw.adb, a-direct.ads, a-direct.adb, indepsw.ads, prj-attr-pm.ads, system-linux-ppc.ads, a-numaux-darwin.ads, a-numaux-darwin.adb, a-swuwha.ads, a-stunha.ads: Minor reformatting From-SVN: r107016
2005-11-15 15:06:45 +01:00
-- Find Name_Id of goto statement, which may be an expanded name
[multiple changes] 2004-07-15 Robert Dewar <dewar@gnat.com> * makegpr.adb, s-secsta.ads, sem_ch3.adb, sem_case.adb: Minor reformatting * gnat_ugn.texi: Add instantiation of direct_io or sequential_io with access values as an example of a warning. * gnat_rm.texi: Document new attribute Has_Access_Values * gnat-style.texi: Document that box comments belong on nested subprograms * sem_util.ads (Has_Access_Values): Improved documentation * s-finimp.ads, s-finimp.adb: Fix spelling error in comment * sem_prag.adb (Check_Duplicated_Export_Name): New procedure (Process_Interface_Name): Call to this new procedure (Set_Extended_Import_Export_External_Name): Call to this new procedure * s-mastop-x86.adb, 9drpc.adb: Fix spelling error in comment * a-direio.ads, a-sequio.ads: Warn if Element_Type has access values * einfo.ads: Minor comment typo fixed 2004-07-15 Jose Ruiz <ruiz@act-europe.fr> * snames.adb: Add _atcb. * snames.ads: Add Name_uATCB. * s-tarest.adb (Create_Restricted_Task): ATCBs are always preallocated (in the expanded code) when using the restricted run time. * s-tarest.ads (Create_Restricted_Task): Created_Task transformed into a in parameter in order to allow ATCBs to be preallocated (in the expanded code). * s-taskin.adb (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. In case of error, the ATCB is deallocated in System.Tasking.Stages. * s-taskin.ads (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. * s-tassta.adb (Create_Task): In case of error the ATCB is deallocated here. It was previously done in Initialize_ATCB. * rtsfind.ads: Make the Ada_Task_Control_Block visible. * exp_ch9.adb: Preallocate the Ada_Task_Control_Block when using the Restricted run time. * exp_ch3.adb: When using the Restricted run time, pass the preallocated Ada_Task_Control_Block when creating a task. 2004-07-15 Ed Schonberg <schonberg@gnat.com> * sem_util.adb (Normalize_Actuals): If there are no actuals on a function call that is itself an actual in an enclosing call, diagnose problem here rather than assuming that resolution will catch it. * sem_ch7.adb (Analyze_Package_Specification): If the specification is the local copy of a generic unit for a formal package, and the generic is a child unit, install private part of ancestors before compiling private part of spec. * sem_cat.adb (Validate_Categorization_Dependency): Simplify code to use scope entities rather than tree structures, to handle properly parent units that are instances rewritten as bodies for inlining purposes. * sem_ch10.adb (Get_Parent_Entity, Implicit_With_On_Parent, Remove_Parents): Handle properly a parent unit that is an instantiation, when the unit has been rewritten as a body for inlining purposes. * par.adb (Goto_List): Global variable to collect goto statements in a given unit, for use in detecting natural loops. * par-ch5.adb (P_Goto_Statement): Add goto to global Goto_List, for use in detecting natural loops. * par-labl.adb (Find_Natural_Loops): Recognize loops create by backwards goto's, and rewrite as a infinite loop, to improve locality of temporaries. * exp_util.adb (Force_Evaluation): Recognize a left-hand side subcomponent that includes an indexed reference, to prevent the generation of copies that would miscompile the desired assignment statement. (Build_Task_Image_Decls): Add a numeric suffix to generated name for string variable, to avoid spurious conflicts with the name of the type of a single protected object. * exp_ch4.adb (Expand_Array_Equality): If indices are distinct, use a loop with an explicit exit statement, to avoid generating an out-of-range value with 'Succ leading to spurious constraint_errors when compiling with -gnatVo. 2004-07-15 Thomas Quinot <quinot@act-europe.fr> * sem_ch4.adb (Analyze_Slice): Always call Analyze on the prefix: it might not be analyzed yet, even if its Etype is already set (case of an unchecked conversion built using Unchecked_Convert_To, for example). If the prefix has already been analyzed, this will be a nop anyway. * exp_ch5.adb (Make_Tag_Ctrl_Assignment): For an assignment of a controller type, or an assignment of a record type with controlled components, copy only user data, and leave the finalization chain pointers untouched. 2004-07-15 Vincent Celier <celier@gnat.com> * make.adb (Collect_Arguments): Improve error message when attempting to compile a source not part of any project, when -x is not used. * prj.ads: (Defined_Variable_Kind): New subtype * prj-attr.adb (Register_New_Package): Two new procedures to register a package with or without its attributes. (Register_New_Attribute): Mew procedure to register a new attribute in a package. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-attr.ads (Attribute_Node_Id): Now a private, self initialized type. (Package_Node_Id): Now a private, self initialized type (Register_New_Package): New procedure to register a package with its attributes. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-dect.adb (Parse_Attribute_Declaration, Parse_Package_Declaration): Adapt to new spec of Prj.Attr. * prj-makr.adb (Make): Parse existing project file before creating other files. Fail if there was an error during parsing. * prj-proc.adb (Add_Attributes, Process_Declarative_Items): Adapt to new spec of Prj.Attr. * prj-strt.adb (Attribute_Reference, Parse_Variable_Reference): Adapt to new spec of Prj.Attr. 2004-07-15 Richard Kenner <kenner@vlsi1.ultra.nyu.edu> * utils2.c: Fix typo in comment. From-SVN: r84774
2004-07-15 22:34:43 +02:00
function Matches
(Label_Node : Node_Id;
Goto_Node : Node_Id) return Boolean;
-- A label and a goto are candidates for a loop if the names match,
-- and both nodes appear in the same body. In addition, both must
-- appear in the same statement list. If they are not in the same
-- statement list, the goto is from within an nested structure, and
-- the label is not a header. We ignore the case where the goto is
-- within a conditional structure, and capture only infinite loops.
procedure Merge;
-- Merge labels and goto statements in order of increasing sloc value.
-- Discard labels of loop and block statements.
procedure No_Header (N : Elmt_Id);
-- The label N is known not to be a loop header. Scan forward and
-- remove all subsequent gotos that may have this node as a target.
[multiple changes] 2004-07-15 Robert Dewar <dewar@gnat.com> * makegpr.adb, s-secsta.ads, sem_ch3.adb, sem_case.adb: Minor reformatting * gnat_ugn.texi: Add instantiation of direct_io or sequential_io with access values as an example of a warning. * gnat_rm.texi: Document new attribute Has_Access_Values * gnat-style.texi: Document that box comments belong on nested subprograms * sem_util.ads (Has_Access_Values): Improved documentation * s-finimp.ads, s-finimp.adb: Fix spelling error in comment * sem_prag.adb (Check_Duplicated_Export_Name): New procedure (Process_Interface_Name): Call to this new procedure (Set_Extended_Import_Export_External_Name): Call to this new procedure * s-mastop-x86.adb, 9drpc.adb: Fix spelling error in comment * a-direio.ads, a-sequio.ads: Warn if Element_Type has access values * einfo.ads: Minor comment typo fixed 2004-07-15 Jose Ruiz <ruiz@act-europe.fr> * snames.adb: Add _atcb. * snames.ads: Add Name_uATCB. * s-tarest.adb (Create_Restricted_Task): ATCBs are always preallocated (in the expanded code) when using the restricted run time. * s-tarest.ads (Create_Restricted_Task): Created_Task transformed into a in parameter in order to allow ATCBs to be preallocated (in the expanded code). * s-taskin.adb (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. In case of error, the ATCB is deallocated in System.Tasking.Stages. * s-taskin.ads (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. * s-tassta.adb (Create_Task): In case of error the ATCB is deallocated here. It was previously done in Initialize_ATCB. * rtsfind.ads: Make the Ada_Task_Control_Block visible. * exp_ch9.adb: Preallocate the Ada_Task_Control_Block when using the Restricted run time. * exp_ch3.adb: When using the Restricted run time, pass the preallocated Ada_Task_Control_Block when creating a task. 2004-07-15 Ed Schonberg <schonberg@gnat.com> * sem_util.adb (Normalize_Actuals): If there are no actuals on a function call that is itself an actual in an enclosing call, diagnose problem here rather than assuming that resolution will catch it. * sem_ch7.adb (Analyze_Package_Specification): If the specification is the local copy of a generic unit for a formal package, and the generic is a child unit, install private part of ancestors before compiling private part of spec. * sem_cat.adb (Validate_Categorization_Dependency): Simplify code to use scope entities rather than tree structures, to handle properly parent units that are instances rewritten as bodies for inlining purposes. * sem_ch10.adb (Get_Parent_Entity, Implicit_With_On_Parent, Remove_Parents): Handle properly a parent unit that is an instantiation, when the unit has been rewritten as a body for inlining purposes. * par.adb (Goto_List): Global variable to collect goto statements in a given unit, for use in detecting natural loops. * par-ch5.adb (P_Goto_Statement): Add goto to global Goto_List, for use in detecting natural loops. * par-labl.adb (Find_Natural_Loops): Recognize loops create by backwards goto's, and rewrite as a infinite loop, to improve locality of temporaries. * exp_util.adb (Force_Evaluation): Recognize a left-hand side subcomponent that includes an indexed reference, to prevent the generation of copies that would miscompile the desired assignment statement. (Build_Task_Image_Decls): Add a numeric suffix to generated name for string variable, to avoid spurious conflicts with the name of the type of a single protected object. * exp_ch4.adb (Expand_Array_Equality): If indices are distinct, use a loop with an explicit exit statement, to avoid generating an out-of-range value with 'Succ leading to spurious constraint_errors when compiling with -gnatVo. 2004-07-15 Thomas Quinot <quinot@act-europe.fr> * sem_ch4.adb (Analyze_Slice): Always call Analyze on the prefix: it might not be analyzed yet, even if its Etype is already set (case of an unchecked conversion built using Unchecked_Convert_To, for example). If the prefix has already been analyzed, this will be a nop anyway. * exp_ch5.adb (Make_Tag_Ctrl_Assignment): For an assignment of a controller type, or an assignment of a record type with controlled components, copy only user data, and leave the finalization chain pointers untouched. 2004-07-15 Vincent Celier <celier@gnat.com> * make.adb (Collect_Arguments): Improve error message when attempting to compile a source not part of any project, when -x is not used. * prj.ads: (Defined_Variable_Kind): New subtype * prj-attr.adb (Register_New_Package): Two new procedures to register a package with or without its attributes. (Register_New_Attribute): Mew procedure to register a new attribute in a package. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-attr.ads (Attribute_Node_Id): Now a private, self initialized type. (Package_Node_Id): Now a private, self initialized type (Register_New_Package): New procedure to register a package with its attributes. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-dect.adb (Parse_Attribute_Declaration, Parse_Package_Declaration): Adapt to new spec of Prj.Attr. * prj-makr.adb (Make): Parse existing project file before creating other files. Fail if there was an error during parsing. * prj-proc.adb (Add_Attributes, Process_Declarative_Items): Adapt to new spec of Prj.Attr. * prj-strt.adb (Attribute_Reference, Parse_Variable_Reference): Adapt to new spec of Prj.Attr. 2004-07-15 Richard Kenner <kenner@vlsi1.ultra.nyu.edu> * utils2.c: Fix typo in comment. From-SVN: r84774
2004-07-15 22:34:43 +02:00
procedure Process_Goto (N : Elmt_Id);
-- N is a forward jump. Scan forward and remove all subsequent gotos
[multiple changes] 2004-07-15 Robert Dewar <dewar@gnat.com> * makegpr.adb, s-secsta.ads, sem_ch3.adb, sem_case.adb: Minor reformatting * gnat_ugn.texi: Add instantiation of direct_io or sequential_io with access values as an example of a warning. * gnat_rm.texi: Document new attribute Has_Access_Values * gnat-style.texi: Document that box comments belong on nested subprograms * sem_util.ads (Has_Access_Values): Improved documentation * s-finimp.ads, s-finimp.adb: Fix spelling error in comment * sem_prag.adb (Check_Duplicated_Export_Name): New procedure (Process_Interface_Name): Call to this new procedure (Set_Extended_Import_Export_External_Name): Call to this new procedure * s-mastop-x86.adb, 9drpc.adb: Fix spelling error in comment * a-direio.ads, a-sequio.ads: Warn if Element_Type has access values * einfo.ads: Minor comment typo fixed 2004-07-15 Jose Ruiz <ruiz@act-europe.fr> * snames.adb: Add _atcb. * snames.ads: Add Name_uATCB. * s-tarest.adb (Create_Restricted_Task): ATCBs are always preallocated (in the expanded code) when using the restricted run time. * s-tarest.ads (Create_Restricted_Task): Created_Task transformed into a in parameter in order to allow ATCBs to be preallocated (in the expanded code). * s-taskin.adb (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. In case of error, the ATCB is deallocated in System.Tasking.Stages. * s-taskin.ads (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. * s-tassta.adb (Create_Task): In case of error the ATCB is deallocated here. It was previously done in Initialize_ATCB. * rtsfind.ads: Make the Ada_Task_Control_Block visible. * exp_ch9.adb: Preallocate the Ada_Task_Control_Block when using the Restricted run time. * exp_ch3.adb: When using the Restricted run time, pass the preallocated Ada_Task_Control_Block when creating a task. 2004-07-15 Ed Schonberg <schonberg@gnat.com> * sem_util.adb (Normalize_Actuals): If there are no actuals on a function call that is itself an actual in an enclosing call, diagnose problem here rather than assuming that resolution will catch it. * sem_ch7.adb (Analyze_Package_Specification): If the specification is the local copy of a generic unit for a formal package, and the generic is a child unit, install private part of ancestors before compiling private part of spec. * sem_cat.adb (Validate_Categorization_Dependency): Simplify code to use scope entities rather than tree structures, to handle properly parent units that are instances rewritten as bodies for inlining purposes. * sem_ch10.adb (Get_Parent_Entity, Implicit_With_On_Parent, Remove_Parents): Handle properly a parent unit that is an instantiation, when the unit has been rewritten as a body for inlining purposes. * par.adb (Goto_List): Global variable to collect goto statements in a given unit, for use in detecting natural loops. * par-ch5.adb (P_Goto_Statement): Add goto to global Goto_List, for use in detecting natural loops. * par-labl.adb (Find_Natural_Loops): Recognize loops create by backwards goto's, and rewrite as a infinite loop, to improve locality of temporaries. * exp_util.adb (Force_Evaluation): Recognize a left-hand side subcomponent that includes an indexed reference, to prevent the generation of copies that would miscompile the desired assignment statement. (Build_Task_Image_Decls): Add a numeric suffix to generated name for string variable, to avoid spurious conflicts with the name of the type of a single protected object. * exp_ch4.adb (Expand_Array_Equality): If indices are distinct, use a loop with an explicit exit statement, to avoid generating an out-of-range value with 'Succ leading to spurious constraint_errors when compiling with -gnatVo. 2004-07-15 Thomas Quinot <quinot@act-europe.fr> * sem_ch4.adb (Analyze_Slice): Always call Analyze on the prefix: it might not be analyzed yet, even if its Etype is already set (case of an unchecked conversion built using Unchecked_Convert_To, for example). If the prefix has already been analyzed, this will be a nop anyway. * exp_ch5.adb (Make_Tag_Ctrl_Assignment): For an assignment of a controller type, or an assignment of a record type with controlled components, copy only user data, and leave the finalization chain pointers untouched. 2004-07-15 Vincent Celier <celier@gnat.com> * make.adb (Collect_Arguments): Improve error message when attempting to compile a source not part of any project, when -x is not used. * prj.ads: (Defined_Variable_Kind): New subtype * prj-attr.adb (Register_New_Package): Two new procedures to register a package with or without its attributes. (Register_New_Attribute): Mew procedure to register a new attribute in a package. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-attr.ads (Attribute_Node_Id): Now a private, self initialized type. (Package_Node_Id): Now a private, self initialized type (Register_New_Package): New procedure to register a package with its attributes. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-dect.adb (Parse_Attribute_Declaration, Parse_Package_Declaration): Adapt to new spec of Prj.Attr. * prj-makr.adb (Make): Parse existing project file before creating other files. Fail if there was an error during parsing. * prj-proc.adb (Add_Attributes, Process_Declarative_Items): Adapt to new spec of Prj.Attr. * prj-strt.adb (Attribute_Reference, Parse_Variable_Reference): Adapt to new spec of Prj.Attr. 2004-07-15 Richard Kenner <kenner@vlsi1.ultra.nyu.edu> * utils2.c: Fix typo in comment. From-SVN: r84774
2004-07-15 22:34:43 +02:00
-- that may have the same target, to preclude spurious loops.
procedure Rewrite_As_Loop
(Loop_Header : Node_Id;
Loop_End : Node_Id);
-- Given a label and a backwards goto, rewrite intervening statements
-- as a loop. Remove the label from the node list, and rewrite the
-- goto with the body of the new loop.
procedure Try_Loop (N : Elmt_Id);
-- N is a label that may be a loop header. Scan forward to find some
-- backwards goto with which to make a loop. Do nothing if there is
-- an intervening label that is not part of a loop, or more than one
-- goto with this target.
-------------
-- Goto_Id --
-------------
function Goto_Id (Goto_Node : Node_Id) return Name_Id is
begin
if Nkind (Name (Goto_Node)) = N_Identifier then
return Chars (Name (Goto_Node));
elsif Nkind (Name (Goto_Node)) = N_Selected_Component then
return Chars (Selector_Name (Name (Goto_Node)));
else
-- In case of error, return Id that can't match anything
return Name_Null;
end if;
end Goto_Id;
-------------
-- Matches --
-------------
function Matches
(Label_Node : Node_Id;
Goto_Node : Node_Id) return Boolean
is
begin
return Chars (Identifier (Label_Node)) = Goto_Id (Goto_Node)
and then Find_Enclosing_Body (Label_Node) =
Find_Enclosing_Body (Goto_Node);
end Matches;
-----------
-- Merge --
-----------
procedure Merge is
L1 : Elmt_Id;
G1 : Elmt_Id;
begin
L1 := First_Elmt (Label_List);
G1 := First_Elmt (Goto_List);
while Present (L1)
and then Present (G1)
loop
if Sloc (Node (L1)) < Sloc (Node (G1)) then
-- Optimization: remove labels of loops and blocks, which
-- play no role in what follows.
if Nkind (Node (L1)) /= N_Loop_Statement
and then Nkind (Node (L1)) /= N_Block_Statement
then
Append_Elmt (Node (L1), Node_List);
end if;
Next_Elmt (L1);
else
Append_Elmt (Node (G1), Node_List);
Next_Elmt (G1);
end if;
end loop;
while Present (L1) loop
Append_Elmt (Node (L1), Node_List);
Next_Elmt (L1);
end loop;
while Present (G1) loop
Append_Elmt (Node (G1), Node_List);
Next_Elmt (G1);
end loop;
end Merge;
---------------
-- No_Header --
---------------
procedure No_Header (N : Elmt_Id) is
S1, S2 : Elmt_Id;
begin
S1 := Next_Elmt (N);
while Present (S1) loop
S2 := Next_Elmt (S1);
if Nkind (Node (S1)) = N_Goto_Statement
and then Matches (Node (N), Node (S1))
then
Remove_Elmt (Node_List, S1);
end if;
S1 := S2;
end loop;
end No_Header;
------------------
-- Process_Goto --
------------------
procedure Process_Goto (N : Elmt_Id) is
Goto1 : constant Node_Id := Node (N);
Goto2 : Node_Id;
S, S1 : Elmt_Id;
begin
S := Next_Elmt (N);
while Present (S) loop
S1 := Next_Elmt (S);
Goto2 := Node (S);
if Nkind (Goto2) = N_Goto_Statement
and then Goto_Id (Goto1) = Goto_Id (Goto2)
and then Find_Enclosing_Body (Goto1) =
Find_Enclosing_Body (Goto2)
then
-- Goto2 may have the same target, remove it from
-- consideration.
Remove_Elmt (Node_List, S);
end if;
S := S1;
end loop;
end Process_Goto;
---------------------
-- Rewrite_As_Loop --
---------------------
procedure Rewrite_As_Loop
(Loop_Header : Node_Id;
Loop_End : Node_Id)
is
Loop_Body : constant List_Id := New_List;
Loop_Stmt : constant Node_Id :=
New_Node (N_Loop_Statement, Sloc (Loop_Header));
Stat : Node_Id;
Next_Stat : Node_Id;
[multiple changes] 2004-07-15 Robert Dewar <dewar@gnat.com> * makegpr.adb, s-secsta.ads, sem_ch3.adb, sem_case.adb: Minor reformatting * gnat_ugn.texi: Add instantiation of direct_io or sequential_io with access values as an example of a warning. * gnat_rm.texi: Document new attribute Has_Access_Values * gnat-style.texi: Document that box comments belong on nested subprograms * sem_util.ads (Has_Access_Values): Improved documentation * s-finimp.ads, s-finimp.adb: Fix spelling error in comment * sem_prag.adb (Check_Duplicated_Export_Name): New procedure (Process_Interface_Name): Call to this new procedure (Set_Extended_Import_Export_External_Name): Call to this new procedure * s-mastop-x86.adb, 9drpc.adb: Fix spelling error in comment * a-direio.ads, a-sequio.ads: Warn if Element_Type has access values * einfo.ads: Minor comment typo fixed 2004-07-15 Jose Ruiz <ruiz@act-europe.fr> * snames.adb: Add _atcb. * snames.ads: Add Name_uATCB. * s-tarest.adb (Create_Restricted_Task): ATCBs are always preallocated (in the expanded code) when using the restricted run time. * s-tarest.ads (Create_Restricted_Task): Created_Task transformed into a in parameter in order to allow ATCBs to be preallocated (in the expanded code). * s-taskin.adb (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. In case of error, the ATCB is deallocated in System.Tasking.Stages. * s-taskin.ads (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. * s-tassta.adb (Create_Task): In case of error the ATCB is deallocated here. It was previously done in Initialize_ATCB. * rtsfind.ads: Make the Ada_Task_Control_Block visible. * exp_ch9.adb: Preallocate the Ada_Task_Control_Block when using the Restricted run time. * exp_ch3.adb: When using the Restricted run time, pass the preallocated Ada_Task_Control_Block when creating a task. 2004-07-15 Ed Schonberg <schonberg@gnat.com> * sem_util.adb (Normalize_Actuals): If there are no actuals on a function call that is itself an actual in an enclosing call, diagnose problem here rather than assuming that resolution will catch it. * sem_ch7.adb (Analyze_Package_Specification): If the specification is the local copy of a generic unit for a formal package, and the generic is a child unit, install private part of ancestors before compiling private part of spec. * sem_cat.adb (Validate_Categorization_Dependency): Simplify code to use scope entities rather than tree structures, to handle properly parent units that are instances rewritten as bodies for inlining purposes. * sem_ch10.adb (Get_Parent_Entity, Implicit_With_On_Parent, Remove_Parents): Handle properly a parent unit that is an instantiation, when the unit has been rewritten as a body for inlining purposes. * par.adb (Goto_List): Global variable to collect goto statements in a given unit, for use in detecting natural loops. * par-ch5.adb (P_Goto_Statement): Add goto to global Goto_List, for use in detecting natural loops. * par-labl.adb (Find_Natural_Loops): Recognize loops create by backwards goto's, and rewrite as a infinite loop, to improve locality of temporaries. * exp_util.adb (Force_Evaluation): Recognize a left-hand side subcomponent that includes an indexed reference, to prevent the generation of copies that would miscompile the desired assignment statement. (Build_Task_Image_Decls): Add a numeric suffix to generated name for string variable, to avoid spurious conflicts with the name of the type of a single protected object. * exp_ch4.adb (Expand_Array_Equality): If indices are distinct, use a loop with an explicit exit statement, to avoid generating an out-of-range value with 'Succ leading to spurious constraint_errors when compiling with -gnatVo. 2004-07-15 Thomas Quinot <quinot@act-europe.fr> * sem_ch4.adb (Analyze_Slice): Always call Analyze on the prefix: it might not be analyzed yet, even if its Etype is already set (case of an unchecked conversion built using Unchecked_Convert_To, for example). If the prefix has already been analyzed, this will be a nop anyway. * exp_ch5.adb (Make_Tag_Ctrl_Assignment): For an assignment of a controller type, or an assignment of a record type with controlled components, copy only user data, and leave the finalization chain pointers untouched. 2004-07-15 Vincent Celier <celier@gnat.com> * make.adb (Collect_Arguments): Improve error message when attempting to compile a source not part of any project, when -x is not used. * prj.ads: (Defined_Variable_Kind): New subtype * prj-attr.adb (Register_New_Package): Two new procedures to register a package with or without its attributes. (Register_New_Attribute): Mew procedure to register a new attribute in a package. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-attr.ads (Attribute_Node_Id): Now a private, self initialized type. (Package_Node_Id): Now a private, self initialized type (Register_New_Package): New procedure to register a package with its attributes. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-dect.adb (Parse_Attribute_Declaration, Parse_Package_Declaration): Adapt to new spec of Prj.Attr. * prj-makr.adb (Make): Parse existing project file before creating other files. Fail if there was an error during parsing. * prj-proc.adb (Add_Attributes, Process_Declarative_Items): Adapt to new spec of Prj.Attr. * prj-strt.adb (Attribute_Reference, Parse_Variable_Reference): Adapt to new spec of Prj.Attr. 2004-07-15 Richard Kenner <kenner@vlsi1.ultra.nyu.edu> * utils2.c: Fix typo in comment. From-SVN: r84774
2004-07-15 22:34:43 +02:00
begin
Stat := Next (Loop_Header);
while Stat /= Loop_End loop
Next_Stat := Next (Stat);
Remove (Stat);
Append (Stat, Loop_Body);
Stat := Next_Stat;
end loop;
Set_Statements (Loop_Stmt, Loop_Body);
Set_Identifier (Loop_Stmt, Identifier (Loop_Header));
Remove (Loop_Header);
Rewrite (Loop_End, Loop_Stmt);
Error_Msg_N
("info: code between label and backwards goto rewritten as loop??",
[multiple changes] 2004-07-15 Robert Dewar <dewar@gnat.com> * makegpr.adb, s-secsta.ads, sem_ch3.adb, sem_case.adb: Minor reformatting * gnat_ugn.texi: Add instantiation of direct_io or sequential_io with access values as an example of a warning. * gnat_rm.texi: Document new attribute Has_Access_Values * gnat-style.texi: Document that box comments belong on nested subprograms * sem_util.ads (Has_Access_Values): Improved documentation * s-finimp.ads, s-finimp.adb: Fix spelling error in comment * sem_prag.adb (Check_Duplicated_Export_Name): New procedure (Process_Interface_Name): Call to this new procedure (Set_Extended_Import_Export_External_Name): Call to this new procedure * s-mastop-x86.adb, 9drpc.adb: Fix spelling error in comment * a-direio.ads, a-sequio.ads: Warn if Element_Type has access values * einfo.ads: Minor comment typo fixed 2004-07-15 Jose Ruiz <ruiz@act-europe.fr> * snames.adb: Add _atcb. * snames.ads: Add Name_uATCB. * s-tarest.adb (Create_Restricted_Task): ATCBs are always preallocated (in the expanded code) when using the restricted run time. * s-tarest.ads (Create_Restricted_Task): Created_Task transformed into a in parameter in order to allow ATCBs to be preallocated (in the expanded code). * s-taskin.adb (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. In case of error, the ATCB is deallocated in System.Tasking.Stages. * s-taskin.ads (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. * s-tassta.adb (Create_Task): In case of error the ATCB is deallocated here. It was previously done in Initialize_ATCB. * rtsfind.ads: Make the Ada_Task_Control_Block visible. * exp_ch9.adb: Preallocate the Ada_Task_Control_Block when using the Restricted run time. * exp_ch3.adb: When using the Restricted run time, pass the preallocated Ada_Task_Control_Block when creating a task. 2004-07-15 Ed Schonberg <schonberg@gnat.com> * sem_util.adb (Normalize_Actuals): If there are no actuals on a function call that is itself an actual in an enclosing call, diagnose problem here rather than assuming that resolution will catch it. * sem_ch7.adb (Analyze_Package_Specification): If the specification is the local copy of a generic unit for a formal package, and the generic is a child unit, install private part of ancestors before compiling private part of spec. * sem_cat.adb (Validate_Categorization_Dependency): Simplify code to use scope entities rather than tree structures, to handle properly parent units that are instances rewritten as bodies for inlining purposes. * sem_ch10.adb (Get_Parent_Entity, Implicit_With_On_Parent, Remove_Parents): Handle properly a parent unit that is an instantiation, when the unit has been rewritten as a body for inlining purposes. * par.adb (Goto_List): Global variable to collect goto statements in a given unit, for use in detecting natural loops. * par-ch5.adb (P_Goto_Statement): Add goto to global Goto_List, for use in detecting natural loops. * par-labl.adb (Find_Natural_Loops): Recognize loops create by backwards goto's, and rewrite as a infinite loop, to improve locality of temporaries. * exp_util.adb (Force_Evaluation): Recognize a left-hand side subcomponent that includes an indexed reference, to prevent the generation of copies that would miscompile the desired assignment statement. (Build_Task_Image_Decls): Add a numeric suffix to generated name for string variable, to avoid spurious conflicts with the name of the type of a single protected object. * exp_ch4.adb (Expand_Array_Equality): If indices are distinct, use a loop with an explicit exit statement, to avoid generating an out-of-range value with 'Succ leading to spurious constraint_errors when compiling with -gnatVo. 2004-07-15 Thomas Quinot <quinot@act-europe.fr> * sem_ch4.adb (Analyze_Slice): Always call Analyze on the prefix: it might not be analyzed yet, even if its Etype is already set (case of an unchecked conversion built using Unchecked_Convert_To, for example). If the prefix has already been analyzed, this will be a nop anyway. * exp_ch5.adb (Make_Tag_Ctrl_Assignment): For an assignment of a controller type, or an assignment of a record type with controlled components, copy only user data, and leave the finalization chain pointers untouched. 2004-07-15 Vincent Celier <celier@gnat.com> * make.adb (Collect_Arguments): Improve error message when attempting to compile a source not part of any project, when -x is not used. * prj.ads: (Defined_Variable_Kind): New subtype * prj-attr.adb (Register_New_Package): Two new procedures to register a package with or without its attributes. (Register_New_Attribute): Mew procedure to register a new attribute in a package. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-attr.ads (Attribute_Node_Id): Now a private, self initialized type. (Package_Node_Id): Now a private, self initialized type (Register_New_Package): New procedure to register a package with its attributes. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-dect.adb (Parse_Attribute_Declaration, Parse_Package_Declaration): Adapt to new spec of Prj.Attr. * prj-makr.adb (Make): Parse existing project file before creating other files. Fail if there was an error during parsing. * prj-proc.adb (Add_Attributes, Process_Declarative_Items): Adapt to new spec of Prj.Attr. * prj-strt.adb (Attribute_Reference, Parse_Variable_Reference): Adapt to new spec of Prj.Attr. 2004-07-15 Richard Kenner <kenner@vlsi1.ultra.nyu.edu> * utils2.c: Fix typo in comment. From-SVN: r84774
2004-07-15 22:34:43 +02:00
Loop_End);
end Rewrite_As_Loop;
--------------
-- Try_Loop --
--------------
procedure Try_Loop (N : Elmt_Id) is
Source : Elmt_Id;
Found : Boolean := False;
S1 : Elmt_Id;
begin
S1 := Next_Elmt (N);
while Present (S1) loop
if Nkind (Node (S1)) = N_Goto_Statement
and then Matches (Node (N), Node (S1))
then
if not Found then
-- If the label and the goto are both in the same statement
-- list, then we've found a loop. Note that labels and goto
-- statements are always part of some list, so In_Same_List
-- always makes sense.
if In_Same_List (Node (N), Node (S1)) then
[multiple changes] 2004-07-15 Robert Dewar <dewar@gnat.com> * makegpr.adb, s-secsta.ads, sem_ch3.adb, sem_case.adb: Minor reformatting * gnat_ugn.texi: Add instantiation of direct_io or sequential_io with access values as an example of a warning. * gnat_rm.texi: Document new attribute Has_Access_Values * gnat-style.texi: Document that box comments belong on nested subprograms * sem_util.ads (Has_Access_Values): Improved documentation * s-finimp.ads, s-finimp.adb: Fix spelling error in comment * sem_prag.adb (Check_Duplicated_Export_Name): New procedure (Process_Interface_Name): Call to this new procedure (Set_Extended_Import_Export_External_Name): Call to this new procedure * s-mastop-x86.adb, 9drpc.adb: Fix spelling error in comment * a-direio.ads, a-sequio.ads: Warn if Element_Type has access values * einfo.ads: Minor comment typo fixed 2004-07-15 Jose Ruiz <ruiz@act-europe.fr> * snames.adb: Add _atcb. * snames.ads: Add Name_uATCB. * s-tarest.adb (Create_Restricted_Task): ATCBs are always preallocated (in the expanded code) when using the restricted run time. * s-tarest.ads (Create_Restricted_Task): Created_Task transformed into a in parameter in order to allow ATCBs to be preallocated (in the expanded code). * s-taskin.adb (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. In case of error, the ATCB is deallocated in System.Tasking.Stages. * s-taskin.ads (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. * s-tassta.adb (Create_Task): In case of error the ATCB is deallocated here. It was previously done in Initialize_ATCB. * rtsfind.ads: Make the Ada_Task_Control_Block visible. * exp_ch9.adb: Preallocate the Ada_Task_Control_Block when using the Restricted run time. * exp_ch3.adb: When using the Restricted run time, pass the preallocated Ada_Task_Control_Block when creating a task. 2004-07-15 Ed Schonberg <schonberg@gnat.com> * sem_util.adb (Normalize_Actuals): If there are no actuals on a function call that is itself an actual in an enclosing call, diagnose problem here rather than assuming that resolution will catch it. * sem_ch7.adb (Analyze_Package_Specification): If the specification is the local copy of a generic unit for a formal package, and the generic is a child unit, install private part of ancestors before compiling private part of spec. * sem_cat.adb (Validate_Categorization_Dependency): Simplify code to use scope entities rather than tree structures, to handle properly parent units that are instances rewritten as bodies for inlining purposes. * sem_ch10.adb (Get_Parent_Entity, Implicit_With_On_Parent, Remove_Parents): Handle properly a parent unit that is an instantiation, when the unit has been rewritten as a body for inlining purposes. * par.adb (Goto_List): Global variable to collect goto statements in a given unit, for use in detecting natural loops. * par-ch5.adb (P_Goto_Statement): Add goto to global Goto_List, for use in detecting natural loops. * par-labl.adb (Find_Natural_Loops): Recognize loops create by backwards goto's, and rewrite as a infinite loop, to improve locality of temporaries. * exp_util.adb (Force_Evaluation): Recognize a left-hand side subcomponent that includes an indexed reference, to prevent the generation of copies that would miscompile the desired assignment statement. (Build_Task_Image_Decls): Add a numeric suffix to generated name for string variable, to avoid spurious conflicts with the name of the type of a single protected object. * exp_ch4.adb (Expand_Array_Equality): If indices are distinct, use a loop with an explicit exit statement, to avoid generating an out-of-range value with 'Succ leading to spurious constraint_errors when compiling with -gnatVo. 2004-07-15 Thomas Quinot <quinot@act-europe.fr> * sem_ch4.adb (Analyze_Slice): Always call Analyze on the prefix: it might not be analyzed yet, even if its Etype is already set (case of an unchecked conversion built using Unchecked_Convert_To, for example). If the prefix has already been analyzed, this will be a nop anyway. * exp_ch5.adb (Make_Tag_Ctrl_Assignment): For an assignment of a controller type, or an assignment of a record type with controlled components, copy only user data, and leave the finalization chain pointers untouched. 2004-07-15 Vincent Celier <celier@gnat.com> * make.adb (Collect_Arguments): Improve error message when attempting to compile a source not part of any project, when -x is not used. * prj.ads: (Defined_Variable_Kind): New subtype * prj-attr.adb (Register_New_Package): Two new procedures to register a package with or without its attributes. (Register_New_Attribute): Mew procedure to register a new attribute in a package. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-attr.ads (Attribute_Node_Id): Now a private, self initialized type. (Package_Node_Id): Now a private, self initialized type (Register_New_Package): New procedure to register a package with its attributes. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-dect.adb (Parse_Attribute_Declaration, Parse_Package_Declaration): Adapt to new spec of Prj.Attr. * prj-makr.adb (Make): Parse existing project file before creating other files. Fail if there was an error during parsing. * prj-proc.adb (Add_Attributes, Process_Declarative_Items): Adapt to new spec of Prj.Attr. * prj-strt.adb (Attribute_Reference, Parse_Variable_Reference): Adapt to new spec of Prj.Attr. 2004-07-15 Richard Kenner <kenner@vlsi1.ultra.nyu.edu> * utils2.c: Fix typo in comment. From-SVN: r84774
2004-07-15 22:34:43 +02:00
Source := S1;
Found := True;
-- The goto is within some nested structure
[multiple changes] 2004-07-15 Robert Dewar <dewar@gnat.com> * makegpr.adb, s-secsta.ads, sem_ch3.adb, sem_case.adb: Minor reformatting * gnat_ugn.texi: Add instantiation of direct_io or sequential_io with access values as an example of a warning. * gnat_rm.texi: Document new attribute Has_Access_Values * gnat-style.texi: Document that box comments belong on nested subprograms * sem_util.ads (Has_Access_Values): Improved documentation * s-finimp.ads, s-finimp.adb: Fix spelling error in comment * sem_prag.adb (Check_Duplicated_Export_Name): New procedure (Process_Interface_Name): Call to this new procedure (Set_Extended_Import_Export_External_Name): Call to this new procedure * s-mastop-x86.adb, 9drpc.adb: Fix spelling error in comment * a-direio.ads, a-sequio.ads: Warn if Element_Type has access values * einfo.ads: Minor comment typo fixed 2004-07-15 Jose Ruiz <ruiz@act-europe.fr> * snames.adb: Add _atcb. * snames.ads: Add Name_uATCB. * s-tarest.adb (Create_Restricted_Task): ATCBs are always preallocated (in the expanded code) when using the restricted run time. * s-tarest.ads (Create_Restricted_Task): Created_Task transformed into a in parameter in order to allow ATCBs to be preallocated (in the expanded code). * s-taskin.adb (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. In case of error, the ATCB is deallocated in System.Tasking.Stages. * s-taskin.ads (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. * s-tassta.adb (Create_Task): In case of error the ATCB is deallocated here. It was previously done in Initialize_ATCB. * rtsfind.ads: Make the Ada_Task_Control_Block visible. * exp_ch9.adb: Preallocate the Ada_Task_Control_Block when using the Restricted run time. * exp_ch3.adb: When using the Restricted run time, pass the preallocated Ada_Task_Control_Block when creating a task. 2004-07-15 Ed Schonberg <schonberg@gnat.com> * sem_util.adb (Normalize_Actuals): If there are no actuals on a function call that is itself an actual in an enclosing call, diagnose problem here rather than assuming that resolution will catch it. * sem_ch7.adb (Analyze_Package_Specification): If the specification is the local copy of a generic unit for a formal package, and the generic is a child unit, install private part of ancestors before compiling private part of spec. * sem_cat.adb (Validate_Categorization_Dependency): Simplify code to use scope entities rather than tree structures, to handle properly parent units that are instances rewritten as bodies for inlining purposes. * sem_ch10.adb (Get_Parent_Entity, Implicit_With_On_Parent, Remove_Parents): Handle properly a parent unit that is an instantiation, when the unit has been rewritten as a body for inlining purposes. * par.adb (Goto_List): Global variable to collect goto statements in a given unit, for use in detecting natural loops. * par-ch5.adb (P_Goto_Statement): Add goto to global Goto_List, for use in detecting natural loops. * par-labl.adb (Find_Natural_Loops): Recognize loops create by backwards goto's, and rewrite as a infinite loop, to improve locality of temporaries. * exp_util.adb (Force_Evaluation): Recognize a left-hand side subcomponent that includes an indexed reference, to prevent the generation of copies that would miscompile the desired assignment statement. (Build_Task_Image_Decls): Add a numeric suffix to generated name for string variable, to avoid spurious conflicts with the name of the type of a single protected object. * exp_ch4.adb (Expand_Array_Equality): If indices are distinct, use a loop with an explicit exit statement, to avoid generating an out-of-range value with 'Succ leading to spurious constraint_errors when compiling with -gnatVo. 2004-07-15 Thomas Quinot <quinot@act-europe.fr> * sem_ch4.adb (Analyze_Slice): Always call Analyze on the prefix: it might not be analyzed yet, even if its Etype is already set (case of an unchecked conversion built using Unchecked_Convert_To, for example). If the prefix has already been analyzed, this will be a nop anyway. * exp_ch5.adb (Make_Tag_Ctrl_Assignment): For an assignment of a controller type, or an assignment of a record type with controlled components, copy only user data, and leave the finalization chain pointers untouched. 2004-07-15 Vincent Celier <celier@gnat.com> * make.adb (Collect_Arguments): Improve error message when attempting to compile a source not part of any project, when -x is not used. * prj.ads: (Defined_Variable_Kind): New subtype * prj-attr.adb (Register_New_Package): Two new procedures to register a package with or without its attributes. (Register_New_Attribute): Mew procedure to register a new attribute in a package. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-attr.ads (Attribute_Node_Id): Now a private, self initialized type. (Package_Node_Id): Now a private, self initialized type (Register_New_Package): New procedure to register a package with its attributes. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-dect.adb (Parse_Attribute_Declaration, Parse_Package_Declaration): Adapt to new spec of Prj.Attr. * prj-makr.adb (Make): Parse existing project file before creating other files. Fail if there was an error during parsing. * prj-proc.adb (Add_Attributes, Process_Declarative_Items): Adapt to new spec of Prj.Attr. * prj-strt.adb (Attribute_Reference, Parse_Variable_Reference): Adapt to new spec of Prj.Attr. 2004-07-15 Richard Kenner <kenner@vlsi1.ultra.nyu.edu> * utils2.c: Fix typo in comment. From-SVN: r84774
2004-07-15 22:34:43 +02:00
else
[multiple changes] 2004-07-15 Robert Dewar <dewar@gnat.com> * makegpr.adb, s-secsta.ads, sem_ch3.adb, sem_case.adb: Minor reformatting * gnat_ugn.texi: Add instantiation of direct_io or sequential_io with access values as an example of a warning. * gnat_rm.texi: Document new attribute Has_Access_Values * gnat-style.texi: Document that box comments belong on nested subprograms * sem_util.ads (Has_Access_Values): Improved documentation * s-finimp.ads, s-finimp.adb: Fix spelling error in comment * sem_prag.adb (Check_Duplicated_Export_Name): New procedure (Process_Interface_Name): Call to this new procedure (Set_Extended_Import_Export_External_Name): Call to this new procedure * s-mastop-x86.adb, 9drpc.adb: Fix spelling error in comment * a-direio.ads, a-sequio.ads: Warn if Element_Type has access values * einfo.ads: Minor comment typo fixed 2004-07-15 Jose Ruiz <ruiz@act-europe.fr> * snames.adb: Add _atcb. * snames.ads: Add Name_uATCB. * s-tarest.adb (Create_Restricted_Task): ATCBs are always preallocated (in the expanded code) when using the restricted run time. * s-tarest.ads (Create_Restricted_Task): Created_Task transformed into a in parameter in order to allow ATCBs to be preallocated (in the expanded code). * s-taskin.adb (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. In case of error, the ATCB is deallocated in System.Tasking.Stages. * s-taskin.ads (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. * s-tassta.adb (Create_Task): In case of error the ATCB is deallocated here. It was previously done in Initialize_ATCB. * rtsfind.ads: Make the Ada_Task_Control_Block visible. * exp_ch9.adb: Preallocate the Ada_Task_Control_Block when using the Restricted run time. * exp_ch3.adb: When using the Restricted run time, pass the preallocated Ada_Task_Control_Block when creating a task. 2004-07-15 Ed Schonberg <schonberg@gnat.com> * sem_util.adb (Normalize_Actuals): If there are no actuals on a function call that is itself an actual in an enclosing call, diagnose problem here rather than assuming that resolution will catch it. * sem_ch7.adb (Analyze_Package_Specification): If the specification is the local copy of a generic unit for a formal package, and the generic is a child unit, install private part of ancestors before compiling private part of spec. * sem_cat.adb (Validate_Categorization_Dependency): Simplify code to use scope entities rather than tree structures, to handle properly parent units that are instances rewritten as bodies for inlining purposes. * sem_ch10.adb (Get_Parent_Entity, Implicit_With_On_Parent, Remove_Parents): Handle properly a parent unit that is an instantiation, when the unit has been rewritten as a body for inlining purposes. * par.adb (Goto_List): Global variable to collect goto statements in a given unit, for use in detecting natural loops. * par-ch5.adb (P_Goto_Statement): Add goto to global Goto_List, for use in detecting natural loops. * par-labl.adb (Find_Natural_Loops): Recognize loops create by backwards goto's, and rewrite as a infinite loop, to improve locality of temporaries. * exp_util.adb (Force_Evaluation): Recognize a left-hand side subcomponent that includes an indexed reference, to prevent the generation of copies that would miscompile the desired assignment statement. (Build_Task_Image_Decls): Add a numeric suffix to generated name for string variable, to avoid spurious conflicts with the name of the type of a single protected object. * exp_ch4.adb (Expand_Array_Equality): If indices are distinct, use a loop with an explicit exit statement, to avoid generating an out-of-range value with 'Succ leading to spurious constraint_errors when compiling with -gnatVo. 2004-07-15 Thomas Quinot <quinot@act-europe.fr> * sem_ch4.adb (Analyze_Slice): Always call Analyze on the prefix: it might not be analyzed yet, even if its Etype is already set (case of an unchecked conversion built using Unchecked_Convert_To, for example). If the prefix has already been analyzed, this will be a nop anyway. * exp_ch5.adb (Make_Tag_Ctrl_Assignment): For an assignment of a controller type, or an assignment of a record type with controlled components, copy only user data, and leave the finalization chain pointers untouched. 2004-07-15 Vincent Celier <celier@gnat.com> * make.adb (Collect_Arguments): Improve error message when attempting to compile a source not part of any project, when -x is not used. * prj.ads: (Defined_Variable_Kind): New subtype * prj-attr.adb (Register_New_Package): Two new procedures to register a package with or without its attributes. (Register_New_Attribute): Mew procedure to register a new attribute in a package. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-attr.ads (Attribute_Node_Id): Now a private, self initialized type. (Package_Node_Id): Now a private, self initialized type (Register_New_Package): New procedure to register a package with its attributes. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-dect.adb (Parse_Attribute_Declaration, Parse_Package_Declaration): Adapt to new spec of Prj.Attr. * prj-makr.adb (Make): Parse existing project file before creating other files. Fail if there was an error during parsing. * prj-proc.adb (Add_Attributes, Process_Declarative_Items): Adapt to new spec of Prj.Attr. * prj-strt.adb (Attribute_Reference, Parse_Variable_Reference): Adapt to new spec of Prj.Attr. 2004-07-15 Richard Kenner <kenner@vlsi1.ultra.nyu.edu> * utils2.c: Fix typo in comment. From-SVN: r84774
2004-07-15 22:34:43 +02:00
No_Header (N);
return;
end if;
else
-- More than one goto with the same target
No_Header (N);
return;
end if;
elsif Nkind (Node (S1)) = N_Label
and then not Found
then
-- Intervening label before possible end of loop. Current
-- label is not a candidate. This is conservative, because
-- the label might not be the target of any jumps, but not
a-except-2005.adb, [...]: Minor reformatting. 2014-01-29 Robert Dewar <dewar@adacore.com> * a-except-2005.adb, a-except.adb, a-excpol-abort.adb, a-exstat.adb, ali.adb, a-numaux.ads, a-numaux-darwin.ads, a-numaux-libc-x86.ads, a-numaux-vms.ads, a-numaux-vxworks.ads, a-numaux-x86.ads, aspects.ads, a-taside.adb, a-teioed.adb, a-textio.adb, a-textio.ads, atree.adb, atree.ads, a-witeio.adb, a-witeio.ads, a-wtedit.adb, a-ztedit.adb, a-ztexio.adb, bcheck.adb, binde.adb, checks.adb, comperr.adb, cstand.adb, debug_a.adb, einfo.ads, errout.adb, erroutc.adb, eval_fat.adb, exp_aggr.adb, exp_attr.adb, exp_ch11.adb, exp_ch3.adb, exp_ch4.adb, exp_ch5.adb, exp_ch6.adb, exp_ch9.adb, exp_dbug.adb, exp_disp.adb, exp_fixd.adb, exp_imgv.adb, exp_intr.adb, exp_util.adb, freeze.adb, frontend.adb, g-comlin.ads, g-mbdira.adb, gnat1drv.adb, gprep.adb, g-spipat.adb, i-cpp.ads, i-vxwork.ads, i-vxwork-x86.ads, krunch.ads, layout.adb, lib-load.adb, lib-writ.adb, lib-writ.ads, live.adb, namet.ads, osint.adb, osint-c.adb, output.ads, par.adb, par-ch10.adb, par-ch13.adb, par-ch3.adb, par-ch4.adb, par-ch5.adb, par-ch6.adb, par-ch9.adb, par-endh.adb, par-labl.adb, par-prag.adb, par-sync.adb, par-tchk.adb, par-util.adb, prj.adb, repinfo.adb, rtsfind.adb, s-arit64.adb, s-asthan-vms-alpha.adb, s-asthan-vms-ia64.adb, s-bignum.adb, scans.adb, scng.adb, s-dimmks.ads, sem_aggr.adb, sem_attr.adb, sem_aux.adb, sem_cat.adb, sem_ch10.adb, sem_ch12.adb, sem_ch13.adb, sem_ch13.ads, sem_ch3.adb, sem_ch4.adb, sem_ch5.adb, sem_ch6.adb, sem_ch8.adb, sem_disp.adb, sem_elab.adb, sem_elim.adb, sem_eval.adb, sem_intr.adb, sem_prag.adb, sem_res.adb, sem_type.adb, sem_util.adb, sem_warn.adb, set_targ.adb, s-fatgen.adb, s-fatgen.ads, s-fileio.adb, s-imgcha.adb, s-imgrea.adb, sinfo.ads, sinput-c.adb, snames.ads-tmpl, s-os_lib.adb, sprint.adb, s-regpat.adb, s-secsta.adb, s-stalib.ads, s-stchop.adb, s-stoele.ads, stand.ads, s-taprop-solaris.adb, s-tasdeb-vms.adb, s-tasini.adb, s-tassta.adb, s-valdec.adb, s-valuti.adb, s-wchjis.adb, s-wchwts.adb, system.ads, system-vms_64.ads, system-vms-ia64.ads, treepr.adb, types.ads, uintp.adb, uname.adb, urealp.adb, usage.adb, vxaddr2line.adb: Minor reformatting. From-SVN: r207260
2014-01-29 16:53:48 +01:00
-- worth dealing with useless labels.
[multiple changes] 2004-07-15 Robert Dewar <dewar@gnat.com> * makegpr.adb, s-secsta.ads, sem_ch3.adb, sem_case.adb: Minor reformatting * gnat_ugn.texi: Add instantiation of direct_io or sequential_io with access values as an example of a warning. * gnat_rm.texi: Document new attribute Has_Access_Values * gnat-style.texi: Document that box comments belong on nested subprograms * sem_util.ads (Has_Access_Values): Improved documentation * s-finimp.ads, s-finimp.adb: Fix spelling error in comment * sem_prag.adb (Check_Duplicated_Export_Name): New procedure (Process_Interface_Name): Call to this new procedure (Set_Extended_Import_Export_External_Name): Call to this new procedure * s-mastop-x86.adb, 9drpc.adb: Fix spelling error in comment * a-direio.ads, a-sequio.ads: Warn if Element_Type has access values * einfo.ads: Minor comment typo fixed 2004-07-15 Jose Ruiz <ruiz@act-europe.fr> * snames.adb: Add _atcb. * snames.ads: Add Name_uATCB. * s-tarest.adb (Create_Restricted_Task): ATCBs are always preallocated (in the expanded code) when using the restricted run time. * s-tarest.ads (Create_Restricted_Task): Created_Task transformed into a in parameter in order to allow ATCBs to be preallocated (in the expanded code). * s-taskin.adb (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. In case of error, the ATCB is deallocated in System.Tasking.Stages. * s-taskin.ads (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. * s-tassta.adb (Create_Task): In case of error the ATCB is deallocated here. It was previously done in Initialize_ATCB. * rtsfind.ads: Make the Ada_Task_Control_Block visible. * exp_ch9.adb: Preallocate the Ada_Task_Control_Block when using the Restricted run time. * exp_ch3.adb: When using the Restricted run time, pass the preallocated Ada_Task_Control_Block when creating a task. 2004-07-15 Ed Schonberg <schonberg@gnat.com> * sem_util.adb (Normalize_Actuals): If there are no actuals on a function call that is itself an actual in an enclosing call, diagnose problem here rather than assuming that resolution will catch it. * sem_ch7.adb (Analyze_Package_Specification): If the specification is the local copy of a generic unit for a formal package, and the generic is a child unit, install private part of ancestors before compiling private part of spec. * sem_cat.adb (Validate_Categorization_Dependency): Simplify code to use scope entities rather than tree structures, to handle properly parent units that are instances rewritten as bodies for inlining purposes. * sem_ch10.adb (Get_Parent_Entity, Implicit_With_On_Parent, Remove_Parents): Handle properly a parent unit that is an instantiation, when the unit has been rewritten as a body for inlining purposes. * par.adb (Goto_List): Global variable to collect goto statements in a given unit, for use in detecting natural loops. * par-ch5.adb (P_Goto_Statement): Add goto to global Goto_List, for use in detecting natural loops. * par-labl.adb (Find_Natural_Loops): Recognize loops create by backwards goto's, and rewrite as a infinite loop, to improve locality of temporaries. * exp_util.adb (Force_Evaluation): Recognize a left-hand side subcomponent that includes an indexed reference, to prevent the generation of copies that would miscompile the desired assignment statement. (Build_Task_Image_Decls): Add a numeric suffix to generated name for string variable, to avoid spurious conflicts with the name of the type of a single protected object. * exp_ch4.adb (Expand_Array_Equality): If indices are distinct, use a loop with an explicit exit statement, to avoid generating an out-of-range value with 'Succ leading to spurious constraint_errors when compiling with -gnatVo. 2004-07-15 Thomas Quinot <quinot@act-europe.fr> * sem_ch4.adb (Analyze_Slice): Always call Analyze on the prefix: it might not be analyzed yet, even if its Etype is already set (case of an unchecked conversion built using Unchecked_Convert_To, for example). If the prefix has already been analyzed, this will be a nop anyway. * exp_ch5.adb (Make_Tag_Ctrl_Assignment): For an assignment of a controller type, or an assignment of a record type with controlled components, copy only user data, and leave the finalization chain pointers untouched. 2004-07-15 Vincent Celier <celier@gnat.com> * make.adb (Collect_Arguments): Improve error message when attempting to compile a source not part of any project, when -x is not used. * prj.ads: (Defined_Variable_Kind): New subtype * prj-attr.adb (Register_New_Package): Two new procedures to register a package with or without its attributes. (Register_New_Attribute): Mew procedure to register a new attribute in a package. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-attr.ads (Attribute_Node_Id): Now a private, self initialized type. (Package_Node_Id): Now a private, self initialized type (Register_New_Package): New procedure to register a package with its attributes. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-dect.adb (Parse_Attribute_Declaration, Parse_Package_Declaration): Adapt to new spec of Prj.Attr. * prj-makr.adb (Make): Parse existing project file before creating other files. Fail if there was an error during parsing. * prj-proc.adb (Add_Attributes, Process_Declarative_Items): Adapt to new spec of Prj.Attr. * prj-strt.adb (Attribute_Reference, Parse_Variable_Reference): Adapt to new spec of Prj.Attr. 2004-07-15 Richard Kenner <kenner@vlsi1.ultra.nyu.edu> * utils2.c: Fix typo in comment. From-SVN: r84774
2004-07-15 22:34:43 +02:00
No_Header (N);
return;
else
-- If the node is a loop_statement, it corresponds to a
-- label-goto pair rewritten as a loop. Continue forward scan.
null;
end if;
Next_Elmt (S1);
end loop;
if Found then
Rewrite_As_Loop (Node (N), Node (Source));
Remove_Elmt (Node_List, N);
Remove_Elmt (Node_List, Source);
end if;
end Try_Loop;
begin
-- Start of processing for Find_Natural_Loops
Merge;
N := First_Elmt (Node_List);
while Present (N) loop
Succ := Next_Elmt (N);
if Nkind (Node (N)) = N_Label then
if No (Succ) then
exit;
elsif Nkind (Node (Succ)) = N_Label then
Try_Loop (Succ);
-- If a loop was found, the label has been removed, and
-- the following goto rewritten as the loop body.
Succ := Next_Elmt (N);
if Nkind (Node (Succ)) = N_Label then
-- Following label was not removed, so current label
-- is not a candidate header.
No_Header (N);
else
-- Following label was part of inner loop. Current
-- label is still a candidate.
Try_Loop (N);
Succ := Next_Elmt (N);
end if;
elsif Nkind (Node (Succ)) = N_Goto_Statement then
Try_Loop (N);
Succ := Next_Elmt (N);
end if;
elsif Nkind (Node (N)) = N_Goto_Statement then
Process_Goto (N);
Succ := Next_Elmt (N);
end if;
N := Succ;
end loop;
end Find_Natural_Loops;
2001-10-02 16:23:52 +02:00
-- Start of processing for Par.Labl
begin
Next_Label_Elmt := First_Elmt (Label_List);
while Present (Next_Label_Elmt) loop
Label_Node := Node (Next_Label_Elmt);
if not Comes_From_Source (Label_Node) then
goto Next_Label;
end if;
-- Find the innermost enclosing body or block, which is where
-- we need to implicitly declare this label
Enclosing_Body_Or_Block := Find_Enclosing_Body_Or_Block (Label_Node);
-- If we didn't find a parent, then the label in question never got
-- hooked into a reasonable declarative part. This happens only in
-- error situations, and we simply ignore the entry (we aren't going
-- to get into the semantics in any case given the error).
if Present (Enclosing_Body_Or_Block) then
Check_Distinct_Labels;
-- Now create the implicit label declaration node and its
-- corresponding defining identifier. Note that the defining
-- occurrence of a label is the implicit label declaration that
-- we are creating. The label itself is an applied occurrence.
Label_Decl_Node :=
New_Node (N_Implicit_Label_Declaration, Sloc (Label_Node));
Defining_Ident_Node :=
New_Entity (N_Defining_Identifier, Sloc (Identifier (Label_Node)));
Set_Chars (Defining_Ident_Node, Chars (Identifier (Label_Node)));
Set_Defining_Identifier (Label_Decl_Node, Defining_Ident_Node);
Set_Label_Construct (Label_Decl_Node, Label_Node);
3psoccon.ads, [...]: Files added. 2003-10-21 Arnaud Charlet <charlet@act-europe.fr> * 3psoccon.ads, 3veacodu.adb, 3vexpect.adb, 3vsoccon.ads, 3vsocthi.adb, 3vsocthi.ads, 3vtrasym.adb, 3zsoccon.ads, 3zsocthi.adb, 3zsocthi.ads, 50system.ads, 51system.ads, 55system.ads, 56osinte.adb, 56osinte.ads, 56taprop.adb, 56taspri.ads, 56tpopsp.adb, 57system.ads, 58system.ads, 59system.ads, 5aml-tgt.adb, 5bml-tgt.adb, 5csystem.ads, 5dsystem.ads, 5fosinte.adb, 5gml-tgt.adb, 5hml-tgt.adb, 5isystem.ads, 5lparame.adb, 5msystem.ads, 5psystem.ads, 5sml-tgt.adb, 5sosprim.adb, 5stpopsp.adb, 5tsystem.ads, 5usystem.ads, 5vml-tgt.adb, 5vsymbol.adb, 5vtraent.adb, 5vtraent.ads, 5wml-tgt.adb, 5xparame.ads, 5xsystem.ads, 5xvxwork.ads, 5yparame.ads, 5ytiitho.adb, 5zinit.adb, 5zml-tgt.adb, 5zparame.ads, 5ztaspri.ads, 5ztfsetr.adb, 5zthrini.adb, 5ztiitho.adb, 5ztpopsp.adb, 7stfsetr.adb, 7straces.adb, 7strafor.adb, 7strafor.ads, 7stratas.adb, a-excach.adb, a-exexda.adb, a-exexpr.adb, a-exextr.adb, a-exstat.adb, a-strsup.adb, a-strsup.ads, a-stwisu.adb, a-stwisu.ads, bld.adb, bld.ads, bld-io.adb, bld-io.ads, clean.adb, clean.ads, ctrl_c.c, erroutc.adb, erroutc.ads, errutil.adb, errutil.ads, err_vars.ads, final.c, g-arrspl.adb, g-arrspl.ads, g-boubuf.adb, g-boubuf.ads, g-boumai.ads, g-bubsor.adb, g-bubsor.ads, g-comver.adb, g-comver.ads, g-ctrl_c.ads, g-dynhta.adb, g-dynhta.ads, g-eacodu.adb, g-excact.adb, g-excact.ads, g-heasor.adb, g-heasor.ads, g-memdum.adb, g-memdum.ads, gnatclean.adb, gnatsym.adb, g-pehage.adb, g-pehage.ads, g-perhas.ads, gpr2make.adb, gpr2make.ads, gprcmd.adb, gprep.adb, gprep.ads, g-semaph.adb, g-semaph.ads, g-string.adb, g-string.ads, g-strspl.ads, g-wistsp.ads, i-vthrea.adb, i-vthrea.ads, i-vxwoio.adb, i-vxwoio.ads, Makefile.generic, Makefile.prolog, Makefile.rtl, prep.adb, prep.ads, prepcomp.adb, prepcomp.ads, prj-err.adb, prj-err.ads, s-boarop.ads, s-carsi8.adb, s-carsi8.ads, s-carun8.adb, s-carun8.ads, s-casi16.adb, s-casi16.ads, s-casi32.adb, s-casi32.ads, s-casi64.adb, s-casi64.ads, s-casuti.adb, s-casuti.ads, s-caun16.adb, s-caun16.ads, s-caun32.adb, s-caun32.ads, s-caun64.adb, s-caun64.ads, scng.adb, scng.ads, s-exnint.adb, s-exnllf.adb, s-exnlli.adb, s-expint.adb, s-explli.adb, s-geveop.adb, s-geveop.ads, s-hibaen.ads, s-htable.adb, s-htable.ads, sinput-c.adb, sinput-c.ads, s-memcop.ads, socket.c, s-purexc.ads, s-scaval.adb, s-stopoo.adb, s-strcom.adb, s-strcom.ads, s-strxdr.adb, s-rident.ads, s-thread.adb, s-thread.ads, s-tpae65.adb, s-tpae65.ads, s-tporft.adb, s-traent.adb, s-traent.ads, styleg.adb, styleg.ads, styleg-c.adb, styleg-c.ads, s-veboop.adb, s-veboop.ads, s-vector.ads, symbols.adb, symbols.ads, tb-alvms.c, tb-alvxw.c, tempdir.adb, tempdir.ads, vms_conv.ads, vms_conv.adb, vms_data.ads, vxaddr2line.adb: Files added. Merge with ACT tree. * 4dintnam.ads, 4mintnam.ads, 4uintnam.ads, 52system.ads, 5dosinte.ads, 5etpopse.adb, 5mosinte.ads, 5qosinte.adb, 5qosinte.ads, 5qstache.adb, 5qtaprop.adb, 5qtaspri.ads, 5stpopse.adb, 5uintman.adb, 5uosinte.ads, adafinal.c, g-enblsp.adb, io-aux.c, scn-nlit.adb, scn-slit.adb, s-exnflt.ads, s-exngen.adb, s-exngen.ads, s-exnlfl.ads, s-exnlin.ads, s-exnsfl.ads, s-exnsin.ads, s-exnssi.ads, s-expflt.ads, s-expgen.adb, s-expgen.ads, s-explfl.ads, s-explin.ads, s-expllf.ads, s-expsfl.ads, s-expsin.ads, s-expssi.ads, style.adb: Files removed. Merge with ACT tree. * 1ic.ads, 31soccon.ads, 31soliop.ads, 3asoccon.ads, 3bsoccon.ads, 3gsoccon.ads, 3hsoccon.ads, 3ssoccon.ads, 3ssoliop.ads, 3wsoccon.ads, 3wsocthi.adb, 3wsocthi.ads, 3wsoliop.ads, 41intnam.ads, 42intnam.ads, 4aintnam.ads, 4cintnam.ads, 4gintnam.ads, 4hexcpol.adb, 4hintnam.ads, 4lintnam.ads, 4nintnam.ads, 4ointnam.ads, 4onumaux.ads, 4pintnam.ads, 4sintnam.ads, 4vcaldel.adb, 4vcalend.adb, 4vintnam.ads, 4wexcpol.adb, 4wintnam.ads, 4zintnam.ads, 51osinte.adb, 51osinte.ads, 52osinte.adb, 52osinte.ads, 53osinte.ads, 54osinte.ads, 5aosinte.adb, 5aosinte.ads, 5asystem.ads, 5ataprop.adb, 5atasinf.ads, 5ataspri.ads, 5atpopsp.adb, 5avxwork.ads, 5bosinte.adb, 5bosinte.ads, 5bsystem.ads, 5cosinte.ads, 5esystem.ads, 5fintman.adb, 5fosinte.ads, 5fsystem.ads, 5ftaprop.adb, 5ftasinf.ads, 5ginterr.adb, 5gintman.adb, 5gmastop.adb, 5gosinte.ads, 5gproinf.ads, 5gsystem.ads, 5gtaprop.adb, 5gtasinf.ads, 5gtpgetc.adb, 5hosinte.adb, 5hosinte.ads, 5hsystem.ads, 5htaprop.adb, 5htaspri.ads, 5htraceb.adb, 5iosinte.adb, 5itaprop.adb, 5itaspri.ads, 5ksystem.ads, 5kvxwork.ads, 5lintman.adb, 5lml-tgt.adb, 5losinte.ads, 5lsystem.ads, 5mvxwork.ads, 5ninmaop.adb, 5nintman.adb, 5nosinte.ads, 5ntaprop.adb, 5ntaspri.ads, 5ointerr.adb, 5omastop.adb, 5oosinte.adb, 5oosinte.ads, 5oosprim.adb, 5oparame.adb, 5osystem.ads, 5otaprop.adb, 5otaspri.ads, 5posinte.ads, 5posprim.adb, 5pvxwork.ads, 5sintman.adb, 5sosinte.adb, 5sosinte.ads, 5ssystem.ads, 5staprop.adb, 5stasinf.ads, 5staspri.ads, 5svxwork.ads, 5tosinte.ads, 5vasthan.adb, 5vinmaop.adb, 5vinterr.adb, 5vintman.adb, 5vintman.ads, 5vmastop.adb, 5vosinte.adb, 5vosinte.ads, 5vosprim.adb, 5vsystem.ads, 5vtaprop.adb, 5vtaspri.ads, 5vtpopde.adb, 5vtpopde.ads, 5wgloloc.adb, 5wintman.adb, 5wmemory.adb, 5wosprim.adb, 5wsystem.ads, 5wtaprop.adb, 5wtaspri.ads, 5ysystem.ads, 5zinterr.adb, 5zintman.adb, 5zosinte.adb, 5zosinte.ads, 5zosprim.adb, 5zsystem.ads, 5ztaprop.adb, 6vcpp.adb, 6vcstrea.adb, 6vinterf.ads, 7sinmaop.adb, 7sintman.adb, 7sosinte.adb, 7sosprim.adb, 7staprop.adb, 7staspri.ads, 7stpopsp.adb, 7straceb.adb, 9drpc.adb, a-caldel.adb, a-caldel.ads, a-charac.ads, a-colien.ads, a-comlin.adb, adaint.c, adaint.h, ada-tree.def, a-diocst.adb, a-diocst.ads, a-direio.adb, a-except.adb, a-except.ads, a-excpol.adb, a-exctra.adb, a-exctra.ads, a-filico.adb, a-interr.adb, a-intsig.adb, a-intsig.ads, ali.adb, ali.ads, ali-util.adb, ali-util.ads, a-ngcefu.adb, a-ngcoty.adb, a-ngelfu.adb, a-nudira.adb, a-nudira.ads, a-nuflra.adb, a-nuflra.ads, a-reatim.adb, a-reatim.ads, a-retide.ads, a-sequio.adb, a-siocst.adb, a-siocst.ads, a-ssicst.adb, a-ssicst.ads, a-strbou.adb, a-strbou.ads, a-strfix.adb, a-strmap.adb, a-strsea.ads, a-strunb.adb, a-strunb.ads, a-ststio.adb, a-stunau.adb, a-stunau.ads, a-stwibo.adb, a-stwibo.ads, a-stwifi.adb, a-stwima.adb, a-stwiun.adb, a-stwiun.ads, a-tags.adb, a-tags.ads, a-tasatt.adb, a-taside.adb, a-teioed.adb, a-textio.adb, a-textio.ads, a-tienau.adb, a-tifiio.adb, a-tiflau.adb, a-tiflio.adb, a-tigeau.adb, a-tigeau.ads, a-tiinau.adb, a-timoau.adb, a-tiocst.adb, a-tiocst.ads, atree.adb, atree.ads, a-witeio.adb, a-witeio.ads, a-wtcstr.adb, a-wtcstr.ads, a-wtdeio.adb, a-wtedit.adb, a-wtenau.adb, a-wtflau.adb, a-wtinau.adb, a-wtmoau.adb, bcheck.adb, binde.adb, bindgen.adb, bindusg.adb, checks.adb, checks.ads, cio.c, comperr.adb, comperr.ads, csets.adb, cstand.adb, cstreams.c, debug_a.adb, debug_a.ads, debug.adb, decl.c, einfo.adb, einfo.ads, errout.adb, errout.ads, eval_fat.adb, eval_fat.ads, exp_aggr.adb, expander.adb, expander.ads, exp_attr.adb, exp_ch11.adb, exp_ch13.adb, exp_ch2.adb, exp_ch3.adb, exp_ch3.ads, exp_ch4.adb, exp_ch5.adb, exp_ch6.adb, exp_ch7.adb, exp_ch7.ads, exp_ch8.adb, exp_ch9.adb, exp_code.adb, exp_dbug.adb, exp_dbug.ads, exp_disp.adb, exp_dist.adb, expect.c, exp_fixd.adb, exp_imgv.adb, exp_intr.adb, exp_pakd.adb, exp_prag.adb, exp_strm.adb, exp_strm.ads, exp_tss.adb, exp_tss.ads, exp_util.adb, exp_util.ads, exp_vfpt.adb, fe.h, fmap.adb, fmap.ads, fname.adb, fname.ads, fname-uf.adb, fname-uf.ads, freeze.adb, freeze.ads, frontend.adb, g-awk.adb, g-awk.ads, g-busora.adb, g-busora.ads, g-busorg.adb, g-busorg.ads, g-casuti.adb, g-casuti.ads, g-catiio.adb, g-catiio.ads, g-cgi.adb, g-cgi.ads, g-cgicoo.adb, g-cgicoo.ads, g-cgideb.adb, g-cgideb.ads, g-comlin.adb, g-comlin.ads, g-crc32.adb, g-crc32.ads, g-debpoo.adb, g-debpoo.ads, g-debuti.adb, g-debuti.ads, g-diopit.adb, g-diopit.ads, g-dirope.adb, g-dirope.ads, g-dyntab.adb, g-dyntab.ads, g-except.ads, g-exctra.adb, g-exctra.ads, g-expect.adb, g-expect.ads, g-hesora.adb, g-hesora.ads, g-hesorg.adb, g-hesorg.ads, g-htable.adb, g-htable.ads, gigi.h, g-io.adb, g-io.ads, g-io_aux.adb, g-io_aux.ads, g-locfil.adb, g-locfil.ads, g-md5.adb, g-md5.ads, gmem.c, gnat1drv.adb, gnatbind.adb, gnatchop.adb, gnatcmd.adb, gnatfind.adb, gnatkr.adb, gnatlbr.adb, gnatlink.adb, gnatls.adb, gnatmake.adb, gnatmem.adb, gnatname.adb, gnatprep.adb, gnatprep.ads, gnatpsta.adb, gnatxref.adb, g-os_lib.adb, g-os_lib.ads, g-regexp.adb, g-regexp.ads, g-regist.adb, g-regist.ads, g-regpat.adb, g-regpat.ads, g-soccon.ads, g-socket.adb, g-socket.ads, g-socthi.adb, g-socthi.ads, g-soliop.ads, g-souinf.ads, g-speche.adb, g-speche.ads, g-spipat.adb, g-spipat.ads, g-spitbo.adb, g-spitbo.ads, g-sptabo.ads, g-sptain.ads, g-sptavs.ads, g-table.adb, g-table.ads, g-tasloc.adb, g-tasloc.ads, g-thread.adb, g-thread.ads, g-traceb.adb, g-traceb.ads, g-trasym.adb, g-trasym.ads, hostparm.ads, i-c.ads, i-cobol.adb, i-cpp.adb, i-cstrea.ads, i-cstrin.adb, i-cstrin.ads, impunit.adb, init.c, inline.adb, interfac.ads, i-pacdec.ads, itypes.adb, itypes.ads, i-vxwork.ads, lang.opt, lang-specs.h, layout.adb, lib.adb, lib.ads, lib-list.adb, lib-load.adb, lib-load.ads, lib-sort.adb, lib-util.adb, lib-writ.adb, lib-writ.ads, lib-xref.adb, lib-xref.ads, link.c, live.adb, make.adb, make.ads, Makefile.adalib, Makefile.in, Make-lang.in, makeusg.adb, mdll.adb, mdll-fil.adb, mdll-fil.ads, mdll-utl.adb, mdll-utl.ads, memroot.adb, memroot.ads, memtrack.adb, misc.c, mkdir.c, mlib.adb, mlib.ads, mlib-fil.adb, mlib-fil.ads, mlib-prj.adb, mlib-prj.ads, mlib-tgt.adb, mlib-tgt.ads, mlib-utl.adb, mlib-utl.ads, namet.adb, namet.ads, namet.h, nlists.ads, nlists.h, nmake.adt, opt.adb, opt.ads, osint.adb, osint.ads, osint-b.adb, osint-c.adb, par.adb, par-ch10.adb, par-ch11.adb, par-ch2.adb, par-ch3.adb, par-ch4.adb, par-ch5.adb, par-ch6.adb, par-ch9.adb, par-endh.adb, par-labl.adb, par-load.adb, par-prag.adb, par-sync.adb, par-tchk.adb, par-util.adb, prj.adb, prj.ads, prj-attr.adb, prj-attr.ads, prj-com.adb, prj-com.ads, prj-dect.adb, prj-dect.ads, prj-env.adb, prj-env.ads, prj-ext.adb, prj-ext.ads, prj-makr.adb, prj-makr.ads, prj-nmsc.adb, prj-nmsc.ads, prj-pars.adb, prj-pars.ads, prj-part.adb, prj-part.ads, prj-pp.adb, prj-pp.ads, prj-proc.adb, prj-proc.ads, prj-strt.adb, prj-strt.ads, prj-tree.adb, prj-tree.ads, prj-util.adb, prj-util.ads, raise.c, raise.h, repinfo.adb, repinfo.h, restrict.adb, restrict.ads, rident.ads, rtsfind.adb, rtsfind.ads, s-addima.ads, s-arit64.adb, s-assert.adb, s-assert.ads, s-atacco.adb, s-atacco.ads, s-auxdec.adb, s-auxdec.ads, s-bitops.adb, scans.ads, scn.adb, scn.ads, s-crc32.adb, s-crc32.ads, s-direio.adb, sem.adb, sem.ads, sem_aggr.adb, sem_attr.adb, sem_attr.ads, sem_case.adb, sem_case.ads, sem_cat.adb, sem_cat.ads, sem_ch10.adb, sem_ch11.adb, sem_ch12.adb, sem_ch12.ads, sem_ch13.adb, sem_ch13.ads, sem_ch3.adb, sem_ch3.ads, sem_ch4.adb, sem_ch5.adb, sem_ch5.ads, sem_ch6.adb, sem_ch6.ads, sem_ch7.adb, sem_ch7.ads, sem_ch8.adb, sem_ch8.ads, sem_ch9.adb, sem_disp.adb, sem_disp.ads, sem_dist.adb, sem_elab.adb, sem_eval.adb, sem_eval.ads, sem_intr.adb, sem_maps.adb, sem_mech.adb, sem_prag.adb, sem_prag.ads, sem_res.adb, sem_res.ads, sem_type.adb, sem_type.ads, sem_util.adb, sem_util.ads, sem_warn.adb, s-errrep.adb, s-errrep.ads, s-exctab.adb, s-exctab.ads, s-exnint.ads, s-exnllf.ads, s-exnlli.ads, s-expint.ads, s-explli.ads, s-expuns.ads, s-fatflt.ads, s-fatgen.adb, s-fatgen.ads, s-fatlfl.ads, s-fatllf.ads, s-fatsfl.ads, s-fileio.adb, s-fileio.ads, s-finimp.adb, s-finimp.ads, s-finroo.adb, s-finroo.ads, sfn_scan.adb, s-gloloc.adb, s-gloloc.ads, s-imgdec.adb, s-imgenu.adb, s-imgrea.adb, s-imgwch.adb, sinfo.adb, sinfo.ads, s-inmaop.ads, sinput.adb, sinput.ads, sinput-d.adb, sinput-l.adb, sinput-l.ads, sinput-p.adb, sinput-p.ads, s-interr.adb, s-interr.ads, s-intman.ads, s-maccod.ads, s-mastop.adb, s-mastop.ads, s-memory.adb, s-memory.ads, snames.adb, snames.ads, snames.h, s-osprim.ads, s-parame.ads, s-parint.ads, s-pooloc.adb, s-pooloc.ads, s-poosiz.adb, sprint.adb, s-proinf.ads, s-scaval.ads, s-secsta.adb, s-secsta.ads, s-sequio.adb, s-shasto.adb, s-shasto.ads, s-soflin.ads, s-stache.adb, s-stache.ads, s-stalib.adb, s-stalib.ads, s-stoele.ads, s-stopoo.ads, s-stratt.adb, s-stratt.ads, s-strops.adb, s-strops.ads, s-taasde.adb, s-taasde.ads, s-tadeca.adb, s-tadeca.ads, s-tadert.adb, s-tadert.ads, s-taenca.adb, s-taenca.ads, s-taprob.adb, s-taprob.ads, s-taprop.ads, s-tarest.adb, s-tarest.ads, s-tasdeb.adb, s-tasdeb.ads, s-tasinf.adb, s-tasinf.ads, s-tasini.adb, s-tasini.ads, s-taskin.adb, s-taskin.ads, s-tasque.adb, s-tasque.ads, s-tasren.adb, s-tasren.ads, s-tasres.ads, s-tassta.adb, s-tassta.ads, s-tasuti.adb, s-tasuti.ads, s-tataat.adb, s-tataat.ads, s-tpinop.adb, s-tpinop.ads, s-tpoben.adb, s-tpoben.ads, s-tpobop.adb, s-tpobop.ads, s-tposen.adb, s-tposen.ads, s-traceb.adb, s-traceb.ads, stringt.adb, stringt.ads, stringt.h, style.ads, stylesw.adb, stylesw.ads, s-unstyp.ads, s-vaflop.ads, s-valrea.adb, s-valuti.adb, s-vercon.adb, s-vmexta.adb, s-wchcnv.ads, s-wchcon.ads, s-widcha.adb, switch.adb, switch.ads, switch-b.adb, switch-c.adb, switch-m.adb, s-wwdcha.adb, s-wwdwch.adb, sysdep.c, system.ads, table.adb, table.ads, targparm.adb, targparm.ads, targtyps.c, tbuild.adb, tbuild.ads, tracebak.c, trans.c, tree_io.adb, treepr.adb, treeprs.adt, ttypes.ads, types.ads, types.h, uintp.adb, uintp.ads, uintp.h, uname.adb, urealp.adb, urealp.ads, urealp.h, usage.adb, utils2.c, utils.c, validsw.adb, validsw.ads, widechar.adb, xeinfo.adb, xnmake.adb, xref_lib.adb, xref_lib.ads, xr_tabls.adb, xr_tabls.ads, xtreeprs.adb, xsnames.adb, einfo.h, sinfo.h, treeprs.ads, nmake.ads, nmake.adb, gnatvsn.ads: Merge with ACT tree. * gnatvsn.adb: Rewritten in a simpler and more efficient way. From-SVN: r72751
2003-10-21 15:42:24 +02:00
-- The following makes sure that Comes_From_Source is appropriately
-- set for the entity, depending on whether the label appeared in
-- the source explicitly or not.
Set_Comes_From_Source
(Defining_Ident_Node, Comes_From_Source (Identifier (Label_Node)));
2001-10-02 16:23:52 +02:00
-- Now attach the implicit label declaration to the appropriate
-- declarative region, creating a declaration list if none exists
if No (Declarations (Enclosing_Body_Or_Block)) then
2001-10-02 16:23:52 +02:00
Set_Declarations (Enclosing_Body_Or_Block, New_List);
end if;
Append (Label_Decl_Node, Declarations (Enclosing_Body_Or_Block));
end if;
<<Next_Label>>
Next_Elmt (Next_Label_Elmt);
end loop;
[multiple changes] 2004-07-15 Robert Dewar <dewar@gnat.com> * makegpr.adb, s-secsta.ads, sem_ch3.adb, sem_case.adb: Minor reformatting * gnat_ugn.texi: Add instantiation of direct_io or sequential_io with access values as an example of a warning. * gnat_rm.texi: Document new attribute Has_Access_Values * gnat-style.texi: Document that box comments belong on nested subprograms * sem_util.ads (Has_Access_Values): Improved documentation * s-finimp.ads, s-finimp.adb: Fix spelling error in comment * sem_prag.adb (Check_Duplicated_Export_Name): New procedure (Process_Interface_Name): Call to this new procedure (Set_Extended_Import_Export_External_Name): Call to this new procedure * s-mastop-x86.adb, 9drpc.adb: Fix spelling error in comment * a-direio.ads, a-sequio.ads: Warn if Element_Type has access values * einfo.ads: Minor comment typo fixed 2004-07-15 Jose Ruiz <ruiz@act-europe.fr> * snames.adb: Add _atcb. * snames.ads: Add Name_uATCB. * s-tarest.adb (Create_Restricted_Task): ATCBs are always preallocated (in the expanded code) when using the restricted run time. * s-tarest.ads (Create_Restricted_Task): Created_Task transformed into a in parameter in order to allow ATCBs to be preallocated (in the expanded code). * s-taskin.adb (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. In case of error, the ATCB is deallocated in System.Tasking.Stages. * s-taskin.ads (Initialize_ATCB): T converted into a in parameter in order to allow ATCBs to be preallocated. * s-tassta.adb (Create_Task): In case of error the ATCB is deallocated here. It was previously done in Initialize_ATCB. * rtsfind.ads: Make the Ada_Task_Control_Block visible. * exp_ch9.adb: Preallocate the Ada_Task_Control_Block when using the Restricted run time. * exp_ch3.adb: When using the Restricted run time, pass the preallocated Ada_Task_Control_Block when creating a task. 2004-07-15 Ed Schonberg <schonberg@gnat.com> * sem_util.adb (Normalize_Actuals): If there are no actuals on a function call that is itself an actual in an enclosing call, diagnose problem here rather than assuming that resolution will catch it. * sem_ch7.adb (Analyze_Package_Specification): If the specification is the local copy of a generic unit for a formal package, and the generic is a child unit, install private part of ancestors before compiling private part of spec. * sem_cat.adb (Validate_Categorization_Dependency): Simplify code to use scope entities rather than tree structures, to handle properly parent units that are instances rewritten as bodies for inlining purposes. * sem_ch10.adb (Get_Parent_Entity, Implicit_With_On_Parent, Remove_Parents): Handle properly a parent unit that is an instantiation, when the unit has been rewritten as a body for inlining purposes. * par.adb (Goto_List): Global variable to collect goto statements in a given unit, for use in detecting natural loops. * par-ch5.adb (P_Goto_Statement): Add goto to global Goto_List, for use in detecting natural loops. * par-labl.adb (Find_Natural_Loops): Recognize loops create by backwards goto's, and rewrite as a infinite loop, to improve locality of temporaries. * exp_util.adb (Force_Evaluation): Recognize a left-hand side subcomponent that includes an indexed reference, to prevent the generation of copies that would miscompile the desired assignment statement. (Build_Task_Image_Decls): Add a numeric suffix to generated name for string variable, to avoid spurious conflicts with the name of the type of a single protected object. * exp_ch4.adb (Expand_Array_Equality): If indices are distinct, use a loop with an explicit exit statement, to avoid generating an out-of-range value with 'Succ leading to spurious constraint_errors when compiling with -gnatVo. 2004-07-15 Thomas Quinot <quinot@act-europe.fr> * sem_ch4.adb (Analyze_Slice): Always call Analyze on the prefix: it might not be analyzed yet, even if its Etype is already set (case of an unchecked conversion built using Unchecked_Convert_To, for example). If the prefix has already been analyzed, this will be a nop anyway. * exp_ch5.adb (Make_Tag_Ctrl_Assignment): For an assignment of a controller type, or an assignment of a record type with controlled components, copy only user data, and leave the finalization chain pointers untouched. 2004-07-15 Vincent Celier <celier@gnat.com> * make.adb (Collect_Arguments): Improve error message when attempting to compile a source not part of any project, when -x is not used. * prj.ads: (Defined_Variable_Kind): New subtype * prj-attr.adb (Register_New_Package): Two new procedures to register a package with or without its attributes. (Register_New_Attribute): Mew procedure to register a new attribute in a package. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-attr.ads (Attribute_Node_Id): Now a private, self initialized type. (Package_Node_Id): Now a private, self initialized type (Register_New_Package): New procedure to register a package with its attributes. New attribute oriented subprograms: Attribute_Node_Id_Of, Attribute_Kind_Of, Set_Attribute_Kind_Of, Attribute_Name_Of, Variable_Kind_Of, Set_Variable_Kind_Of, Optional_Index_Of, Next_Attribute. New package oriented subprograms: Package_Node_Id_Of, Add_Unknown_Package, First_Attribute_Of, Add_Attribute. * prj-dect.adb (Parse_Attribute_Declaration, Parse_Package_Declaration): Adapt to new spec of Prj.Attr. * prj-makr.adb (Make): Parse existing project file before creating other files. Fail if there was an error during parsing. * prj-proc.adb (Add_Attributes, Process_Declarative_Items): Adapt to new spec of Prj.Attr. * prj-strt.adb (Attribute_Reference, Parse_Variable_Reference): Adapt to new spec of Prj.Attr. 2004-07-15 Richard Kenner <kenner@vlsi1.ultra.nyu.edu> * utils2.c: Fix typo in comment. From-SVN: r84774
2004-07-15 22:34:43 +02:00
Find_Natural_Loops;
2001-10-02 16:23:52 +02:00
end Labl;