Differences From Artifact [814ac130dc]:
- File src/natools-constant_indefinite_ordered_maps.adb — part of check-in [c0a78f48d7] at 2015-03-17 22:06:18 on branch trunk — constant_indefinite_ordered_maps: add constructors that provide mutation semantics (user: nat, size: 31509) [annotate] [blame] [check-ins using]
To Artifact [13af223639]:
- File
src/natools-constant_indefinite_ordered_maps.adb
— part of check-in
[bfb15a00ff]
at
2015-08-26 17:27:29
on branch trunk
— constant_indefinite_ordered_maps: work around a regression in newer GNAT versions
For some reason GNAT 5.2 can't find Constant_Reference anymore, so creating new primitive functions so user-defined indexing still works. (user: nat, size: 32105) [annotate] [blame] [check-ins using]
︙ | |||
993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 | 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 | + + + + + + + + + + + + + + + + + + | end Delete; ------------------------------ -- Updatable Map Operations -- ------------------------------ function Constant_Reference_For_Bugged_GNAT (Container : aliased in Updatable_Map; Position : in Cursor) return Constant_Reference_Type is begin return Constant_Reference (Constant_Map (Container), Position); end Constant_Reference_For_Bugged_GNAT; function Constant_Reference_For_Bugged_GNAT (Container : aliased in Updatable_Map; Key : in Key_Type) return Constant_Reference_Type is begin return Constant_Reference (Constant_Map (Container), Key); end Constant_Reference_For_Bugged_GNAT; function Reference (Container : aliased in out Updatable_Map; Position : in Cursor) return Reference_Type is use type Backend_Refs.Immutable_Reference; |
︙ | |||
1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 | 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 | + + | end if; return (Backend => Container.Backend, Element => Container.Backend.Query.Data.Nodes (Position.Index).Element); end Reference; procedure Update_Element (Container : in out Updatable_Map; Position : in Cursor; Process : not null access procedure (Key : in Key_Type; Element : in out Element_Type)) is pragma Unreferenced (Container); Accessor : constant Backend_Refs.Accessor := Position.Backend.Query; begin Process.all (Accessor.Data.Nodes (Position.Index).Key.all, Accessor.Data.Nodes (Position.Index).Element.all); end Update_Element; |
︙ |