+2009-04-17 Nicolas Roche <roche@adacore.com>
+
+ * initialize.c (__gnat_initialize): remove MAX_PATH limitation on each
+ argument length.
+
+2009-04-17 Gary Dismukes <dismukes@adacore.com>
+
+ * sem_elim.adb (Eliminate_Error_Msg): Minor change to error message to
+ cover both calls and attribute references ("call" => "reference").
+
+2009-04-17 Ed Schonberg <schonberg@adacore.com>
+
+ * sem_ch3.adb (Analyze_Subtype_Declaration): A subtype of an access
+ type for which Storage_Size is set to 0 is legal in a pure unit.
+
2009-04-17 Thomas Quinot <quinot@adacore.com>
* exp_ch7.adb: Minor reformatting
/* Adjust gnat_argv to support Unicode characters. */
{
- char arg_utf8[MAX_PATH];
LPWSTR *wargv;
int wargc;
int k;
+ int size;
wargv = CommandLineToArgvW (GetCommandLineW(), &wargc);
for (k=0; k<wargc; k++)
{
- WS2SC (arg_utf8, wargv[k], MAX_PATH);
- gnat_argv[k] = (char *) xmalloc (strlen (arg_utf8) + 1);
- strcpy (gnat_argv[k], arg_utf8);
+ size = WS2SC (NULL, wargv[k], 0);
+ gnat_argv[k] = (char *) xmalloc (size + 1);
+ WS2SC (gnat_argv[k], wargv[k], size);
}
LocalFree (wargv);
-- A Pure library_item must not contain the declaration of a
-- named access type, except within a subprogram, generic
- -- subprogram, task unit, or protected unit (RM 10.2.1(16)).
+ -- subprogram, task unit, or protected unit, or if it has
+ -- a specified Storage_Size of zero (RM05-10.2.1(15.4-15.5)).
if Comes_From_Source (Id)
and then In_Pure_Unit
and then not In_Subprogram_Task_Protected_Unit
+ and then not No_Pool_Assigned (Id)
then
Error_Msg_N
("named access types not allowed in pure unit", N);
for J in Elim_Entities.First .. Elim_Entities.Last loop
if E = Elim_Entities.Table (J).Subp then
Error_Msg_Sloc := Sloc (Elim_Entities.Table (J).Prag);
- Error_Msg_NE ("cannot call subprogram & eliminated #", N, E);
+ Error_Msg_NE ("cannot reference subprogram & eliminated #", N, E);
return;
end if;
end loop;