+2009-06-25 Pascal Obry <obry@adacore.com>
+
+ * a-stwise.adb, a-stzsea.adb: Fix confusion between 'Length and 'Last.
+
2009-06-25 Emmanuel Briot <briot@adacore.com>
* fmap.ads, make.adb, prj.adb, prj.ads, prj-nmsc.adb, prj-env.adb,
-- Unmapped case
if Mapping'Address = Wide_Maps.Identity'Address then
- Ind := Source'First;
- while Ind <= Source'Length - PL1 loop
+ while Ind <= Source'Last - PL1 loop
if Pattern = Source (Ind .. Ind + PL1) then
Num := Num + 1;
Ind := Ind + Pattern'Length;
-- Mapped case
else
- Ind := Source'First;
- while Ind <= Source'Length - PL1 loop
+ while Ind <= Source'Last - PL1 loop
Cur := Ind;
for K in Pattern'Range loop
if Pattern (K) /= Value (Mapping, Source (Cur)) then
-- Unmapped case
if Mapping'Address = Wide_Wide_Maps.Identity'Address then
- Ind := Source'First;
- while Ind <= Source'Length - PL1 loop
+ while Ind <= Source'Last - PL1 loop
if Pattern = Source (Ind .. Ind + PL1) then
Num := Num + 1;
Ind := Ind + Pattern'Length;
-- Mapped case
else
- Ind := Source'First;
- while Ind <= Source'Length - PL1 loop
+ while Ind <= Source'Last - PL1 loop
Cur := Ind;
for K in Pattern'Range loop
if Pattern (K) /= Value (Mapping, Source (Cur)) then