aix: Fix building fat library for AIX
[official-gcc.git] / gcc / m2 / ChangeLog
blobd8b5c970c34dc982953de37902c5369d38ecdb85
1 2024-05-03  Gaius Mulley  <gaiusmod2@gmail.com>
3         PR modula2/114929
4         * gm2-compiler/M2LangDump.mod (GenQualidentSymString): Add
5         missing return result into identstr.
6         * gm2-compiler/M2Quads.mod (ForLoopLastIteratorVariable): New
7         procedure.
8         (ForLoopLastIteratorConstant): Ditto.
9         (ForLoopLastIterator): Ditto.
10         (BuildForToByDo): Remove LastIterator calculation and call
11         ForLoopLastIterator instead.
12         (FinalValue): Replace with ...
13         (LastIterator): ... this.
15 2024-05-02  Gaius Mulley  <gaiusmod2@gmail.com>
17         PR modula2/113836
18         * gm2-compiler/M2AsmUtil.def: Remove export qualified and
19         unused import.
20         * gm2-compiler/M2LangDump.mod (AddRuleTextDump): New procedure.
21         (AddRuleScopeQualidentDump): Add warning check against unmatched
22         rule.
23         (GenQualidentSymString): New procedure function.
24         (IdentQualidentMatch): New procedure function.
25         (IsRuleFilenameMatch): New procedure function.
26         (CheckRuleMatch): New procedure function.
27         (AddRuleFilenameDump): New procedure function.
28         * gm2-gcc/m2misc.cc (m2misc_warning_m2_dump_filter): New function.
29         * gm2-gcc/m2misc.def (warning_m2_dump_filter): New procedure.
30         * gm2-gcc/m2misc.h (m2misc_warning_m2_dump_filter): New prototype.
31         * gm2-gcc/m2pp.cc (VERBOSE_TYPE_DESC): New define.
32         (m2pp_identifier): Define out verbose type info.
33         (m2pp_constructor): Define out verbose type info.
34         (m2pp_assignment): Define out verbose type info.
35         * gm2-lang.cc (ENABLE_M2DUMP_ALL): Remove.
36         * lang.opt (fm2-dump): Add.
37         (fm2-dump-decl=): Add.
38         (fm2-dump-gimple=): Add.
39         (fm2-dump-quad=): Add.
40         (fm2-dump-filter=): Add.
42 2024-04-25  Gaius Mulley  <gaiusmod2@gmail.com>
44         PR modula2/114836
45         * gm2-compiler/M2Range.mod (FoldTypeAssign): Avoid error
46         string concatenation.
48 2024-04-25  Gaius Mulley  <gaiusmod2@gmail.com>
50         * gm2-compiler/M2FileName.def (CalculateFileName): Remove
51         quoted string in comment.
52         * gm2-compiler/M2Range.mod (FoldTypeParam): Generate dialect
53         specific parameter incompatibility error message.
55 2024-04-23  Jakub Jelinek  <jakub@redhat.com>
57         * lang.opt (fdef=, fmod=): Spelling fix: recognise -> recognize.
59 2024-04-23  Jakub Jelinek  <jakub@redhat.com>
61         * lang.opt (fuse-list=): Spelling fix: finalializations ->
62         finalizations.
64 2024-04-22  Gaius Mulley  <gaiusmod2@gmail.com>
66         PR modula2/114811
67         * gm2-compiler/M2GenGCC.mod (FoldBinarySet): Add condition
68         checking to ensure op2 and op3 are fully resolved before
69         type checking is performed.
71 2024-04-22  Gaius Mulley  <gaiusmod2@gmail.com>
73         PR modula2/114807
74         * gm2-compiler/M2Check.mod (checkUnbounded): Remove unused
75         local variables.
76         (constCheckMeta): Include check for IsReallyPointer in the
77         failure case.
78         * gm2-compiler/M2Quads.mod (MoveWithMode): Remove CopyConstString.
79         * gm2-compiler/SymbolTable.def (IsHiddenReallyPointer): Export.
80         * gm2-compiler/SymbolTable.mod (SkipHiddenType): Remove.
81         (IsReallyPointer): Include IsHiddenReallyPointer test.
83 2024-04-20  Gaius Mulley  <gaiusmod2@gmail.com>
85         PR modula2/112893
86         * gm2-compiler/M2Check.mod (GetProcedureProcType): Import.
87         (getType): Return value using GetProcedureProcType if sym is a
88         procedure.
89         * gm2-compiler/M2Range.mod (FoldTypeExpr): Remove quad if
90         expression is type compatible.
91         * gm2-compiler/SymbolTable.def (GetProcedureProcType): New
92         procedure function.
93         * gm2-compiler/SymbolTable.mod (Procedure): Add ProcedureType.
94         (MakeProcedure): Initialize ProcedureType.
95         (PutParam): Call AddProcedureProcTypeParam.
96         (PutVarParam): Call AddProcedureProcTypeParam.
97         (AddProcedureProcTypeParam): New procedure.
98         (GetProcedureProcType): New procedure function.
100 2024-04-16  Gaius Mulley  <gaiusmod2@gmail.com>
102         PR modula2/114745
103         * gm2-compiler/M2Code.mod (DumpLangDecl): Replace with ...
104         (GetDumpDecl): ... this.
105         (DumpLangGimple): Replace with ...
106         (GetDumpGimple): ... this.
107         * gm2-compiler/M2GenGCC.mod:
108         * gm2-compiler/M2LangDump.mod (GetDumpLangQuadFilename): Replace with ...
109         (GetDumpQuadFilename): ... this.
110         (GetDumpLangDeclFilename): Replace with ...
111         (GetDumpDeclFilename): ... this.
112         (GetDumpLangGimpleFilename): Replace with ...
113         (GetDumpGimpleFilename): ... this.
114         * gm2-compiler/M2Options.def (GetDumpLangDeclFilename): New
115         procedure function.
116         (GetDumpDeclFilename): Ditto.
117         (SetDumpLangDeclFilename): New procedure.
118         (SetDumpDeclFilename): Ditto.
119         (GetDumpLangQuadFilename): New procedure function.
120         (GetDumpQuadFilename): Ditto
121         (SetDumpLangQuadFilename): New procedure.
122         (SetDumpQuadFilename): Ditto.
123         (GetDumpLangGimpleFilename): New procedure function.
124         (GetDumpGimpleFilename): Ditto.
125         (SetDumpLangGimpleFilename): New procedure.
126         (SetDumpGimpleFilename): Ditto.
127         (GetDumpLangGimple): New procedure function.
128         (SetM2Dump): New procedure.
129         (GetDumpGimple): New procedure function.
130         (GetDumpQuad): Ditto.
131         (GetDumpDecl): Ditto.
132         * gm2-compiler/M2Options.mod (DumpLangDeclFilename): Remove.
133         (DumpLangQuadFilename): Ditto.
134         (DumpLangGimpleFilename): Ditto.
135         (DumpDeclFilename): New variable.
136         (DumpQuadFilename): Ditto.
137         (DumpGimpleFilename): Ditto.
138         (DebugTraceTree): New variable.
139         (SetQuadDebugging): Rewrite.
140         (GetDumpLangDeclFilename): Replace with ...
141         (GetDumpDeclFilename): ... this.
142         (SetDumpLangQuadFilename): Replace with ...
143         (SetDumpQuadFilename): ... this.
144         (GetDumpLangGimpleFilename): Replace with ...
145         (GetDumpGimpleFilename): ... this.
146         (SetDumpLangGimpleFilename): Replace with ...
147         (SetDumpGimpleFilename): ... this.
148         (GetDumpLangGimple): Remove.
149         (MatchDump): New procedure function.
150         (SetM2Dump): New procedure.
151         (GetDumpGimple): New procedure function.
152         (GetDumpQuad): Ditto.
153         (GetDumpDecl): Ditto.
154         (GetDumpLangGimple): Ditto.
155         * gm2-compiler/M2Quads.mod (BreakAtQuad): Assigned to 140.
156         (BuildTypeCoercion): Add ConstExpr parameter.
157         Check for const parameter in a const expression.
158         Create a constant temporary if in a const expression.
159         (BuildCastFunction): Pass ConstExpr to BuildTypeCoercion.
160         (BuildFunctionCall): Pass ConstExpr to BuildTypeCoercion.
161         * gm2-compiler/PCSymBuild.mod (buildConstFunction): Test for Cast
162         and call InitConvert.
163         (ErrorConstFunction): Add CAST to the error message.
164         * gm2-compiler/SymbolTable.mod (GetConstStringContent): Remove
165         unused procedure.
166         * gm2-gcc/m2decl.cc (m2decl_DeclareKnownConstant): Copy value
167         and change type of value.
168         * gm2-gcc/m2options.h (M2Options_GetDumpLangDeclFilename): Remove.
169         (M2Options_SetDumpLangDeclFilename): Ditto.
170         (M2Options_GetDumpLangQuadFilename): Ditto.
171         (M2Options_SetDumpLangQuadFilename): Ditto.
172         (M2Options_GetDumpLangGimpleFilename): Ditto.
173         (M2Options_SetDumpLangGimpleFilename): Ditto.
174         (M2Options_GetDumpLangGimple): Ditto.
175         (M2Options_GetDumpDeclFilename): New function.
176         (M2Options_SetDumpDeclFilename): Ditto.
177         (M2Options_GetDumpQuadFilename): Ditto.
178         (M2Options_SetDumpQuadFilename): Ditto.
179         (M2Options_GetDumpGimpleFilename): Ditto.
180         (M2Options_SetDumpGimpleFilename): Ditto.
181         (M2Options_SetM2Dump): Ditto.
182         (M2Options_GetDumpGimple): Ditto.
183         * gm2-gcc/m2pp.cc (GM2): New define.
184         (m2pp_type_lowlevel): Remove linefeed.
185         (m2pp_identifier): Add type description for const.
186         (m2pp_assignment): Display lhs/rhs types.
187         (m2pp_dump_gimple): Replace GetDumpLangGimple with GetDumpGimple.
188         * gm2-lang.cc (ENABLE_QUAD_DUMP_ALL): Remove.
189         (ENABLE_M2DUMP_ALL): New define.
190         (gm2_langhook_handle_option): Remove commented options
191         OPT_fdump_lang_all, OPT_fdump_lang_decl_, OPT_fdump_lang_gimple,
192         OPT_fdump_lang_gimple_, OPT_fdump_lang_quad and
193         OPT_fdump_lang_quad_.
194         Add commented options OPT_fm2_dump_, OPT_fm2_dump_decl_,
195         OPT_fm2_dump_gimple_ and OPT_fm2_dump_quad_.
197 2024-04-09  Gaius Mulley  <gaiusmod2@gmail.com>
199         * tools-src/makeSystem: Invoke ${COMPILER} once and adjust
200         the echo string to expand the shell variables with -wrapper
201         gdb, --args.
203 2024-04-09  Gaius Mulley  <gaiusmod2@gmail.com>
205         PR modula2/114648
206         * gm2-compiler/M2Options.mod (LineDirectives): Initially
207         set to true.
209 2024-04-06  Gaius Mulley  <gaiusmod2@gmail.com>
211         PR modula2/114617
212         * gm2-compiler/M2GenGCC.mod (CodeStatememt): Add quad trace.
213         (ResolveConstantExpressions): Add parameter p to FoldIfLess,
214         FoldIfGre, FoldIfLessEqu, FoldIfGreEqu, FoldIfEqu, FoldIfNotEqu,
215         FoldIfIn and FoldIfNotIn.
216         (CodeInline): Add constExpr variable and pass it to GetQuadOtok.
217         (CodeReturnValue): Ditto.
218         (CodeParam): Ditto.
219         (FoldStringLength): Ditto.
220         (FoldStringConvertM2nul): Ditto.
221         (FoldStringConvertCnul): Ditto.
222         (DeclaredOperandsBecomes): Ditto.
223         (TypeCheckBecomes): Ditto.
224         (PerformFoldBecomes): Ditto.
225         (CodeBecomes): Ditto.
226         (CheckElementSetTypes): Ditto.
227         (CodeBinarySet): Ditto.
228         (PerformCodeIfLess): Ditto.
229         (PerformCodeIfGre): Ditto.
230         (PerformCodeIfLessEqu): Ditto.
231         (PerformCodeIfGreEqu): Ditto.
232         (PerformCodeIfEqu): Ditto.
233         (PerformCodeIfNotEqu): Ditto.
234         (IsValidExpressionRelOp): Ditto.
235         (PerformCodeIfIn): Ditto.
236         (PerformCodeIfNotIn): Ditto.
237         (CodeXIndr): Ditto.
238         (QuadCondition): New procedure function.
239         (IsBooleanRelOpPattern): Ditto.
240         (FoldBooleanRelopPattern): Ditto.
241         (FoldIfGre): Check for boolean relop constant expression and
242         add parameter p.
243         (FoldIfLessEqu): Ditto.
244         (FoldIfIn): Ditto.
245         (FoldIfEqu): Ditto.
246         (FoldIfNotIn): Ditto.
247         (FoldIfGreEqu): New procedure.
248         (FoldIfNotEqu): Ditto.
249         * gm2-compiler/M2Optimize.mod (ReduceBranch): Add constExpr
250         variable and pass it to GetQuadOtok.
251         * gm2-compiler/M2Quads.def (IsBecomes): New procedure function.
252         (IsDummy): Ditto.
253         (IsQuadConstExpr): Ditto.
254         (SetQuadConstExpr): Ditto.
255         (GetQuadDest): New procedure.
256         (GetQuadOp1): New procedure.
257         (GetQuadOp2): New procedure.
258         (GetQuadOp3): New procedure.
259         (GetQuadOtok): New procedure.
260         (GetQuadOTypetok): New procedure.
261         (PutQuadOtok): New procedure.
262         (IsInConstParameters): New procedure function.
263         * gm2-compiler/M2Quads.mod (IsBecomes): New procedure function.
264         (IsDummy): Ditto.
265         (IsQuadConstExpr): Ditto.
266         (SetQuadConstExpr): Ditto.
267         (GetQuadDest): New procedure.
268         (GetQuadOp1): New procedure.
269         (GetQuadOp2): New procedure.
270         (GetQuadOp3): New procedure.
271         (GetQuadOtok): New procedure.
272         (GetQuadOTypetok): New procedure.
273         (PutQuadOtok): New procedure.
274         (IsInConstParameters): New procedure function.
275         (ConstStack): Remove to ...
276         (ConstExprStack): ... this.
277         (ConstParamStack): New variable and initialize.
278         (QuadFrame): New field ConstExpr.
279         (GetQuadOtok): Add parameter constExpr and assign.
280         (PutQuadOtok): Add constExpr parameter and assign.
281         (PutQuadOType): Ditto.
282         (GetQuadOTypetok): Ditto.
283         (EraseQuad): Assign ConstExpr to FALSE.
284         (FoldSubrange): Set ConstExpr to FALSE in BecomesOp.
285         (PushInConstParameters): New procedure.
286         (PopInConstParameters): New procedure.
287         (IsInConstParameters): New procedure function.
288         * gm2-compiler/M2SymInit.mod (IssueConditional): Add
289         constExpr boolean variable.
290         (CheckReadBeforeInitQuad): Ditto.
291         (trashParam): Ditto.
292         * gm2-compiler/P3Build.bnf (ConstExpression): Call
293         PushInConstExpression and PopInConstExpression.
294         (ConstSetOrQualidentOrFunction): Call
295         PushInConstParameters and PopInConstParameters.
296         * gm2-compiler/PCBuild.bnf (ConstExpression): Call
297         PushInConstExpression and PopInConstExpression.
298         * gm2-compiler/PHBuild.bnf: Ditto
299         * gm2-gcc/m2expr.cc (m2expr_BuildCondIfExpression): New
300         function.
301         * gm2-gcc/m2expr.def (BuildCondIfExpression): New prototype.
302         * gm2-gcc/m2expr.h (m2expr_BuildCondIfExpression): New function.
304 2024-04-05  Christophe Lyon  <christophe.lyon@linaro.org>
306         * Make-lang.in (m2.install-dvi): New rule.
308 2024-04-02  Gaius Mulley  <gaiusmod2@gmail.com>
310         PR modula2/114565
311         * gm2-compiler/M2GenGCC.mod (CodeStatement): Test
312         GetDebugTraceQuad before calling DisplayQuad.
313         * gm2-compiler/M2LexBuf.mod (NumberIO): Import CardToStr.
314         (GetToken): Test GetDebugTraceToken before writing the
315         token number or token line.
316         * gm2-compiler/M2Options.def (SetDebugTraceQuad): Rename to
317         (SetM2DebugTraceFilter): ...this.
318         (SetDebugTraceAPI): Remove.
319         (GetDebugTraceQuad): New procedure function.
320         (GetDebugTraceTree): Ditto.
321         (GetDebugTraceToken): Ditto.
322         (GetDebugTraceLine): Ditto.
323         (GetDebugFunctionLineNumbers): Ditto.
324         * gm2-compiler/M2Options.mod (DebugFunctionLineNumbers): New
325         boolean variable.
326         (DebugTraceQuad): Ditto.
327         (DebugTraceTree): Ditto.
328         (DebugTraceLine): Ditto.
329         (DebugTraceToken): Ditto.
330         (errors1): New procedure.
331         (SetDebugTraceQuad): Remove.
332         (SetM2DebugTraceFilter): New procedure implemented.
333         (SetM2DebugTrace): Ditto.
334         (GetDebugTraceQuad): Ditto.
335         (GetDebugTraceToken ): Ditto.
336         (GetDebugTraceLine): Ditto.
337         (SetDebugTraceLine): Remove.
338         * gm2-compiler/M2Quads.mod (GenQuadOTrash): Test
339         GetDebugTraceQuad and call DisplayQuad.
340         (GenQuadOTypetok): Ditto.
341         * gm2-compiler/SymbolTable.mod: Replace
342         DebugFunctionLineNumbers with GetDebugFunctionLineNumbers.
343         * gm2-gcc/init.cc (_M2_M2LangDump_init): Add prototype.
344         (init_PerCompilationInit): Add call.
345         * gm2-gcc/m2misc.cc (m2misc_cerror): New function.
346         (m2misc_error): Ditto.
347         * gm2-gcc/m2misc.def (error): New procedure.
348         (cerror): Ditto.
349         * gm2-gcc/m2misc.h (m2misc_cerror): New prototype.
350         (m2misc_error): Ditto.
351         * gm2-gcc/m2options.h (M2Options_SetDebugTraceQuad): New
352         prototype.
353         (M2Options_SetDebugTraceAPI): Remove.
354         (M2Options_GetDebugTraceToken): New prototype.
355         (M2Options_GetDebugTraceLine): Ditto.
356         (M2Options_SetDebugFunctionLineNumbers): Ditto.
357         (M2Options_GetDebugFunctionLineNumbers): Ditto.
358         (M2Options_SetM2DebugTraceFilter): Ditto.
359         * gm2-lang.cc (gm2_langhook_init_options): Remove
360         OPT_fdebug_trace_quad case.
361         Remove OPT_fdebug_trace_api case.
362         Add OPT_fm2_debug_trace_ case.
363         * lang.opt (fm2-debug-trace): New option.
364         (fdebug-trace-api): Remove.
365         (fdebug-trace-quad): Remove.
366         * m2.flex (m2flex_M2Error): Check s for NULL.
367         (skipnewline): New function.
368         (consumeLine): Call traceline.
370 2024-04-01  Gaius Mulley  <gaiusmod2@gmail.com>
372         PR modula2/114548
373         * gm2-compiler/M2Quads.mod (ConvertToAddress): Pass
374         procedure, false parameters to BuildConvertFunction.
375         (PushOne): Pass procedure, true parameters to
376         BuildConvertFunction.
377         Remove usused parameter internal.
378         (BuildPseudoBy): Remove parameter to PushOne.
379         (BuildIncProcedure): Ditto.
380         (BuildDecProcedure): Ditto.
381         (BuildFunctionCall): Add ConstExpr parameter to
382         BuildPseudoFunctionCall.
383         (BuildConstFunctionCall): Add procedure and true to
384         BuildConvertFunction.
385         (BuildPseudoFunctionCall): Add ConstExpr parameter.
386         Pass ProcSym and ConstExpr to BuildLengthFunction,
387         BuildConvertFunction, BuildOddFunction, BuildAbsFunction,
388         BuildCapFunction, BuildValFunction, BuildChrFunction,
389         BuildOrdFunction, BuildIntFunction, BuildTruncFunction,
390         BuildFloatFunction, BuildAddAdrFunction, BuildSubAdrFunction,
391         BuildDifAdrFunction, BuildCastFunction, BuildReFunction,
392         BuildImFunction and BuildCmplxFunction.
393         (BuildAddAdrFunction): Add ProcSym, ConstExpr parameters and
394         check for constant parameters.
395         (BuildSubAdrFunction): Ditto.
396         (BuildDifAdrFunction): Ditto.
397         (ConstExprError): Ditto.
398         (BuildLengthFunction): Ditto.
399         (BuildOddFunction): Ditto.
400         (BuildAbsFunction): Ditto.
401         (BuildCapFunction): Ditto.
402         (BuildChrFunction): Ditto.
403         (BuildOrdFunction): Ditto.
404         (BuildIntFunction): Ditto.
405         (BuildValFunction): Ditto.
406         (BuildCastFunction): Ditto.
407         (BuildConvertFunction): Ditto.
408         (BuildTruncFunction): Ditto.
409         (BuildFloatFunction): Ditto.
410         (BuildReFunction): Ditto.
411         (BuildImFunction): Ditto.
412         (BuildCmplxFunction): Ditto.
414 2024-03-31  Christophe Lyon  <christophe.lyon@linaro.org>
416         * Make-lang.in (m2.install-info): Fix rule.
418 2024-03-31  Christophe Lyon  <christophe.lyon@linaro.org>
420         * Make-lang.in (install-html): New rule.
422 2024-03-28  Gaius Mulley  <gaiusmod2@gmail.com>
424         PR modula2/114520
425         * gm2-compiler/P0SyntaxCheck.bnf (DetectImport): New
426         procedure.
427         (EnableImportCheck): New boolean.
428         (Expect): Call DetectImport.
429         (Export): Set EnableImportCheck TRUE before ';' and FALSE
430         afterwards.
432 2024-03-28  Gaius Mulley  <(no_default)>
434         PR modula2/114517
435         * gm2-compiler/M2Options.def (SetCpp): Add comment.
436         (GetCpp): Move after SetCpp.
437         (GetLineDirectives): New procedure function.
438         * gm2-compiler/M2Options.mod (GetLineDirectives): New
439         procedure function.
440         * gm2-gcc/m2options.h (M2Options_GetLineDirectives): New
441         prototype.
442         * gm2-lang.cc (gm2_langhook_init_options): OPT_fcpp only
443         assert if !value.
444         * m2.flex: Test GetLineDirectives before changing to LINE0
445         state.
447 2024-03-28  Gaius Mulley  <gaiusmod2@gmail.com>
449         * target-independent/m2/Builtins.texi: Rebuilt.
450         * target-independent/m2/gm2-libs.texi: Rebuilt.
452 2024-03-26  Gaius Mulley  <gaiusmod2@gmail.com>
454         PR modula2/114478
455         * gm2-gcc/m2builtins.cc (struct builtin_macro_definition): New struct.
456         (lookup_builtin_macro): New function.
457         (m2builtins_BuildBuiltinTree): Rewrite to lookup builtin function
458         and builtin macro.
459         (lookup_builtin_function): New function.
460         (define_builtin): Rename parameter type to prototype push macro
461         definition to builtin_macros vector.
462         (define_builtin_ext): New function.
463         (define_builtin_math): New function.
464         (m2builtins_init): Add isgreater, isless, isgreaterequal,
465         islessequal, islessgreater, isunordered, isnormal to macro definitions.
466         * gm2-libs/Builtins.def (isgreater): New procedure function.
467         (isgreaterf): Ditto.
468         (isgreaterl): Ditto.
469         (isgreaterequal): Ditto.
470         (isgreaterequalf): Ditto.
471         (isgreaterequall): Ditto.
472         (isless): Ditto.
473         (islessf): Ditto.
474         (islessl): Ditto.
475         (islessequal): Ditto.
476         (islessequalf): Ditto.
477         (islessequall): Ditto.
478         (islessgreater): Ditto.
479         (islessgreaterf): Ditto.
480         (islessgreaterl): Ditto.
481         (isunordered): Ditto.
482         (isunorderedf): Ditto.
483         (isunorderedl): Ditto.
484         (iseqsig): Ditto.
485         (iseqsigf): Ditto.
486         (iseqsigl): Ditto.
487         (isnormal): Ditto.
488         (isnormalf): Ditto.
489         (isnormall): Ditto.
490         (isinf_sign): Ditto.
491         (isinf_signf): Ditto.
492         (isinf_signl): Ditto.
493         * gm2-libs/Builtins.mod (isgreater): New procedure function.
494         (isgreaterf): Ditto.
495         (isgreaterl): Ditto.
496         (isgreaterequal): Ditto.
497         (isgreaterequalf): Ditto.
498         (isgreaterequall): Ditto.
499         (isless): Ditto.
500         (islessf): Ditto.
501         (islessl): Ditto.
502         (islessequal): Ditto.
503         (islessequalf): Ditto.
504         (islessequall): Ditto.
505         (islessgreater): Ditto.
506         (islessgreaterf): Ditto.
507         (islessgreaterl): Ditto.
508         (isunordered): Ditto.
509         (isunorderedf): Ditto.
510         (isunorderedl): Ditto.
511         (iseqsig): Ditto.
512         (iseqsigf): Ditto.
513         (iseqsigl): Ditto.
514         (isnormal): Ditto.
515         (isnormalf): Ditto.
516         (isnormall): Ditto.
517         (isinf_sign): Ditto.
518         (isinf_signf): Ditto.
519         (isinf_signl): Ditto.
521 2024-03-25  Gaius Mulley  <gaiusmod2@gmail.com>
523         * Make-lang.in (doc/m2.pdf): Add line break.
524         * target-independent/m2/Builtins.texi: Rebuilt.
525         * target-independent/m2/gm2-libs.texi: Rebuilt.
527 2024-03-23  Gaius Mulley  <gaiusmod2@gmail.com>
529         PR modula2/114444
530         * gm2-compiler/M2Quads.mod (BuildTruncFunction): Correct
531         error format specifier.
532         (BuildFloatFunction): Correct error format specifier.
534 2024-03-23  Gaius Mulley  <gaiusmod2@gmail.com>
536         PR modula2/114443
537         * m2.flex: Call AddTokCharStar with a stringtok if
538         end of line is reached without a closing quote.
540 2024-03-22  Gaius Mulley  <gaiusmod2@gmail.com>
542         PR modula2/114422
543         * gm2-compiler/M2Quads.mod (BuildConstructor): Add escape
544         character.
546 2024-03-21  Gaius Mulley  <gaiusmod2@gmail.com>
548         PR modula2/113836
549         * Make-lang.in (GM2_C_OBJS): Add m2/gm2-gcc/m2pp.o.
550         (m2/m2pp.o): Remove rule.
551         (GM2-COMP-BOOT-DEFS): Add M2LangDump.def.
552         (GM2-COMP-BOOT-MODS): Add M2LangDump.mod.
553         (GM2-GCC-DEFS): Add M2LangDump.def.
554         (GM2-GCC-MODS): Add M2LangDump.mod.
555         * gm2-compiler/M2CaseList.mod (WriteCase): Rewrite.
556         * gm2-compiler/M2Code.mod (DoModuleDeclare): Call
557         DumpFilteredResolver depending upon DumpLangDecl.
558         (DoCodeBlock): Call CreateDumpGimple depending upon
559         DumpLangGimple.
560         (Code): Replace DisplayQuadList blocks with DumpQuadruples.
561         (DisplayQuadsInScope): Remove.
562         (DisplayQuadNumbers): Remove.
563         (CodeBlock): Rewrite.
564         * gm2-compiler/M2GCCDeclare.def (IncludeDumpSymbol): New procedure.
565         (DumpFilteredResolver): New procedure.
566         (DumpFilteredDefinitive): New procedure.
567         * gm2-compiler/M2GCCDeclare.mod (IncludeDumpSymbol): New procedure.
568         (DumpFilteredResolver): New procedure.
569         (DumpFilteredDefinitive): New procedure.
570         (doInclude): Rewrite to use GetDumpFile.
571         (WatchIncludeList): Remove fixed debugging value.
572         (doExclude): Rewrite to use GetDumpFile.
573         (DeclareTypesConstantsProceduresInRange): Remove fixed debugging
574         values.
575         (PreAddModGcc): Rename parameter t as tree.
576         (IncludeGetNth): Rewrite to use GetDumpFile.
577         (IncludeType): Ditto.
578         (IncludeSubscript): Ditto.
579         (PrintLocalSymbol): Ditto.
580         (PrintLocalSymbols): Ditto.
581         (IncludeGetVarient): Ditto.
582         (PrintDeclared): Ditto.
583         (PrintAlignment): Ditto.
584         (PrintDecl): Ditto.
585         (PrintScope): Ditto.
586         (PrintProcedure): Ditto.
587         (PrintSym): Ditto.
588         (PrintSymbol): Ditto.
589         (PrintTerse): Ditto.
590         * gm2-compiler/M2Options.def (GetDumpLangDeclFilename): New
591         procedure function.
592         (SetDumpLangDeclFilename): New procedure.
593         (GetDumpLangQuadFilename): New procedure function.
594         (SetDumpLangQuadFilename): New procedure.
595         (GetDumpLangGimpleFilename): New procedure function.
596         (SetDumpLangGimpleFilename): New procedure.
597         (SetM2DumpFilter): New procedure.
598         (GetM2DumpFilter): New procedure function.
599         (GetDumpLangGimple): New procedure function.
600         * gm2-compiler/M2Options.mod (GetDumpLangDeclFilename): New
601         procedure function.
602         (SetDumpLangDeclFilename): New procedure.
603         (GetDumpLangQuadFilename): New procedure function.
604         (SetDumpLangQuadFilename): New procedure.
605         (GetDumpLangGimpleFilename): New procedure function.
606         (SetDumpLangGimpleFilename): New procedure.
607         (SetM2DumpFilter): New procedure.
608         (GetM2DumpFilter): New procedure function.
609         (GetDumpLangGimple): New procedure function.
610         * gm2-compiler/M2Quads.def (DumpQuadruples): New procedure.
611         * gm2-compiler/M2Quads.mod (DumpUntil): New procedure.
612         (GetCtorInit): New procedure function.
613         (GetCtorFini): New procedure function.
614         (DumpQuadrupleFilter): New procedure function.
615         (DumpQuadrupleAll): New procedure.
616         (DisplayQuadList): Remove procedure.
617         (DumpQuadruples): New procedure.
618         (DisplayQuadRange): Rewrite.
619         (DisplayQuad): Ditto.
620         (DisplayProcedureAttributes): Ditto.
621         (WriteOperator): Ditto.
622         (WriteMode): Ditto.
623         * gm2-compiler/M2Scope.mod (ForeachScopeBlockDo2): Replace
624         DisplayQuadruples with TraceQuadruples.
625         (ForeachScopeBlockDo3): Replace DisplayQuadruples with
626         TraceQuadruples.
627         * gm2-compiler/SymbolConversion.def (Gcc2Mod): New procedure function.
628         * gm2-compiler/SymbolConversion.mod: New procedure function.
629         * gm2-gcc/m2misc.cc (m2misc_DebugTree): New function.
630         (m2misc_DebugTreeChain): New function.
631         * gm2-gcc/m2options.h (M2Options_GetDumpLangDeclFilename): New
632         prototype.
633         (M2Options_SetDumpLangDeclFilename): New prototype.
634         (M2Options_GetDumpLangQuadFilename): New prototype.
635         (M2Options_SetDumpLangQuadFilename): New prototype.
636         (M2Options_GetDumpLangGimpleFilename): New prototype.
637         (M2Options_SetDumpLangGimpleFilename): New prototype.
638         (M2Options_GetDumpLangGimple): New prototype.
639         (M2Options_SetM2DumpFilter): New prototype.
640         (M2Options_GetM2DumpFilter): New prototype.
641         * m2pp.cc: Move to...
642         * gm2-gcc/m2pp.cc: ...here.
643         * m2pp.h: Move to...
644         * gm2-gcc/m2pp.h: ...here.
645         * gm2-gcc/m2statement.cc (m2statement_BuildEndFunctionCode): Call
646         m2pp_dump_gimple.
647         * gm2-lang.cc (ENABLE_QUAD_DUMP_ALL): New define.
648         (gm2_langhook_init_options): Add switch cases for proposed new
649         command line options.
650         * gm2-libs/DynamicStrings.def (ReverseIndex): New procedure
651         function.
652         * gm2-libs/DynamicStrings.mod: New procedure function.
653         * gm2-compiler/M2LangDump.def: New file.
654         * gm2-compiler/M2LangDump.mod: New file.
655         * gm2-gcc/m2langdump.h: New file.
656         * gm2-gcc/m2pp.def: New file.
658 2024-03-21  Gaius Mulley  <gaiusmod2@gmail.com>
660         PR modula2/114418
661         * gm2-compiler/PCSymBuild.mod (PushConstFunctionType): Check
662         func against NulSym and issue an error.
664 2024-03-18  Gaius Mulley  <gaiusmod2@gmail.com>
666         PR modula2/114380
667         * gm2-compiler/SymbolTable.mod (GetLowestType): Do not
668         skip over a set type, but return sym.
670 2024-03-17  Gaius Mulley  <gaiusmod2@gmail.com>
672         PR modula2/114296
673         * gm2-compiler/M2ALU.mod (ElementsSolved): Add tokenno parameter.
674         Add constant checks and generate error messages.
675         (EvalSetValues): Pass tokenno parameter to ElementsSolved.
676         * gm2-compiler/M2LexBuf.mod (stop): New procedure.
677         (MakeVirtualTok): Call stop if caret = BadTokenNo.
678         * gm2-compiler/M2Quads.def (BuildNulExpression): Add tokpos
679         parameter.
680         (BuildSetStart): Ditto.
681         (BuildEmptySet): Ditto.
682         (BuildConstructorEnd): Add startpos parameter.
683         (BuildTypeForConstructor): Add tokpos parameter.
684         * gm2-compiler/M2Quads.mod (BuildNulExpression): Add tokpos
685         parameter and push tokpos to the quad stack.
686         (BuildSetStart): Add tokpos parameter and push tokpos.
687         (BuildSetEnd): Rewrite.
688         (BuildEmptySet): Add tokpos parameter and push tokpos with
689         the set type.
690         (BuildConstructorStart): Pop typepos.
691         (BuildConstructorEnd): Add startpos parameter.
692         Create valtok from startpos and cbratokpos.
693         (BuildTypeForConstructor): Add tokpos parameter.
694         * gm2-compiler/M2Range.def (InitAssignmentRangeCheck): Rename
695         d to des and e to expr.
696         Add destok and exprtok parameters.
697         * gm2-compiler/M2Range.mod (InitAssignmentRangeCheck): Rename
698         d to des and e to expr.
699         Add destok and exprtok parameters.
700         Save destok and exprtok into range record.
701         (FoldAssignment): Pass exprtok to TryDeclareConstant.
702         * gm2-compiler/P3Build.bnf (ComponentValue): Rewrite.
703         (Constructor): Rewrite.
704         (ConstSetOrQualidentOrFunction): Rewrite.
705         (SetOrQualidentOrFunction): Rewrite.
706         * gm2-compiler/PCBuild.bnf (ConstSetOrQualidentOrFunction): Rewrite.
707         (SetOrQualidentOrFunction): Rewrite.
708         * gm2-compiler/PHBuild.bnf (Constructor): Rewrite.
709         (ConstSetOrQualidentOrFunction): Rewrite.
711 2024-03-14  Gaius Mulley  <gaiusmod2@gmail.com>
713         PR modula2/114294
714         * gm2-compiler/M2Quads.mod (BuildConstHighFromSym):
715         Call PutConst to assign the type Cardinal in the result
716         constant.
718 2024-03-14  Gaius Mulley  <gaiusmod2@gmail.com>
720         PR modula2/114333
721         * gm2-compiler/M2GenGCC.mod (CodeStatement): Remove op1, op2 and
722         op3 parameters to CodeIfLess, CodeIfLessEqu, CodeIfGreEqu, CodeIfGre,
723         CodeIfIn, CodeIfNotIn.
724         (CodeIfLess): Rewrite.
725         (PerformCodeIfLess): New procedure.
726         (CodeIfLess): Rewrite.
727         (PerformCodeIfLess): New procedure.
728         (CodeIfLessEqu): Rewrite.
729         (PerformCodeIfLessEqu): New procedure.
730         (CodeIfGreEqu): Rewrite.
731         (PerformCodeIfGreEqu): New procedure.
732         (CodeIfGre): Rewrite.
733         (PerformCodeIfGre): New procedure.
734         (CodeIfIn): Rewrite.
735         (PerformCodeIfIn): New procedure.
736         (CodeIfNotIn): Rewrite.
737         (PerformCodeIfNotIn): New procedure.
739 2024-03-14  Gaius Mulley  <gaiusmod2@gmail.com>
741         PR modula2/114333
742         * gm2-compiler/M2Check.mod (checkUnbounded): New procedure
743         function.
744         (checkArrayTypeEquivalence): Extend checking to cover unbounded
745         arrays, arrays and constants.
746         (IsTyped): Simplified the expression and corrected a test for
747         IsConstructor.
748         (checkTypeKindViolation): New procedure function.
749         (doCheckPair): Call checkTypeKindViolation.
750         * gm2-compiler/M2GenGCC.mod (CodeStatement): Remove parameters
751         to CodeEqu and CodeNotEqu.
752         (PerformCodeIfEqu): New procedure.
753         (CodeIfEqu): Rewrite.
754         (PerformCodeIfNotEqu): New procedure.
755         (CodeIfNotEqu): Rewrite.
756         * gm2-compiler/M2Quads.mod (BuildRelOpFromBoolean): Correct
757         comment.
759 2024-03-11  Gaius Mulley  <gaiusmod2@gmail.com>
761         PR modula2/114295
762         * gm2-compiler/M2Batch.mod (MakeProgramSource): Call PutDeclared
763         if the module is known.
764         (MakeDefinitionSource): Ditto.
765         (MakeImplementationSource): Ditto.
766         * gm2-compiler/M2Comp.mod (ExamineHeader): New procedure.
767         (ExamineCompilationUnit): Rewrite.
768         (PeepInto): Rewrite.
769         * gm2-compiler/M2Error.mod (NewError): Remove default call to
770         GetTokenNo.
771         * gm2-compiler/M2Quads.mod (callRequestDependant): Push tokno with
772         Adr.
773         (BuildStringAdrParam): Ditto.
774         (doBuildBinaryOp): Push OperatorPos on the bool stack.
775         (BuildRelOp): Ditto.
776         * gm2-compiler/P2Build.bnf (SetType): Pass set token pos to
777         BuildSetType.
778         (PointerType): Pass pointer token pos to BuildPointerType.
779         * gm2-compiler/P2SymBuild.def (BuildPointerType): Add parameter
780         pointerpos.
781         (BuildSetType): Add parameter setpos.
782         * gm2-compiler/P2SymBuild.mod (BuildPointerType): Add parameter
783         pointerpos.  Build combined token and use it when creating a
784         pointer type.
785         (BuildSetType): Add parameter setpos.  Build combined token and
786         use it when creating a set type.
787         * gm2-compiler/SymbolTable.mod (DebugUnknownToken): New constant.
788         (CheckTok): New procedure function.
789         (MakeProcedure): Call CheckTok.
790         (MakeRecord): Ditto.
791         (MakeVarient): Ditto.
792         (MakeEnumeration): Ditto.
793         (MakeHiddenType): Ditto.
794         (MakeConstant): Ditto.
795         (MakeConstStringCnul): Ditto.
796         (MakeSubrange): Ditto.
797         (MakeTemporary): Ditto.
798         (MakeVariableForParam): Ditto.
799         (MakeParameterHeapVar): Ditto.
800         (MakePointer): Ditto.
801         (MakeSet): Ditto.
802         (MakeUnbounded): Ditto.
803         (MakeProcType): Ditto.
805 2024-03-08  Gaius Mulley  <gaiusmod2@gmail.com>
807         * gm2-compiler/M2Quads.mod (Init): Use InitIndexTuned with
808         default size 65K.
809         * gm2-compiler/SymbolConversion.mod (Init): Ditto.
810         * gm2-compiler/SymbolTable.mod (BEGIN): Ditto.
811         * mc-boot/GM2Dependent.cc: Rebuild.
812         * mc-boot/GM2Dependent.h: Rebuild.
813         * mc-boot/GM2RTS.cc: Rebuild.
814         * pge-boot/GIndexing.cc: Rebuild.
815         * pge-boot/GIndexing.h: Rebuild.
816         * pge-boot/GM2Dependent.cc: Rebuild.
817         * pge-boot/GM2Dependent.h: Rebuild.
818         * pge-boot/GM2RTS.cc: Rebuild.
820 2024-03-07  Gaius Mulley  <gaiusmod2@gmail.com>
822         PR modula2/109969
823         * gm2-compiler/M2LexBuf.def (TokenToLineNo): Rename parameter.
824         (TokenToColumnNo): Rename parameter.
825         (TokenToLocation): Rename parameter.
826         (FindFileNameFromToken): Rename parameter.
827         (DumpTokens): Rewrite comment.
828         * gm2-compiler/M2LexBuf.mod: Rewrite.
829         * gm2-compiler/P0SyntaxCheck.bnf (CheckInsertCandidate):
830         DumpTokens before and after inserting recovery token.
831         * gm2-gcc/m2builtins.cc (do_target_support_exists): Add
832         bf_c99_compl case.
833         * gm2-libs/Indexing.def (InitIndexTuned): New procedure
834         function.
835         (IsEmpty): New procedure function.
836         * gm2-libs/Indexing.mod (InitIndexTuned): New procedure
837         function.
838         (IsEmpty): New procedure function.
839         (Index): New field GrowFactor.
840         (PutIndice): Use GrowFactor to extend dynamic array.
842 2024-03-04  Gaius Mulley  <gaiusmod2@gmail.com>
844         PR modula2/114227
845         * gm2-libs-iso/M2RTS.mod (ProcedureChain): Remove.
846         (ProcedureList): Remove.
847         (ExecuteReverse): Remove.
848         (ExecuteTerminationProcedures): Rewrite.
849         (ExecuteInitialProcedures): Rewrite.
850         (AppendProc): Remove.
851         (InstallTerminationProcedure): Rewrite.
852         (InstallInitialProcedure): Rewrite.
853         (InitProcList): Remove.
854         * gm2-libs/M2Dependent.def (InstallTerminationProcedure):
855         New procedure.
856         (ExecuteTerminationProcedures): New procedure.
857         (InstallInitialProcedure): New procedure.
858         (ExecuteInitialProcedures): New procedure.
859         * gm2-libs/M2Dependent.mod (ProcedureChain): New type.
860         (ProcedureList): New type.
861         (ExecuteReverse): New procedure.
862         (ExecuteTerminationProcedures): New procedure.
863         (ExecuteInitialProcedures): New procedure.
864         (AppendProc): New procedure.
865         (InstallTerminationProcedure): New procedure.
866         (InstallInitialProcedure): New procedure.
867         (InitProcList): New procedure.
868         * gm2-libs/M2RTS.mod (ProcedureChain): Remove.
869         (ProcedureList): Remove.
870         (ExecuteReverse): Remove.
871         (ExecuteTerminationProcedures): Rewrite.
872         (ExecuteInitialProcedures): Rewrite.
873         (AppendProc): Remove.
874         (InstallTerminationProcedure): Rewrite.
875         (InstallInitialProcedure): Rewrite.
876         (InitProcList): Remove.
878 2024-02-25  Gaius Mulley  <gaiusmod2@gmail.com>
880         PR modula2/113749
881         * Make-lang.in (BUILD-PGE-O): Add m2/pge-boot/Gwrapc.o.
882         * gm2-libs-ch/wrapc.c (wrapc_SeekSet): New function.
883         (wrapc_SeekEnd): Ditto.
884         (wrapc_ReadOnly): Ditto.
885         (wrapc_WriteOnly): Ditto.
886         * gm2-libs/FIO.mod (SEEK_SET): Remove.
887         (SEEK_END): Remove.
888         (UNIXREADONLY): Remove.
889         (UNIXWRITEONLY): Remove.
890         (ConnectToUnix): Replace UNIXWRITEONLY with a call to WriteOnly.
891         Replace UNIXREADONLY with a call to ReadOnly.
892         (SetPositionFromBeginning): Replace SEEK_SET with a call to
893         SeekSet.
894         (SetPositionFromEnd): Replace SEEK_END with a call to
895         SeekEnd.
896         * gm2-libs/wrapc.def (SeekSet): New procedure function.
897         (SeekEnd): New procedure function.
898         (ReadOnly): New procedure function.
899         (WriteOnly): New procedure function.
900         * mc-boot-ch/Glibc.c (BUILD_MC_LIBC_TRACE): Undef.
901         (check_init): New function.
902         (tracedb): Ditto.
903         (tracedb_open): Ditto.
904         (tracedb_result): Ditto.
905         (libc_read): Ditto.
906         (libc_write): Ditto.
907         (libc_close): Ditto.
908         (libc_creat): Ditto.
909         (libc_open): Ditto.
910         (libc_lseek): Ditto.
911         * mc-boot-ch/Gwrapc.c (wrapc_SeekSet): New function.
912         (wrapc_SeekEnd): Ditto.
913         (wrapc_ReadOnly): Ditto.
914         (wrapc_WriteOnly): Ditto.
915         * mc-boot/GDynamicStrings.cc: Rebuilt.
916         * mc-boot/GFIO.cc: Ditto.
917         * mc-boot/GIndexing.cc: Ditto.
918         * mc-boot/GM2Dependent.cc: Ditto.
919         * mc-boot/GM2EXCEPTION.cc: Ditto.
920         * mc-boot/GPushBackInput.cc: Ditto.
921         * mc-boot/GRTExceptions.cc: Ditto.
922         * mc-boot/GRTint.cc: Ditto.
923         * mc-boot/GSArgs.cc: Ditto.
924         * mc-boot/GStdIO.cc: Ditto.
925         * mc-boot/GStringConvert.cc: Ditto.
926         * mc-boot/GSysStorage.cc: Ditto.
927         * mc-boot/Gdecl.cc: Ditto.
928         * mc-boot/Gkeyc.cc: Ditto.
929         * mc-boot/Glibc.h: Ditto.
930         * mc-boot/GmcComment.cc: Ditto.
931         * mc-boot/GmcComp.cc: Ditto.
932         * mc-boot/GmcDebug.cc: Ditto.
933         * mc-boot/GmcMetaError.cc: Ditto.
934         * mc-boot/GmcStack.cc: Ditto.
935         * mc-boot/GmcStream.cc: Ditto.
936         * mc-boot/GnameKey.cc: Ditto.
937         * mc-boot/GsymbolKey.cc: Ditto.
938         * mc-boot/Gvarargs.cc: Ditto.
939         * mc-boot/Gwrapc.h: Ditto.
940         * mc/decl.mod (getSymName): Add pointerref clause.
941         * mc/mcStream.mod (copy): Check for an error after every read.
942         * mc/varargs.mod (copy): Rewrite pointer arithmetic using INC to
943         avoid type incompatibility.
944         * pge-boot/GDynamicStrings.cc: Rebuilt.
945         * pge-boot/GDynamicStrings.h: Ditto.
946         * pge-boot/GFIO.cc: Ditto.
947         * pge-boot/GFIO.h: Ditto.
948         * pge-boot/GIO.cc: Ditto.
949         * pge-boot/GIndexing.cc: Ditto.
950         * pge-boot/GM2Dependent.cc: Ditto.
951         * pge-boot/GM2EXCEPTION.cc: Ditto.
952         * pge-boot/GNameKey.cc: Ditto.
953         * pge-boot/GPushBackInput.cc: Ditto.
954         * pge-boot/GRTExceptions.cc: Ditto.
955         * pge-boot/GStdIO.cc: Ditto.
956         * pge-boot/GSymbolKey.cc: Ditto.
957         * pge-boot/GSysStorage.cc: Ditto.
958         * pge-boot/Glibc.h: Ditto.
959         * pge-boot/Gwrapc.cc: Ditto.
960         * pge-boot/Gwrapc.h: Ditto.
962 2024-02-22  Gaius Mulley  <gaiusmod2@gmail.com>
964         PR modula2/114055
965         * gm2-compiler/M2Check.mod (Import): IsConstLitInternal and
966         IsConstLit.
967         (isInternal): New procedure function.
968         (doCheck): Test for isInternal in either operand and early
969         return true.
970         * gm2-compiler/M2Quads.mod (PushOne): Rewrite with extra
971         parameter internal.
972         (BuildPseudoBy): Add TRUE parameter to PushOne call.
973         (BuildIncProcedure): Add FALSE parameter to PushOne call.
974         (BuildDecProcedure): Add FALSE parameter to PushOne call.
975         * gm2-compiler/M2Range.mod (ForLoopBeginTypeCompatible):
976         Uncomment code and tidy up error string.
977         * gm2-compiler/SymbolTable.def (PutConstLitInternal):
978         New procedure.
979         (IsConstLitInternal): New procedure function.
980         * gm2-compiler/SymbolTable.mod (PutConstLitInternal):
981         New procedure.
982         (IsConstLitInternal): New procedure function.
983         (SymConstLit): New field IsInternal.
984         (CreateConstLit): Initialize IsInternal to FALSE.
986 2024-02-21  Gaius Mulley  <gaiusmod2@gmail.com>
988         PR modula2/114026
989         * gm2-compiler/M2GenGCC.mod (Import): Remove DisplayQuadruples.
990         Remove DisplayQuadList.
991         (MixTypesBinary): Replace check with overflowCheck.
992         New variable typeChecking.
993         Use GenQuadOTypetok to retrieve typeChecking.
994         Use typeChecking to suppress error message.
995         * gm2-compiler/M2LexBuf.def (MakeVirtual2Tok): New procedure
996         function.
997         * gm2-compiler/M2LexBuf.mod (MakeVirtualTok): Improve comment.
998         (MakeVirtual2Tok): New procedure function.
999         * gm2-compiler/M2Quads.def (GetQuadOTypetok): New procedure.
1000         * gm2-compiler/M2Quads.mod (QuadFrame): New field CheckType.
1001         (PutQuadO): Rewrite using PutQuadOType.
1002         (PutQuadOType): New procedure.
1003         (GetQuadOTypetok): New procedure.
1004         (BuildPseudoBy): Rewrite.
1005         (BuildForToByDo): Remove type checking.
1006         Add parameters e2, e2tok, BySym, bytok to
1007         InitForLoopBeginRange.
1008         Push the RangeId.
1009         (BuildEndFor): Pop the RangeId.
1010         Use GenQuadOTypetok to generate AddOp without type checking.
1011         Call PutRangeForIncrement with the RangeId and IncQuad.
1012         (GenQuadOtok): Rewrite using GenQuadOTypetok.
1013         (GenQuadOTypetok): New procedure.
1014         * gm2-compiler/M2Range.def (InitForLoopBeginRangeCheck):
1015         Rename d as des, e as expr.
1016         Add expr1, expr1tok, expr2, expr2tok, byconst, byconsttok
1017         parameters.
1018         (PutRangeForIncrement): New procedure.
1019         * gm2-compiler/M2Range.mod (Import): MakeVirtual2Tok.
1020         (Range): Add expr2, byconst, destok, exprtok, expr2tok,
1021         incrementquad.
1022         (InitRange): Initialize expr2 to NulSym.
1023         Initialize byconst to NulSym.
1024         Initialize tokenNo, destok, exprtok, expr2tok, byconst to
1025         UnknownTokenNo.
1026         Initialize incrementquad to 0.
1027         (PutRangeForIncrement): New procedure.
1028         (PutRangeDesExpr2): New procedure.
1029         (InitForLoopBeginRangeCheck): Rewrite.
1030         (ForLoopBeginTypeCompatible): New procedure function.
1031         (CodeForLoopBegin): Call ForLoopBeginTypeCompatible and
1032         only code the for loop assignment if all the type checks
1033         succeed.
1035 2024-02-19  Gaius Mulley  <gaiusmod2@gmail.com>
1037         PR modula2/113889
1038         * gm2-compiler/M2ALU.mod (StringFitsArray): Add tokeno parameter
1039         to GetStringLength.
1040         (InitialiseArrayOfCharWithString): Add tokeno parameter to
1041         GetStringLength.
1042         (CheckGetCharFromString): Add tokeno parameter to GetStringLength.
1043         * gm2-compiler/M2Const.mod (constResolveViaMeta): Replace
1044         PutConstString with PutConstStringKnown.
1045         * gm2-compiler/M2GCCDeclare.mod (DeclareCharConstant): Add tokenno
1046         parameter and add assert.  Use tokenno to generate location.
1047         (DeclareStringConstant): Add tokenno and add asserts.
1048         Add tokenno parameter to calls to GetStringLength.
1049         (PromoteToString): Add assert and add tokenno parameter to
1050         GetStringLength.
1051         (PromoteToCString): Add assert and add tokenno parameter to
1052         GetStringLength.
1053         (DeclareConstString): New procedure function.
1054         (TryDeclareConst): Remove size local variable.
1055         Check IsConstStringKnown.
1056         Call DeclareConstString.
1057         (PrintString): New procedure.
1058         (PrintVerboseFromList): Call PrintString.
1059         (CheckResolveSubrange): Check IsConstStringKnown before creating
1060         subrange for char or issuing an error.
1061         * gm2-compiler/M2GenGCC.mod (ResolveConstantExpressions): Add
1062         StringLengthOp, StringConvertM2nulOp, StringConvertCnulOp case
1063         clauses.
1064         (FindSize): Add assert IsConstStringKnown.
1065         (StringToChar): New variable tokenno.
1066         Add tokenno parameter to GetStringLength.
1067         (FoldStringLength): New procedure.
1068         (FoldStringConvertM2nul): New procedure.
1069         (FoldStringConvertCnul): New procedure.
1070         (CodeAddr): Add tokenno parameter.
1071         Replace CurrentQuadToken with tokenno.
1072         Add tokenno parameter to GetStringLength.
1073         (PrepareCopyString): Rewrite.
1074         (IsConstStrKnown): New procedure function.
1075         (FoldAdd): Detect conststring op2 and op3 which are known and
1076         concat.  Place result into op1.
1077         (FoldStandardFunction): Pass tokenno as a parameter to
1078         GetStringLength.
1079         (CodeXIndr): Rewrite comment.
1080         Rename op1 to left, op3 to right.
1081         Pass rightpos to GetStringLength.
1082         * gm2-compiler/M2Quads.def (QuadrupleOp): Add
1083         StringConvertCnulOp, StringConvertM2nulOp and StringLengthOp.
1084         * gm2-compiler/M2Quads.mod (import): Remove MakeConstLitString.
1085         Add CopyConstString and PutConstStringKnown.
1086         (IsInitialisingConst): Add StringConvertCnulOp,
1087         StringConvertM2nulOp and StringLengthOp.
1088         (callRequestDependant): Replace MakeConstLitString with
1089         MakeConstString.
1090         (DeferMakeConstStringCnul): New procedure function.
1091         (DeferMakeConstStringM2nul): New procedure function.
1092         (CheckParameter): Add early return if the string const is unknown.
1093         (DescribeType): Add token parameter to GetStringLength.
1094         Check for IsConstStringKnown.
1095         (ManipulateParameters): Use DeferMakeConstStringCnul and
1096         DeferMakeConstStringM2nul.
1097         (MakeLengthConst): Remove and replace with...
1098         (DeferMakeLengthConst): ... this.
1099         (doBuildBinaryOp): Create ConstString and set it to contents
1100         unknown.
1101         Check IsConstStringKnown before generating error message.
1102         (WriteQuad): Add StringConvertCnulOp, StringConvertM2nulOp and
1103         StringLengthOp.
1104         (WriteOperator): Add StringConvertCnulOp, StringConvertM2nulOp and
1105         StringLengthOp.
1106         * gm2-compiler/M2SymInit.mod (CheckReadBeforeInitQuad): Add
1107         StringConvertCnulOp, StringConvertM2nulOp and StringLengthOp.
1108         * gm2-compiler/NameKey.mod (LengthKey): Allow NulName to return 0.
1109         * gm2-compiler/P2SymBuild.mod (BuildString): Replace
1110         MakeConstLitString with MakeConstString.
1111         (DetermineType): Replace PutConstString with PutConstStringKnown.
1112         * gm2-compiler/SymbolTable.def (MakeConstVar): Tidy up comment.
1113         (MakeConstLitString): Remove.
1114         (MakeConstString): New procedure function.
1115         (MakeConstStringCnul): New procedure function.
1116         (MakeConstStringM2nul): New procedure function.
1117         (PutConstStringKnown): New procedure.
1118         (CopyConstString): New procedure.
1119         (IsConstStringKnown): New procedure function.
1120         (IsConstStringM2): New procedure function.
1121         (IsConstStringC): New procedure function.
1122         (IsConstStringM2nul): New procedure function.
1123         (IsConstStringCnul): New procedure function.
1124         (GetStringLength): Add token parameter.
1125         (PutConstString): Remove.
1126         (GetConstStringM2): Remove.
1127         (GetConstStringC): Remove.
1128         (GetConstStringM2nul): Remove.
1129         (GetConstStringCnul): Remove.
1130         (MakeConstStringC): Remove.
1131         * gm2-compiler/SymbolTable.mod (SymConstString): Remove
1132         M2Variant, NulM2Variant, CVariant, NulCVariant.
1133         Add Known.
1134         (CheckAnonymous): Replace $$ with __anon.
1135         (IsNameAnonymous): Replace $$ with __anon.
1136         (MakeConstVar): Detect whether the name is nul and treat as
1137         a temporary constant.
1138         (MakeConstLitString): Remove.
1139         (BackFillString): Remove.
1140         (InitConstString): Rewrite.
1141         (GetConstStringM2): Remove.
1142         (GetConstStringC): Remove.
1143         (GetConstStringContent): New procedure function.
1144         (GetConstStringM2nul): Remove.
1145         (GetConstStringCnul): Remove.
1146         (MakeConstStringCnul): Rewrite.
1147         (MakeConstStringM2nul): Rewrite.
1148         (MakeConstStringC): Remove.
1149         (MakeConstString): Rewrite.
1150         (PutConstStringKnown): New procedure.
1151         (CopyConstString): New procedure.
1152         (PutConstString): Remove.
1153         (IsConstStringKnown): New procedure function.
1154         (IsConstStringM2): New procedure function.
1155         (IsConstStringC): Rewrite.
1156         (IsConstStringM2nul): Rewrite.
1157         (IsConstStringCnul): Rewrite.
1158         (GetConstStringKind): New procedure function.
1159         (GetString): Check Known.
1160         (GetStringLength): Add token parameter and check Known.
1162 2024-02-10  Gaius Mulley  <gaiusmod2@gmail.com>
1164         PR modula2/113848
1165         * gm2-libs/SArgs.mod (GetArg): Re-write address arithmetic
1166         to avoid (void *) computation.
1168 2024-02-03  Gaius Mulley  <gaiusmod2@gmail.com>
1170         PR modula2/113730
1171         * gm2-compiler/M2Base.mod (IsUserType): New procedure function.
1172         (MixTypes): Use IsUserType instead of IsType before calling MixTypes.
1173         * gm2-compiler/M2GenGCC.mod (GetTypeMode): Remove and import from
1174         SymbolTable.
1175         (CodeBinaryCheck): Replace call to MixTypes with MixTypesBinary.
1176         (CodeBinary): Replace call to MixTypes with MixTypesBinary.
1177         (CodeIfLess): Replace MixTypes with ComparisonMixTypes.
1178         (CodeIfGre): Replace MixTypes with ComparisonMixTypes.
1179         (CodeIfLessEqu): Replace MixTypes with ComparisonMixTypes.
1180         (CodeIfGreEqu): Replace MixTypes with ComparisonMixTypes.
1181         (CodeIfEqu): Replace MixTypes with ComparisonMixTypes.
1182         (CodeIfNotEqu): Replace MixTypes with ComparisonMixTypes.
1183         (ComparisonMixTypes): New procedure function.
1184         * gm2-compiler/M2Quads.mod (BuildEndFor): Replace GenQuadO
1185         with GenQuadOtok and pass tokenpos for the operands to the AddOp
1186         and XIndrOp.
1187         (CheckRangeIncDec): Check etype against NulSym and dtype for a
1188         pointer and set etype to Address.
1189         (BuildAddAdrFunction): New variable opa.  Convert operand to an
1190         address and save result in opa.  Replace GenQuad with GenQuadOtok.
1191         (BuildSubAdrFunction): New variable opa.  Convert operand to an
1192         address and save result in opa.  Replace GenQuad with GenQuadOtok.
1193         (BuildDiffAdrFunction): New variable opa.  Convert operand to an
1194         address and save result in opa.  Replace GenQuad with GenQuadOtok.
1195         (calculateMultipicand): Replace GenQuadO with GenQuadOtok.
1196         (ConvertToAddress): New procedure function.
1197         (BuildDynamicArray): Convert index to address before adding to
1198         the base.
1199         * gm2-compiler/SymbolTable.def (GetTypeMode): New procedure function.
1200         * gm2-compiler/SymbolTable.mod (GetTypeMode): New procedure
1201         function implemented (moved from M2GenGCC.mod).
1202         * gm2-libs/SArgs.mod (GetArg): Replace cast to PtrToChar with ADDRESS.
1204 2024-02-01  Gaius Mulley  <gaiusmod2@gmail.com>
1206         PR modula2/111627
1207         PR modula2/112506
1208         * gm2-compiler/M2Comp.mod (Pass0CheckMod): Test IsDefImp before
1209         checking IsDefinitionForC.
1211 2024-01-31  Gaius Mulley  <gaiusmod2@gmail.com>
1213         * gm2-compiler/M2Comp.mod (Pass0CheckMod): Tidy up comment.
1214         * gm2-compiler/P1Build.bnf (PossiblyExportIdent): Replace
1215         PushTF with PushTFtok.
1217 2024-01-26  Gaius Mulley  <gaiusmod2@gmail.com>
1219         * gm2-compiler/M2Check.mod (dumpIndice): New procedure.
1220         (dumpIndex): New procedure.
1221         (dumptInfo): New procedure.
1222         (buildError4): Add comment and pass formal and actual to
1223         MetaError4.  Improve text describing error.
1224         (buildError2): Generate different error descriptions for
1225         the three error kinds.
1226         (checkConstMeta): Add block comment.  Add more meta checks
1227         and call doCheckPair to complete string const checking.
1228         Add tinfo parameter.
1229         (checkConstEquivalence): Add tinfo parameter.
1230         * gm2-compiler/M2GCCDeclare.mod (PrintVerboseFromList):
1231         Print the length of a const string.
1232         * gm2-compiler/M2GenGCC.mod (CodeParam): Remove parameters
1233         op1, op2 and op3.
1234         (doParam): Add paramtok parameter.  Use paramtok instead rather
1235         than CurrentQuadToken.
1236         (CodeParam): Rewrite.
1237         * gm2-compiler/M2Quads.mod (CheckProcedureParameters):
1238         Add comments explaining that const strings are not checked
1239         in M2Quads.mod.
1240         (FailParameter): Use MetaErrorT2 with tokpos rather than
1241         MetaError2.
1242         (doBuildBinaryOp): Assign OldPos and OperatorPos before the
1243         IF block.
1244         * gm2-compiler/SymbolTable.mod (PutConstString): Add call to
1245         InitWhereDeclaredTok.
1247 2024-01-25  Gaius Mulley  <gaiusmod2@gmail.com>
1249         * gm2-libs/libc.def (lseek): Change the second parameter
1250         type to CSSIZE_T and make the return value optional.
1252 2024-01-24  Gaius Mulley  <gaiusmod2@gmail.com>
1254         PR modula2/113559
1255         * gm2-libs/FIO.mod (SetPositionFromBeginning): Convert pos into
1256         CSSIZE_T during call to lseek.
1257         (SetPositionFromEnd): Convert pos into CSSIZE_T during call to
1258         lseek.
1260 2024-01-23  H.J. Lu  <hjl.tools@gmail.com>
1262         PR bootstrap/113554
1263         * mc/mc.flex (alloca): Don't redefine.
1264         (handleDate): Replace (long *)0 with (time_t *)0 when calling
1265         time.
1267 2024-01-19  Gaius Mulley  <gaiusmod2@gmail.com>
1269         * gm2-compiler/M2BasicBlock.mod (InitBasicBlocks): Rename
1270         ForeachScopeBlockDo to ForeachScopeBlockDo3.
1271         * gm2-compiler/M2Code.mod: Import ForeachScopeBlockDo2.
1272         (OptimizeScopeBlock): Call ForeachScopeBlockDo3 for
1273         procedures with three parameters and ForeachScopeBlockDo2
1274         for two parameters.
1275         (CodeBlock): Ditto.
1276         * gm2-compiler/M2GCCDeclare.mod (DeclareTypesConstantsProcedures):
1277         Rename ForeachScopeBlockDo to ForeachScopeBlockDo3.
1278         * gm2-compiler/M2GenGCC.def (ConvertQuadsToTree): Remove Scope
1279         parameter.
1280         * gm2-compiler/M2GenGCC.mod (ConvertQuadsToTree): Remove Scope
1281         parameter.
1282         (MaybeDebugBuiltinMemcpy): Remove parameter tok.
1283         (MaybeDebugBuiltinMemset): Remove.
1284         (MakeCopyUse): Remove tokenno from call to
1285         MaybeDebugBuiltinMemcpy.
1286         (PerformFoldBecomes): Remove desloc and exprloc.
1287         (checkArrayElements): Remove location.  Remove virtpos
1288         as a parameter to MaybeDebugBuiltinMemcpy.
1289         (NoWalkProcedure): Add attribute unused.
1290         (CheckElementSetTypes): Remove parameter p.
1291         Remove CurrentQuadToken in call to MaybeDebugBuiltinMemcpy.
1292         Remove NoWalkProcedure from call to CheckElementSetTypes.
1293         Remove tokenno from call to MaybeDebugBuiltinMemcpy.
1294         * gm2-compiler/M2Optimize.mod (RemoveProcedures): Replace
1295         two parameter indirect procedure iterator with
1296         ForeachScopeBlockDo2.
1297         * gm2-compiler/M2SSA.mod: Remove ForeachScopeBlockDo.
1298         * gm2-compiler/M2Scope.def (ForeachScopeBlockDo2): New
1299         declaration.
1300         (ForeachScopeBlockDo): Rename ...
1301         (ForeachScopeBlockDo3): ... to this.
1302         (ScopeProcedure2): New declaration.
1303         * gm2-compiler/M2Scope.mod (ForeachScopeBlockDo2): New
1304         procedure.
1305         (ForeachScopeBlockDo): Rename ...
1306         (ForeachScopeBlockDo3): ... to this.
1308 2024-01-18  Gaius Mulley  <gaiusmod2@gmail.com>
1310         PR modula2/111956
1311         * Make-lang.in (host_mc_longreal): Remove.
1312         * configure: Regenerate.
1313         * configure.ac (M2C_LONGREAL_FLOAT128): Remove.
1314         (M2C_LONGREAL_PPC64LE): Remove.
1315         * gm2-compiler/M2Options.def (SetIBMLongDouble): New procedure.
1316         (GetIBMLongDouble): New procedure function.
1317         (SetIEEELongDouble): New procedure.
1318         (GetIEEELongDouble): New procedure function.
1319         * gm2-compiler/M2Options.mod (SetIBMLongDouble): New procedure.
1320         (GetIBMLongDouble): New procedure function.
1321         (SetIEEELongDouble): New procedure.
1322         (GetIEEELongDouble): New procedure function.
1323         (InitializeLongDoubleFlags): New procedure called during
1324         module block initialization.
1325         * gm2-gcc/m2configure.cc: Remove duplicate includes.
1326         (m2configure_M2CLongRealFloat128): Remove.
1327         (m2configure_M2CLongRealIBM128): Remove.
1328         (m2configure_M2CLongRealLongDouble): Remove.
1329         (m2configure_M2CLongRealLongDoublePPC64LE): Remove.
1330         (m2configure_TargetIEEEQuadDefault): New function.
1331         * gm2-gcc/m2configure.def (M2CLongRealFloat128): Remove.
1332         (M2CLongRealIBM128): Remove.
1333         (M2CLongRealLongDouble): Remove.
1334         (M2CLongRealLongDoublePPC64LE): Remove.
1335         (TargetIEEEQuadDefault): New function.
1336         * gm2-gcc/m2configure.h (m2configure_M2CLongRealFloat128): Remove.
1337         (m2configure_M2CLongRealIBM128): Remove.
1338         (m2configure_M2CLongRealLongDouble): Remove.
1339         (m2configure_M2CLongRealLongDoublePPC64LE): Remove.
1340         (m2configure_TargetIEEEQuadDefault): New function.
1341         * gm2-gcc/m2options.h (M2Options_SetIBMLongDouble): New prototype.
1342         (M2Options_GetIBMLongDouble): New prototype.
1343         (M2Options_SetIEEELongDouble): New prototype.
1344         (M2Options_GetIEEELongDouble): New prototype.
1345         * gm2-gcc/m2type.cc (build_m2_long_real_node): Re-implement using
1346         results of M2Options_GetIBMLongDouble and M2Options_GetIEEELongDouble.
1347         * gm2-lang.cc (gm2_langhook_handle_option): Add case
1348         OPT_mabi_ibmlongdouble and call M2Options_SetIBMLongDouble.
1349         Add case OPT_mabi_ieeelongdouble and call M2Options_SetIEEELongDouble.
1350         * gm2config.aci.in: Regenerate.
1351         * gm2spec.cc (lang_specific_driver): Remove block defined by
1352         M2C_LONGREAL_PPC64LE.
1353         Remove case OPT_mabi_ibmlongdouble.
1354         Remove case OPT_mabi_ieeelongdouble.
1356 2024-01-11  Gaius Mulley  <gaiusmod2@gmail.com>
1358         PR modula2/112946
1359         * gm2-compiler/M2GenGCC.mod (IsExpressionCompatible): Import.
1360         (ExpressionTypeCompatible): Import.
1361         (CodeStatement): Remove op1, op2, op3 parameters from CodeSetOr,
1362         CodeSetAnd, CodeSetSymmetricDifference, CodeSetLogicalDifference.
1363         (checkArrayElements): Rename op1 to des and op3 to expr.
1364         Use despos and exprpos instead of CurrentQuadToken.
1365         (checkRecordTypes): Rename op1 to des and op2 to expr.
1366         Use virtpos instead of CurrentQuadToken.
1367         (checkIncorrectMeta): Ditto.
1368         (checkBecomes): Rename op1 to des and op3 to expr.
1369         Use virtpos instead of CurrentQuadToken.
1370         (NoWalkProcedure): New procedure stub.
1371         (CheckBinaryExpressionTypes): New procedure function.
1372         (CheckElementSetTypes): New procedure function.
1373         (CodeBinarySet): Re-write.
1374         (FoldBinarySet): Re-write.
1375         (CodeSetOr): Remove parameters op1, op2 and op3.
1376         (CodeSetAnd): Ditto.
1377         (CodeSetLogicalDifference): Ditto.
1378         (CodeSetSymmetricDifference): Ditto.
1379         (CodeIfIn): Call CheckBinaryExpressionTypes and
1380         CheckElementSetTypes.
1381         * gm2-compiler/M2Quads.mod (BuildRotateFunction): Correct
1382         parameters to MakeVirtualTok to reflect parameter block
1383         passed to Rotate.
1385 2024-01-09  Gaius Mulley  <gaiusmod2@gmail.com>
1387         PR modula2/112920
1388         * gm2-compiler/M2GCCDeclare.mod (Group): New declaration.
1389         Import MakeSubrange, MakeConstVar, MakeConstLit and DivTrunc.
1390         (FreeGroup): New declaration.
1391         (GlobalGroup): New declaration.
1392         (ToBeSolvedByQuads): Remove.
1393         (NilTypedArrays): Remove.
1394         (PartiallyDeclared): Remove.
1395         (HeldByAlignment): Remove.
1396         (FinishedAlignment): Remove.
1397         (ToDoList): Remove.
1398         (DebugSet): Re-format.
1399         (DebugNumber): Re-format.
1400         (DebugSetNumbers): Reference sets using GlobalGroup.
1401         (AddSymToWatch): Re-format.
1402         (WatchIncludeList): Reference sets using GlobalGroup.
1403         (WatchRemoveList): Reference sets using GlobalGroup.
1404         (NewGroup): New procedure.
1405         (DisposeGroup): New procedure.
1406         (InitGroup): New procedure.
1407         (KillGroup): New procedure.
1408         (DupGroup): New procedure.
1409         (EqualGroup): New procedure.
1410         (LookupSet): New procedure.
1411         (CanDeclareTypePartially): Reference sets using GlobalGroup.
1412         (CompletelyResolved): Reference sets using GlobalGroup.
1413         (IsNilTypedArrays): Reference sets using GlobalGroup.
1414         (IsFullyDeclared): Reference sets using GlobalGroup.
1415         (IsPartiallyDeclared): Reference sets using GlobalGroup.
1416         (IsPartiallyOrFullyDeclared): Reference sets using GlobalGroup.
1417         (DeclareTypeConstFully): Reference sets using GlobalGroup.
1418         (bodyl): Remove.
1419         (Body): Use bodyt and to lookup the required set.
1420         (ForeachTryDeclare): Remove parameter l.  Lookup set instead.
1421         (DeclareOutstandingTypes): Add new rules setarraynul and setfully.
1422         Reference sets using GlobalGroup.
1423         (ActivateWatch): New procedure.
1424         (DeclareTypesConstantsProceduresInRange): Re-written to check
1425         group change.
1426         (DeclareTypesConstantsProcedures): Re-written to check
1427         group change.
1428         (DeclareBoolean): Reference sets using GlobalGroup.
1429         (DeclarePackedBoolean): Ditto.
1430         (DeclareDefaultConstants): Ditto.
1431         (FreeGroup): Initialized.
1432         (GlobalGroup): Ditto.
1433         * gm2-compiler/Sets.def (EqualSet): New procedure function.
1434         Remove export qualified list of identifiers.
1435         * gm2-compiler/Sets.mod (EqualSet): New procedure function.
1437 2024-01-04  David Malcolm  <dmalcolm@redhat.com>
1439         * lang.opt.urls: New file, autogenerated by
1440         regenerate-opt-urls.py.
1442 2023-12-15  Gaius Mulley  <gaiusmod2@gmail.com>
1444         PR modula2/112946
1445         * gm2-compiler/M2Check.mod (checkConstMeta): New procedure
1446         function.
1447         (checkConstEquivalence): New procedure function.
1448         (doCheckPair): Add call to checkConstEquivalence.
1449         * gm2-compiler/M2GenGCC.mod (ResolveConstantExpressions): Call
1450         FoldBecomes with reduced parameters.
1451         (FoldBecomes): Re-write.
1452         (TryDeclareConst): New procedure.
1453         (RemoveQuads): New procedure.
1454         (DeclaredOperandsBecomes): New procedure function.
1455         (TypeCheckBecomes): New procedure function.
1456         (PerformFoldBecomes): New procedure.
1457         * gm2-compiler/M2Range.mod (FoldAssignment): Call
1458         AssignmentTypeCompatible to check des expr compatibility.
1459         * gm2-compiler/M2SymInit.mod (CheckReadBeforeInitQuad): Remove
1460         parameter lst.
1461         (FilterCheckReadBeforeInitQuad): Remove parameter lst.
1462         (CheckReadBeforeInitFirstBasicBlock): Remove parameter lst.
1463         Call FilterCheckReadBeforeInitQuad without lst.
1465 2023-12-13  Gaius Mulley  <gaiusmod2@gmail.com>
1467         PR modula2/112921
1468         * gm2-libs-iso/ConvStringShort.def: New file.
1469         * gm2-libs-iso/ConvStringShort.mod: New file.
1470         * gm2-libs-iso/ShortConv.def: New file.
1471         * gm2-libs-iso/ShortConv.mod: New file.
1472         * gm2-libs-iso/ShortMath.def: New file.
1473         * gm2-libs-iso/ShortMath.mod: New file.
1474         * gm2-libs-iso/ShortStr.def: New file.
1475         * gm2-libs-iso/ShortStr.mod: New file.
1477 2023-12-12  Gaius Mulley  <gaiusmod2@gmail.com>
1479         PR modula2/112984
1480         * gm2-libs-coroutines/SYSTEM.mod: Remove redundant import of memcpy.
1481         * gm2-libs-iso/ClientSocket.mod: Remove redundant import of IOConsts.
1482         * gm2-libs-iso/IOChan.mod: Remove redundant import of IOConsts.
1483         * gm2-libs-iso/IOLink.mod: Remove redundant import of IOChan and SYSTEM.
1484         * gm2-libs-iso/IOResult.mod: Remove redundant import of IOChan.
1485         * gm2-libs-iso/LongIO.mod: Remove redundant import of writeString.
1486         * gm2-libs-iso/LongWholeIO.mod: Remove redundant import of IOChan.
1487         * gm2-libs-iso/M2RTS.mod: Remove redundant import of ADDRESS.
1488         * gm2-libs-iso/MemStream.mod: Remove redundant import of ADDRESS.
1489         * gm2-libs-iso/RTdata.mod: Remove redundant import of DeviceTablePtr.
1490         * gm2-libs-iso/RTfio.mod: Remove redundant import of DeviceTablePtr.
1491         * gm2-libs-iso/RTgen.mod: Remove redundant import of DeviceTablePtr.
1492         * gm2-libs-iso/RealIO.mod: Remove redundant import of writeString.
1493         * gm2-libs-iso/RndFile.mod: Remove redundant import of SYSTEM.
1494         * gm2-libs-iso/SYSTEM.mod: Remove redundant import of memcpy.
1495         * gm2-libs-iso/ShortWholeIO.mod: Remove redundant import of IOConsts.
1496         * gm2-libs-iso/TextIO.mod: Remove redundant import of IOChan.
1497         * gm2-libs-iso/TextUtil.mod: Remove redundant import of IOChan.
1498         * gm2-libs-iso/WholeIO.mod: Remove redundant import of IOChan.
1499         * gm2-libs-log/BitByteOps.mod: Remove redundant import of BYTE.
1500         * gm2-libs-log/FileSystem.mod: Remove redundant import of BYTE and ADDRESS.
1501         * gm2-libs-log/InOut.mod: Remove redundant import of String.
1502         * gm2-libs-log/RealConversions.mod: Remove redundant import of StringToLongreal.
1503         * gm2-libs/FIO.mod: Remove redundant import of SIZE.
1504         * gm2-libs/FormatStrings.mod: Remove redundant import of String
1505         and ConCatChar.
1506         * gm2-libs/IO.mod: Remove redundant import of SIZE.
1507         * gm2-libs/Indexing.mod: Remove redundant import of ADDRESS.
1508         * gm2-libs/M2Dependent.mod: Remove redundant import of SIZE.
1509         * gm2-libs/M2RTS.mod: Remove redundant import of ADDRESS.
1510         * gm2-libs/OptLib.mod: Remove redundant import of DynamicStrings.
1511         * gm2-libs/SYSTEM.mod: Remove redundant import of memcpy.
1512         * gm2-libs/StringConvert.mod: Remove redundant import of String.
1514 2023-12-07  Gaius Mulley  <gaiusmod2@gmail.com>
1516         PR modula2/112893
1517         * gm2-compiler/M2Base.mod (Ass): Extend array to include proc row
1518         and column.  Allow PIM to assign cardinal variables to address
1519         variables.
1520         (Expr): Ditto.
1521         (Comp): Ditto.
1522         * gm2-compiler/M2Check.mod (getSType): New procedure function.
1523         Replace all occurances of GetSType with getSType.
1524         * gm2-compiler/M2GenGCC.mod (CodeParam): Rewrite format specifier
1525         error message.
1526         * gm2-compiler/M2Quads.mod (CheckProcTypeAndProcedure): Add tokno
1527         parameter.
1528         * gm2-compiler/M2Range.def (InitTypesParameterCheck): Add tokno
1529         parameter.
1530         (InitParameterRangeCheck): Add tokno parameter.
1531         Remove EXPORT QUALIFIED list.
1532         (InitParameterRangeCheck): Add tokno parameter.
1533         * gm2-compiler/M2Range.mod (InitTypesParameterCheck): Add tokno
1534         parameter and pass tokno to PutRangeParam.
1535         (InitParameterRangeCheck): Add tokno parameter and pass tokno to
1536         PutRangeParam.
1537         (PutRangeParam): Add tokno parameter and assign to tokenNo.
1538         (FoldTypeParam): Rewrite format string.
1540 2023-12-06  Thomas Schwinge  <thomas@codesourcery.com>
1542         * lang.opt (-isysroot): New.
1544 2023-12-05  Gaius Mulley  <gaiusmod2@gmail.com>
1546         PR modula2/112865
1547         * gm2-compiler/M2Quads.mod (BuildReFunction): Use
1548         GetDType to retrieve the type of the operand when
1549         converting the complex type to its scalar equivalent.
1550         (BuildImFunction): Use GetDType to retrieve the type of the
1551         operand when converting the complex type to its scalar
1552         equivalent.
1554 2023-12-05  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
1556         * mc/mc.flex [__GNUC__]: Define alloca as __builtin_alloca.
1557         (handleDate): Use strchr instead of index.
1559 2023-12-04  Gaius Mulley  <gaiusmod2@gmail.com>
1561         PR modula2/112825
1562         * tools-src/makeSystem: Change all occurrences of -c to -S.
1564 2023-11-01  Gaius Mulley  <gaiusmod2@gmail.com>
1566         PR modula2/102989
1567         * gm2-compiler/SymbolTable.mod (OverflowZType): Import from m2expr.
1568         (ConstantStringExceedsZType): Remove import.
1569         (GetConstLitType): Replace ConstantStringExceedsZType with OverflowZType.
1570         * gm2-gcc/m2decl.cc (m2decl_ConstantStringExceedsZType): Remove.
1571         (m2decl_BuildConstLiteralNumber): Re-write.
1572         * gm2-gcc/m2decl.def (ConstantStringExceedsZType): Remove.
1573         * gm2-gcc/m2decl.h (m2decl_ConstantStringExceedsZType): Remove.
1574         * gm2-gcc/m2expr.cc (m2expr_StrToWideInt): Rewrite to check overflow.
1575         (m2expr_OverflowZType): New function.
1576         (ToWideInt): New function.
1577         * gm2-gcc/m2expr.def (OverflowZType): New procedure function declaration.
1578         * gm2-gcc/m2expr.h (m2expr_OverflowZType): New prototype.
1580 2023-10-27  Gaius Mulley  <gaiusmod2@gmail.com>
1582         PR modula2/111530
1583         * gm2-libs-ch/cgetopt.c (cgetopt_cgetopt_long): Re-format.
1584         (cgetopt_cgetopt_long_only): Re-format.
1585         (cgetopt_SetOption):  Re-format and assign flag to NULL
1586         if name is also NULL.
1587         * gm2-libs/GetOpt.def (AddLongOption): Add index parameter
1588         and change flag to be a VAR parameter rather than a pointer.
1589         (GetOptLong): Re-format.
1590         (GetOpt): Correct comment.
1591         * gm2-libs/GetOpt.mod: Re-write to rely on cgetopt rather
1592         than implement long option creation in GetOpt.
1593         * gm2-libs/cgetopt.def (SetOption): has_arg type is INTEGER.
1595 2023-10-25  Gaius Mulley  <gaiusmod2@gmail.com>
1597         PR modula2/111955
1598         * gm2-gcc/m2builtins.cc (gm2_isnan_node): New tree.
1599         (DoBuiltinIsnan): New function.
1600         (m2builtins_BuiltInIsnan): New function.
1601         (m2builtins_init): Initialize gm2_isnan_node.
1602         (list_of_builtins): Add define for __builtin_isnan.
1603         * gm2-libs-ch/wrapc.c (wrapc_isnan): New function.
1604         (wrapc_isnanf): New function.
1605         (wrapc_isnanl): New function.
1606         * gm2-libs/Builtins.def (isnanf): New procedure function.
1607         (isnan): New procedure function.
1608         (isnanl): New procedure function.
1609         * gm2-libs/Builtins.mod:
1610         * gm2-libs/wrapc.def (isnan): New function.
1611         (isnanf): New function.
1612         (isnanl): New function.
1614 2023-10-24  Gaius Mulley  <gaiusmod2@gmail.com>
1616         * gm2-libs/M2Dependent.mod (InitDependencyList): New
1617         procedure.
1618         (CreateModule): Call InitDependencyList to initialize
1619         all fields of DependencyList.
1621 2023-10-24  Gaius Mulley  <gaiusmod2@gmail.com>
1623         * gm2-libs/M2Dependent.mod (CreateModule): Initialize all
1624         dependency fields for DependencyList.
1626 2023-10-17  Gaius Mulley  <gaiusmod2@gmail.com>
1628         PR modula2/111756
1629         * Make-lang.in (CM2DEP): New define conditionally set if
1630         ($(CXXDEPMODE),depmode=gcc3).
1631         (GM2_1): Use $(CM2DEP).
1632         (m2/gm2-gcc/%.o): Ensure $(@D)/$(DEPDIR) is created.
1633         Add $(CM2DEP) to the $(COMPILER) command and use $(POSTCOMPILE).
1634         (m2/gm2-gcc/m2configure.o): Ditto.
1635         (m2/gm2-lang.o): Ditto.
1636         (m2/m2pp.o): Ditto.
1637         (m2/gm2-gcc/rtegraph.o): Ditto.
1638         (m2/mc-boot/$(SRC_PREFIX)%.o): Ditto.
1639         (m2/mc-boot-ch/$(SRC_PREFIX)%.o): Ditto.
1640         (m2/mc-boot-ch/$(SRC_PREFIX)%.o): Ditto.
1641         (m2/mc-boot/main.o): Ditto.
1642         (mcflex.o): Ditto.
1643         (m2/gm2-libs-boot/M2RTS.o): Ditto.
1644         (m2/gm2-libs-boot/%.o): Ditto.
1645         (m2/gm2-libs-boot/%.o): Ditto.
1646         (m2/gm2-libs-boot/RTcodummy.o): Ditto.
1647         (m2/gm2-libs-boot/RTintdummy.o): Ditto.
1648         (m2/gm2-libs-boot/wrapc.o): Ditto.
1649         (m2/gm2-libs-boot/UnixArgs.o): Ditto.
1650         (m2/gm2-libs-boot/choosetemp.o): Ditto.
1651         (m2/gm2-libs-boot/errno.o): Ditto.
1652         (m2/gm2-libs-boot/dtoa.o): Ditto.
1653         (m2/gm2-libs-boot/ldtoa.o): Ditto.
1654         (m2/gm2-libs-boot/termios.o): Ditto.
1655         (m2/gm2-libs-boot/SysExceptions.o): Ditto.
1656         (m2/gm2-libs-boot/SysStorage.o): Ditto.
1657         (m2/gm2-compiler-boot/M2GCCDeclare.o): Ditto.
1658         (m2/gm2-compiler-boot/M2Error.o): Ditto.
1659         (m2/gm2-compiler-boot/%.o): Ditto.
1660         (m2/gm2-compiler-boot/%.o): Ditto.
1661         (m2/gm2-compiler-boot/m2flex.o): Ditto.
1662         (m2/gm2-compiler/%.o): Ditto.
1663         (m2/gm2-compiler/m2flex.o): Ditto.
1664         (m2/gm2-libs-iso/%.o): Ditto.
1665         (m2/gm2-libs/%.o): Ditto.
1666         (m2/gm2-libs/%.o): Ditto.
1667         (m2/gm2-libs/choosetemp.o): Ditto.
1668         (m2/boot-bin/mklink$(exeext)): Ditto.
1669         (m2/pge-boot/%.o): Ditto.
1670         (m2/pge-boot/%.o): Ditto.
1671         (m2/gm2-compiler/%.o): Ensure $(@D)/$(DEPDIR) is created and use
1672         $(POSTCOMPILE).
1673         (m2/gm2-compiler/%.o): Ditto.
1674         (m2/gm2-libs-iso/%.o): Ditto.
1675         (m2/gm2-libs/%.o): Ditto.
1676         * README: Purge out of date info.
1677         * gm2-compiler/M2Comp.mod (MakeSaveTempsFileNameExt): Import.
1678         (OnExitDelete): Import.
1679         (GetModuleDefImportStatementList): Import.
1680         (GetModuleModImportStatementList): Import.
1681         (GetImportModule): Import.
1682         (IsImportStatement): Import.
1683         (IsImport): Import.
1684         (GetImportStatementList): Import.
1685         (File): Import.
1686         (Close): Import.
1687         (EOF): Import.
1688         (IsNoError): Import.
1689         (WriteLine): Import.
1690         (WriteChar): Import.
1691         (FlushOutErr): Import.
1692         (WriteS): Import.
1693         (OpenToRead): Import.
1694         (OpenToWrite): Import.
1695         (ReadS): Import.
1696         (WriteS): Import.
1697         (GetM): Import.
1698         (GetMM): Import.
1699         (GetDepTarget): Import.
1700         (GetMF): Import.
1701         (GetMP): Import.
1702         (GetObj): Import.
1703         (GetMD): Import.
1704         (GetMMD): Import.
1705         (GenerateDefDependency): New procedure.
1706         (GenerateDependenciesFromImport): New procedure.
1707         (GenerateDependenciesFromList): New procedure.
1708         (GenerateDependencies): New procedure.
1709         (Compile): Re-write.
1710         (compile): Re-format.
1711         (CreateFileStem): New procedure function.
1712         (DoPass0): Re-write.
1713         (IsLibrary): New procedure function.
1714         (IsUnique): New procedure function.
1715         (Append): New procedure.
1716         (MergeDep): New procedure.
1717         (GetRuleTarget): New procedure function.
1718         (ReadDepContents): New procedure function.
1719         (WriteDep): New procedure.
1720         (WritePhonyDep): New procedure.
1721         (WriteDepContents): New procedure.
1722         (CreateDepFilename): New procedure function.
1723         (Pass0CheckDef): New procedure function.
1724         (Pass0CheckMod): New procedure function.
1725         (DoPass0): Re-write.
1726         (DepContent): New variable.
1727         (DepOutput): New variable.
1728         (BaseName): New procedure function.
1729         * gm2-compiler/M2GCCDeclare.mod (PrintTerse): Handle IsImport.
1730         Replace IsGnuAsmVolatile with IsGnuAsm.
1731         * gm2-compiler/M2Options.def (EXPORT QUALIFIED): Remove list.
1732         (SetM): New procedure.
1733         (GetM): New procedure function.
1734         (SetMM): New procedure.
1735         (GetMM): New procedure function.
1736         (SetMF): New procedure.
1737         (GetMF): New procedure function.
1738         (SetPPOnly): New procedure.
1739         (GetB): New procedure function.
1740         (SetMD): New procedure.
1741         (GetMD): New procedure function.
1742         (SetMMD): New procedure.
1743         (GetMMD): New procedure function.
1744         (SetMQ): New procedure.
1745         (SetMT): New procedure.
1746         (GetMT): New procedure function.
1747         (GetDepTarget): New procedure function.
1748         (SetMP): New procedure.
1749         (GetMP): New procedure function.
1750         (SetObj): New procedure.
1751         (SetSaveTempsDir): New procedure.
1752         * gm2-compiler/M2Options.mod (SetM): New procedure.
1753         (GetM): New procedure function.
1754         (SetMM): New procedure.
1755         (GetMM): New procedure function.
1756         (SetMF): New procedure.
1757         (GetMF): New procedure function.
1758         (SetPPOnly): New procedure.
1759         (GetB): New procedure function.
1760         (SetMD): New procedure.
1761         (GetMD): New procedure function.
1762         (SetMMD): New procedure.
1763         (GetMMD): New procedure function.
1764         (SetMQ): New procedure.
1765         (SetMT): New procedure.
1766         (GetMT): New procedure function.
1767         (GetDepTarget): New procedure function.
1768         (SetMP): New procedure.
1769         (GetMP): New procedure function.
1770         (SetObj): New procedure.
1771         (SetSaveTempsDir): New procedure.
1772         * gm2-compiler/M2Preprocess.def (PreprocessModule): New parameters
1773         topSource and outputDep.  Re-write.
1774         (MakeSaveTempsFileNameExt): New procedure function.
1775         (OnExitDelete): New procedure function.
1776         * gm2-compiler/M2Preprocess.mod (GetM): Import.
1777         (GetMM): Import.
1778         (OnExitDelete): Add debugging message.
1779         (RemoveFile): Add debugging message.
1780         (BaseName): Remove.
1781         (BuildCommandLineExecute): New procedure function.
1782         * gm2-compiler/M2Search.def (SetDefExtension): Remove unnecessary
1783         spacing.
1784         * gm2-compiler/SymbolTable.mod (GetSymName): Handle ImportSym and
1785         ImportStatementSym.
1786         * gm2-gcc/m2options.h (M2Options_SetMD): New function.
1787         (M2Options_GetMD): New function.
1788         (M2Options_SetMMD): New function.
1789         (M2Options_GetMMD): New function.
1790         (M2Options_SetM): New function.
1791         (M2Options_GetM): New function.
1792         (M2Options_SetMM): New function.
1793         (M2Options_GetMM): New function.
1794         (M2Options_GetMQ): New function.
1795         (M2Options_SetMF): New function.
1796         (M2Options_GetMF): New function.
1797         (M2Options_SetMT): New function.
1798         (M2Options_SetMP): New function.
1799         (M2Options_GetMP): New function.
1800         (M2Options_GetDepTarget): New function.
1801         * gm2-lang.cc (gm2_langhook_init): Correct comment case.
1802         (gm2_langhook_init_options): Add case OPT_M and
1803         OPT_MM.
1804         (gm2_langhook_post_options): Add case OPT_MF, OPT_MT,
1805         OPT_MD and OPT_MMD.
1806         * lang-specs.h (M2CPP): Pass though MF option.
1807         (MDMMD): New define.  Add MDMMD to "@modula-2".
1809 2023-10-15  Gaius Mulley  <gaiusmod2@gmail.com>
1811         * Make-lang.in (m2.tags): New rule.
1813 2023-10-11  Gaius Mulley  <gaiusmod2@gmail.com>
1815         * gm2-compiler/M2GCCDeclare.mod (DeclareSubrange): Check
1816         the base type of the subrange against the ZTYPE and call
1817         DeclareSubrangeNarrow if necessary.
1818         (DeclareSubrangeNarrow): New procedure function.
1820 2023-10-11  Gaius Mulley  <gaiusmod2@gmail.com>
1822         PR modula2/111675
1823         * gm2-compiler/M2CaseList.mod (appendTree): Replace
1824         InitStringCharStar with InitString.
1825         * gm2-compiler/M2GCCDeclare.mod: Import AreConstantsEqual.
1826         (DeclareSubrange): Add zero alignment test and call
1827         BuildSmallestTypeRange if necessary.
1828         (WalkSubrangeDependants): Walk the align expression.
1829         (IsSubrangeDependants): Test the align expression.
1830         * gm2-compiler/M2Quads.mod (BuildStringAdrParam): Correct end name.
1831         * gm2-compiler/P2SymBuild.mod (BuildTypeAlignment): Allow subranges
1832         to be zero aligned (packed).
1833         * gm2-compiler/SymbolTable.mod (Subrange): Add Align field.
1834         (MakeSubrange): Set Align to NulSym.
1835         (PutAlignment): Assign Subrange.Align to align.
1836         (GetAlignment): Return Subrange.Align.
1837         * gm2-gcc/m2expr.cc (noBitsRequired): Rewrite.
1838         (calcNbits): Rename ...
1839         (m2expr_calcNbits): ... to this and test for negative values.
1840         (m2expr_BuildTBitSize): Replace calcNBits with m2expr_calcNbits.
1841         * gm2-gcc/m2expr.def (calcNbits): Export.
1842         * gm2-gcc/m2expr.h (m2expr_calcNbits): New prototype.
1843         * gm2-gcc/m2type.cc (noBitsRequired): Remove.
1844         (m2type_BuildSmallestTypeRange): Call m2expr_calcNbits.
1845         (m2type_BuildSubrangeType): Create range_type from
1846         build_range_type (type, lowval, highval).
1848 2023-09-29  Gaius Mulley  <gaiusmod2@gmail.com>
1850         * gm2-compiler/M2Quads.mod (EndBuildFor): Improve
1851         block comments.
1852         * gm2-libs-iso/SysClock.mod (ExtractDate): Replace
1853         testDays with yearOfDays.  New local variable monthOfDays.
1855 2023-09-26  Gaius Mulley  <gaiusmod2@gmail.com>
1857         PR modula2/111510
1858         * gm2-compiler/M2GenGCC.mod (IsExportedGcc): Minor spacing changes.
1859         (BuildTrashTreeFromInterface): Minor spacing changes.
1860         * gm2-compiler/M2Options.mod (GetRuntimeModuleOverride): Call
1861         string to generate a nul terminated C style string.
1862         * gm2-compiler/M2Quads.mod (BuildStringAdrParam): New procedure.
1863         (BuildM2InitFunction): Replace inline parameter generation with
1864         calls to BuildStringAdrParam.
1866 2023-09-19  Gaius Mulley  <gaiusmod2@gmail.com>
1868         * Make-lang.in (host_mc_longreal): Detect hosting on powerpc64le
1869         and if so use __float128 for longreal in mc.
1870         (MC_ARGS): Append host_mc_longreal.
1871         * config-make.in (TEST_TARGET_CPU_DEFAULT): New variable.
1872         (TEST_HOST_CPU_DEFAULT): New variable.
1873         * configure: Regenerate.
1874         * configure.ac (M2C_LONGREAL_FLOAT128): New define set if target
1875         is powerpc64le.
1876         (M2C_LONGREAL_PPC64LE): New define set if target is powerpc64le.
1877         * gm2-compiler/M2GCCDeclare.mod: Correct comment case.
1878         * gm2-compiler/M2GenGCC.mod (MaybeDebugBuiltinAlloca): Call
1879         SetLastFunction for the builtin function call.
1880         (MaybeDebugBuiltinMemcpy): Call SetLastFunction for the builtin
1881         function call.
1882         (MaybeDebugBuiltinMemset): New procedure function.
1883         (MakeCopyUse): Use GNU formatting.
1884         (UseBuiltin): Rewrite to check BuiltinExists.
1885         (CodeDirectCall): Rewrite to check BuiltinExists and call
1886         SetLastFunction.
1887         (CodeMakeAdr): Re-format.
1888         * gm2-compiler/M2Options.def (SetDebugBuiltins): New procedure.
1889         * gm2-compiler/M2Options.mod (SetUninitVariableChecking): Allow
1890         "cond" to switch UninitVariableConditionalChecking separately.
1891         (SetDebugBuiltins): New procedure.
1892         * gm2-compiler/M2Quads.def (BuildFunctionCall): Add parameter
1893         ConstExpr.
1894         * gm2-compiler/M2Quads.mod (BuildRealProcedureCall): Add parameter
1895         to BuildRealFuncProcCall.
1896         (BuildRealFuncProcCall): Add ConstExpr parameter.  Pass ConstExpr
1897         to BuildFunctionCall.
1898         (BuildFunctionCall): Add parameter ConstExpr.  Pass ConstExpr to
1899         BuildRealFunctionCall.
1900         (BuildConstFunctionCall): Add parameter ConstExpr.  Pass ConstExpr to
1901         BuildFunctionCall.
1902         (BuildRealFunctionCall): Add parameter ConstExpr.  Pass ConstExpr to
1903         BuildRealFuncProcCall.
1904         * gm2-compiler/P3Build.bnf (SetOrDesignatorOrFunction): Pass FALSE
1905         to BuildFunctionCall.
1906         (AssignmentOrProcedureCall): Pass FALSE to BuildFunctionCall.
1907         * gm2-compiler/SymbolTable.def (IsProcedureBuiltinAvailable): New
1908         procedure function.
1909         * gm2-compiler/SymbolTable.mod (CanUseBuiltin): New procedure
1910         function.
1911         (IsProcedureBuiltinAvailable): New procedure function.
1912         * gm2-gcc/m2builtins.cc (DEBUGGING): Undef.
1913         (bf_category): New enum type.
1914         (struct builtin_function_entry): New field function_avail.
1915         (m2builtins_BuiltInMemCopy): Rename from ...
1916         (m2builtins_BuiltinMemCopy): ... this.
1917         (DoBuiltinMemSet): New function.
1918         (m2builtins_BuiltinMemSet): New function.
1919         (do_target_support_exists): New function.
1920         (target_support_exists): New function.
1921         (m2builtins_BuiltinExists): Return true or false.
1922         (m2builtins_BuildBuiltinTree): Rename local variables.
1923         Replace long_double_type_node with GetM2LongRealType.
1924         (m2builtins_init): Use GetM2LongRealType rather than
1925         long_double_type_node.
1926         * gm2-gcc/m2builtins.def (BuiltInMemCopy): Rename to ...
1927         (BuiltinMemCopy): ... this.
1928         (BuiltinMemSet): New procedure function.
1929         * gm2-gcc/m2builtins.h (m2builtins_BuiltInMemCopy): Rename to ...
1930         (m2builtins_BuiltinMemCopy): ... this.
1931         (m2builtins_BuiltinMemSet): New procedure function.
1932         * gm2-gcc/m2configure.cc (m2configure_M2CLongRealFloat128): New
1933         procedure function.
1934         (m2configure_M2CLongRealIBM128): New procedure function.
1935         (m2configure_M2CLongRealLongDouble): New procedure function.
1936         (m2configure_M2CLongRealLongDoublePPC64LE): New procedure function.
1937         * gm2-gcc/m2configure.def (M2CLongRealFloat128): New procedure function.
1938         (M2CLongRealIBM128): New procedure function.
1939         (M2CLongRealLongDouble): New procedure function.
1940         (M2CLongRealLongDoublePPC64LE): New procedure function.
1941         * gm2-gcc/m2configure.h (m2configure_FullPathCPP): New procedure function.
1942         (m2configure_M2CLongRealFloat128): New procedure function.
1943         (m2configure_M2CLongRealIBM128): New procedure function.
1944         (m2configure_M2CLongRealLongDouble): New procedure function.
1945         (m2configure_M2CLongRealLongDoublePPC64LE): New procedure function.
1946         * gm2-gcc/m2convert.cc (m2convert_BuildConvert): Use convert_loc.
1947         * gm2-gcc/m2options.h (M2Options_SetDebugBuiltins): New function.
1948         * gm2-gcc/m2statement.cc (m2statement_BuildAssignmentTree): Set
1949         TREE_USED to true.
1950         (m2statement_BuildGoto):Set TREE_USED to true.
1951         (m2statement_BuildParam): Set TREE_USED to true.
1952         (m2statement_BuildBuiltinCallTree): New function.
1953         (m2statement_BuildFunctValue): Set TREE_USED to true.
1954         * gm2-gcc/m2statement.def (BuildBuiltinCallTree): New procedure function.
1955         * gm2-gcc/m2statement.h (m2statement_BuildBuiltinCallTree): New
1956         procedure function.
1957         * gm2-gcc/m2treelib.cc (m2treelib_DoCall0): Remove spacing.
1958         (m2treelib_DoCall1): Remove spacing.
1959         (m2treelib_DoCall2): Remove spacing.
1960         (m2treelib_DoCall3): Remove spacing.
1961         (add_stmt): Rename parameter.
1962         * gm2-gcc/m2type.cc (build_set_type): Remove spacing.
1963         (build_m2_specific_size_type): Remove spacing.
1964         (finish_build_pointer_type): Remove spacing.
1965         (m2type_BuildVariableArrayAndDeclare): Remove spacing.
1966         (build_m2_short_real_node): Remove spacing.
1967         (build_m2_real_node): Remove spacing.
1968         (build_m2_long_real_node): Use float128_type_node if
1969         M2CLongRealFloat128 is set.
1970         (build_m2_ztype_node): Remove spacing.
1971         (build_m2_long_int_node): Remove spacing.
1972         (build_m2_long_card_node): Remove spacing.
1973         (build_m2_short_int_node): Remove spacing.
1974         (build_m2_short_card_node): Remove spacing.
1975         (build_m2_iso_loc_node): Remove spacing.
1976         (m2type_SameRealType): New function.
1977         (m2type_InitBaseTypes): Create m2_c_type_node using
1978         m2_long_complex_type_node.
1979         (m2type_SetAlignment): Tidy up comment.
1980         * gm2-gcc/m2type.def (SameRealType):  New procedure function.
1981         * gm2-gcc/m2type.h (m2type_SameRealType): New procedure function.
1982         * gm2-lang.cc (gm2_langhook_type_for_mode): Build long complex
1983         node from m2 language specific long double node.
1984         * gm2-libs-log/RealConversions.mod (IsNan): New procedure
1985         function.
1986         (doPowerOfTen): Re-implement.
1987         * gm2-libs/Builtins.mod: Add newline.
1988         * gm2-libs/DynamicStrings.def (ReplaceChar): New procedure function.
1989         * gm2-libs/DynamicStrings.mod (ReplaceChar): New procedure function.
1990         * gm2config.aci.in (M2C_LONGREAL_FLOAT128): New config value.
1991         (M2C_LONGREAL_PPC64LE): New config value.
1992         * gm2spec.cc (lang_specific_driver): New local variable
1993         need_default_mabi set to default value depending upon
1994         M2C_LONGREAL_PPC64LE and M2C_LONGREAL_FLOAT128.
1995         * lang.opt (Wcase-enum): Moved to correct section.
1996         * m2pp.cc (m2pp_real_type): New function.
1997         (m2pp_type): Call m2pp_real_type.
1998         (m2pp_print_mode): New function.
1999         (m2pp_simple_type): Call m2pp_simple_type.
2000         (m2pp_float): New function.
2001         (m2pp_expression): Call m2pp_float.
2002         * mc-boot/GDynamicStrings.cc: Rebuild.
2003         * mc-boot/GDynamicStrings.h: Rebuild.
2004         * mc-boot/GFIO.cc: Rebuild.
2005         * mc-boot/GFIO.h: Rebuild.
2006         * mc-boot/GIO.cc: Rebuild.
2007         * mc-boot/GRTint.cc: Rebuild.
2008         * mc-boot/Gdecl.cc: Rebuild.
2009         * mc-boot/GmcOptions.cc: Rebuild.
2010         * mc-boot/GmcOptions.h: Rebuild.
2011         * mc/decl.mod: Rebuild.
2012         * mc/mcOptions.def (getCRealType): New procedure function.
2013         (getCLongRealType): New procedure function.
2014         (getCShortRealType): New procedure function.
2015         * mc/mcOptions.mod (getCRealType): New procedure function.
2016         (getCLongRealType): New procedure function.
2017         (getCShortRealType): New procedure function.
2019 2023-09-14  Gaius Mulley  <gaiusmod2@gmail.com>
2021         * gm2-compiler/M2CaseList.mod (NewRanges): Add block
2022         comment.
2023         (NewSet): Add block comment.
2024         (DisplayRanges): Add block comment.
2025         (IncludeElement): Add block comment.
2026         (IncludeElements): Add block comment.
2027         (appendString): Add block comment.
2028         (appendEnum): Add block comment.
2029         (appendTree): Add block comment.
2030         (SubrangeErrors): Add block comment.
2032 2023-09-14  Gaius Mulley  <gaiusmod2@gmail.com>
2034         * gm2-compiler/M2CaseList.mod (appendString): New procedure.
2035         (appendEnum): Re-implement.
2036         (NoOfSetElements): New procedure function.
2037         (isPrintableChar): New procedure function.
2038         (appendTree): New procedure.
2039         (SubrangeErrors): New procedure.
2040         (EmitMissingRangeErrors): Call SubrangeErrors if appropriate.
2041         * gm2-compiler/M2SymInit.mod (SetFieldInitializedNo): Avoid
2042         using a temporary variable once.
2043         (IsLocalVar): Comment out.
2044         (RecordContainsVarient): Remove fieldtype.
2045         (GenerateNoteFlow): Remove lst parameter.
2046         (CheckDeferredRecordAccess): Remove lst parameter.
2047         (CheckUnary): Remove lst parameter.  Remove procSym.
2048         (CheckBinary): Remove lst parameter.  Remove procSym.
2049         (CheckIndrX): Remove lst parameter.  Remove procSym.
2050         (CheckXIndr): Remove bblst and procSym parameters.
2051         (CheckRecordField): Remove procSym, op1tok, op2tok and op2.
2052         (CheckBecomes): Remove procSym and bblst.
2053         (CheckComparison): Remove procSym and bblst.
2054         (CheckAddr): Remove procSym parameter.
2055         * gm2-gcc/m2expr.cc (m2expr_CSTIntToString): New function.
2056         (m2expr_CSTIntToChar): New function.
2057         * gm2-gcc/m2expr.def (CSTIntToString): New procedure function
2058         declaration.
2059         (CSTIntToChar): New procedure function declaration.
2060         * gm2-gcc/m2expr.h (m2expr_CSTIntToChar): New prototype.
2061         (m2expr_CSTIntToString): New prototype.
2063 2023-09-13  Gaius Mulley  <gaiusmod2@gmail.com>
2065         * Make-lang.in (GM2_FLAGS): Add -Wcase-enum.
2066         (GM2_ISO_FLAGS): Add -Wcase-enum.
2067         * gm2-compiler/M2CaseList.mod (EnumerateErrors): Issue
2068         singular or plural start text prior to the enum list.
2069         Remove unused parameter tokenno.
2070         (EmitMissingRangeErrors): New procedure.
2071         (MissingCaseBounds): Call EmitMissingRangeErrors.
2072         (MissingCaseStatementBounds): Call EmitMissingRangeErrors.
2073         * gm2-libs-iso/TextIO.mod: Fix spacing.
2075 2023-09-12  Gaius Mulley  <gaiusmod2@gmail.com>
2077         * gm2-compiler/M2CaseList.def (PushCase): Rename parameters
2078         r to rec and v to va.  Add expr parameter.
2079         (MissingCaseStatementBounds): New procedure function.
2080         * gm2-compiler/M2CaseList.mod (RangePair): Add expression.
2081         (PushCase): Rename parameters r to rec and v to va.  Add
2082         expr parameter.
2083         (RemoveRange): New procedure function.
2084         (SubBitRange): Detect the case when the range in the set matches
2085         lo..hi.
2086         (CheckLowHigh): New procedure.
2087         (ExcludeCaseRanges): Rename parameter c to cd.  Rename local
2088         variables q to cl and r to rp.
2089         (High): Remove.
2090         (Low): Remove.
2091         (DoEnumValues): Remove.
2092         (IncludeElement): New procedure.
2093         (IncludeElements): New procedure.
2094         (ErrorRangeEnum): New procedure.
2095         (ErrorRange): Remove.
2096         (ErrorRanges): Remove.
2097         (appendEnum): New procedure.
2098         (appendStr): New procedure.
2099         (EnumerateErrors): New procedure.
2100         (MissingCaseBounds): Re-implement.
2101         (InRangeList): Remove.
2102         (MissingCaseStatementBounds): New procedure function.
2103         (checkTypes): Re-format.
2104         (inRange): Re-format.
2105         (TypeCaseBounds): Re-format.
2106         * gm2-compiler/M2Error.mod (GetAnnounceScope): Add noscope to
2107         case label list.
2108         * gm2-compiler/M2GCCDeclare.mod: Replace ForeachFieldEnumerationDo
2109         with ForeachLocalSymDo.
2110         * gm2-compiler/M2Options.def (SetCaseEnumChecking): New procedure.
2111         (CaseEnumChecking): New variable.
2112         * gm2-compiler/M2Options.mod (SetCaseEnumChecking): New procedure.
2113         (Module initialization): set CaseEnumChecking to FALSE.
2114         * gm2-compiler/M2Quads.def (QuadOperator): Alphabetically ordered.
2115         * gm2-compiler/M2Quads.mod (IsBackReferenceConditional): Add else
2116         clause.
2117         (BuildCaseStart): Pass selector expression to InitCaseBounds.
2118         (CheckUninitializedVariablesAreUsed): Remove.
2119         (IsInlineWithinBlock): Remove.
2120         (AsmStatementsInBlock): Remove.
2121         (CheckVariablesInBlock): Remove commented code.
2122         (BeginVarient): Pass NulSym to InitCaseBounds.
2123         * gm2-compiler/M2Range.mod (FoldCaseBounds): New local variable
2124         errorGenerated.  Add call to MissingCaseStatementBounds.
2125         * gm2-compiler/P3Build.bnf (CaseEndStatement): Call ElseCase.
2126         * gm2-compiler/PCSymBuild.mod (InitDesExpr): Add else clause.
2127         (InitFunction): Add else clause.
2128         (InitConvert): Add else clause.
2129         (InitLeaf): Add else clause.
2130         (InitBinary): Add else clause.
2131         (InitUnary): Add else clause.
2132         * gm2-compiler/SymbolTable.def (GetNth): Re-write comment.
2133         (ForeachFieldEnumerationDo): Re-write comment stating alphabetical
2134         traversal.
2135         * gm2-compiler/SymbolTable.mod (GetNth): Re-write comment.
2136         Add case label for EnumerationSym and call GetItemFromList.
2137         (ForeachFieldEnumerationDo): Re-write comment stating alphabetical
2138         traversal.
2139         (SymEnumeration): Add ListOfFields used for declaration order.
2140         (MakeEnumeration): Initialize ListOfFields.
2141         (PutFieldEnumeration): Include Field in ListOfFields.
2142         * gm2-gcc/m2options.h (M2Options_SetCaseEnumChecking): New
2143         function.
2144         * gm2-lang.cc (gm2_langhook_handle_option): Add
2145         OPT_Wcase_enum case and call M2Options_SetCaseEnumChecking.
2146         * lang.opt (Wcase-enum): Add.
2148 2023-09-11  Gaius Mulley  <gaiusmod2@gmail.com>
2150         PR modula2/111330
2151         * gm2-compiler/M2SymInit.mod (CheckReadBeforeInitQuad): Add
2152         case labels LogicalDiffOp, DummyOp, OptParamOp and
2153         InitAddressOp.
2155 2023-08-20  Gaius Mulley  <gaiusmod2@gmail.com>
2157         PR modula2/111085
2158         * gm2-libs/Builtins.def (nexttoward): Alter the second
2159         parameter to LONGREAL.
2160         (nexttowardf): Alter the second parameter to LONGREAL.
2161         * gm2-libs/Builtins.mod (nexttoward): Alter the second
2162         parameter to LONGREAL.
2163         (nexttowardf): Alter the second parameter to LONGREAL.
2164         * gm2-libs/cbuiltin.def (nexttoward): Alter the second
2165         parameter to LONGREAL.
2166         (nexttowardf): Alter the second parameter to LONGREAL.
2168 2023-08-13  Iain Sandoe  <iain@sandoe.co.uk>
2170         * Make-lang.in: Update suffix spellings to use 'soext'.
2171         Add libc to the plugin link.
2173 2023-08-12  Gaius Mulley  <gaiusmod2@gmail.com>
2175         PR modula2/110779
2176         * gm2-libs-iso/SysClock.mod (EpochTime): New procedure.
2177         (GetClock): Call EpochTime if the C time functions are
2178         unavailable.
2179         * gm2-libs-iso/wrapclock.def (istimezone): New function
2180         definition.
2182 2023-08-12  Gaius Mulley  <gaiusmod2@gmail.com>
2184         PR modula2/108119
2185         * Make-lang.in (M2RTE_PLUGIN_SO): Assigned to
2186         plugin/m2rte$(exeext).so if enable_plugin is yes.
2187         (m2.all.cross): Replace plugin/m2rte$(soext) with
2188         $(M2RTE_PLUGIN_SO).
2189         (m2.all.encap): Replace plugin/m2rte$(soext) with
2190         $(M2RTE_PLUGIN_SO).
2191         (m2.install-plugin): Add dummy rule when enable_plugin
2192         is not yes.
2193         (plugin/m2rte$(exeext).so): Add dummy rule when enable_plugin
2194         is not yes.
2195         (m2/stage2/cc1gm2$(exeext)): Replace plugin/m2rte$(soext) with
2196         $(M2RTE_PLUGIN_SO).
2197         (m2/stage1/cc1gm2$(exeext)): Replace plugin/m2rte$(soext) with
2198         $(M2RTE_PLUGIN_SO).
2199         * gm2spec.cc (lang_specific_driver): Set need_plugin to false
2200         by default.
2202 2023-08-09  Gaius Mulley  <gaiusmod2@gmail.com>
2204         PR modula2/110779
2205         * gm2-libs-iso/SysClock.mod (GetClock): Test GetTimespec
2206         return value.
2207         (SetClock): Test SetTimespec return value.
2208         * gm2-libs-iso/wrapclock.def (GetTimespec): Add integer
2209         return type.
2210         (SetTimespec): Add integer return type.
2212 2023-08-05  Gaius Mulley  <gaiusmod2@gmail.com>
2214         PR modula2/110779
2215         * gm2-libs-iso/SysClock.mod: Re-implement using wrapclock.
2216         * gm2-libs-iso/wrapclock.def: New file.
2218 2023-08-01  Gaius Mulley  <gaiusmod2@gmail.com>
2220         PR modula2/110161
2221         * gm2-compiler/M2Check.mod (checkProcTypeEquivalence): New
2222         procedure function.
2223         (checkTypeKindEquivalence): Call checkProcTypeEquivalence
2224         if either left or right is a proc type.
2225         * gm2-compiler/M2Quads.mod (BuildRelOp): Create
2226         combinedTok prior to creating the range check quadruple.
2227         Use combinedTok when creating the range check quadruple.
2229 2023-08-01  Gaius Mulley  <gaiusmod2@gmail.com>
2231         PR modula2/110865
2232         * gm2-compiler/M2Quads.mod (BuildDesignatorArray):
2233         Rename t as type and d as dim.  New variable result.
2234         Allow constants of an array type to be indexed.
2236 2023-07-25  Gaius Mulley  <gaiusmod2@gmail.com>
2238         PR modula2/110174
2239         * gm2-compiler/M2GCCDeclare.def (PromoteToCString): New procedure
2240         function.
2241         * gm2-compiler/M2GCCDeclare.mod (PromoteToCString): New procedure
2242         function.
2243         * gm2-compiler/M2GenGCC.mod (BuildTreeFromInterface): Call
2244         skip_const_decl before chaining the parameter value.
2245         Use PromoteToCString to ensure the string is nul terminated.
2246         (CodeInline): Remove all parameters and replace with quad.
2247         Use GetQuadOtok to get operand token numbers.
2248         Remove call to DeclareConstant and replace it with PromoteToCString.
2249         * gm2-compiler/M2Quads.def (BuildInline): Rename into ...
2250         (BuildAsm): ... this.
2251         * gm2-compiler/M2Quads.mod: (BuildInline): Rename into ...
2252         (BuildAsm): ... this.
2253         (BuildAsmElement): Add debugging.
2254         * gm2-compiler/P1Build.bnf: Remove import of BuildInline.
2255         * gm2-compiler/P2Build.bnf: Remove import of BuildInline.
2256         * gm2-compiler/P3Build.bnf: Remove import of BuildInline and
2257         import BuildAsm.
2258         * gm2-compiler/PHBuild.bnf: Remove import of BuildInline.
2259         * gm2-libs-iso/SysClock.mod (foo): Remove.
2260         * gm2-libs/FIO.mod (BufferedRead): Rename parameter a to dest.
2261         Rename variable t to src.
2262         * m2pp.cc (pf): Correct block comment.
2263         (pe): Correct block comment.
2264         (m2pp_asm_expr): New function.
2265         (m2pp_statement): Call m2pp_asm_expr.
2267 2023-07-22  Gaius Mulley  <gaiusmod2@gmail.com>
2269         PR modula2/110631
2270         * gm2-libs/FIO.def (ReadAny): Correct comment as
2271         HIGH (a) + 1 is number of bytes.
2272         (WriteAny): Correct comment as HIGH (a) + 1 is number of
2273         bytes.
2274         * gm2-libs/FIO.mod (ReadAny): Correct comment as
2275         HIGH (a) + 1 is number of bytes.  Also pass HIGH (a) + 1
2276         to BufferedRead.
2277         (WriteAny): Correct comment as HIGH (a) + 1 is number of
2278         bytes.  Also pass HIGH (a) + 1 to BufferedWrite.
2279         (BufferedWrite): Rename parameter a to src, rename variable
2280         t to dest.  Correct parameter order to memcpy.
2282 2023-07-20  Gaius Mulley  <gaiusmod2@gmail.com>
2284         * gm2-compiler/M2SymInit.mod (IsExempt): Remove parameter exemption.
2285         (CheckIndrX): Call SetupLAlias between lhs and content.
2286         (trashParam): Re-write.
2287         (SetVarLRInitialized): Indicate shadow and heap are initialized.
2288         Call SetupIndr between shadow and heap.
2289         * gm2-compiler/P2SymBuild.mod: Import
2290         PutProcedureParameterHeapVars.
2291         (EndBuildProcedure): Call PutProcedureParameterHeapVars.
2292         * gm2-compiler/SymbolTable.def (GetParameterHeapVar): New
2293         procedure function.
2294         (PutProcedureParameterHeapVars): New procedure function.
2295         * gm2-compiler/SymbolTable.mod (MakeParameterHeapVar): New
2296         procedure function.
2297         (GetParameterHeapVar): New procedure function.
2298         (PuttParameterHeapVar): New procedure function.
2299         (PutProcedureParameterHeapVars): New procedure.
2300         (VarParam): HeapVar new record field.
2301         (PutVarParam): HeapVar assigned to NulSym.
2303 2023-07-19  Gaius Mulley  <gaiusmod2@gmail.com>
2305         PR modula2/110284
2306         * Make-lang.in (m2_OBJS): Add m2/gm2-gcc/rtegraph.o and
2307         m2/gm2-compiler-boot/m2flex.o.
2308         (c-family/m2pp.o): Remove.
2309         * Make-maintainer.in (c-family/m2pp.o): Add.
2311 2023-07-19  Gaius Mulley  <gaiusmod2@gmail.com>
2313         * gm2-compiler/M2Quads.mod (BuildDifAdrFunction): Removed
2314         unnecessary in error message.  Use vartok for location.
2315         (BuildOddFunction): Use optok for location.
2316         (BuildAbsFunction): Use vartok for location.  Bugfix set vartok.
2317         (BuildCapFunction): Use optok for location.
2318         (BuildOrdFunction): Use optok for location and correct format
2319         specifier.
2320         (BuildShiftFunction): Use vartok for location.
2321         (BuildRotateFunction): Use vartok for location.
2322         (BuildTruncFunction): Use vartok for location.
2323         (BuildFloatFunction): Use vartok for location.
2324         (BuildReFunction): Use vartok for location.
2325         (BuildImFunction): Use vartok for location.
2326         * gm2-compiler/M2SymInit.mod (trashParam): Remove commented code.
2328 2023-07-19  Gaius Mulley  <gaiusmod2@gmail.com>
2330         * gm2-compiler/M2Quads.mod (BuildRealFuncProcCall): Set the trash
2331         parameter value to NIL if DEALLOCATE is detected.
2332         * gm2-compiler/M2SymInit.mod (CheckDeferredRecordAccess): Pass
2333         tok to SetVarInitialized.  Pass tok to GetVarComponentInitialized.
2334         (ComponentFindVar): Add tok parameter.  Check aliased pointer
2335         against Nil and generate warning if necessary.
2336         (deRefComponent): Add tok and sym parameters and pass them to
2337         getContent.
2338         (SetVarComponentInitialized): Add tok parameter.  Pass tok to
2339         ComponentFindVar.  Pass tok and sym to deRefComponent.
2340         (GetVarComponentInitialized): Add tok parameter.  Pass tok to
2341         ComponentFindVar.  Pass tok to deRefComponent.
2342         (SetVarInitialized): Add tok parameter.  Pass tok to
2343         SetVarComponentInitialized.
2344         (doGetVarInitialized): Add tok parameter.  Pass tok to
2345         GetVarComponentInitialized.
2346         (CheckXIndr): Pass lhs and lhstok to getContent.
2347         (CheckIndrX): Pass rhs and rhstok to getContent.
2348         (CheckBecomes): Pass destok to ComponentFindVar.  Pass des and
2349         destok to deRefComponent.
2350         (CheckAddr): Pass contenttok to GetVarInitialized.  Pass ptrtok
2351         to SetVarInitialized.
2352         (CheckReadBeforeInitQuad): Pass op1tok to SetVarInitialized for
2353         op1 cases and op3tok for op3 cases.
2354         (trashParam): Get operand tokens.  Pass op3tok to
2355         SetVarInitialized.  Pass op3 and op3tok to getContent.
2356         Alias ptr to NIL if procedure is DEALLOCATE.  Pass op3tok to
2357         SetVarInitialized.
2358         (IsDeallocate): New procedure function.
2359         (DetectTrash): Use IsDeallocate.
2360         (SetupLAlias): Allow exp to be Nil.
2361         (getContent): Generate warning message if ptr is Nil.
2363 2023-07-18  Gaius Mulley  <gaiusmod2@gmail.com>
2365         * Make-lang.in: Minor formatting change.
2366         * gm2-compiler/M2GCCDeclare.mod
2367         (DeclareUnboundedProcedureParameters): Rename local variables.
2368         (WalkUnboundedProcedureParameters): Rename local variables.
2369         (DoVariableDeclaration): Avoid declaration of a variable if
2370         it is on the heap (used by static analysis only).
2371         * gm2-compiler/M2GenGCC.mod: Formatting.
2372         * gm2-compiler/M2Quads.def (GetQuadTrash): New procedure function.
2373         * gm2-compiler/M2Quads.mod (GetQuadTrash): New procedure function.
2374         (QuadFrame): Add Trash field.
2375         (BuildRealFuncProcCall): Detect ALLOCATE and DEALLOCATE and create
2376         a heap variable for parameter 1 saving it as the trashed variable
2377         for static analysis.
2378         (GenQuadOTrash): New procedure.
2379         (DisplayQuadRange): Bugfix.  Write the scope number.
2380         * gm2-compiler/M2SymInit.mod: Rewritten to separate LValue
2381         equivalence from LValue to RValue pairings.  Comprehensive
2382         detection of variant record implemented.  Allow dereferencing
2383         of pointers through LValue/RValue chains.
2384         * gm2-compiler/SymbolTable.def (PutVarHeap): New procedure.
2385         (IsVarHeap): New procedure function.
2386         (ForeachParamSymDo): New procedure.
2387         * gm2-compiler/SymbolTable.mod (PutVarHeap): New procedure.
2388         (IsVarHeap): New procedure function.
2389         (ForeachParamSymDo): New procedure.
2390         (MakeVariableForParam): Reformatted.
2391         (CheckForUnknownInModule): Reformatted.
2392         (SymVar): Add field Heap.
2393         (MakeVar): Assign Heap to FALSE.
2395 2023-07-13  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
2397         * Make-lang.in (m2/boot-bin/mklink$(exeext)): Add $(LDFLAGS).
2399 2023-07-11  Gaius Mulley  <gaiusmod2@gmail.com>
2401         * gm2-compiler/M2BasicBlock.def (InitBasicBlocksFromRange): New
2402         parameter ScopeSym.
2403         * gm2-compiler/M2BasicBlock.mod (ConvertQuads2BasicBlock): New
2404         parameter ScopeSym.
2405         (InitBasicBlocksFromRange): New parameter ScopeSym.  Call
2406         ConvertQuads2BasicBlock with ScopeSym.
2407         (DisplayBasicBlocks): Uncomment.
2408         * gm2-compiler/M2Code.mod: Replace VariableAnalysis with
2409         ScopeBlockVariableAnalysis.
2410         (InitialDeclareAndOptiomize): Add parameter scope.
2411         (SecondDeclareAndOptimize): Add parameter scope.
2412         * gm2-compiler/M2GCCDeclare.mod (DeclareConstructor): Add scope
2413         parameter to DeclareTypesConstantsProceduresInRange.
2414         (DeclareTypesConstantsProceduresInRange): New parameter scope.
2415         Pass scope to DisplayQuadRange.  Reformatted.
2416         * gm2-compiler/M2GenGCC.def (ConvertQuadsToTree): New parameter
2417         scope.
2418         * gm2-compiler/M2GenGCC.mod (ConvertQuadsToTree): New parameter
2419         scope.
2420         * gm2-compiler/M2Optimize.mod (KnownReachable): New parameter
2421         scope.
2422         * gm2-compiler/M2Options.def (SetUninitVariableChecking): Add
2423         arg parameter.
2424         * gm2-compiler/M2Options.mod (SetUninitVariableChecking): Add
2425         arg parameter and set boolean UninitVariableChecking and
2426         UninitVariableConditionalChecking.
2427         (UninitVariableConditionalChecking): New boolean set to FALSE.
2428         * gm2-compiler/M2Quads.def (IsGoto): New procedure function.
2429         (DisplayQuadRange): Add scope parameter.
2430         (LoopAnalysis): Add scope parameter.
2431         * gm2-compiler/M2Quads.mod: Import PutVarArrayRef.
2432         (IsGoto): New procedure function.
2433         (LoopAnalysis): Add scope parameter and use MetaErrorT1 instead
2434         of WarnStringAt.
2435         (BuildStaticArray): Call PutVarArrayRef.
2436         (BuildDynamicArray): Call PutVarArrayRef.
2437         (DisplayQuadRange): Add scope parameter.
2438         (GetM2OperatorDesc): Add relational condition cases.
2439         * gm2-compiler/M2Scope.def (ScopeProcedure): Add parameter.
2440         * gm2-compiler/M2Scope.mod (DisplayScope): Pass scopeSym to
2441         DisplayQuadRange.
2442         (ForeachScopeBlockDo): Pass scopeSym to p.
2443         * gm2-compiler/M2SymInit.def (VariableAnalysis): Rename to ...
2444         (ScopeBlockVariableAnalysis): ... this.
2445         * gm2-compiler/M2SymInit.mod (ScopeBlockVariableAnalysis): Add
2446         scope parameter.
2447         (bbEntry): New pointer to record.
2448         (bbArray): New array.
2449         (bbFreeList): New variable.
2450         (errorList): New list.
2451         (IssueConditional): New procedure.
2452         (GenerateNoteFlow): New procedure.
2453         (IssueWarning): New procedure.
2454         (IsUniqueWarning): New procedure.
2455         (CheckDeferredRecordAccess): Re-implement.
2456         (CheckBinary): Add warning and lst parameters.
2457         (CheckUnary): Add warning and lst parameters.
2458         (CheckXIndr): Add warning and lst parameters.
2459         (CheckIndrX): Add warning and lst parameters.
2460         (CheckBecomes): Add warning and lst parameters.
2461         (CheckComparison): Add warning and lst parameters.
2462         (CheckReadBeforeInitQuad): Add warning and lst parameters to all
2463         Check procedures.  Add all case quadruple clauses.
2464         (FilterCheckReadBeforeInitQuad): Add warning and lst parameters.
2465         (CheckReadBeforeInitFirstBasicBlock): Add warning and lst parameters.
2466         (bbArrayKill): New procedure.
2467         (DumpBBEntry): New procedure.
2468         (DumpBBArray): New procedure.
2469         (DumpBBSequence): New procedure.
2470         (TestBBSequence): New procedure.
2471         (CreateBBPermultations): New procedure.
2472         (ScopeBlockVariableAnalysis): New procedure.
2473         (GetOp3): New procedure.
2474         (GenerateCFG): New procedure.
2475         (NewEntry): New procedure.
2476         (AppendEntry): New procedure.
2477         (init): Initialize bbFreeList and errorList.
2478         * gm2-compiler/SymbolTable.def (PutVarArrayRef): New procedure.
2479         (IsVarArrayRef): New procedure function.
2480         * gm2-compiler/SymbolTable.mod (SymVar): ArrayRef new field.
2481         (MakeVar): Set ArrayRef to FALSE.
2482         (PutVarArrayRef): New procedure.
2483         (IsVarArrayRef): New procedure function.
2484         * gm2-gcc/init.cc (_M2_M2SymInit_init): New prototype.
2485         (init_PerCompilationInit): Add call to _M2_M2SymInit_init.
2486         * gm2-gcc/m2options.h (M2Options_SetUninitVariableChecking):
2487         New definition.
2488         * gm2-lang.cc (gm2_langhook_handle_option): Add new case
2489         OPT_Wuninit_variable_checking_.
2490         * lang.opt: Wuninit-variable-checking= new entry.
2492 2023-07-03  Gaius Mulley  <gaiusmod2@gmail.com>
2494         PR modula2/110125
2495         * Make-lang.in (GM2-COMP-BOOT-DEFS): Add M2SymInit.def.
2496         (GM2-COMP-BOOT-MODS): Add M2SymInit.mod.
2497         * gm2-compiler/M2BasicBlock.mod: Formatting changes.
2498         * gm2-compiler/M2Code.mod: Remove import of VariableAnalysis from
2499         M2Quads.  Import VariableAnalysis from M2SymInit.mod.
2500         * gm2-compiler/M2GCCDeclare.mod (PrintVerboseFromList):
2501         Add debugging print for a component.
2502         (TypeConstFullyDeclared): Call RememberType for every type.
2503         * gm2-compiler/M2GenGCC.mod (CodeReturnValue): Add parameter to
2504         GetQuadOtok.
2505         (CodeBecomes): Add parameter to GetQuadOtok.
2506         (CodeXIndr): Add parameter to GetQuadOtok.
2507         * gm2-compiler/M2Optimize.mod (ReduceBranch): Reformat and
2508         preserve operand token positions when reducing the branch
2509         quadruples.
2510         (ReduceGoto): Reformat.
2511         (FoldMultipleGoto): Reformat.
2512         (KnownReachable): Reformat.
2513         * gm2-compiler/M2Options.def (UninitVariableChecking): New
2514         variable declared and exported.
2515         (SetUninitVariableChecking): New procedure.
2516         * gm2-compiler/M2Options.mod (SetWall): Set
2517         UninitVariableChecking.
2518         (SetUninitVariableChecking): New procedure.
2519         * gm2-compiler/M2Quads.def (PutQuadOtok): Exported and declared.
2520         (VariableAnalysis): Removed.
2521         * gm2-compiler/M2Quads.mod (PutQuadOtok): New procedure.
2522         (doVal): Reformatted.
2523         (MarkAsWrite): Reformatted.
2524         (MarkArrayAsWritten): Reformatted.
2525         (doIndrX): Use PutQuadOtok.
2526         (MakeRightValue): Use GenQuadOtok.
2527         (MakeLeftValue): Use GenQuadOtok.
2528         (CheckReadBeforeInitialized): Remove.
2529         (IsNeverAltered): Reformat.
2530         (DebugLocation): New procedure.
2531         (BuildDesignatorPointer): Use GenQuadO to preserve operand token
2532         position.
2533         (BuildRelOp): Use GenQuadOtok ditto.
2534         * gm2-compiler/SymbolTable.def (VarCheckReadInit): New procedure.
2535         (VarInitState): New procedure.
2536         (PutVarInitialized): New procedure.
2537         (PutVarFieldInitialized): New procedure function.
2538         (GetVarFieldInitialized): New procedure function.
2539         (PrintInitialized): New procedure.
2540         * gm2-compiler/SymbolTable.mod (VarCheckReadInit): New procedure.
2541         (VarInitState): New procedure.
2542         (PutVarInitialized): New procedure.
2543         (PutVarFieldInitialized): New procedure function.
2544         (GetVarFieldInitialized): New procedure function.
2545         (PrintInitialized): New procedure.
2546         (LRInitDesc): New type.
2547         (SymVar): InitState new field.
2548         (MakeVar): Initialize InitState.
2549         * gm2-gcc/m2options.h (M2Options_SetUninitVariableChecking):
2550         New function declaration.
2551         * gm2-lang.cc (gm2_langhook_handle_option): Detect
2552         OPT_Wuninit_variable_checking and call SetUninitVariableChecking.
2553         * lang.opt: Add Wuninit-variable-checking.
2554         * gm2-compiler/M2SymInit.def: New file.
2555         * gm2-compiler/M2SymInit.mod: New file.
2557 2023-06-30  Iain Sandoe  <iain@sandoe.co.uk>
2559         PR testsuite/108835
2560         * gm2-libs/RTint.mod: Do not use NIL timeout setting on select,
2561         test failures sequentially, finishing on the first success.
2563 2023-06-18  Gaius Mulley  <gaiusmod2@gmail.com>
2565         PR modula2/110284
2566         * Make-lang.in (m2_OBJS): Assign $(GM2_C_OBJS).
2567         (GM2_C_OBJS): Remove m2/stor-layout.o.
2568         (m2/stor-layout.o): Remove rule.
2569         * gm2-gcc/gcc-consolidation.h (rtl.h): Remove include.
2570         (df.h): Remove include.
2571         (except.h): Remove include.
2573 2023-06-15  Marek Polacek  <polacek@redhat.com>
2575         * Make-lang.in: New var, GM2_PICFLAGS.  Use it.
2577 2023-06-13  Gaius Mulley  <gaiusmod2@gmail.com>
2579         * Make-lang.in (check-format-error): New rule.
2580         * gm2-compiler/M2MetaError.mod (op): Add calls InternalError if
2581         digits are detected.
2582         * gm2-compiler/M2Quads.mod (BuildForToByDo): Bugfix to format
2583         specifier.
2584         (BuildLengthFunction): Bugfix to format specifiers.
2585         (BuildOddFunction): Bugfix to format specifiers.
2586         (BuildAbsFunction): Bugfix to format specifiers.
2587         (BuildCapFunction): Bugfix to format specifiers.
2588         (BuildChrFunction): Bugfix to format specifiers.
2589         (BuildOrdFunction): Bugfix to format specifiers.
2590         (BuildMakeAdrFunction): Bugfix to format specifiers.
2591         (BuildSizeFunction): Bugfix to format specifiers.
2592         (BuildBitSizeFunction): Bugfix to format specifiers.
2593         * tools-src/checkmeta.py: New file.
2595 2023-06-12  Gaius Mulley  <gaiusmod2@gmail.com>
2597         PR modula2/110189
2598         * gm2-compiler/M2Quads.mod (BuildAbsFunction): Replace abort
2599         format specifier.
2600         (BuildValFunction): Replace abort format specifier.
2601         (BuildCastFunction): Replace abort format specifier.
2602         (BuildMinFunction): Replace abort format specifier.
2603         (BuildMaxFunction): Replace abort format specifier.
2604         (BuildTruncFunction): Replace abort format specifier.
2605         * gm2-compiler/P3Build.bnf (Pass1): Remove.
2606         (Pass2): Remove.
2607         (Pass3): Remove.
2608         (Expect): Add Pass1.
2609         (AsmStatement): Remove Pass3.
2610         (AsmOperands): Remove Pass3.
2611         (AsmOperandSpec): Remove Pass3.
2612         (AsmInputElement): Remove Pass3.
2613         (AsmOutputElement): Remove Pass3.
2614         (AsmTrashList): Remove Pass3.
2616 2023-06-12  Gaius Mulley  <gaiusmod2@gmail.com>
2618         PR modula2/110126
2619         * gm2-compiler/M2Quads.def (BuildAsmElement): Remove
2620         trash parameter.
2621         (BuildAsmTrash): New procedure.
2622         * gm2-compiler/M2Quads.mod (BuildAsmTrash): New procedure.
2623         (BuildAsmElement): Remove trash parameter.
2624         * gm2-compiler/P3Build.bnf (AsmTrashList): Rewrite.
2626 2023-06-08  Gaius Mulley  <gaiusmod2@gmail.com>
2628         PR modula2/110126
2629         * gm2-compiler/M2GenGCC.mod (BuildTreeFromInterface): Remove
2630         tokenno parameter.  Use object tok instead of tokenno.
2631         (BuildTrashTreeFromInterface): Use object tok instead of
2632         GetDeclaredMod.
2633         (CodeInline): Remove tokenno from parameter list to BuildTreeFromInterface.
2634         * gm2-compiler/M2Quads.def (BuildAsmElement): Exported and
2635         defined.
2636         * gm2-compiler/M2Quads.mod (BuildOptimizeOff): Reformatted.
2637         (BuildInline): Reformatted.
2638         (BuildLineNo): Reformatted.
2639         (UseLineNote): Reformatted.
2640         (BuildAsmElement): New procedure.
2641         * gm2-compiler/P0SyntaxCheck.bnf (AsmOperands): Use
2642         ConstExpression instead of string.
2643         (AsmElement): Use ConstExpression instead of string.
2644         (TrashList): Use ConstExpression instead of string.
2645         * gm2-compiler/P1Build.bnf (AsmOperands): Use
2646         ConstExpression instead of string.
2647         (AsmElement): Use ConstExpression instead of string.
2648         (TrashList): Use ConstExpression instead of string.
2649         * gm2-compiler/P2Build.bnf (AsmOperands): Use
2650         ConstExpression instead of string.
2651         (AsmElement): Use ConstExpression instead of string.
2652         (TrashList): Use ConstExpression instead of string.
2653         * gm2-compiler/P3Build.bnf (AsmOperands): Rewrite.
2654         (AsmOperandSpec): Rewrite.
2655         (AsmOutputList): New rule.
2656         (AsmInputList): New rule.
2657         (TrashList): Rewrite.
2658         * gm2-compiler/PCBuild.bnf (AsmOperands): Use
2659         ConstExpression instead of string.
2660         (AsmElement): Use ConstExpression instead of string.
2661         (TrashList): Use ConstExpression instead of string.
2662         * gm2-compiler/PHBuild.bnf (AsmOperands): Use
2663         ConstExpression instead of string.
2664         (AsmElement): Use ConstExpression instead of string.
2665         (TrashList): Use ConstExpression instead of string.
2666         * gm2-compiler/SymbolTable.def (PutRegInterface):
2667         Rewrite interface.
2668         (GetRegInterface): Rewrite interface.
2669         * gm2-compiler/SymbolTable.mod (SetFirstUsed): New procedure.
2670         (PutFirstUsed): New procedure.
2671         (PutRegInterface): Rewrite.
2672         (GetRegInterface): Rewrite.
2674 2023-06-07  Jakub Jelinek  <jakub@redhat.com>
2676         * Make-lang.in: Build $(generated_files) before building
2677         all $(GM2_C_OBJS).
2679 2023-06-07  Gaius Mulley  <gaiusmod2@gmail.com>
2681         PR modula2/110019
2682         * gm2-compiler/SymbolKey.mod (SearchAndDo): Reformatted.
2683         (ForeachNodeDo): Reformatted.
2684         * gm2-compiler/SymbolTable.mod (AddListify): Join list
2685         with "," or "and" if more than one word is in the list.
2686         * m2.flex: Remove -1 from atoi(yytext) line number.
2688 2023-06-03  Gaius Mulley  <gaiusmod2@gmail.com>
2690         PR modula2/110003
2691         * gm2-compiler/P2SymBuild.mod (GetParameterShadowVar): Import.
2692         (CheckFormalParameterSection): Call PutDeclared for the shadow
2693         variable associated with the parameter.
2695 2023-05-24  Gaius Mulley  <gaiusmod2@gmail.com>
2697         PR modula2/109952
2698         * Make-maintainer.in: Change header to include emacs file mode.
2699         * gm2-compiler/M2GenGCC.mod (BuildHighFromChar): Check whether
2700         operand is a constant string and is nul terminated then return one.
2701         * gm2-compiler/PCSymBuild.mod (WalkFunction): Add default return
2702         TRUE.  Static analysis missing return path fix.
2703         * gm2-libs/IO.mod (Init): Rewrite to help static analysis.
2704         * target-independent/m2/gm2-libs.texi: Rebuild.
2706 2023-05-19  Gaius Mulley  <gaiusmod2@gmail.com>
2708         PR modula2/109908
2709         * gm2-libs-iso/Strings.mod (Delete): Re-implement.
2711 2023-05-18  Bernhard Reutner-Fischer  <aldot@gcc.gnu.org>
2713         * gm2-gcc/m2builtins.cc (doradix): Use _P defines from tree.h.
2714         (doplaces): Ditto.
2715         (doexponentmin): Ditto.
2716         (doexponentmax): Ditto.
2717         (dolarge): Ditto.
2718         (dosmall): Ditto.
2719         (dogUnderflow): Ditto.
2720         * gm2-gcc/m2convert.cc (unsafe_conversion_p): Ditto.
2721         * gm2-gcc/m2expr.cc (m2expr_build_unary_op_check): Ditto.
2722         (m2expr_build_binary_op_check): Ditto.
2723         * gm2-gcc/m2tree.cc (m2tree_is_var): Ditto.
2724         * gm2-gcc/m2treelib.cc (build_modify_expr): Ditto.
2725         * gm2-gcc/m2type.cc (gm2_finish_decl): Ditto.
2726         * m2pp.cc (hextree): Ditto.
2727         (m2pp_call_expr): Ditto.
2729 2023-05-17  Gaius Mulley  <gaiusmod2@gmail.com>
2731         * gm2-libs-iso/LongWholeIO.mod (WriteInt): Only request a
2732         sign if the value is < 0.
2733         * gm2-libs-iso/ShortWholeIO.mod (WriteInt): Only request a
2734         sign if the value is < 0.
2735         * gm2-libs-iso/WholeIO.mod (WriteInt): Only request a sign
2736         if the value is < 0.
2737         * gm2-libs-iso/WholeStr.mod (WriteInt): Only request a sign
2738         if the value is < 0.
2740 2023-05-16  Gaius Mulley  <gaiusmod2@gmail.com>
2742         PR modula2/109879
2743         * gm2-libs-iso/LongIO.mod (ReadReal): Call SkipSpaces.
2744         * gm2-libs-iso/LongWholeIO.mod (ReadInt): Call SkipSpaces.
2745         (ReadCard): Call SkipSpaces.
2746         * gm2-libs-iso/RealIO.mod (ReadReal): Call SkipSpaces.
2747         * gm2-libs-iso/ShortWholeIO.mod: (ReadInt): Call SkipSpaces.
2748         (ReadCard): Call SkipSpaces.
2749         * gm2-libs-iso/TextIO.mod: Import SkipSpaces.
2750         * gm2-libs-iso/WholeIO.mod (ReadInt): Call SkipSpaces.
2751         (ReadCard): Call SkipSpaces.
2752         * gm2-libs-iso/TextUtil.def: New file.
2753         * gm2-libs-iso/TextUtil.mod: New file.
2755 2023-05-16  Gaius Mulley  <gaiusmod2@gmail.com>
2757         PR modula2/108344
2758         * gm2-libs-coroutines/TimerHandler.mod (EnableLED): New constant.
2759         (Timer): Test EnableLED before switching on the scroll LED.
2761 2023-05-12  Gaius Mulley  <gaiusmod2@gmail.com>
2763         PR modula2/109830
2764         * gm2-libs-iso/SeqFile.mod (newCid): New parameter toAppend
2765         used to select FIO.OpenForRandom.
2766         (OpenRead): Pass extra parameter to newCid.
2767         (OpenWrite): Pass extra parameter to newCid.
2768         (OpenAppend): Pass extra parameter to newCid.
2770 2023-05-11  Gaius Mulley  <gaiusmod2@gmail.com>
2772         PR modula2/109810
2773         * gm2-compiler/M2ALU.mod (ConvertConstToType): Use
2774         PrepareCopyString in place of DoCopyString.
2775         * gm2-compiler/M2GenGCC.def (DoCopyString): Rename to ...
2776         (PrepareCopyString): ... this.
2777         * gm2-compiler/M2GenGCC.mod (CodeStatement): Call CodeReturnValue
2778         with a single parameter.  Call CodeXIndr with a single parameter.
2779         (CodeReturnValue): Remove parameters and replace with a single
2780         quadno.  Reimplement using PrepareCopyString.  Issue error
2781         if the string exceeds designator space.
2782         (DoCopyString): Reimplement and rename to ...
2783         (PrepareCopyString): ... this.
2784         (CodeXIndr): Remove parameters and replace with a single
2785         quadno.  Reimplement using PrepareCopyString.  Issue error
2786         if the string exceeds designator space.
2787         (CodeBecomes): Remove parameters and replace with a single
2788         quadno.  Reimplement using PrepareCopyString.  Issue error
2789         if the string exceeds designator space.
2790         * gm2-compiler/M2Quads.def (BuildReturn): Rename parameter to
2791         tokreturn.
2792         * gm2-compiler/M2Quads.mod (BuildReturn): Rename parameter to
2793         tokreturn.  Rename tokno to tokcombined.
2795 2023-05-09  Gaius Mulley  <gaiusmod2@gmail.com>
2797         PR modula2/109779
2798         * gm2-libs-iso/RTgen.mod (doLook): Remove old.
2799         Remove re-assignment of result.
2800         * gm2-libs-iso/TextIO.mod (CanRead): Rename into ...
2801         (CharAvailable): ... this.
2802         (DumpState): New procedure.
2803         (SetResult): Rename as SetNul.
2804         (WasGoodChar): Rename into ...
2805         (EofOrEoln): ... this.
2806         (SkipLine): Skip over the newline.
2807         (ReadString): Flip THEN ELSE statements after testing for
2808         EofOrEoln.
2809         (ReadRestLine): Flip THEN ELSE statements after testing for
2810         EofOrEoln.
2812 2023-05-04  Gaius Mulley  <gaiusmod2@gmail.com>
2814         PR modula2/109729
2815         * gm2-compiler/M2GenGCC.mod (CodeStatement): Detect
2816         ArithAddOp and call CodeAddChecked.
2817         (ResolveConstantExpressions): Detect ArithAddOp and call
2818         FoldArithAdd.
2819         (FoldArithAdd): New procedure.
2820         (FoldAdd): Refactor to use FoldArithAdd.
2821         * gm2-compiler/M2Quads.def (QuadOperator): Add ArithAddOp.
2822         * gm2-compiler/M2Quads.mod: Remove commented imports.
2823         (QuadFrame): Changed comments to use GNU coding standards.
2824         (ArithPlusTok): New global variable.
2825         (BuildForToByDo): Use ArithPlusTok instead of PlusTok.
2826         (MakeOp): Detect ArithPlusTok and return ArithAddOp.
2827         (WriteQuad): Add ArithAddOp clause.
2828         (WriteOperator): Add ArithAddOp clause.
2829         (Init): Initialize ArithPlusTok.
2831 2023-05-04  Gaius Mulley  <gaiusmod2@gmail.com>
2833         PR modula2/109675
2834         * Make-lang.in (MC-LIB-DEFS): Remove M2LINK.def.
2835         (BUILD-PGE-O): Remove GM2LINK.o.
2836         * Make-maintainer.in (PPG-DEFS): New define.
2837         (PPG-LIB-DEFS): Remove M2LINK.def.
2838         (BUILD-BOOT-PPG-H): Add PPGDEF .h files.
2839         (m2/ppg$(exeext)): Remove M2LINK.o
2840         (PGE-DEPS): New define.
2841         (m2/pg$(exeext)): Remove M2LINK.o.
2842         (m2/gm2-pge-boot/$(SRC_PREFIX)%.o): Add -Im2/gm2-pge-boot.
2843         (m2/pge$(exeext)): Remove M2LINK.o.
2844         (pge-maintainer): Re-implement.
2845         (pge-libs-push): Re-implement.
2846         (m2/m2obj3/cc1gm2$(exeext)): Remove M2LINK.o.
2847         * gm2-libs/DynamicStrings.mod (writeAddress): Re-implement
2848         using snprintf.
2849         * gm2-libs/M2Dependent.mod: Remove commented out imports.
2850         * mc-boot/GDynamicStrings.cc: Rebuild.
2851         * mc-boot/GFIO.cc: Rebuild.
2852         * mc-boot/GFormatStrings.cc: Rebuild.
2853         * mc-boot/GM2Dependent.cc: Rebuild.
2854         * mc-boot/GM2Dependent.h: Rebuild.
2855         * mc-boot/GM2RTS.cc: Rebuild.
2856         * mc-boot/GM2RTS.h: Rebuild.
2857         * mc-boot/GRTExceptions.cc: Rebuild.
2858         * mc-boot/GRTint.cc: Rebuild.
2859         * mc-boot/GSFIO.cc: Rebuild.
2860         * mc-boot/GStringConvert.cc: Rebuild.
2861         * mc-boot/Gdecl.cc: Rebuild.
2862         * pge-boot/GASCII.cc: Rebuild.
2863         * pge-boot/GASCII.h: Rebuild.
2864         * pge-boot/GArgs.cc: Rebuild.
2865         * pge-boot/GArgs.h: Rebuild.
2866         * pge-boot/GAssertion.cc: Rebuild.
2867         * pge-boot/GAssertion.h: Rebuild.
2868         * pge-boot/GBreak.h: Rebuild.
2869         * pge-boot/GCmdArgs.h: Rebuild.
2870         * pge-boot/GDebug.cc: Rebuild.
2871         * pge-boot/GDebug.h: Rebuild.
2872         * pge-boot/GDynamicStrings.cc: Rebuild.
2873         * pge-boot/GDynamicStrings.h: Rebuild.
2874         * pge-boot/GEnvironment.h: Rebuild.
2875         * pge-boot/GFIO.cc: Rebuild.
2876         * pge-boot/GFIO.h: Rebuild.
2877         * pge-boot/GFormatStrings.h:: Rebuild.
2878         * pge-boot/GFpuIO.h:: Rebuild.
2879         * pge-boot/GIO.cc: Rebuild.
2880         * pge-boot/GIO.h: Rebuild.
2881         * pge-boot/GIndexing.cc: Rebuild.
2882         * pge-boot/GIndexing.h: Rebuild.
2883         * pge-boot/GLists.cc: Rebuild.
2884         * pge-boot/GLists.h: Rebuild.
2885         * pge-boot/GM2Dependent.cc: Rebuild.
2886         * pge-boot/GM2Dependent.h: Rebuild.
2887         * pge-boot/GM2EXCEPTION.cc: Rebuild.
2888         * pge-boot/GM2EXCEPTION.h: Rebuild.
2889         * pge-boot/GM2RTS.cc: Rebuild.
2890         * pge-boot/GM2RTS.h: Rebuild.
2891         * pge-boot/GNameKey.cc: Rebuild.
2892         * pge-boot/GNameKey.h: Rebuild.
2893         * pge-boot/GNumberIO.cc: Rebuild.
2894         * pge-boot/GNumberIO.h: Rebuild.
2895         * pge-boot/GOutput.cc: Rebuild.
2896         * pge-boot/GOutput.h: Rebuild.
2897         * pge-boot/GPushBackInput.cc: Rebuild.
2898         * pge-boot/GPushBackInput.h: Rebuild.
2899         * pge-boot/GRTExceptions.cc: Rebuild.
2900         * pge-boot/GRTExceptions.h: Rebuild.
2901         * pge-boot/GSArgs.h: Rebuild.
2902         * pge-boot/GSEnvironment.h: Rebuild.
2903         * pge-boot/GSFIO.cc: Rebuild.
2904         * pge-boot/GSFIO.h: Rebuild.
2905         * pge-boot/GSYSTEM.h: Rebuild.
2906         * pge-boot/GScan.h: Rebuild.
2907         * pge-boot/GStdIO.cc: Rebuild.
2908         * pge-boot/GStdIO.h: Rebuild.
2909         * pge-boot/GStorage.cc: Rebuild.
2910         * pge-boot/GStorage.h: Rebuild.
2911         * pge-boot/GStrCase.cc: Rebuild.
2912         * pge-boot/GStrCase.h: Rebuild.
2913         * pge-boot/GStrIO.cc: Rebuild.
2914         * pge-boot/GStrIO.h: Rebuild.
2915         * pge-boot/GStrLib.cc: Rebuild.
2916         * pge-boot/GStrLib.h: Rebuild.
2917         * pge-boot/GStringConvert.h: Rebuild.
2918         * pge-boot/GSymbolKey.cc: Rebuild.
2919         * pge-boot/GSymbolKey.h: Rebuild.
2920         * pge-boot/GSysExceptions.h: Rebuild.
2921         * pge-boot/GSysStorage.cc: Rebuild.
2922         * pge-boot/GSysStorage.h: Rebuild.
2923         * pge-boot/GTimeString.h: Rebuild.
2924         * pge-boot/GUnixArgs.h: Rebuild.
2925         * pge-boot/Gbnflex.cc: Rebuild.
2926         * pge-boot/Gbnflex.h: Rebuild.
2927         * pge-boot/Gdtoa.h: Rebuild.
2928         * pge-boot/Gerrno.h: Rebuild.
2929         * pge-boot/Gldtoa.h: Rebuild.
2930         * pge-boot/Glibc.h: Rebuild.
2931         * pge-boot/Glibm.h: Rebuild.
2932         * pge-boot/Gpge.cc: Rebuild.
2933         * pge-boot/Gtermios.h: Rebuild.
2934         * pge-boot/Gwrapc.h: Rebuild.
2935         * mc-boot/GM2LINK.h: Removed.
2936         * pge-boot/GM2LINK.cc: Removed.
2937         * pge-boot/GM2LINK.h: Removed.
2939 2023-04-30  Gaius Mulley  <gaiusmod2@gmail.com>
2941         * gm2-compiler/SymbolTable.mod (ConstLitPoolEntry): New
2942         pointer to record.
2943         (ConstLitSym): New field RangeError.
2944         (ConstLitPoolTree): New SymbolTree representing name to
2945         index.
2946         (ConstLitArray): New dynamic array containing pointers
2947         to a ConstLitPoolEntry.
2948         (CreateConstLit): New procedure function.
2949         (LookupConstLitPoolEntry): New procedure function.
2950         (AddConstLitPoolEntry): New procedure function.
2951         (MakeConstLit): Re-implemented to check the constant lit
2952         pool before calling CreateConstLit.
2953         * m2.flex: Add ability to decode binary constant literals.
2955 2023-04-26  Gaius Mulley  <gaiusmod2@gmail.com>
2957         PR modula2/108121
2958         * gm2-compiler/M2ALU.mod (Less): Reformatted.
2959         * gm2-compiler/SymbolTable.mod (DetermineSizeOfConstant): Remove
2960         from import.
2961         (ConstantStringExceedsZType): Import.
2962         (GetConstLitType): Re-implement using ConstantStringExceedsZType.
2963         * gm2-gcc/m2decl.cc (m2decl_DetermineSizeOfConstant): Remove.
2964         (m2decl_ConstantStringExceedsZType): New function.
2965         (m2decl_BuildConstLiteralNumber): Re-implement.
2966         * gm2-gcc/m2decl.def (DetermineSizeOfConstant): Remove.
2967         (ConstantStringExceedsZType): New function.
2968         * gm2-gcc/m2decl.h (m2decl_DetermineSizeOfConstant): Remove.
2969         (m2decl_ConstantStringExceedsZType): New function.
2970         * gm2-gcc/m2expr.cc (append_digit): Remove.
2971         (m2expr_interpret_integer): Remove.
2972         (append_m2_digit): Remove.
2973         (m2expr_StrToWideInt): New function.
2974         (m2expr_interpret_m2_integer): Remove.
2975         * gm2-gcc/m2expr.def (CheckConstStrZtypeRange): New function.
2976         * gm2-gcc/m2expr.h (m2expr_StrToWideInt): New function.
2977         * gm2-gcc/m2type.cc (build_m2_word64_type_node): New function.
2978         (build_m2_ztype_node): New function.
2979         (m2type_InitBaseTypes): Call build_m2_ztype_node.
2980         * gm2-lang.cc (gm2_type_for_size): Re-write using early returns.
2982 2023-04-21  Arsen Arsenović  <arsen@aarsen.me>
2984         * Make-lang.in: Remove references to $(P).
2985         * Make-maintainer.in: Ditto.
2987 2023-04-21  Gaius Mulley  <gaiusmod2@gmail.com>
2989         PR modula2/109586
2990         * gm2-gcc/m2tree.cc (m2tree_IsAConstant): Add (TREE_CODE
2991         (t) == CONSTRUCTOR) to expression.
2993 2023-04-13  Gaius Mulley  <gaiusmod2@gmail.com>
2995         PR modula2/109488
2996         * lang.opt: Fix typo "maybe" to "may be".
2998 2023-04-13  Gaius Mulley  <gaiusmod2@gmail.com>
3000         * gm2-compiler/M2ALU.def (PopChar): New procedure function.
3001         * gm2-compiler/M2ALU.mod (PopChar): New procedure function.
3002         * gm2-compiler/M2GCCDeclare.mod (PromoteToString): Detect
3003         a single constant char and build a C string.
3004         * gm2-compiler/M2GenGCC.mod (IsConstStr): New procedure
3005         function.
3006         (GetStr): New procedure function.
3007         (FoldAdd): Use IsConstStr.
3008         * gm2-compiler/M2Quads.mod: Formatting changes.
3009         * gm2-gcc/m2expr.cc (m2expr_GetCstInteger): New function.
3010         * gm2-gcc/m2expr.def (GetCstInteger): New procedure function.
3011         * gm2-gcc/m2expr.h (m2expr_GetCstInteger): New prototype.
3013 2023-04-05  Gaius Mulley  <gaiusmod2@gmail.com>
3015         PR modula2/109423
3016         * gm2-compiler/M2Base.def (Unbounded): Remove.
3017         * gm2-compiler/M2Error.def (ErrorAbort0): Add noreturn
3018         attribute.
3019         * gm2-compiler/M2Quads.mod (BuildInclProcedure): Correct
3020         error format string.
3021         (BuildExceptProcedure): Correct error format string.
3022         (BuildAdrFunction): Call PutWriteQuad when taking the
3023         address of a variable.
3024         * gm2-libs-ch/SysExceptions.c (_M2_SysExceptions_init): Add
3025         parameters.
3026         * gm2-libs-ch/wrapc.c (_M2_wrapc_init): Add parameters.
3027         * gm2-libs/DynamicStrings.mod (DumpStringInfo): Remove t.
3028         (PopAllocationExemption): Remove f.
3029         * gm2-libs/FIO.mod (BufferedWrite): Remove result.
3030         * gm2-libs/FormatStrings.mod (Copy): Remove endpos and
3031         afterperc.
3032         (HandlePercent): Remove result.
3033         * gm2-libs/Indexing.mod (RemoveIndiceFromIndex): Remove k.
3034         * gm2-libs/M2Dependent.mod (CreateModule): Remove p0
3035         and p1.
3036         (DumpModuleData): Remove mptr.
3037         (ConstructModules): Remove nulp.
3038         * gm2-libs/RTExceptions.mod (PopHandler): Remove i.
3039         * gm2-libs/RTint.mod (Listen): Remove b4s, b4m, afs
3040         and afm.
3041         * gm2-libs/SFIO.mod (ReadS): Remove c.
3042         * gm2-libs/StringConvert.mod (doDecimalPlaces): Remove
3043         whole and fraction.
3045 2023-04-03  Gaius Mulley  <gaiusmod2@gmail.com>
3047         PR modula2/109388
3048         * gm2-compiler/M2GCCDeclare.mod (DoVariableDeclaration):
3049         Remove second parameter module.  Adjust all callers to
3050         remove the second parameter.
3051         * gm2-compiler/PHBuild.bnf (CheckAndInsert): Remove.
3052         (InStopSet): Remove.
3053         (PeepToken): Remove.
3054         (PushQualident): Remove.
3055         (SimpleDes): Remove.
3056         (ActualParameters): Remove.
3058 2023-04-02  Gaius Mulley  <gaiusmod2@gmail.com>
3060         PR modula2/109336
3061         * Make-lang.in (GM2_O): Set to -O0.
3062         (GM2_LIBS): Remove target libraries and replace with build libs.
3063         (BUILD-LIBS): New declaration.
3064         (m2/gm2-libs/libgm2.a): New rule.
3065         (m2/gm2-libs/%.o): New rule.
3066         (m2/gm2-libs/choosetemp.o): New rule.
3067         * gm2-compiler/M2ColorString.mod (append): Use ADR rather than
3068         implicit conversion.
3069         * gm2-compiler/M2Comp.mod (Compile): Add qprintf messages for when
3070         a source file is not found.  Improve comments and formatting.
3071         * gm2-libs-ch/cgetopt.c (cgetopt_cgetopt_long): Remove
3072         ansi-decl.h.  Add getopt.h.
3073         (cgetopt_cgetopt_long_only): Change cgetopt_ to getopt_.
3074         * gm2spec.cc (lang_specific_driver): Do not skip -fmod=.
3075         Remove comment.
3077 2023-03-29  Gaius Mulley  <gaiusmod2@gmail.com>
3079         PR modula2/109336
3080         PR modula2/109315
3081         * gm2-compiler/M2FileName.mod (CalculateFileName): Simplified by
3082         ensuring the extension contains the ".".
3083         (CalculateStemName): Re-formatted.
3084         (ExtractExtension): Re-formatted.
3085         (ExtractModule): Re-formatted.
3086         * gm2-compiler/M2Options.def (setdefextension): Add block comment.
3087         (setmodextension): Add block comment.  Re-formatted.
3088         * gm2-compiler/M2Options.mod (setdefextension): Add block comment.
3089         (setmodextension): Add block comment.  Re-formatted.
3090         * gm2-compiler/M2Search.mod (FindSourceDefFile): Use
3091         DefaultDefExt.
3092         (DefaultDefExt): New constant.
3093         (DefaultModExt): New constant.
3094         (FindSourceModFile): Use DefaultModExt.
3095         * gm2-gcc/m2decl.cc (m2decl_DeclareKnownVariable): Correct
3096         spelling.
3097         * gm2spec.cc (M2SOURCE): New constant.
3098         (LANGSPEC): New value.
3099         (MATHLIB): New value.
3100         (WITHLIBC): New value.
3101         (SKIPOPT): New value.
3102         (lang_specific_driver): Replace seen_module_extension bool with
3103         module_extension char *.  Detect -fmod= and remember extension.
3104         Use the extension to detect modula-2 source and mark it as such.
3106 2023-03-23  Gaius Mulley  <gaiusmod2@gmail.com>
3108         PR modula2/109264
3109         * gm2-compiler/M2Quads.mod (BuildConstFunctionCall): Comment
3110         out ErrorString in debugging block.
3111         (BuildConstructorStart): Replace Assert with a call to
3112         MetaErrorT3.  Import MetaErrorT3.
3113         * gm2-compiler/PCSymBuild.mod (buildConstFunction): Rename
3114         local variables.
3115         (WalkFunctionParam): Remove test for IsEnumeration when
3116         resolving MIN or MAX parameters.
3117         * gm2-compiler/PHBuild.bnf (BlockAssert): New procedure.
3118         (ErrorArrayat): New procedure.
3119         (Expect): Renamed parameter t to tok.
3120         (PushQualident): New rule.
3121         (ConstSetOrQualidentOrFunction): Force AutoOn.
3122         (TypeDeclaration): Add debugging assert.
3123         (SimpleType): Add debugging assert.
3124         (DefaultRecordAttributes): New rule (and bugfix).
3125         (FieldPragmaExpression): New rule (and bugfix).
3126         (PragmaConstExpression): New rule (and bugfix).
3127         (SetOrDesignatorOrFunction): Add debugging assert.
3128         (Block): Add debugging assert.
3129         * gm2-gcc/m2expr.cc (m2expr_ConstantExpressionWarning): int
3130         to bool.
3131         * gm2-gcc/m2expr.h (m2expr_TreeOverflow): int to bool.
3132         (m2expr_GetBooleanTrue): Remove.
3133         (m2expr_GetBooleanFalse): Remove.
3134         * gm2-gcc/m2options.h (M2Options_SetStatistics): Replace
3135         int with bool.
3137 2023-03-22  Gaius Mulley  <gaiusmod2@gmail.com>
3139         PR modula2/109248
3140         * Make-lang.in (m2/pge-boot/%.o): Add CFLAGS and CXXFLAGS for C
3141         and C++ compiles.
3142         * gm2spec.cc (add_m2_I_path): Indentation.
3143         (lang_specific_driver): New variable seen_pathname.
3144         Detect -fm2-pathname.  If not seen then push_back_Ipath (".").
3145         Change non iso library path to "m2cor,m2log,m2pim,m2iso".
3147 2023-03-22  Gaius Mulley  <gaiusmod2@gmail.com>
3149         PR modula2/107630
3150         * Make-lang.in (m2/stage2/cc1gm2$(exeext)): Remove
3151         m2/gm2-libs-boot/M2LINK.o.
3152         (m2/stage1/cc1gm2$(exeext)): Ditto.
3153         (GM2-LIBS-BOOT-DEFS): Remove M2LINK.def.
3154         (GM2-LIBS-DEFS): Ditto.
3155         (m2/mc-boot/$(SRC_PREFIX)%.o): Replace CXX_FLAGS with CXXFLAGS.
3156         (m2/mc-boot-ch/$(SRC_PREFIX)%.o): Ditto.
3157         (m2/mc-boot/main.o): Ditto.
3158         (mcflex.o): Add $(CFLAGS).
3159         (m2/gm2-libs-boot/M2LINK.o): Remove rule.
3160         * gm2-compiler/M2GCCDeclare.def (DeclareM2linkGlobals): Remove.
3161         * gm2-compiler/M2GCCDeclare.mod: (M2LinkEntry): Remove.
3162         (M2LinkIndex): Remove.
3163         (DoVariableDeclaration): Remove initial and call to
3164         AddEntryM2Link.
3165         (AddEntryM2Link): Remove.
3166         (GetEntryM2Link): Remove.
3167         (DeclareM2linkGlobals): Remove.
3168         (DetectM2LinkInitial): Remove.
3169         (InitM2LinkModule): Remove.
3170         * gm2-compiler/M2GenGCC.mod (CodeFinallyEnd): Remove call to
3171         DeclareM2linkGlobals.
3172         * gm2-compiler/M2Quads.mod (BuildM2InitFunction): Add extra
3173         parameter containing runtime module override to ConstructModules.
3174         * gm2-compiler/M2Scaffold.mod: Update comment describing
3175         ConstructModules.
3176         * gm2-gcc/m2decl.cc (m2decl_DeclareM2linkForcedModuleInitOrder):
3177         Remove.
3178         * gm2-libs-iso/M2RTS.def (ConstructModules): Add overrideliborder
3179         parameter.
3180         * gm2-libs-iso/M2RTS.mod: Add overrideliborder parameter.
3181         * gm2-libs/M2Dependent.def (ConstructModules): Add overrideliborder
3182         parameter.
3183         * gm2-libs/M2Dependent.mod (ConstructModules): Add overrideliborder
3184         parameter.
3185         * gm2-libs/M2RTS.def (ConstructModules): Add overrideliborder parameter.
3186         * gm2-libs/M2RTS.mod (ConstructModules): Add overrideliborder
3187         parameter.
3188         * gm2-libs/M2LINK.def: Removed.
3190 2023-03-21  Gaius Mulley  <gaiusmod2@gmail.com>
3192         * Make-lang.in (m2/mc-boot/$(SRC_PREFIX)%.o): Add $(CXXFLAGS).
3193         (m2/mc-boot-ch/$(SRC_PREFIX)%.o): Add $(CXXFLAGS).
3194         (m2/mc-boot-ch/$(SRC_PREFIX)%.o): Add $(CXXFLAGS).
3195         (m2/mc-boot/main.o): Add $(CXXFLAGS).
3197 2023-03-19  Gaius Mulley  <gaiusmod2@gmail.com>
3199         * Make-maintainer.in (gm2.maintainer-clean): Remove.
3200         (gm2.maintainer-help): Add gm2.maintainer-tools,
3201         gm2.maintainer-doc.  Remove gm2.maintainer-clean.
3202         Change target-independent directory to target-independent/m2.
3203         * gm2-compiler/ppg.mod: Correct __FILE_ typo to __FILE__.
3204         * gm2-compiler/M2Options.def (SetAutoInit): Update comment.
3205         * gm2-compiler/M2Options.mod (SetAutoInit): Update comment.
3206         * gm2-gcc/m2color.cc (m2color_colorize_start): Rename name_len
3207         to _name_high.
3208         * gm2-gcc/m2color.def (colorize_start): change ARRAY OF CHAR to
3209         ADDRESS and add _name_high.
3210         * gm2-gcc/m2decl.cc (m2decl_BuildStartFunctionDeclaration): Change
3211         int to bool.
3212         * gm2-gcc/m2decl.h (m2decl_BuildStartFunctionDeclaration): Change
3213         int to bool.
3214         * gm2-gcc/m2expr.cc (m2expr_BuildBinarySetDo): Change int to bool.
3215         (m2expr_BuildIfConstInVar): Change int to bool.
3216         (m2expr_BuildIfNotConstInVar): Change int to bool.
3217         (m2expr_BuildIfVarInVar): Change int to bool.
3218         (m2expr_BuildIfNotVarInVar): Change int to bool.
3219         (m2expr_BuildForeachWordInSetDoIfExpr): Change int to bool.
3220         * gm2-gcc/m2expr.h (m2expr_BuildIfNotVarInVar): Change int to bool.
3221         (m2expr_BuildIfVarInVar): Change int to bool.
3222         (m2expr_BuildIfNotConstInVar): Change int to bool.
3223         (m2expr_BuildIfConstInVar): Change int to bool.
3224         * gm2-gcc/m2options.h (M2Options_SetAutoInit): Change int to bool.
3225         (M2Options_SetNilCheck): Change int to bool.
3226         (M2Options_SetReturnCheck): Change int to bool.
3227         (M2Options_SetCaseCheck): Change int to bool.
3228         (M2Options_SetCheckAll): Change int to bool.
3229         (M2Options_SetVerboseUnbounded): Change int to bool.
3230         (M2Options_SetUnboundedByReference): Change int to bool.
3231         (M2Options_SetOptimizing): Change int to bool.
3232         (M2Options_SetQuiet): Change int to bool.
3233         (M2Options_SetCpp): Change int to bool.
3234         (M2Options_SetM2g): Change int to bool.
3235         (M2Options_SetLowerCaseKeywords): Change int to bool.
3236         (M2Options_SetVerbose): Change int to bool.
3237         * gm2-gcc/m2treelib.cc (m2treelib_get_rvalue): Change int to bool.
3238         (m2treelib_get_field_no): Change int to bool.
3239         (m2treelib_get_set_value): Change int to bool.
3240         (m2treelib_get_set_address): Change int to bool.
3241         (m2treelib_get_set_address_if_var): Change int to bool.
3242         * gm2-gcc/m2treelib.def (get_set_address_if_var): Change int to bool.
3243         (get_set_address): Change int to bool.
3244         (get_set_value): Change int to bool.
3245         (get_field_no): Change int to bool.
3246         (get_rvalue): Change int to bool.
3247         * gm2-gcc/m2treelib.h (m2treelib_get_field_no): Change int to bool.
3248         (m2treelib_get_set_value): Change int to bool.
3249         (m2treelib_get_set_address): Change int to bool.
3250         (m2treelib_get_set_address_if_var): Change int to bool.
3251         * gm2-gcc/m2type.cc (m2type_BuildEndFunctionType): Change int to bool.
3252         * gm2-gcc/m2type.h (m2type_BuildEndFunctionType): Change int to bool.
3253         * gm2-libs-ch/dtoa.cc (dtoa_calcsign): Change int to bool.
3254         * gm2-libs-ch/ldtoa.cc (dtoa_calcsign): Change int to bool.
3255         (ldtoa_ldtoa): Change int to bool.
3256         * m2.flex (functionInfo): Change int to bool.
3257         (pushFunction): Change parameter from int to bool.
3258         * mc-boot/GDebug.cc (Debug_Halt): Rebuild.
3259         * mc-boot/GDebug.h (Debug_Halt): Rebuild.
3260         * mc-boot/GDynamicStrings.cc: Rebuild.
3261         * mc-boot/GDynamicStrings.h: Rebuild.
3262         * mc-boot/GFIO.cc: Rebuild.
3263         * mc-boot/GM2RTS.cc: Rebuild.
3264         * mc-boot/GM2RTS.h: Rebuild.
3265         * mc-boot/GPushBackInput.cc: Rebuild.
3266         * mc-boot/GRTExceptions.cc: Rebuild.
3267         * mc-boot/GRTint.cc: Rebuild.
3268         * mc-boot/GSysStorage.cc: Rebuild.
3269         * mc-boot/Gdecl.cc: Rebuild.
3270         * mc-boot/GsymbolKey.cc: Rebuild.
3271         * mc/symbolKey.mod: Rebuild.
3272         * target-independent/m2/Builtins.texi: Rebuild.
3273         * target-independent/m2/SYSTEM-iso.texi: Rebuild.
3274         * target-independent/m2/SYSTEM-pim.texi: Rebuild.
3275         * target-independent/m2/gm2-libs.texi: Rebuild.
3276         * tools-src/def2doc.py (PIM_Log): Change gm2-libs-pim to
3277         gm2-lib-log.
3279 2023-03-17  Gaius Mulley  <gaiusmod2@gmail.com>
3281         PR modula2/109032
3282         * gm2-gcc/m2expr.cc: Correct ? : order in comments.
3283         (m2expr_BuildDivM2): Improve comment.
3284         * lang.opt: Improve option descriptions.
3286 2023-03-17  Gaius Mulley  <gaiusmod2@gmail.com>
3288         PR modula2/109102
3289         * gm2-gcc/m2builtins.cc (ASSERT): Change format specifier to
3290         use %qs rather than quotes.
3292 2023-03-17  Gaius Mulley  <gaiusmod2@gmail.com>
3294         * gm2-compiler/M2AsmUtil.mod (SymNeedsModulePrefix):
3295         Re-implemented.
3296         * gm2-libs/SysStorage.mod (enableTrace): Disable tracing.
3298 2023-03-16  Gaius Mulley  <gaiusmod2@gmail.com>
3300         * gm2-compiler/SymbolKey.mod (PutSymKey): Halt parameters
3301         reordered.
3302         (DelSymKey): Ditto.
3303         * gm2-compiler/ppg.mod (GetEpsilon): Ditto.
3304         (GetReachEnd): Ditto.
3305         (GetFollow): Ditto.
3306         (CodeCondition): Ditto.
3307         (CodeThenDo): Ditto.
3308         (CodeEnd): Ditto.
3309         (RecoverCondition): Ditto.
3310         (ConditionIndent): Ditto.
3311         * gm2-libs-ch/m2rts.h (M2RTS_Halt): Ditto.
3312         * gm2-libs-coroutines/Executive.mod (Assert): Ditto.
3313         (Resume): Remove redundant comments.
3314         (Wait): Remove redundant comments.
3315         * gm2-libs-coroutines/SYSTEM.mod (TRANSFER): Halt parameters
3316         reordered.
3317         (IOTransferHandler): Ditto.
3318         (Finished): Ditto.
3319         (localInit): Ditto.
3320         * gm2-libs-coroutines/TimerHandler.mod (WaitOn): Halt parameters
3321         reordered.
3322         (Cancel): Ditto.
3323         (ReArmEvent): Ditto.
3324         (OnActiveQueue): Ditto.
3325         * gm2-libs-iso/COROUTINES.mod (NEWCOROUTINE): Ditto.
3326         (Transfer): Ditto.
3327         (IOTRANSFER): Ditto.
3328         * gm2-libs-iso/EXCEPTIONS.mod (RAISE): Correct Halt parameters.
3329         * gm2-libs-iso/M2RTS.def (Halt): Halt parameters reordered.
3330         (HaltC): Ditto.
3331         * gm2-libs-iso/M2RTS.mod: Ditto.
3332         * gm2-libs-iso/RTentity.mod (PutKey): Ditto.
3333         (DelKey): Ditto.
3334         (findChildAndParent): Ditto.
3335         (assert): Ditto.
3336         * gm2-libs-iso/Storage.mod (ALLOCATE): Add DebugTrace.
3337         Add UseMallocFree test.
3338         (DEALLOCATE): Add DebugTrace.  Add UseMallocFree test.
3339         (assert): Halt parameters reordered.
3340         * gm2-libs-log/Termbase.mod (Read): Ditto.
3341         (KeyPressed): Ditto.
3342         (Write): Ditto.
3343         (Init): Ditto.
3344         * gm2-libs/Debug.def (Halt): Halt parameters reordered.
3345         * gm2-libs/Debug.mod (Halt): Ditto.
3346         * gm2-libs/DynamicStrings.def (PopAllocation): Improve comment.
3347         * gm2-libs/DynamicStrings.mod (PopAllocation): Improve comment.
3348         Halt parameters reordered.
3349         * gm2-libs/M2RTS.def (Halt): Ditto.
3350         (HaltC): Ditto.
3351         * gm2-libs/M2RTS.mod (Halt): Ditto.
3352         (HaltC): Ditto.
3353         * gm2-libs/PushBackInput.mod (PutStr): Ditto.
3354         (PutString): Ditto.
3355         (PutCh): Ditto.
3356         * gm2-libs/RTExceptions.mod (GetBaseExceptionBlock): Ditto.
3357         * gm2-libs/RTint.mod (ReArmTimeVector): Ditto.
3358         (GetTimeVector): Ditto.
3359         (AttachVector): Ditto.
3360         (IncludeVector): Ditto.
3361         (Listen): Ditto.
3362         * gm2-libs/SysStorage.mod (ALLOCATE): Ditto.
3363         (DEALLOCATE): Ditto.
3364         (REALLOCATE): Ditto.
3365         * gm2-libs-coroutines/Debug.def: Removed.
3366         * gm2-libs-coroutines/Debug.mod: Removed.
3368 2023-03-16  Gaius Mulley  <gaiusmod2@gmail.com>
3370         * Make-lang.in: Rename target-independent to
3371         target-independent/m2.
3372         * target-independent/readme.txt: Update.
3373         * target-independent/m2/gm2-ebnf.texi: New file.
3374         * target-independent/m2/gpl_v3_without_node.texi: New file.
3375         * target-independent/Builtins.texi: Rename ...
3376         * target-independent/m2/Builtins.texi: ... to this.
3377         * target-independent/SYSTEM-iso.texi: Rename ...
3378         * target-independent/m2/SYSTEM-iso.texi: ... to this.
3379         * target-independent/SYSTEM-pim.texi: Rename ...
3380         * target-independent/m2/SYSTEM-pim.texi: ... to this.
3381         * target-independent/gm2-libs.texi: Rename ...
3382         * target-independent/m2/gm2-libs.texi: ... to this.
3384 2023-03-15  Gaius Mulley  <gaiusmod2@gmail.com>
3386         PR modula2/109125
3387         * gm2-libs-ch/dtoa.cc (dtoa_strtod): Replace int with bool.
3388         * gm2-libs-ch/ldtoa.cc (ldtoa_strtold): Replace int with bool.
3390 2023-03-14  Gaius Mulley  <gaiusmod2@gmail.com>
3392         PR modula2/109125
3393         * gm2-libs-ch/cgetopt.c (cgetopt_SetOption): Replace int
3394         for bool.
3395         * gm2-libs-ch/termios.c (doSetUnset): Replace int for bool.
3396         * gm2-libs/Builtins.mod (isfinitef): Correct typo in return
3397         statement.
3399 2023-03-13  Gaius Mulley  <gaiusmod2@gmail.com>
3401         PR modula2/109103
3402         * gm2-compiler/M2ALU.def (PushString): New parameter issueError.
3403         * gm2-compiler/M2ALU.mod (PushString): New parameter issueError.
3404         * gm2-compiler/SymbolTable.mod (PushString): New parameter issueError.
3405         * gm2-gcc/m2decl.cc (m2decl_DetermineSizeOfConstant): Pass
3406         location to interpret_m2_integer.
3407         (m2decl_BuildConstLiteralNumber): New parameter issueError.
3408         * gm2-gcc/m2expr.cc (m2expr_IsTrue): Replace int with bool.
3409         (m2expr_IsFalse): Replace int with bool.
3410         (m2expr_AreConstantsEqual): Replace int with bool.
3411         (m2expr_BuildBinaryForeachWordDo): Call m2linemap_internal_error_at.
3412         (append_digit): Ditto.
3413         (m2expr_interpret_integer): Add location parameter.
3414         (append_m2_digit): Call m2linemap_internal_error_at.
3415         (m2expr_interpret_m2_integer): Add location parameter.
3416         (m2expr_GetSizeOf): Replace sizeof with SIZE in error message.
3417         * gm2-gcc/m2expr.h (m2expr_AreRealOrComplexConstantsEqual):
3418         Replace int with bool.
3419         (m2expr_AreConstantsEqual): Ditto.
3420         (m2expr_IsFalse): Ditto.
3421         (m2expr_IsTrue): Ditto.
3422         (m2expr_interpret_integer): Add location parameter.
3423         (m2expr_interpret_m2_integer): Add location parameter.
3424         * gm2-gcc/m2linemap.cc (mformat_value): New function.
3425         (expand_format): New function.
3426         (expand_message): New function.
3427         (gm2_internal_error_at): New function.
3428         (m2linemap_internal_error_at): New function.
3429         * gm2-gcc/m2linemap.h (m2linemap_internal_error_at): New function.
3430         * gm2-gcc/m2options.h (M2Options_SetISO): Replace int with bool.
3431         (M2Options_SetPIM): Ditto.
3432         (M2Options_SetPIM2): Ditto.
3433         (M2Options_SetPIM3): Ditto.
3434         (M2Options_SetPIM4): Ditto.
3435         (M2Options_SetFloatValueCheck): Ditto.
3436         (M2Options_SetWholeValueCheck): Ditto.
3437         (M2Options_GetISO): Ditto.
3438         (M2Options_GetPIM): Ditto.
3439         (M2Options_GetPIM2): Ditto.
3440         (M2Options_GetPIM3): Ditto.
3441         (M2Options_GetPIM4): Ditto.
3442         (M2Options_GetPositiveModFloor): Ditto.
3443         (M2Options_GetFloatValueCheck): Ditto.
3444         (M2Options_GetWholeValueCheck): Ditto.
3445         (M2Options_Setc): Ditto.
3446         (M2Options_Getc): Ditto.
3447         (M2Options_SetPPOnly): Ditto.
3448         (M2Options_GetPPOnly): Ditto.
3449         (M2Options_SetUselist): Ditto.
3450         (M2Options_SetAutoInit): Ditto.
3451         (M2Options_SetPositiveModFloor): Ditto.
3452         (M2Options_SetNilCheck): Ditto.
3453         (M2Options_SetWholeDiv): Ditto.
3454         (M2Options_SetIndex): Ditto.
3455         (M2Options_SetRange): Ditto.
3456         (M2Options_SetReturnCheck): Ditto.
3457         (M2Options_SetCaseCheck): Ditto.
3458         (M2Options_SetCheckAll): Ditto.
3459         (M2Options_SetExceptions): Ditto.
3460         (M2Options_SetStyle): Ditto.
3461         (M2Options_SetPedantic): Ditto.
3462         (M2Options_SetPedanticParamNames): Ditto.
3463         (M2Options_SetPedanticCast): Ditto.
3464         (M2Options_SetExtendedOpaque): Ditto.
3465         (M2Options_SetVerboseUnbounded): Ditto.
3466         (M2Options_SetXCode): Ditto.
3467         (M2Options_SetCompilerDebugging): Ditto.
3468         (M2Options_SetQuadDebugging): Ditto.
3469         (M2Options_SetDebugTraceQuad): Ditto.
3470         (M2Options_SetDebugTraceAPI): Ditto.
3471         (M2Options_SetSources): Ditto.
3472         (M2Options_SetUnboundedByReference): Ditto.
3473         (M2Options_SetDumpSystemExports): Ditto.
3474         (M2Options_SetOptimizing): Ditto.
3475         (M2Options_SetQuiet): Ditto.
3476         (M2Options_SetCC1Quiet): Ditto.
3477         (M2Options_SetCpp): Ditto.
3478         (M2Options_SetSwig): Ditto.
3479         (M2Options_SetWholeProgram): Ditto.
3480         (M2Options_SetDebugFunctionLineNumbers): Ditto.
3481         (M2Options_SetGenerateStatementNote): Ditto.
3482         (M2Options_GetCpp): Ditto.
3483         (M2Options_GetM2g): Ditto.
3484         (M2Options_SetM2g): Ditto.
3485         (M2Options_SetLowerCaseKeywords): Ditto.
3486         (M2Options_SetVerbose): Ditto.
3487         (M2Options_SetUnusedVariableChecking): Ditto.
3488         (M2Options_SetUnusedParameterChecking): Ditto.
3489         (M2Options_SetStrictTypeChecking): Ditto.
3490         (M2Options_SetWall): Ditto.
3491         (M2Options_SetSaveTemps): Ditto.
3492         (M2Options_GetSaveTemps): Ditto.
3493         (M2Options_SetScaffoldStatic): Ditto.
3494         (M2Options_SetScaffoldDynamic): Ditto.
3495         (M2Options_SetScaffoldMain): Ditto.
3496         (M2Options_SetGenModuleList): Ditto.
3497         (M2Options_SetShared): Ditto.
3498         * gm2-libs-ch/M2LINK.c: Ditto.
3499         * gm2-libs-ch/m2rts.h (M2RTS_RequestDependant): Replace
3500         const char * with const void *.
3501         (M2RTS_RegisterModule): Ditto.
3502         (M2RTS_ConstructModules): Ditto.
3503         * gm2-gcc/m2decl.def (DetermineSizeOfConstant): New parameter
3504         issueError.
3505         * gm2-gcc/m2decl.h (DetermineSizeOfConstant): New parameter
3506         issueError.
3508 2023-03-12  Gaius Mulley  <gaiusmod2@gmail.com>
3510         PR modula2/109089
3511         * gm2-compiler/M2GCCDeclare.mod (DeclareKnownType): Import.
3512         * gm2-gcc/gcc-consolidation.h (stdbool.h): Include.
3513         * gm2-gcc/init.h (defined): Change block start.
3514         * gm2-gcc/m2block.cc: Change FALSE to false, change TRUE to true.
3515         * gm2-gcc/m2block.h: Change int to bool.
3516         * gm2-gcc/m2builtins.cc: Ditto.
3517         * gm2-gcc/m2builtins.h: Ditto.
3518         * gm2-gcc/m2convert.cc: Change FALSE to false, TRUE to true and
3519         int to bool.
3520         * gm2-gcc/m2convert.h: Change int to bool.
3521         * gm2-gcc/m2decl.cc: Change int to bool.
3522         * gm2-gcc/m2decl.h: Change int to bool.
3523         * gm2-gcc/m2expr.cc: Change FALSE to false, TRUE to true and
3524         int to bool.
3525         * gm2-gcc/m2expr.h: Change int to bool.
3526         * gm2-gcc/m2statement.cc: Change FALSE to false, TRUE to true and
3527         int to bool.
3528         * gm2-gcc/m2statement.h: Change int to bool.
3529         * gm2-gcc/m2top.cc: Change int to bool.
3530         * gm2-gcc/m2top.h: Change int to bool.
3531         * gm2-gcc/m2tree.cc: Change int to bool.
3532         * gm2-gcc/m2tree.h: Change int to bool.
3533         * gm2-gcc/m2type.cc: Change int to bool.
3534         * gm2-gcc/m2type.h: Change int to bool.
3535         * gm2-lang.cc (convert_loc): Call convert_to_integer for BOOLEAN_TYPE.
3536         * gm2-libs/Builtins.def (isfinitef): Change return value from
3537         BOOLEAN to INTEGER.
3538         (isfinite): Ditto.
3539         (isfinitel): Ditto.
3540         * gm2-libs/Builtins.mod (isfinitef): Change return value from
3541         BOOLEAN to INTEGER.
3542         (isfinite): Ditto.
3543         (isfinitel): Ditto.
3544         * mc-boot/GASCII.cc: Rebuild.
3545         * mc-boot/GASCII.h: Rebuild.
3546         * mc-boot/GArgs.cc: Rebuild.
3547         * mc-boot/GArgs.h: Rebuild.
3548         * mc-boot/GAssertion.cc: Rebuild.
3549         * mc-boot/GAssertion.h: Rebuild.
3550         * mc-boot/GBreak.cc: Rebuild.
3551         * mc-boot/GBreak.h: Rebuild.
3552         * mc-boot/GCOROUTINES.h: Rebuild.
3553         * mc-boot/GCmdArgs.cc: Rebuild.
3554         * mc-boot/GCmdArgs.h: Rebuild.
3555         * mc-boot/GDebug.cc: Rebuild.
3556         * mc-boot/GDebug.h: Rebuild.
3557         * mc-boot/GDynamicStrings.cc: Rebuild.
3558         * mc-boot/GDynamicStrings.h: Rebuild.
3559         * mc-boot/GEnvironment.cc: Rebuild.
3560         * mc-boot/GEnvironment.h: Rebuild.
3561         * mc-boot/GFIO.cc: Rebuild.
3562         * mc-boot/GFIO.h: Rebuild.
3563         * mc-boot/GFormatStrings.cc: Rebuild.
3564         * mc-boot/GFormatStrings.h: Rebuild.
3565         * mc-boot/GFpuIO.cc: Rebuild.
3566         * mc-boot/GFpuIO.h: Rebuild.
3567         * mc-boot/GIO.cc: Rebuild.
3568         * mc-boot/GIO.h: Rebuild.
3569         * mc-boot/GIndexing.cc: Rebuild.
3570         * mc-boot/GIndexing.h: Rebuild.
3571         * mc-boot/GM2Dependent.cc: Rebuild.
3572         * mc-boot/GM2Dependent.h: Rebuild.
3573         * mc-boot/GM2EXCEPTION.cc: Rebuild.
3574         * mc-boot/GM2EXCEPTION.h: Rebuild.
3575         * mc-boot/GM2LINK.h: Rebuild.
3576         * mc-boot/GM2RTS.cc: Rebuild.
3577         * mc-boot/GM2RTS.h: Rebuild.
3578         * mc-boot/GMemUtils.cc: Rebuild.
3579         * mc-boot/GMemUtils.h: Rebuild.
3580         * mc-boot/GNumberIO.cc: Rebuild.
3581         * mc-boot/GNumberIO.h: Rebuild.
3582         * mc-boot/GPushBackInput.cc: Rebuild.
3583         * mc-boot/GPushBackInput.h: Rebuild.
3584         * mc-boot/GRTExceptions.cc: Rebuild.
3585         * mc-boot/GRTExceptions.h: Rebuild.
3586         * mc-boot/GRTco.h: Rebuild.
3587         * mc-boot/GRTentity.h: Rebuild.
3588         * mc-boot/GRTint.cc: Rebuild.
3589         * mc-boot/GRTint.h: Rebuild.
3590         * mc-boot/GSArgs.cc: Rebuild.
3591         * mc-boot/GSArgs.h: Rebuild.
3592         * mc-boot/GSFIO.cc: Rebuild.
3593         * mc-boot/GSFIO.h: Rebuild.
3594         * mc-boot/GSYSTEM.h: Rebuild.
3595         * mc-boot/GSelective.h: Rebuild.
3596         * mc-boot/GStdIO.cc: Rebuild.
3597         * mc-boot/GStdIO.h: Rebuild.
3598         * mc-boot/GStorage.cc: Rebuild.
3599         * mc-boot/GStorage.h: Rebuild.
3600         * mc-boot/GStrCase.cc: Rebuild.
3601         * mc-boot/GStrCase.h: Rebuild.
3602         * mc-boot/GStrIO.cc: Rebuild.
3603         * mc-boot/GStrIO.h: Rebuild.
3604         * mc-boot/GStrLib.cc: Rebuild.
3605         * mc-boot/GStrLib.h: Rebuild.
3606         * mc-boot/GStringConvert.cc: Rebuild.
3607         * mc-boot/GStringConvert.h: Rebuild.
3608         * mc-boot/GSysExceptions.h: Rebuild.
3609         * mc-boot/GSysStorage.cc: Rebuild.
3610         * mc-boot/GSysStorage.h: Rebuild.
3611         * mc-boot/GTimeString.cc: Rebuild.
3612         * mc-boot/GTimeString.h: Rebuild.
3613         * mc-boot/GUnixArgs.h: Rebuild.
3614         * mc-boot/Galists.cc: Rebuild.
3615         * mc-boot/Galists.h: Rebuild.
3616         * mc-boot/Gdecl.cc: Rebuild.
3617         * mc-boot/Gdecl.h: Rebuild.
3618         * mc-boot/Gdtoa.h: Rebuild.
3619         * mc-boot/Gerrno.h: Rebuild.
3620         * mc-boot/Gkeyc.cc: Rebuild.
3621         * mc-boot/Gkeyc.h: Rebuild.
3622         * mc-boot/Gldtoa.h: Rebuild.
3623         * mc-boot/Glibc.h: Rebuild.
3624         * mc-boot/Glibm.h: Rebuild.
3625         * mc-boot/Glists.cc: Rebuild.
3626         * mc-boot/Glists.h: Rebuild.
3627         * mc-boot/GmcComment.cc: Rebuild.
3628         * mc-boot/GmcComment.h: Rebuild.
3629         * mc-boot/GmcComp.cc: Rebuild.
3630         * mc-boot/GmcComp.h: Rebuild.
3631         * mc-boot/GmcDebug.cc: Rebuild.
3632         * mc-boot/GmcDebug.h: Rebuild.
3633         * mc-boot/GmcError.cc: Rebuild.
3634         * mc-boot/GmcError.h: Rebuild.
3635         * mc-boot/GmcFileName.cc: Rebuild.
3636         * mc-boot/GmcFileName.h: Rebuild.
3637         * mc-boot/GmcLexBuf.cc: Rebuild.
3638         * mc-boot/GmcLexBuf.h: Rebuild.
3639         * mc-boot/GmcMetaError.cc: Rebuild.
3640         * mc-boot/GmcMetaError.h: Rebuild.
3641         * mc-boot/GmcOptions.cc: Rebuild.
3642         * mc-boot/GmcOptions.h: Rebuild.
3643         * mc-boot/GmcPreprocess.cc: Rebuild.
3644         * mc-boot/GmcPreprocess.h: Rebuild.
3645         * mc-boot/GmcPretty.cc: Rebuild.
3646         * mc-boot/GmcPretty.h: Rebuild.
3647         * mc-boot/GmcPrintf.cc: Rebuild.
3648         * mc-boot/GmcPrintf.h: Rebuild.
3649         * mc-boot/GmcQuiet.cc: Rebuild.
3650         * mc-boot/GmcQuiet.h: Rebuild.
3651         * mc-boot/GmcReserved.cc: Rebuild.
3652         * mc-boot/GmcReserved.h: Rebuild.
3653         * mc-boot/GmcSearch.cc: Rebuild.
3654         * mc-boot/GmcSearch.h: Rebuild.
3655         * mc-boot/GmcStack.cc: Rebuild.
3656         * mc-boot/GmcStack.h: Rebuild.
3657         * mc-boot/GmcStream.cc: Rebuild.
3658         * mc-boot/GmcStream.h: Rebuild.
3659         * mc-boot/Gmcflex.h: Rebuild.
3660         * mc-boot/Gmcp1.cc: Rebuild.
3661         * mc-boot/Gmcp1.h: Rebuild.
3662         * mc-boot/Gmcp2.cc: Rebuild.
3663         * mc-boot/Gmcp2.h: Rebuild.
3664         * mc-boot/Gmcp3.cc: Rebuild.
3665         * mc-boot/Gmcp3.h: Rebuild.
3666         * mc-boot/Gmcp4.cc: Rebuild.
3667         * mc-boot/Gmcp4.h: Rebuild.
3668         * mc-boot/Gmcp5.cc: Rebuild.
3669         * mc-boot/Gmcp5.h: Rebuild.
3670         * mc-boot/GnameKey.cc: Rebuild.
3671         * mc-boot/GnameKey.h: Rebuild.
3672         * mc-boot/GsymbolKey.cc: Rebuild.
3673         * mc-boot/GsymbolKey.h: Rebuild.
3674         * mc-boot/Gtermios.h: Rebuild.
3675         * mc-boot/Gtop.cc: Rebuild.
3676         * mc-boot/Gvarargs.cc: Rebuild.
3677         * mc-boot/Gvarargs.h: Rebuild.
3678         * mc-boot/Gwlists.cc: Rebuild.
3679         * mc-boot/Gwlists.h: Rebuild.
3680         * mc-boot/Gwrapc.h: Rebuild.
3681         * mc/decl.mod (doBoolC): New procedure.
3682         (doBaseC): Call doBoolC.
3683         * mc/keyc.mod: Import useBool.
3684         (genBool): New procedure.
3685         (genDefs): Call genBool.
3686         * mc/mcOptions.def (useBool): New procedure.
3687         * mc/mcOptions.mod (useBool): New procedure.
3688         (useBoolType): New variable.
3689         (optionIs): Assign useBoolType to TRUE.
3691 2023-03-04  Gaius Mulley  <gaiusmod2@gmail.com>
3693         * mc-boot-ch/GBuiltins.cc: New file.
3694         * mc-boot-ch/Gdtoa.cc: New file.
3695         * mc-boot-ch/Gerrno.cc: New file.
3696         * mc-boot-ch/Gldtoa.cc: New file.
3697         * mc-boot-ch/Gm2rtsdummy.cc: New file.
3698         * mc-boot/GASCII.cc: New file.
3699         * mc-boot/GArgs.cc: New file.
3700         * mc-boot/GAssertion.cc: New file.
3701         * mc-boot/GBreak.cc: New file.
3702         * mc-boot/GCmdArgs.cc: New file.
3703         * mc-boot/GDebug.cc: New file.
3704         * mc-boot/GDynamicStrings.cc: New file.
3705         * mc-boot/GEnvironment.cc: New file.
3706         * mc-boot/GFIO.cc: New file.
3707         * mc-boot/GFormatStrings.cc: New file.
3708         * mc-boot/GFpuIO.cc: New file.
3709         * mc-boot/GIO.cc: New file.
3710         * mc-boot/GIndexing.cc: New file.
3711         * mc-boot/GM2Dependent.cc: New file.
3712         * mc-boot/GM2EXCEPTION.cc: New file.
3713         * mc-boot/GM2RTS.cc: New file.
3714         * mc-boot/GMemUtils.cc: New file.
3715         * mc-boot/GNumberIO.cc: New file.
3716         * mc-boot/GPushBackInput.cc: New file.
3717         * mc-boot/GRTExceptions.cc: New file.
3718         * mc-boot/GRTint.cc: New file.
3719         * mc-boot/GSArgs.cc: New file.
3720         * mc-boot/GSFIO.cc: New file.
3721         * mc-boot/GStdIO.cc: New file.
3722         * mc-boot/GStorage.cc: New file.
3723         * mc-boot/GStrCase.cc: New file.
3724         * mc-boot/GStrIO.cc: New file.
3725         * mc-boot/GStrLib.cc: New file.
3726         * mc-boot/GStringConvert.cc: New file.
3727         * mc-boot/GSysStorage.cc: New file.
3728         * mc-boot/GTimeString.cc: New file.
3729         * mc-boot/Galists.cc: New file.
3730         * mc-boot/Gdecl.cc: New file.
3731         * mc-boot/Gkeyc.cc: New file.
3732         * mc-boot/Glists.cc: New file.
3733         * mc-boot/GmcComment.cc: New file.
3734         * mc-boot/GmcComp.cc: New file.
3735         * mc-boot/GmcDebug.cc: New file.
3736         * mc-boot/GmcError.cc: New file.
3737         * mc-boot/GmcFileName.cc: New file.
3738         * mc-boot/GmcLexBuf.cc: New file.
3739         * mc-boot/GmcMetaError.cc: New file.
3740         * mc-boot/GmcOptions.cc: New file.
3741         * mc-boot/GmcPreprocess.cc: New file.
3742         * mc-boot/GmcPretty.cc: New file.
3743         * mc-boot/GmcPrintf.cc: New file.
3744         * mc-boot/GmcQuiet.cc: New file.
3745         * mc-boot/GmcReserved.cc: New file.
3746         * mc-boot/GmcSearch.cc: New file.
3747         * mc-boot/GmcStack.cc: New file.
3748         * mc-boot/GmcStream.cc: New file.
3749         * mc-boot/Gmcp1.cc: New file.
3750         * mc-boot/Gmcp2.cc: New file.
3751         * mc-boot/Gmcp3.cc: New file.
3752         * mc-boot/Gmcp4.cc: New file.
3753         * mc-boot/Gmcp5.cc: New file.
3754         * mc-boot/GnameKey.cc: New file.
3755         * mc-boot/GsymbolKey.cc: New file.
3756         * mc-boot/Gtop.cc: New file.
3757         * mc-boot/Gvarargs.cc: New file.
3758         * mc-boot/Gwlists.cc: New file.
3759         * pge-boot/GASCII.cc: New file.
3760         * pge-boot/GArgs.cc: New file.
3761         * pge-boot/GAssertion.cc: New file.
3762         * pge-boot/GBuiltins.cc: New file.
3763         * pge-boot/GDebug.cc: New file.
3764         * pge-boot/GDynamicStrings.cc: New file.
3765         * pge-boot/GFIO.cc: New file.
3766         * pge-boot/GIO.cc: New file.
3767         * pge-boot/GIndexing.cc: New file.
3768         * pge-boot/GLists.cc: New file.
3769         * pge-boot/GM2Dependent.cc: New file.
3770         * pge-boot/GM2EXCEPTION.cc: New file.
3771         * pge-boot/GM2LINK.cc: New file.
3772         * pge-boot/GM2RTS.cc: New file.
3773         * pge-boot/GNameKey.cc: New file.
3774         * pge-boot/GNumberIO.cc: New file.
3775         * pge-boot/GOutput.cc: New file.
3776         * pge-boot/GPushBackInput.cc: New file.
3777         * pge-boot/GRTExceptions.cc: New file.
3778         * pge-boot/GRTco.cc: New file.
3779         * pge-boot/GSFIO.cc: New file.
3780         * pge-boot/GSYSTEM.cc: New file.
3781         * pge-boot/GSelective.cc: New file.
3782         * pge-boot/GStdIO.cc: New file.
3783         * pge-boot/GStorage.cc: New file.
3784         * pge-boot/GStrCase.cc: New file.
3785         * pge-boot/GStrIO.cc: New file.
3786         * pge-boot/GStrLib.cc: New file.
3787         * pge-boot/GSymbolKey.cc: New file.
3788         * pge-boot/GSysExceptions.cc: New file.
3789         * pge-boot/GSysStorage.cc: New file.
3790         * pge-boot/Gabort.cc: New file.
3791         * pge-boot/Gbnflex.cc: New file.
3792         * pge-boot/Gcbuiltin.cc: New file.
3793         * pge-boot/Gdtoa.cc: New file.
3794         * pge-boot/Gerrno.cc: New file.
3795         * pge-boot/Gldtoa.cc: New file.
3796         * pge-boot/Glibc.cc: New file.
3797         * pge-boot/Glibm.cc: New file.
3798         * pge-boot/Gmcrts.cc: New file.
3799         * pge-boot/Gpge.cc: New file.
3800         * pge-boot/Gwrapc.cc: New file.
3801         * pge-boot/main.cc: New file.
3802         * pge-boot/network.cc: New file.
3804 2023-03-04  Gaius Mulley  <gaiusmod2@gmail.com>
3806         * Make-lang.in (MC-LIB-BOOT-C): Rename to MC-LIB-BOOT-CC.
3807         (MC-BOOT-C): Rename to MC-BOOT-CC.
3808         (BUILD-MC-BOOT-C): Rename to BUILD-MC-BOOT-CC.
3809         (BUILD-MC-BOOT-AUTO-C): Rename to BUILD-MC-BOOT-AUTO-CC.
3810         (m2/mc-boot/$(SRC_PREFIX)%.o): Change source file extension to .cc.
3811         (m2/mc-boot-ch/$(SRC_PREFIX)%.o): Ditto.
3812         * Make-maintainer.in (m2/gm2-ppg-boot/$(SRC_PREFIX)%.o): Change
3813         source file extension to .cc.
3814         (m2/gm2-ppg-boot/main.o): Ditto.
3815         (m2/gm2-ppg-boot/$(SRC_PREFIX)%.o): Ditto.
3816         to .cc.
3817         (m2/gm2-pg-boot/main.o): Ditto.
3818         (m2/gm2-pge-boot/$(SRC_PREFIX)ldtoa.o): Ditto.
3819         (m2/gm2-pge-boot/$(SRC_PREFIX)dtoa.o): Ditto.
3820         (m2/gm2-pge-boot/$(SRC_PREFIX)errno.o): Ditto.
3821         (m2/gm2-pge-boot/$(SRC_PREFIX)M2RTS.o): Ditto.
3822         (m2/gm2-pge-boot/$(SRC_PREFIX)%.o): Ditto.
3823         (m2/gm2-pge-boot/$(SRC_PREFIX)%.o): Ditto.
3824         (m2/gm2-pge-boot/$(SRC_PREFIX)pge.o): Ditto.
3825         (m2/gm2-pge-boot/main.o): Ditto.
3826         (mc-push): Ditto.
3827         (mc-clean): Ditto.
3828         (mc-stage2): Ditto.
3829         ((objdir)/m2/mc-boot-gen): Ditto.
3830         (m2/mc-boot-gen/$(SRC_PREFIX)decl.c): Ditto.
3831         (m2/mc-boot-gen/$(SRC_PREFIX)%.c): Ditto.
3832         * mc-boot-ch/GBuiltins.c: Correct comment and rename.
3833         * mc-boot-ch/Gdtoa.c: Correct comment and rename.
3834         * mc-boot-ch/Gldtoa.c: Correct comment and rename
3835         * mc-boot-ch/Gtermios.cc: Rename from Gtermios.c.
3836         * mc-boot-ch/Gerrno.c: Rename.
3837         * mc-boot-ch/GRTco.c: Removed.
3838         * mc-boot/GASCII.c: Rename to mc-boot/GASCII.cc.
3839         * mc-boot/GArgs.c: Rename to mc-boot/GArgs.cc.
3840         * mc-boot/GAssertion.c: Rename to mc-boot/GAssertion.cc.
3841         * mc-boot/GBreak.c: Rename to mc-boot/GBreak.cc.
3842         * mc-boot/GCmdArgs.c: Rename to mc-boot/GCmdArgs.cc.
3843         * mc-boot/GDebug.c: Rename to mc-boot/GDebug.cc.
3844         * mc-boot/GDynamicStrings.c: Rename to mc-boot/GDynamicStrings.cc.
3845         * mc-boot/GEnvironment.c: Rename to mc-boot/GEnvironment.cc.
3846         * mc-boot/GFIO.c: Rename to mc-boot/GFIO.cc.
3847         * mc-boot/GFormatStrings.c: Rename to mc-boot/GFormatStrings.cc.
3848         * mc-boot/GFpuIO.c: Rename to mc-boot/GFpuIO.cc.
3849         * mc-boot/GIO.c: Rename to mc-boot/GIO.cc.
3850         * mc-boot/GIndexing.c: Rename to mc-boot/GIndexing.cc.
3851         * mc-boot/GM2Dependent.c: Rename to mc-boot/GM2Dependent.cc.
3852         * mc-boot/GM2EXCEPTION.c: Rename to mc-boot/GM2EXCEPTION.cc.
3853         * mc-boot/GM2RTS.c: Rename to mc-boot/GM2RTS.cc.
3854         * mc-boot/GMemUtils.c: Rename to mc-boot/GMemUtils.cc.
3855         * mc-boot/GNumberIO.c: Rename to mc-boot/GNumberIO.cc.
3856         * mc-boot/GPushBackInput.c: Rename to mc-boot/GPushBackInput.cc.
3857         * mc-boot/GRTExceptions.c: Rename to mc-boot/GRTExceptions.cc.
3858         * mc-boot/GRTint.c: Rename to mc-boot/GRTint.cc.
3859         * mc-boot/GSArgs.c: Rename to mc-boot/GSArgs.cc.
3860         * mc-boot/GSFIO.c: Rename to mc-boot/GSFIO.cc.
3861         * mc-boot/GStdIO.c: Rename to mc-boot/GStdIO.cc.
3862         * mc-boot/GStorage.c: Rename to mc-boot/GStorage.cc.
3863         * mc-boot/GStrCase.c: Rename to mc-boot/GStrCase.cc.
3864         * mc-boot/GStrIO.c: Rename to mc-boot/GStrIO.cc.
3865         * mc-boot/GStrLib.c: Rename to mc-boot/GStrLib.cc.
3866         * mc-boot/GStringConvert.c: Rename to mc-boot/GStringConvert.cc.
3867         * mc-boot/GSysStorage.c: Rename to mc-boot/GSysStorage.cc.
3868         * mc-boot/GTimeString.c: Rename to mc-boot/GTimeString.cc.
3869         * mc-boot/Galists.c: Rename to mc-boot/Galists.cc.
3870         * mc-boot/Gdecl.c: Rename to mc-boot/Gdecl.cc.
3871         * mc-boot/Gkeyc.c: Rename to mc-boot/Gkeyc.cc.
3872         * mc-boot/Glists.c: Rename to mc-boot/Glists.cc.
3873         * mc-boot/GmcComment.c: Rename to mc-boot/GmcComment.cc.
3874         * mc-boot/GmcComp.c: Rename to mc-boot/GmcComp.cc.
3875         * mc-boot/GmcDebug.c: Rename to mc-boot/GmcDebug.cc.
3876         * mc-boot/GmcError.c: Rename to mc-boot/GmcError.cc.
3877         * mc-boot/GmcFileName.c: Rename to mc-boot/GmcFileName.cc.
3878         * mc-boot/GmcLexBuf.c: Rename to mc-boot/GmcLexBuf.cc.
3879         * mc-boot/GmcMetaError.c: Rename to mc-boot/GmcMetaError.cc.
3880         * mc-boot/GmcOptions.c: Rename to mc-boot/GmcOptions.cc.
3881         * mc-boot/GmcPreprocess.c: Rename to mc-boot/GmcPreprocess.cc.
3882         * mc-boot/GmcPretty.c: Rename to mc-boot/GmcPretty.cc.
3883         * mc-boot/GmcPrintf.c: Rename to mc-boot/GmcPrintf.cc.
3884         * mc-boot/GmcQuiet.c: Rename to mc-boot/GmcQuiet.cc.
3885         * mc-boot/GmcReserved.c: Rename to mc-boot/GmcReserved.cc.
3886         * mc-boot/GmcSearch.c: Rename to mc-boot/GmcSearch.cc.
3887         * mc-boot/GmcStack.c: Rename to mc-boot/GmcStack.cc.
3888         * mc-boot/GmcStream.c: Rename to mc-boot/GmcStream.cc.
3889         * mc-boot/Gmcp1.c: Rename to mc-boot/Gmcp1.cc.
3890         * mc-boot/Gmcp2.c: Rename to mc-boot/Gmcp2.cc.
3891         * mc-boot/Gmcp3.c: Rename to mc-boot/Gmcp3.cc.
3892         * mc-boot/Gmcp4.c: Rename to mc-boot/Gmcp4.cc.
3893         * mc-boot/Gmcp5.c: Rename to mc-boot/Gmcp5.cc.
3894         * mc-boot/GnameKey.c: Rename to mc-boot/GnameKey.cc.
3895         * mc-boot/GsymbolKey.c: Rename to mc-boot/GsymbolKey.cc.
3896         * mc-boot/Gtop.c: Rename to mc-boot/Gtop.cc.
3897         * mc-boot/Gvarargs.c: Rename to mc-boot/Gvarargs.cc.
3898         * mc-boot/Gwlists.c: Rename to mc-boot/Gwlists.cc.
3899         * pge-boot/GASCII.c: Rename to pge-boot/GASCII.cc.
3900         * pge-boot/GArgs.c: Rename to pge-boot/GArgs.cc.
3901         * pge-boot/GAssertion.c: Rename to pge-boot/GAssertion.cc.
3902         * pge-boot/GBuiltins.c: Rename to pge-boot/GBuiltins.cc.
3903         * pge-boot/GDebug.c: Rename to pge-boot/GDebug.cc.
3904         * pge-boot/GDynamicStrings.c: Rename to pge-boot/GDynamicStrings.cc.
3905         * pge-boot/GFIO.c: Rename to pge-boot/GFIO.cc.
3906         * pge-boot/GIO.c: Rename to pge-boot/GIO.cc.
3907         * pge-boot/GIndexing.c: Rename to pge-boot/GIndexing.cc.
3908         * pge-boot/GLists.c: Rename to pge-boot/GLists.cc.
3909         * pge-boot/GM2Dependent.c: Rename to pge-boot/GM2Dependent.cc.
3910         * pge-boot/GM2EXCEPTION.c: Rename to pge-boot/GM2EXCEPTION.cc.
3911         * pge-boot/GM2LINK.c: Rename to pge-boot/GM2LINK.cc.
3912         * pge-boot/GM2RTS.c: Rename to pge-boot/GM2RTS.cc.
3913         * pge-boot/GNameKey.c: Rename to pge-boot/GNameKey.cc.
3914         * pge-boot/GNumberIO.c: Rename to pge-boot/GNumberIO.cc.
3915         * pge-boot/GOutput.c: Rename to pge-boot/GOutput.cc.
3916         * pge-boot/GPushBackInput.c: Rename to pge-boot/GPushBackInput.cc.
3917         * pge-boot/GRTExceptions.c: Rename to pge-boot/GRTExceptions.cc.
3918         * pge-boot/GRTco.c: Rename to pge-boot/GRTco.cc.
3919         * pge-boot/GSFIO.c: Rename to pge-boot/GSFIO.cc.
3920         * pge-boot/GSYSTEM.c: Rename to pge-boot/GSYSTEM.cc.
3921         * pge-boot/GSelective.c: Rename to pge-boot/GSelective.cc.
3922         * pge-boot/GStdIO.c: Rename to pge-boot/GStdIO.cc.
3923         * pge-boot/GStorage.c: Rename to pge-boot/GStorage.cc.
3924         * pge-boot/GStrCase.c: Rename to pge-boot/GStrCase.cc.
3925         * pge-boot/GStrIO.c: Rename to pge-boot/GStrIO.cc.
3926         * pge-boot/GStrLib.c: Rename to pge-boot/GStrLib.cc.
3927         * pge-boot/GSymbolKey.c: Rename to pge-boot/GSymbolKey.cc.
3928         * pge-boot/GSysExceptions.c: Rename to pge-boot/GSysExceptions.cc.
3929         * pge-boot/GSysStorage.c: Rename to pge-boot/GSysStorage.cc.
3930         * pge-boot/Gabort.c: Rename to pge-boot/Gabort.cc.
3931         * pge-boot/Gbnflex.c: Rename to pge-boot/Gbnflex.cc.
3932         * pge-boot/Gcbuiltin.c: Rename to pge-boot/Gcbuiltin.cc.
3933         * pge-boot/Gdtoa.c: Rename to pge-boot/Gdtoa.cc.
3934         * pge-boot/Gerrno.c: Rename to pge-boot/Gerrno.cc.
3935         * pge-boot/Gldtoa.c: Rename to pge-boot/Gldtoa.cc.
3936         * pge-boot/Glibc.c: Rename to pge-boot/Glibc.cc.
3937         * pge-boot/Glibm.c: Rename to pge-boot/Glibm.cc.
3938         * pge-boot/Gmcrts.c: Rename to pge-boot/Gmcrts.cc.
3939         * pge-boot/Gpge.c: Rename to pge-boot/Gpge.cc.
3940         * pge-boot/Gwrapc.c: Rename to pge-boot/Gwrapc.cc.
3941         * pge-boot/README: Correct description.
3942         * pge-boot/main.c: Rename to pge-boot/main.cc.
3943         * pge-boot/network.c: Rename to pge-boot/network.cc.
3945 2023-02-28  Gaius Mulley  <gaiusmod2@gmail.com>
3947         PR modula2/108956
3948         * Make-lang.in (m2/gm2-libs-boot/M2RTS.o): New specific rule to
3949         add the --suppress-noreturn option.
3950         * Make-maintainer.in (m2/gm2-ppg-boot/$(SRC_PREFIX)M2RTS.o): New
3951         specific rule to add the --suppress-noreturn option.
3952         (m2/gm2-pg-boot/$(SRC_PREFIX)M2RTS.o): New
3953         specific rule to add the --suppress-noreturn option.
3954         (m2/gm2-pg-boot/$(SRC_PREFIX)%.o): Add missing $(srcdir).
3955         (m2/gm2-pge-boot/$(SRC_PREFIX)M2RTS.o): New
3956         specific rule to add the --suppress-noreturn option.
3957         (m2/gm2-pge-boot/$(SRC_PREFIX)%.o): Add missing $(srcdir).
3958         * gm2-libs-ch/UnixArgs.cc (LIBNAME): New define.
3959         (_M2_UnixArgs_ctor): Add LIBNAME parameter to RegisterModule.
3960         * gm2-libs-ch/dtoa.cc (LIBNAME): New define.
3961         (_M2_dtoa_ctor): Add LIBNAME parameter to RegisterModule.
3962         * gm2-libs-ch/ldtoa.cc (LIBNAME): New define.
3963         (_M2_ldtoa_ctor): Add LIBNAME parameter to RegisterModule.
3964         * pge-boot/m2rts.h (M2RTS_RegisterModule): Add libname
3965         parameter.
3966         * gm2-libs-ch/m2rts.h (M2RTS_RegisterModule): Add libname
3967         parameter.
3968         * mc-boot-ch/GUnixArgs.cc (_M2_UnixArgs_ctor): Remove.
3969         * pge-boot/GUnixArgs.cc (LIBNAME): New define.
3970         (_M2_UnixArgs_ctor): Add LIBNAME parameter to RegisterModule.
3971         * gm2-libs/RTint.def (AttachVector): Rename parameter.
3972         * mc-boot/GDynamicStrings.c: Rebuilt.
3973         * mc-boot/GFIO.c: Rebuilt.
3974         * mc-boot/GIndexing.c: Rebuilt.
3975         * mc-boot/GM2EXCEPTION.c: Rebuilt.
3976         * mc-boot/GPushBackInput.c: Rebuilt.
3977         * mc-boot/GRTExceptions.c: Rebuilt.
3978         * mc-boot/GRTint.c: Rebuilt.
3979         * mc-boot/GRTint.h: Rebuilt.
3980         * mc-boot/GStdIO.c: Rebuilt.
3981         * mc-boot/GStringConvert.c: Rebuilt.
3982         * mc-boot/GSysStorage.c: Rebuilt.
3983         * mc-boot/Gdecl.c: Rebuilt.
3984         * mc-boot/Gkeyc.c: Rebuilt.
3985         * mc-boot/GmcComment.c: Rebuilt.
3986         * mc-boot/GmcComp.c: Rebuilt.
3987         * mc-boot/GmcDebug.c: Rebuilt.
3988         * mc-boot/GmcMetaError.c: Rebuilt.
3989         * mc-boot/GmcOptions.c: Rebuilt.
3990         * mc-boot/GmcOptions.h: Rebuilt.
3991         * mc-boot/GmcStack.c: Rebuilt.
3992         * mc-boot/GnameKey.c: Rebuilt.
3993         * mc-boot/GsymbolKey.c: Rebuilt.
3994         * mc/decl.mod:: Rebuilt.
3995         * mc/mcOptions.def: Rebuilt.
3996         * mc/mcOptions.mod:: Rebuilt.
3997         * pge-boot/GDynamicStrings.c: Rebuilt.
3998         * pge-boot/GFIO.c: Rebuilt.
3999         * pge-boot/GIndexing.c: Rebuilt.
4000         * pge-boot/GM2EXCEPTION.c: Rebuilt.
4001         * pge-boot/GM2RTS.c: Rebuilt.
4002         * pge-boot/GNameKey.c: Rebuilt.
4003         * pge-boot/GPushBackInput.c: Rebuilt.
4004         * pge-boot/GRTExceptions.c: Rebuilt.
4005         * pge-boot/GStdIO.c: Rebuilt.
4006         * pge-boot/GSymbolKey.c: Rebuilt.
4007         * pge-boot/GSysStorage.c: Rebuilt.
4009 2023-02-25  Gaius Mulley  <gaiusmod2@gmail.com>
4011         PR modula2/108261
4012         * Make-lang.in (GM2-COMP-BOOT-DEFS): DynamicStringPath.def
4013         remove.  DynamicPath.def add.
4014         (GM2-COMP-BOOT-MODS): DynamicStringPath.mod remove.
4015         DynamicPath.mod add.
4016         * Make-maintainer.in (BUILD-BOOT-PPG-H): New dependency.
4017         (m2/gm2-ppg-boot/$(SRC_PREFIX)%.o): $(BUILD-BOOT-PPG-H) Add
4018         dependency.
4019         (PGE-DEF): New definition.
4020         (BUILD-BOOT-PG-H): New dependency.
4021         (m2/gm2-pg-boot/$(SRC_PREFIX)%.o): $(BUILD-BOOT-PG-H) Add
4022         dependency.
4023         (BUILD-BOOT-PGE-H): New dependency.
4024         (m2/gm2-pge-boot/$(SRC_PREFIX)%.o): $(BUILD-BOOT-PGE-H) Add
4025         dependency.
4026         (GM2PATH): Add pathname entries.
4027         (m2/boot-bin/mc-devel$(exeext)): Add m2/mc-boot-ch/Gm2rtsdummy.o
4028         dependency.
4029         (m2/boot-bin/mc-opt$(exeext)): Fix -I path.
4030         * gm2-compiler/DynamicStringPath.def: Renamed module to
4031         DynamicPath.
4032         (GetUserPath): Remove.
4033         (GetSystemPath): Remove.
4034         (SetUserPath): Remove.
4035         (SetSystemPath): Remove.
4036         (DumpPath): New procedure definition.
4037         * gm2-compiler/DynamicStringPath.mod: Renamed module to
4038         DynamicPath.
4039         (GetUserPath): Remove.
4040         (GetSystemPath): Remove.
4041         (SetUserPath): Remove.
4042         (SetSystemPath): Remove.
4043         (DumpPath): Remove Debugging conditional.
4044         * gm2-compiler/M2AsmUtil.mod: Import EqualArray, NulName and
4045         GetLibName.
4046         (Debugging): New declaration.
4047         (GetFullSymName): Re-implemented to prefix (mange) libname
4048         to any extern variable/procedure which is IsExportQualified.
4049         * gm2-compiler/M2Comp.mod (qprintLibName): New procedure.
4050         * gm2-compiler/M2Graph.mod (resolveImports): Add libname.
4051         * gm2-compiler/M2Options.def (SetM2Prefix): New procedure.
4052         (GetM2Prefix): New procedure function.
4053         (SetM2PathName): New procedure.
4054         (GetM2PathName): New procedure function.
4055         * gm2-compiler/M2Options.mod: (SetM2Prefix): New procedure implemented.
4056         (GetM2Prefix): New procedure function implemented.
4057         (SetM2PathName): New procedure implemented.
4058         (GetM2PathName): New procedure function implemented.
4059         (RuntimeModuleOverride): Set to DefaultRuntimeModuleOverride.
4060         * gm2-compiler/M2Quads.mod: Import GetLibName.
4061         (SafeRequestSym) Pass result of GetLibName to RequestDependant.
4062         (callRequestDependant): Add libname as a parameter.
4063         (BuildM2InitFunction): Add libname as a parameter.
4064         (BuildM2FiniFunction): Add libname as a parameter.
4065         (BuildM2CtorFunction): Add libname as a parameter.
4066         * gm2-compiler/M2Scaffold.mod (LookupModuleSym): Set LibName
4067         if a definition source was found.
4068         * gm2-compiler/M2Search.def (FindSourceFile): Add named library parameter.
4069         (FindSourceDefFile): Add named library parameter.
4070         (FindSourceModFile): Add named library parameter.
4071         * gm2-compiler/M2Search.mod (FindSourceFile): Reimplement.
4072         (FindSourceDefFile): Add named library parameter.
4073         (FindSourceModFile): Add named library parameter.
4074         * gm2-compiler/SymbolTable.def (MakeProcedureCtorExtern): Add
4075         libname parameter.
4076         (PutLibName): New procedure.
4077         (GetLibName): New procedure function.
4078         * gm2-compiler/SymbolTable.mod (MakeProcedureCtorExtern): Add
4079         libname parameter.
4080         (GenName): Add libname parameter.
4081         (InitCtorFields): Add moduleSym as a parameter.
4082         (PutCtorExtern): Add libname parameter to GenName.
4083         * gm2-gcc/init.cc (_M2_DynamicStringPath_init): Rename function...
4084         (_M2_DynamicPath_init): ...to this.
4085         (_M2_PathName_init): Added.
4086         * gm2-gcc/m2decl.cc (m2decl_DeclareM2linkStaticInitialization):
4087         Add m2pim as the manged component of the exported symbol.
4088         (m2decl_DeclareM2linkForcedModuleInitOrder): Add m2pim mangle prefix.
4089         * gm2-gcc/m2options.h (M2Options_SetM2Prefix): New function.
4090         (M2Options_GetM2Prefix): New function.
4091         (M2Options_SetM2PathName): New function.
4092         (M2Options_GetM2PathName): New function.
4093         * gm2-lang.cc (push_back_Ipath): New function.
4094         (add_one_import_path): New function.
4095         (gm2_langhook_handle_option): Record -I component.  Call
4096         SetM2PathName when -fm2-pathname= is seen.  Record -fm2-pathnameI
4097         component.  Call SetM2Prefix when -fm2-prefix= is seen.
4098         (gm2_langhook_post_options): Iterative over pathname entries
4099         and call SetM2PathName, SetSearchPath as appropriate.
4100         * gm2-libs-iso/M2RTS.def (ConstructModules): Add libname parameter.
4101         (DeconstructModules): Add libname parameter.
4102         (RegisterModule): Add libname parameter.
4103         (RequestDependant): Add libname parameter.
4104         * gm2-libs-iso/M2RTS.mod (ConstructModules): Add libname parameter.
4105         (DeconstructModules): Add libname parameter.
4106         (RegisterModule): Add libname parameter.
4107         (RequestDependant): Add libname parameter.
4108         * gm2-libs-min/M2RTS.def (ConstructModules): Add libname parameter.
4109         (DeconstructModules): Add libname parameter.
4110         (RegisterModule): Add libname parameter.
4111         (RequestDependant): Add libname parameter.
4112         * gm2-libs-min/M2RTS.mod (ConstructModules): Add libname parameter.
4113         (DeconstructModules): Add libname parameter.
4114         (RegisterModule): Add libname parameter.
4115         (RequestDependant): Add libname parameter.
4116         * gm2-libs/M2Dependent.def (ConstructModules): Add libname parameter.
4117         (DeconstructModules): Add libname parameter.
4118         (RegisterModule): Add libname parameter.
4119         (RequestDependant): Add libname parameter.
4120         * gm2-libs/M2Dependent.mod (ConstructModules): Add libname parameter.
4121         (DeconstructModules): Add libname parameter.
4122         (RegisterModule): Add libname parameter.
4123         (RequestDependant): Add libname parameter.
4124         * gm2-libs/M2RTS.def (ConstructModules): Add libname parameter.
4125         (DeconstructModules): Add libname parameter.
4126         (RegisterModule): Add libname parameter.
4127         (RequestDependant): Add libname parameter.
4128         * gm2-libs/M2RTS.mod (ConstructModules): Add libname parameter.
4129         (DeconstructModules): Add libname parameter.
4130         (RegisterModule): Add libname parameter.
4131         (RequestDependant): Add libname parameter.
4132         * gm2-libs/RTint.mod (FindVector): Rename variables.
4133         (initInputVector): Rename variables.
4134         (initOutputVector): Rename variables.
4135         (InitTimeVector): Rename variables.
4136         (FindVectorNo): Rename variables.
4137         (FindPendingVector): Rename variables.
4138         (ReArmTimeVector): Rename variables.
4139         (GetTimeVector): Rename variables.
4140         (AttachVector): Rename variables.
4141         (AttachVector): Rename variables.
4142         (IncludeVector): Rename variables.
4143         (ExcludeVector): Rename variables.
4144         (AddFd): Rename variables.
4145         (AddFd): Rename variables.
4146         (DumpPendingQueue): Rename variables.
4147         (stop): Remove.
4148         (activatePending): Rename variables.
4149         (Listen): Rename variables.
4150         * gm2-libs/libc.def (snprintf): New function.
4151         * gm2-libs/sckt.def: Change all exported identifiers to be
4152         export qualified.
4153         * gm2spec.cc (push_back_Ipath): New function.
4154         (add_m2_I_path): New function.
4155         (lang_specific_driver): Skip -fm2-pathname= and remember pathname.
4156         Skip -I and record the path and current pathname.  Call add_m2_I_path.
4157         * lang-specs.h: Replace %{I*} with %{fm2-pathname*}.
4158         * lang.opt (-fm2-pathname=): New entry.
4159         (-fm2-pathname): New entry.
4160         (-fm2-prefix=): New entry.
4161         * mc-boot-ch/GUnixArgs.cc (_M2_UnixArgs_dep): New function.
4162         (_M2_UnixArgs_ctor::_M2_UnixArgs_ctor): New method.
4163         * mc-boot-ch/Glibc.c (libc_snprintf): New function.
4164         * mc-boot-ch/m2rts.h (M2RTS_RequestDependant): Changed prototype.
4165         (M2RTS_RegisterModule): Changed prototype.
4166         * mc-boot/GDynamicStrings.c: Rebuild.
4167         * mc-boot/GFIO.c: Rebuild.
4168         * mc-boot/GIndexing.c: Rebuild.
4169         * mc-boot/GM2Dependent.c: Rebuild.
4170         * mc-boot/GM2Dependent.h: Rebuild.
4171         * mc-boot/GM2EXCEPTION.c: Rebuild.
4172         * mc-boot/GM2RTS.c: Rebuild.
4173         * mc-boot/GM2RTS.h: Rebuild.
4174         * mc-boot/GPushBackInput.c: Rebuild.
4175         * mc-boot/GRTExceptions.c: Rebuild.
4176         * mc-boot/GRTint.c: Rebuild.
4177         * mc-boot/GStdIO.c: Rebuild.
4178         * mc-boot/GStringConvert.c: Rebuild.
4179         * mc-boot/GSysStorage.c: Rebuild.
4180         * mc-boot/Gdecl.c: Rebuild.
4181         * mc-boot/Gkeyc.c: Rebuild.
4182         * mc-boot/Glibc.h: Rebuild.
4183         * mc-boot/GmcComment.c: Rebuild.
4184         * mc-boot/GmcComp.c: Rebuild.
4185         * mc-boot/GmcDebug.c: Rebuild.
4186         * mc-boot/GmcMetaError.c: Rebuild.
4187         * mc-boot/GmcStack.c: Rebuild.
4188         * mc-boot/GnameKey.c: Rebuild.
4189         * mc-boot/GsymbolKey.c: Rebuild.
4190         * pge-boot/GASCII.c: Rebuild.
4191         * pge-boot/GArgs.c: Rebuild.
4192         * pge-boot/GAssertion.c: Rebuild.
4193         * pge-boot/GDebug.c: Rebuild.
4194         * pge-boot/GDynamicStrings.c: Rebuild.
4195         * pge-boot/GFIO.c: Rebuild.
4196         * pge-boot/GIO.c: Rebuild.
4197         * pge-boot/GIndexing.c: Rebuild.
4198         * pge-boot/GLists.c: Rebuild.
4199         * pge-boot/GM2Dependent.c: Rebuild.
4200         * pge-boot/GM2Dependent.h: Rebuild.
4201         * pge-boot/GM2EXCEPTION.c: Rebuild.
4202         * pge-boot/GM2RTS.c: Rebuild.
4203         * pge-boot/GM2RTS.h: Rebuild.
4204         * pge-boot/GNameKey.c: Rebuild.
4205         * pge-boot/GNumberIO.c: Rebuild.
4206         * pge-boot/GOutput.c: Rebuild.
4207         * pge-boot/GPushBackInput.c: Rebuild.
4208         * pge-boot/GRTExceptions.c: Rebuild.
4209         * pge-boot/GSFIO.c: Rebuild.
4210         * pge-boot/GStdIO.c: Rebuild.
4211         * pge-boot/GStorage.c: Rebuild.
4212         * pge-boot/GStrCase.c: Rebuild.
4213         * pge-boot/GStrIO.c: Rebuild.
4214         * pge-boot/GStrLib.c: Rebuild.
4215         * pge-boot/GSymbolKey.c: Rebuild.
4216         * pge-boot/GSysExceptions.c (_M2_SysExceptions_finish): Rename this...
4217         (_M2_SysExceptions_fini): ... to this.
4218         * pge-boot/GSysStorage.c: Rebuild.
4219         (_M2_SysStorage_finish): Rename this...
4220         (_M2_SysStorage_fini): ... to this.
4221         * pge-boot/GUnixArgs.cc: New file.
4222         * pge-boot/Gbnflex.c (_M2_bnflex_finish): Rename this...
4223         (_M2_bnflex_fini): ... to this.
4224         * pge-boot/Gerrno.c (_M2_errno_finish): Rename this...
4225         (_M2_errno_fini): ... to this.
4226         * pge-boot/Glibc.c (libc_snprintf): New function.
4227         * pge-boot/Glibc.h (libc_snprintf): New prototype.
4228         * pge-boot/Gpge.c (_M2_pge_finish): Rename this...
4229         (_M2_pge_fini): ... to this.
4230         * pge-boot/Gtermios.cc (_M2_termios_finish): Rename this...
4231         (_M2_termios_fini): ... to this.
4232         * pge-boot/main.c (_M2_RTExceptions_finish): Rename this...
4233         (_M2_RTExceptions_fini): ... to this.
4234         (_M2_M2EXCEPTION_finish): Rename this...
4235         (_M2_M2EXCEPTION_fini): ... to this.
4236         (_M2_M2RTS_finish): Rename this...
4237         (_M2_M2RTS_fini): ... to this.
4238         (_M2_SysExceptions_finish): Rename this...
4239         (_M2_SysExceptions_fini): ... to this.
4240         (_M2_StrLib_finish): Rename this...
4241         (_M2_StrLib_fini): ... to this.
4242         (_M2_errno_finish): Rename this...
4243         (_M2_errno_fini): ... to this.
4244         (_M2_termios_finish): Rename this...
4245         (_M2_termios_fini): ... to this.
4246         (_M2_IO_finish): Rename this...
4247         (_M2_IO_fini): ... to this.
4248         (_M2_StdIO_finish): Rename this...
4249         (_M2_StdIO_fini): ... to this.
4250         (_M2_Debug_finish): Rename this...
4251         (_M2_Debug_fini): ... to this.
4252         (_M2_SysStorage_finish): Rename this...
4253         (_M2_SysStorage_fini): ... to this.
4254         (_M2_Storage_finish): Rename this...
4255         (_M2_Storage_fini): ... to this.
4256         (_M2_StrIO_finish): Rename this...
4257         (_M2_StrIO_fini): ... to this.
4258         (_M2_DynamicStrings_finish): Rename this...
4259         (_M2_DynamicStrings_fini): ... to this.
4260         (_M2_Assertion_finish): Rename this...
4261         (_M2_Assertion_fini): ... to this.
4262         (_M2_Indexing_finish): Rename this...
4263         (_M2_Indexing_fini): ... to this.
4264         (_M2_NameKey_finish): Rename this...
4265         (_M2_NameKey_fini): ... to this.
4266         (_M2_NumberIO_finish): Rename this...
4267         (_M2_NumberIO_fini): ... to this.
4268         (_M2_PushBackInput_finish): Rename this...
4269         (_M2_PushBackInput_fini): ... to this.
4270         (_M2_SymbolKey_finish): Rename this...
4271         (_M2_SymbolKey_fini): ... to this.
4272         (_M2_UnixArgs_finish): Rename this...
4273         (_M2_UnixArgs_fini): ... to this.
4274         (_M2_FIO_finish): Rename this...
4275         (_M2_FIO_fini): ... to this.
4276         (_M2_SFIO_finish): Rename this...
4277         (_M2_SFIO_fini): ... to this.
4278         (_M2_StrCase_finish): Rename this...
4279         (_M2_StrCase_fini): ... to this.
4280         (_M2_bnflex_finish): Rename this...
4281         (_M2_bnflex_fini): ... to this.
4282         (_M2_Lists_finish): Rename this...
4283         (_M2_Lists_fini): ... to this.
4284         (_M2_Args_finish): Rename this...
4285         (_M2_Args_fini): ... to this.
4286         (_M2_Output_finish): Rename this...
4287         (_M2_Output_fini): ... to this.
4288         (_M2_pge_finish): Rename this...
4289         (_M2_pge_fini): ... to this.
4290         * plugin/m2rte.cc (m2_runtime_error_calls): Change all runtime
4291         procedure names to their name mangled counterparts.
4292         * gm2-libs-iso/wrapsock.c: Removed.
4293         * gm2-libs-iso/wraptime.c: Removed.
4294         * mc-boot/Gpth.h: Removed.
4295         * gm2-compiler/PathName.def: New file.
4296         * gm2-compiler/PathName.mod: New file.
4297         * gm2-compiler/DynamicPath.def: New file.
4298         * gm2-compiler/DynamicPath.mod: New file.
4300 2023-02-06  Gaius Mulley  <gaiusmod2@gmail.com>
4302         PR modula2/108135
4303         * gm2-compiler/M2Search.mod (DSdbEnter): Comment out.
4304         (DSdbExit): Comment out.
4306 2023-02-06  Co-Authored by: Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
4308         PR modula2/107234
4309         * m2pp.cc (m2pp_integer_cst): Use
4310         HOST_WIDE_INT_PRINT_UNSIGNED as the format specifier.
4312 2023-02-06  Gaius Mulley  <gaiusmod2@gmail.com>
4314         * gm2-compiler/M2Preprocess.mod (BaseName): Comment out.
4315         * gm2-lang.cc (opt): Remove.
4316         * gm2spec.cc (add_include): Remove.
4317         (full_libraries): Remove.
4318         (concat_option): Remove.
4320 2023-02-03  Gaius Mulley  <gaiusmod2@gmail.com>
4322         * Make-lang.in (TEXISRC): Remove m2/images/gnu.eps.
4323         (RSTSRC): Remove m2/images/gnu.eps.
4324         (doc/m2.dvi): Add $(objdir)/m2/images/gnu.eps.
4325         (doc/m2.pdf): Add $(objdir)/m2/images/gnu.eps.
4326         (M2_PDFFILES): New definition.
4327         (m2.install-pdf): New rule.
4328         (m2.pod): Add $(objdir)/m2/images/gnu.eps.
4329         (m2.info): Add $(objdir)/m2/images/gnu.eps.
4330         (m2.html): New rule.
4331         (m2/gpl_v3_without_node.texi): New rule.
4332         (plugin/m2rte$(soext)): Simplify mkinstalldirs.
4333         (cc1gm2$(exeext)): Ditto.
4334         (m2/stage1/cc1gm2$(exeext)): Ditto.
4335         (m2/gm2-gcc/%.o): Ditto.
4336         (m2/gm2-gcc/rtegraph.o): Ditto.
4337         (m2/gm2-gcc/$(SRC_PREFIX)%.h): Ditto.
4338         (m2/mc-boot/$(SRC_PREFIX)%.o):Ditto.
4339         (m2/mc-boot-ch/$(SRC_PREFIX)%.o): Ditto.
4340         (m2/mc-boot/main.o): Ditto.
4341         (m2/gm2-libs-boot/%.o): Ditto.
4342         (m2/gm2-libs-boot/$(SRC_PREFIX)%.h): Ditto.
4343         (m2/gm2-libs-boot/RTcodummy.o): Ditto.
4344         (m2/gm2-libs-boot/wrapc.o): Ditto.
4345         (m2/gm2-libs-boot/M2LINK.o): Ditto.
4346         (m2/gm2-libs-boot/UnixArgs.o): Ditto.
4347         (m2/gm2-libs-boot/choosetemp.o): Ditto.
4348         (m2/gm2-libs-boot/errno.o): Ditto.
4349         (m2/gm2-libs-boot/dtoa.o): Ditto.
4350         (m2/gm2-libs-boot/ldtoa.o): Ditto.
4351         (m2/gm2-libs-boot/termios.o): Ditto.
4352         (m2/gm2-libs-boot/SysExceptions.o): Ditto.
4353         (m2/gm2-libs-boot/SysStorage.o): Ditto.
4354         (m2/gm2-compiler-boot/M2GCCDeclare.o): Ditto.
4355         (m2/gm2-compiler-boot/M2Error.o): Ditto.
4356         (m2/gm2-compiler-boot/%.o): Ditto.
4357         (m2/gm2-compiler-boot/$(SRC_PREFIX)%.h): Ditto.
4358         (m2/gm2-compiler-boot/m2flex.o): Ditto.
4359         (m2/gm2-compiler/m2flex.c): Ditto.
4360         (m2/gm2-libiberty/$(SRC_PREFIX)%.h): Ditto.
4361         (m2/gm2-compiler/%.o): Ditto.
4362         (m2/gm2-compiler/m2flex.o): Ditto.
4363         (m2/gm2-compiler/%.o): Ditto.
4364         (m2/gm2-libs-iso/%.o): Ditto.
4365         (m2/gm2-libs/gm2-libs-host.h): Ditto.
4366         ($(objdir)/m2/gm2-libs-min/SYSTEM.def): Ditto.
4367         ($(objdir)/m2/gm2-libs/SYSTEM.def): Ditto.
4368         ($(objdir)/m2/gm2-libs-iso/SYSTEM.def): Ditto.
4369         ($(objdir)/m2/gm2-libs-coroutines/SYSTEM.def): Ditto.
4370         (m2/gm2-compiler/gm2.a): Ditto.
4371         (m2/gm2-libs-boot/libgm2.a): Ditto.
4372         (m2/gm2-compiler-boot/gm2.a): Ditto.
4373         (m2/boot-bin/mklink$(exeext)): Ditto.
4374         (m2/gm2-compiler-boot/$(SRC_PREFIX)%.h): Ditto.
4375         (m2/gm2-compiler/%.mod): Ditto.
4376         (m2/gm2-compiler-boot/%.mod): Ditto.
4377         (m2/pge-boot/%.o): Ditto.
4379 2023-02-01  Gaius Mulley  <gaiusmod2@gmail.com>
4381         * Make-lang.in (GM2_FLAGS): Add -fno-return -Wreturn-type.
4382         (GM2_ISO_FLAGS): Add -fno-return -Wreturn-type.
4383         * Make-maintainer.in (GM2PATH): Split into separate -I components.
4384         (MC-LIB-DEFS): Add RTentity.def.
4385         (m2/boot-bin/mc-devel$(exeext)): Changed -I$(GM2PATH) to
4386         $(GM2PATH).
4387         (m2/boot-bin/mc-opt$(exeext)): Separate -I paths.
4388         (m2/mc/decl.o): Separate -I paths.
4389         (gm2-bootstrap): Separate -I paths.
4390         (m2/mc-boot-gen/$(SRC_PREFIX)%.h): Separate -I paths.
4391         (m2/mc-boot-gen/$(SRC_PREFIX)decl.c): Separate -I paths.
4392         (m2/mc-boot-gen/$(SRC_PREFIX)%.c): Separate -I paths.
4393         (gm2.verifyparanoid): Separate -I paths.
4394         (gm2.verifystage12): Separate -I paths.
4395         * gm2-compiler/M2ALU.mod (GetConstructorElement): Add default
4396         Return NulSym.  Remove return from the error case.
4397         * gm2-compiler/M2Base.mod (ComplexToScalar): Return RType
4398         from the error case.
4399         (MixMetaTypes):  Return MakeError as a default.
4400         * gm2-compiler/M2GCCDeclare.mod (GetTypeMin): Return NulSym
4401         from the error case.
4402         (GetTypeMax): Return NulSym from the error case.
4403         * gm2-compiler/M2GenGCC.mod (IsExportedGcc): Replace Assert
4404         by InternalError.
4405         * gm2-compiler/M2Quads.mod (GetItemPointedTo): Add InternalError.
4406         (GetTypeMin): Add InternalError.
4407         (GetTypeMax): Add InternalError.
4408         * gm2-compiler/M2System.mod (InitSystem): Call
4409         PutProcedureNoReturn on Throw.
4410         * gm2-gcc/m2except.cc (m2except_InitExceptions): fn_throw_tree
4411         declare as noreturn.  fn_rethrow_tree declare as noreturn.
4412         * gm2-libs-coroutines/Debug.def (Halt): Add noreturn attribute.
4413         * gm2-libs-coroutines/SYSTEM.def (THROW): Add noreturn attribute.
4414         * gm2-libs-iso/ClientSocket.mod (dorbytes): Add return FALSE.
4415         * gm2-libs-iso/EXCEPTIONS.def (RAISE): Add noreturn attribute.
4416         * gm2-libs-iso/IOLink.def (RAISEdevException): Add noreturn attribute.
4417         * gm2-libs-iso/M2RTS.def (HALT): Add noreturn attribute.
4418         (Halt): Ditto.
4419         (HaltC): Ditto.
4420         (ErrorMessage): Ditto.
4421         (AssignmentException): Ditto.
4422         (ReturnException): Ditto.
4423         (IncException): Ditto.
4424         (DecException): Ditto.
4425         (InclException): Ditto.
4426         (ExclException): Ditto.
4427         (ShiftException): Ditto.
4428         (RotateException): Ditto.
4429         (StaticArraySubscriptException): Ditto.
4430         (DynamicArraySubscriptException): Ditto.
4431         (ForLoopBeginException): Ditto.
4432         (ForLoopToException): Ditto.
4433         (ForLoopEndException): Ditto.
4434         (PointerNilException): Ditto.
4435         (NoReturnException): Ditto.
4436         (CaseException): Ditto.
4437         (WholeNonPosDivException): Ditto.
4438         (WholeNonPosModException): Ditto.
4439         (WholeZeroDivException): Ditto.
4440         (WholeZeroRemException): Ditto.
4441         (WholeValueException): Ditto.
4442         (RealValueException): Ditto.
4443         (ParameterException): Ditto.
4444         (NoException): Ditto.
4445         * gm2-libs-iso/SYSTEM.def (THROW): Ditto.
4446         * gm2-libs-iso/TermFile.mod (dorbytes): Add default return FALSE.
4447         * gm2-libs-min/M2RTS.def: Add noreturn attribute.
4448         * gm2-libs/FIO.mod (BufferedRead): Return -1.
4449         (getFileName): Return NIL.
4450         (getFileNameLength): Return 0.
4451         * gm2-libs/M2RTS.def (HaltC): Add noreturn attribute.
4452         (AssignmentException): Ditto.
4453         (ReturnException): Ditto.
4454         (IncException): Ditto.
4455         (DecException): Ditto.
4456         (InclException): Ditto.
4457         (ExclException): Ditto.
4458         (ShiftException): Ditto.
4459         (RotateException): Ditto.
4460         (StaticArraySubscriptException): Ditto.
4461         (DynamicArraySubscriptException): Ditto.
4462         (ForLoopBeginException): Ditto.
4463         (ForLoopToException): Ditto.
4464         (ForLoopEndException): Ditto.
4465         (PointerNilException): Ditto.
4466         (NoReturnException): Ditto.
4467         (CaseException): Ditto.
4468         (WholeNonPosDivException): Ditto.
4469         (WholeNonPosModException): Ditto.
4470         (WholeZeroDivException): Ditto.
4471         (WholeZeroRemException): Ditto.
4472         (WholeValueException): Ditto.
4473         (RealValueException): Ditto.
4474         (ParameterException): Ditto.
4475         (NoException): Ditto.
4476         * gm2-libs/RTExceptions.def (Raise): Ditto.
4477         * gm2-libs/RTExceptions.mod (InvokeHandler): Ditto.
4478         * gm2-libs/SYSTEM.def (THROW): Ditto.
4479         * m2.flex (_M2_m2flex_fini): Remamed to...
4480         (_M2_m2flex_finish): ...here.
4481         * mc-boot-ch/GBuiltins.c (_M2_Builtins_finish): Remamed to...
4482         (_M2_Builtins_fini): ...this.
4483         * mc-boot-ch/GRTco.c (_M2_RTco_finish): Remamed to...
4484         (_M2_RTco_fini): ...this.
4485         * mc-boot-ch/GSYSTEM.c (_M2_SYSTEM_finish): Remamed to...
4486         (_M2_SYSTEM_fini): ...this.
4487         * mc-boot-ch/GSelective.c (_M2_Selective_finish): Remamed to...
4488         (_M2_Selective_fini): ...this.
4489         * mc-boot-ch/GSysExceptions.c (_M2_SysExceptions_init): Add
4490         parameters.
4491         (_M2_SysExceptions_finish): Remamed to...
4492         (_M2_SysExceptions_fini): ...this.
4493         * mc-boot-ch/GUnixArgs.cc (_M2_UnixArgs_finish): Remamed to...
4494         (_M2_UnixArgs_fini): ...this.
4495         (_M2_UnixArgs_ctor::_M2_UnixArgs_ctor): Change parameter
4496         to _M2_UnixArgs_fini.
4497         * mc-boot-ch/Gdtoa.c (_M2_dtoa_finish): Remamed to...
4498         (_M2_dtoa_fini): ...this.
4499         * mc-boot-ch/Gerrno.c (_M2_errno_finish): Remamed to...
4500         (_M2_errno_fini): ...this.
4501         * mc-boot-ch/Gldtoa.c (_M2_ldtoa_finish): Remamed to...
4502         (_M2_ldtoa_fini): ...this.
4503         * mc-boot-ch/Gtermios.cc (_M2_termios_init): Add parameters.
4504         (_M2_termios_finish): Remamed to...
4505         (_M2_termios_fini): ...this.
4506         * mc-boot-ch/Gwrapc.c (_M2_wrapc_init): Add parameters.
4507         (_M2_wrapc_finish): Remamed to...
4508         (_M2_wrapc_fini): ...this.
4509         * mc-boot/GASCII.c: Rebuild.
4510         * mc-boot/GArgs.c: Rebuild.
4511         * mc-boot/GAssertion.c: Rebuild.
4512         * mc-boot/GBreak.c: Rebuild.
4513         * mc-boot/GCmdArgs.c: Rebuild.
4514         * mc-boot/GDebug.c: Rebuild.
4515         * mc-boot/GDynamicStrings.c: Rebuild.
4516         * mc-boot/GEnvironment.c: Rebuild.
4517         * mc-boot/GFIO.c: Rebuild.
4518         * mc-boot/GFormatStrings.c: Rebuild.
4519         * mc-boot/GFpuIO.c: Rebuild.
4520         * mc-boot/GIO.c: Rebuild.
4521         * mc-boot/GIndexing.c: Rebuild.
4522         * mc-boot/GM2Dependent.c: Rebuild.
4523         * mc-boot/GM2EXCEPTION.c: Rebuild.
4524         * mc-boot/GM2RTS.c: Rebuild.
4525         * mc-boot/GM2RTS.h: Rebuild.
4526         * mc-boot/GMemUtils.c: Rebuild.
4527         * mc-boot/GNumberIO.c: Rebuild.
4528         * mc-boot/GPushBackInput.c: Rebuild.
4529         * mc-boot/GRTExceptions.c: Rebuild.
4530         * mc-boot/GRTExceptions.h: Rebuild.
4531         * mc-boot/GRTco.h: Rebuild.
4532         * mc-boot/GRTint.c: Rebuild.
4533         * mc-boot/GSArgs.c: Rebuild.
4534         * mc-boot/GSFIO.c: Rebuild.
4535         * mc-boot/GStdIO.c: Rebuild.
4536         * mc-boot/GStorage.c: Rebuild.
4537         * mc-boot/GStrCase.c: Rebuild.
4538         * mc-boot/GStrIO.c: Rebuild.
4539         * mc-boot/GStrLib.c: Rebuild.
4540         * mc-boot/GStringConvert.c: Rebuild.
4541         * mc-boot/GSysStorage.c: Rebuild.
4542         * mc-boot/GTimeString.c: Rebuild.
4543         * mc-boot/Galists.c: Rebuild.
4544         * mc-boot/Gdecl.c: Rebuild.
4545         * mc-boot/Gkeyc.c: Rebuild.
4546         * mc-boot/Glists.c: Rebuild.
4547         * mc-boot/GmcComment.c: Rebuild.
4548         * mc-boot/GmcComp.c: Rebuild.
4549         * mc-boot/GmcDebug.c: Rebuild.
4550         * mc-boot/GmcError.c: Rebuild.
4551         * mc-boot/GmcFileName.c: Rebuild.
4552         * mc-boot/GmcLexBuf.c: Rebuild.
4553         * mc-boot/GmcMetaError.c: Rebuild.
4554         * mc-boot/GmcOptions.c: Rebuild.
4555         * mc-boot/GmcPreprocess.c: Rebuild.
4556         * mc-boot/GmcPretty.c: Rebuild.
4557         * mc-boot/GmcPrintf.c: Rebuild.
4558         * mc-boot/GmcQuiet.c: Rebuild.
4559         * mc-boot/GmcReserved.c: Rebuild.
4560         * mc-boot/GmcSearch.c: Rebuild.
4561         * mc-boot/GmcStack.c: Rebuild.
4562         * mc-boot/GmcStream.c: Rebuild.
4563         * mc-boot/Gmcp1.c: Rebuild.
4564         * mc-boot/Gmcp2.c: Rebuild.
4565         * mc-boot/Gmcp3.c: Rebuild.
4566         * mc-boot/Gmcp4.c: Rebuild.
4567         * mc-boot/Gmcp5.c: Rebuild.
4568         * mc-boot/GnameKey.c: Rebuild.
4569         * mc-boot/GsymbolKey.c: Rebuild.
4570         * mc-boot/Gtop.c: Rebuild.
4571         * mc-boot/Gvarargs.c: Rebuild.
4572         * mc-boot/Gwlists.c: Rebuild.
4573         * mc-boot/GRTentity.h: New file.
4574         * mc/decl.mod (scaffoldStatic): Change _finish to _fini.
4575         * mc/mc.flex (_M2_mcflex_fini): New function.
4576         (_M2_mcflex_finish): Remove function.
4577         * tools-src/mklink.c (GenerateFinishCalls): Change
4578         _finish to _fini.
4579         (GeneratePrototypes): Change _finish to _fini.
4581 2023-01-31  Gaius Mulley  <gaiusmod2@gmail.com>
4583         * Make-lang.in (gm2-libs.texi-check): Rename
4584         m2/gm2-libs-pim to m2/gm2-libs-log.
4585         * gm2-libs-pim/BitBlockOps.def: Moved to...
4586         * gm2-libs-log/BitBlockOps.def: ...here.
4587         * gm2-libs-pim/BitBlockOps.mod: Moved to...
4588         * gm2-libs-log/BitBlockOps.mod: ...here.
4589         * gm2-libs-pim/BitByteOps.def: Moved to...
4590         * gm2-libs-log/BitByteOps.def: ...here.
4591         * gm2-libs-pim/BitByteOps.mod: Moved to...
4592         * gm2-libs-log/BitByteOps.mod: ...here.
4593         * gm2-libs-pim/BitWordOps.def: Moved to...
4594         * gm2-libs-log/BitWordOps.def: ...here.
4595         * gm2-libs-pim/BitWordOps.mod: Moved to...
4596         * gm2-libs-log/BitWordOps.mod: ...here.
4597         * gm2-libs-pim/BlockOps.def: Moved to...
4598         * gm2-libs-log/BlockOps.def: ...here.
4599         * gm2-libs-pim/BlockOps.mod: Moved to...
4600         * gm2-libs-log/BlockOps.mod: ...here.
4601         * gm2-libs-pim/Break.c: Moved to...
4602         * gm2-libs-log/Break.c: ...here.
4603         * gm2-libs-pim/Break.def: Moved to...
4604         * gm2-libs-log/Break.def: ...here.
4605         * gm2-libs-pim/CardinalIO.def: Moved to...
4606         * gm2-libs-log/CardinalIO.def: ...here.
4607         * gm2-libs-pim/CardinalIO.mod: Moved to...
4608         * gm2-libs-log/CardinalIO.mod: ...here.
4609         * gm2-libs-pim/Conversions.def: Moved to...
4610         * gm2-libs-log/Conversions.def: ...here.
4611         * gm2-libs-pim/Conversions.mod: Moved to...
4612         * gm2-libs-log/Conversions.mod: ...here.
4613         * gm2-libs-pim/DebugPMD.def: Moved to...
4614         * gm2-libs-log/DebugPMD.def: ...here.
4615         * gm2-libs-pim/DebugPMD.mod: Moved to...
4616         * gm2-libs-log/DebugPMD.mod: ...here.
4617         * gm2-libs-pim/DebugTrace.def: Moved to...
4618         * gm2-libs-log/DebugTrace.def: ...here.
4619         * gm2-libs-pim/DebugTrace.mod: Moved to...
4620         * gm2-libs-log/DebugTrace.mod: ...here.
4621         * gm2-libs-pim/Delay.def: Moved to...
4622         * gm2-libs-log/Delay.def: ...here.
4623         * gm2-libs-pim/Delay.mod: Moved to...
4624         * gm2-libs-log/Delay.mod: ...here.
4625         * gm2-libs-pim/Display.def: Moved to...
4626         * gm2-libs-log/Display.def: ...here.
4627         * gm2-libs-pim/Display.mod: Moved to...
4628         * gm2-libs-log/Display.mod: ...here.
4629         * gm2-libs-pim/ErrorCode.def: Moved to...
4630         * gm2-libs-log/ErrorCode.def: ...here.
4631         * gm2-libs-pim/ErrorCode.mod: Moved to...
4632         * gm2-libs-log/ErrorCode.mod: ...here.
4633         * gm2-libs-pim/FileSystem.def: Moved to...
4634         * gm2-libs-log/FileSystem.def: ...here.
4635         * gm2-libs-pim/FileSystem.mod: Moved to...
4636         * gm2-libs-log/FileSystem.mod: ...here.
4637         * gm2-libs-pim/FloatingUtilities.def: Moved to...
4638         * gm2-libs-log/FloatingUtilities.def: ...here.
4639         * gm2-libs-pim/FloatingUtilities.mod: Moved to...
4640         * gm2-libs-log/FloatingUtilities.mod: ...here.
4641         * gm2-libs-pim/InOut.def: Moved to...
4642         * gm2-libs-log/InOut.def: ...here.
4643         * gm2-libs-pim/InOut.mod: Moved to...
4644         * gm2-libs-log/InOut.mod: ...here.
4645         * gm2-libs-pim/Keyboard.def: Moved to...
4646         * gm2-libs-log/Keyboard.def: ...here.
4647         * gm2-libs-pim/Keyboard.mod: Moved to...
4648         * gm2-libs-log/Keyboard.mod: ...here.
4649         * gm2-libs-pim/LongIO.def: Moved to...
4650         * gm2-libs-log/LongIO.def: ...here.
4651         * gm2-libs-pim/LongIO.mod: Moved to...
4652         * gm2-libs-log/LongIO.mod: ...here.
4653         * gm2-libs-pim/NumberConversion.def: Moved to...
4654         * gm2-libs-log/NumberConversion.def: ...here.
4655         * gm2-libs-pim/NumberConversion.mod: Moved to...
4656         * gm2-libs-log/NumberConversion.mod: ...here.
4657         * gm2-libs-pim/README.texi: Moved to...
4658         * gm2-libs-log/README.texi: ...here.
4659         * gm2-libs-pim/Random.def: Moved to...
4660         * gm2-libs-log/Random.def: ...here.
4661         * gm2-libs-pim/Random.mod: Moved to...
4662         * gm2-libs-log/Random.mod: ...here.
4663         * gm2-libs-pim/RealConversions.def: Moved to...
4664         * gm2-libs-log/RealConversions.def: ...here.
4665         * gm2-libs-pim/RealConversions.mod: Moved to...
4666         * gm2-libs-log/RealConversions.mod: ...here.
4667         * gm2-libs-pim/RealInOut.def: Moved to...
4668         * gm2-libs-log/RealInOut.def: ...here.
4669         * gm2-libs-pim/RealInOut.mod: Moved to...
4670         * gm2-libs-log/RealInOut.mod: ...here.
4671         * gm2-libs-pim/Strings.def: Moved to...
4672         * gm2-libs-log/Strings.def: ...here.
4673         * gm2-libs-pim/Strings.mod: Moved to...
4674         * gm2-libs-log/Strings.mod: ...here.
4675         * gm2-libs-pim/Termbase.def: Moved to...
4676         * gm2-libs-log/Termbase.def: ...here.
4677         * gm2-libs-pim/Termbase.mod: Moved to...
4678         * gm2-libs-log/Termbase.mod: ...here.
4679         * gm2-libs-pim/Terminal.def: Moved to...
4680         * gm2-libs-log/Terminal.def: ...here.
4681         * gm2-libs-pim/Terminal.mod: Moved to...
4682         * gm2-libs-log/Terminal.mod: ...here.
4683         * gm2-libs-pim/TimeDate.def: Moved to...
4684         * gm2-libs-log/TimeDate.def: ...here.
4685         * gm2-libs-pim/TimeDate.mod: Moved to...
4686         * gm2-libs-log/TimeDate.mod: ...here.
4688 2023-01-28  Iain Sandoe  <iain@sandoe.co.uk>
4690         * lang.opt: Claim Wreturn-type.
4692 2023-01-27  Gaius Mulley  <gaiusmod2@gmail.com>
4694         * gm2-compiler/M2Comp.mod:  Import MetaString0.
4695         (ExamineCompilationUnit): New variable Message.
4696         Create and format error string.
4697         * gm2-compiler/M2LexBuf.mod: New variable SeenEof.
4698         (GetNonEofToken): New procedure.
4699         (Init): Set SeenEof to FALSE.
4700         (GetToken): Use GetNonEofToken instead of calls to
4701         m2flex.GetToken and GetToken.
4702         (AddTok): Detect eoftok and set SeenEof.
4704 2023-01-27  Gaius Mulley  <gaiusmod2@gmail.com>
4706         * gm2-compiler/M2Options.def: Export GetMQ, SetMQ.
4707         * gm2-compiler/M2Preprocess.mod: (MakeSaveTempsFileName):
4708         Test NewDir against NIL.  Test Dumpdir against NIL.
4709         Test GetMD () against NIL.  Test GetMMD () against NIL.
4710         Test GetMQ () against NIL.  Test GetObj () against NIL.
4711         Test tempfile against NIL.
4712         * gm2-compiler/P2SymBuild.def: Export
4713         BuildNoReturnAttribute.
4715 2023-01-27  Iain Sandoe  <iain@sandoe.co.uk>
4717         PR modula2/108555
4718         PR modula2/108182
4719         PR modula2/102343
4720         * gm2-lang.cc (gm2_langhook_option_lang_mask): Do not claim CL_C
4721         or CL_DRIVER.
4722         (gm2_langhook_init_options): Handle options that we want to pass
4723         to the preprocessor.
4724         * lang-specs.h: Pass -B and -save-temps to regular compile lines.
4725         * lang.opt: Add C and Driver options that Modula-2 intercepts for
4726         internal use. Reorder options into two sections and to collate.
4728 2023-01-26  Gaius Mulley  <gaiusmod2@gmail.com>
4730         * gm2-compiler/M2GCCDeclare.mod: Import IsProcedureNoReturn.
4731         (DeclareProcedureToGccWholeProgram): New variable declared and set
4732         returnType.  Pass returnType to BuildEndFunctionDeclaration.
4733         Extra parameter IsProcedureNoReturn passed to
4734         BuildEndFunctionDeclaration.
4735         * gm2-compiler/M2Quads.mod (BuildM2MainFunction): Correct
4736         scaffold comment and add extra return 0.
4737         * gm2-compiler/P2Build.bnf: Import BuildNoReturnAttribute.
4738         (ProcedureHeading): Process EndBuildFormalParameters before
4739         parsing AttributeNoReturn.
4740         (DefProcedureHeading): Process EndBuildFormalParameters before
4741         parsing AttributeNoReturn.
4742         (AttributeNoReturn): Call BuildNoReturnAttribute.
4743         * gm2-compiler/P2SymBuild.def (BuildNoReturnAttribute): New
4744         procedure.
4745         * gm2-compiler/P2SymBuild.mod (BuildNoReturnAttribute): New
4746         procedure.
4747         * gm2-compiler/SymbolTable.def (PutProcedureInline): Corrected
4748         comment.
4749         (PutProcedureNoReturn): New procedure.
4750         (IsProcedureNoReturn): New procedure function.
4751         * gm2-compiler/SymbolTable.mod (SymProcedure): IsNoReturn
4752         new field.
4753         (MakeProcedure): Initialize IsNoReturn to FALSE.
4754         (PutProcedureNoReturn): New procedure.
4755         (IsProcedureNoReturn): New procedure function.
4756         * gm2-gcc/m2decl.cc (m2decl_BuildEndFunctionDeclaration):
4757         Add extra parameter isnoreturn.  Set TREE_THIS_VOLATILE
4758         to isnoreturn.
4759         * gm2-gcc/m2decl.def (BuildEndFunctionDeclaration): Add
4760         extra parameter isnoreturn.
4761         * gm2-gcc/m2decl.h (m2decl_BuildEndFunctionDeclaration): Add
4762         extra parameter isnoreturn.
4763         * gm2-gcc/m2except.cc (m2except_InitExceptions): Change all
4764         function decl to pass an extra parameter isnoreturn.
4766 2023-01-26  Gaius Mulley  <gaiusmod2@gmail.com>
4768         * m2.flex (splitSlashStar): Fix comment so that /* does not
4769         appear inside the comment.
4771 2023-01-26  Iain Sandoe  <iain@sandoe.co.uk>
4773         PR modula2/108553
4774         * gm2-lang.cc (gm2_langhook_init_options): Remove debug code.
4776 2023-01-26  Gaius Mulley  <gaiusmod2@gmail.com>
4778         * Make-lang.in (m2/gm2config.h): Rewrite rule to be
4779         dependent upon m2/gm2config.aci.
4780         (m2/gm2config.aci): Newrule.
4781         * configure.ac (AC_CONFIG_HEADERS): Change destination
4782         to gm2config.aci.
4783         * configure: Regenerate.
4784         * gm2-libs/config-host: Regenerate.
4785         * gm2-compiler/M2GCCDeclare.mod (AddSymToWatch): Comment
4786         out.
4787         * gm2-compiler/M2Quads.mod (BuildConstHighFromSym): Remove
4788         Dim.
4789         (StartBuildWith): Call BuildStmtNoteTok.
4790         (BuildStmtNoteTok): New procedure.
4791         (BuildStmtNote): Re-implement re-factor into two
4792         procedures and call BuildStmtNoteTok.
4793         * gm2config.h.in: Remove.
4794         * gm2config.aci.in: New file.
4796 2023-01-25  Iain Sandoe  <iain@sandoe.co.uk>
4798         PR modula2/102343
4799         PR modula2/108182
4800         * gm2-compiler/M2Comp.mod: Early exit for pre-processor-only jobs.
4801         * gm2-compiler/M2Options.def (SetPPOnly, GetPPOnly, SetMD, GetMD,
4802         SetMMD, GetMMD, SetMQ, GetMQ, SetObj, GetObj, SetDumpDir,
4803         GetDumpDir):New.
4804         * gm2-compiler/M2Options.mod:(SetPPOnly, GetPPOnly, SetMD, GetMD,
4805         SetMMD, GetMMD, SetMQ, GetMQ, SetObj, GetObj, SetDumpDir,
4806         GetDumpDir):New.
4807         * gm2-compiler/M2Preprocess.def (PreprocessModule): Add flag to
4808         indicate the main file.
4809         * gm2-compiler/M2Preprocess.mod: Handle Preprocess-only jobs,
4810         handle MD, MMD and MQ options.
4811         * gm2-gcc/m2options.h (M2Options_SetPPOnly, M2Options_GetPPOnly,
4812         M2Options_SetDumpDir, M2Options_SetMD, M2Options_GetMD,
4813         M2Options_SetMMD, M2Options_GetMMD, M2Options_SetMQ, M2Options_GetMQ,
4814         M2Options_SetObj, M2Options_GetObj): New.
4815         * gm2-gcc/m2type.cc (m2type_InitBaseTypes): Early exit for pre-
4816         processor-only jobs.
4817         * gm2-lang.cc (gm2_langhook_init): Handle preprocess-only commands.
4818         (gm2_langhook_option_lang_mask): Claim C and Driver options so that
4819         we can intercept them for building pre-processor commands.
4820         (gm2_langhook_init_options): Collect the preprocessor line here.
4821         Save options that have different actions for preprocessor and compile
4822         commands.
4823         (gm2_langhook_handle_option): Only handle the modula-2 options here.
4824         (gm2_langhook_post_options): Do not create a back-end for pre-
4825         processor-only jobs.
4826         * gm2spec.cc (lang_specific_driver): Ignore PCH options, append a
4827         scaffold-main for cases where we are building a main module with
4828         -c.
4829         * lang-specs.h: Revise to handle preprocessor-only jobs and to
4830         consume pre-processed files.
4831         * lang.opt: Remove Driver and C options copies (we claim these
4832         separately).
4834 2023-01-24  Co-Authored by: Iain Sandoe  <iain@sandoe.co.uk>
4836         * Make-lang.in (GM2-COMP-BOOT-DEFS): Add
4837         DynamicStringPath.def.
4838         (GM2-COMP-BOOT-MODS): Add DynamicStringPath.mod.
4839         (GM2-COMP-DEFS): Add DynamicStringPath.def.
4840         (GM2-COMP-MODS): Add DynamicStringPath.mod.
4841         ($(objdir)/m2/gm2-libs-min/SYSTEM.def): Split path into
4842         multiple -I components.
4843         ($(objdir)/m2/gm2-libs/SYSTEM.def): Ditto.
4844         ($(objdir)/m2/gm2-libs-coroutines/SYSTEM.def): Ditto.
4845         * gm2-compiler/M2Options.mod: Import DynamicStringPath.
4846         (SetSearchPath): Reimplement using DynamicStringPath
4847         procedures.
4848         * gm2-compiler/M2Search.def (InitSearchPath): Remove.
4849         (PrependSearchPath): Remove.
4850         * gm2-compiler/M2Search.mod (SFIO): Remove import.
4851         (DynamicStringPath): Add import.
4852         (Directory): Remove.
4853         (UserPath): Remove.
4854         (InitialPath): Remove.
4855         (InitSearchPath): Remove.
4856         (PrependSearchPath): Remove.
4857         (FindSourceFile): Re-implement.
4858         (FindSourceDefFile): Re-implement.
4859         (FindSourceModFile): Re-implement.
4860         * gm2-gcc/init.cc (_M2_DynamicStringPath_init):
4861         New prototype.
4862         (init_FrontEndInit): Call _M2_DynamicStringPath_init.
4863         * tools-src/makeSystem: Allow multiple -I paths.
4864         * gm2-compiler/DynamicStringPath.def: New file.
4865         * gm2-compiler/DynamicStringPath.mod: New file.
4866         * gm2-gcc/m2options.h (M2Options_SetMakeIncludePath): Add
4867         prototype.
4869 2023-01-24  Gaius Mulley  <gaiusmod2@gmail.com>
4871         * m2.flex (cpreprocessor): Add temporary variable
4872         which is initialized to 0.
4873         (commentCLevel): New variable.
4874         (endOfCComment): New function.
4875         (splitSlashStar): New function to split /* into / and *
4876         tokens.
4877         (COMMENTC): New flex state.
4878         ("/*"): New rule to test whether we should treat /*
4879         as a single token or as two tokens.
4880         (<COMMENTC>.): New rule to skip a character.
4881         (<COMMENTC>\n.*): New rule to consume the line.
4882         (<COMMENTC>"*/"): New rule to call endOfCComment.
4884 2023-01-24  Gaius Mulley  <gaiusmod2@gmail.com>
4886         * gm2-libs-iso/RTco.def: Import RTentity.
4887         Declare RTco as a definition for C module.
4889 2023-01-23  Iain Sandoe  <iain@sandoe.co.uk>
4891         PR modula2/108182
4892         PR modula2/108480
4893         * Make-lang.in: Pass libsubdir to the language init
4894         build.
4895         * gm2-lang.cc (INCLUDE_VECTOR): Define.
4896         (add_one_import_path): New.
4897         (add_m2_import_paths): New.
4898         (gm2_langhook_post_options): Arrange to add the include
4899         paths (and add the system ones) in the same order as C
4900         uses.
4901         * gm2spec.cc (build_archive_path): Remove.
4902         (add_default_combination): Remove.
4903         (add_default_archives): Remove.
4904         (add_default_libs): We no longer need a '-L' option, just
4905         emit the -l and each library in use.
4906         (build_include_path): Remove.
4907         (add_include): Remove.
4908         (add_default_includes): Remove.
4909         (library_installed): Remove.
4910         (check_valid_library): Remove.
4911         (check_valid_list): Remove.
4912         (convert_abbreviation): Diagnose unhandled cases.
4913         (lang_specific_driver): Skip options where we will add back
4914         a validated version.
4915         * lang-specs.h (M2CPP): Reformat, append %I when -fcpp is not
4916         in use.  Revise the cc1gm2 spec to omit mentioning options that
4917         are handled in the c pre-processor line.
4918         * lang.opt: Allow preprocessing and path options as input to the
4919         cc1gm2 invocation, so that they can be passed to the preprocessor
4920         invocation.
4922 2023-01-23  Iain Sandoe  <iain@sandoe.co.uk>
4924         PR modula2/108405
4925         * gm2-libs-iso/Preemptive.mod (initPreemptive): Use a value for
4926         extra space that is divisible by common OS pagesizes.
4928 2023-01-20  Gaius Mulley  <gaiusmod2@gmail.com>
4930         * gm2-libs/Args.mod (GetArg): Check index before
4931         accessing array.
4932         * gm2-libs/M2Dependent.mod (toCString): Check index
4933         before accessing array.
4934         * mc-boot/GArgs.c: Rebuilt.
4935         * mc-boot/GM2Dependent.c: Rebuilt.
4936         * mc-boot/Gkeyc.c: Rebuilt.
4937         * mc/keyc.mod (seenUIntMin): Initialize once.
4938         (seenUIntMax): Initialize once.
4939         (checkLimits): Only test seenUIntMin and seenUIntMax
4940         once.
4941         * pge-boot/GArgs.c:  Rebuilt.
4942         * pge-boot/GM2Dependent.c: Rebuilt.
4944 2023-01-20  Gaius Mulley  <gaiusmod2@gmail.com>
4946         * gm2-gcc/m2statement.cc (gm2_gimplify_function_node):
4947         Remove.
4948         * gm2-libs/DynamicStrings.mod (Equal): Remove dead code.
4949         * m2.flex (<COMMENT>"<*"): Add {} for else statement.
4950         * m2pp.cc (hextree): Add conditional #ifdef DEBUGGING.
4951         * mc-boot/GDynamicStrings.c: Rebuild.
4952         * pge-boot/GDynamicStrings.c: Rebuild.
4953         * pge-boot/GFIO.c: Rebuild.
4954         * pge-boot/GIndexing.c: Rebuild.
4955         * pge-boot/GM2EXCEPTION.c: Rebuild.
4956         * pge-boot/GM2RTS.c: Rebuild.
4957         * pge-boot/GNameKey.c: Rebuild.
4958         * pge-boot/GPushBackInput.c: Rebuild.
4959         * pge-boot/GRTExceptions.c: Rebuild.
4960         * pge-boot/GStdIO.c: Rebuild.
4961         * pge-boot/GSymbolKey.c: Rebuild.
4962         * pge-boot/GSysStorage.c: Rebuild.
4964 2023-01-17  Gaius Mulley  <gaiusmod2@gmail.com>
4966         * mc-boot/GM2RTS.c: Rebuilt.
4967         * mc-boot/GM2RTS.h: Rebuilt.
4968         * mc-boot/Gdecl.c: Rebuilt.
4969         * mc-boot/GmcOptions.c: Rebuilt.
4970         * mc/mcOptions.mod (displayVersion):
4971         Split first printf into three components
4973 2023-01-17  Gaius Mulley  <gaiusmod2@gmail.com>
4975         * gm2-libs-iso/M2RTS.def (Halt): Parameter file renamed to filename.
4976         (HaltC): New procedure declaration.
4977         (ErrorMessage): Parameter file renamed to filename.
4978         * gm2-libs-iso/M2RTS.mod (Halt): Parameter file renamed to
4979         filename.
4980         (HaltC): New procedure implementation.
4981         (ErrorStringC): New procedure implementation.
4982         (ErrorMessageC): New procedure implementation.
4983         * gm2-libs/M2RTS.def (Halt): Parameter file renamed to filename.
4984         (HaltC): New procedure declaration.
4985         (ErrorMessage): Parameter file renamed to filename.
4986         * gm2-libs/M2RTS.mod (Halt): Parameter file renamed to filename.
4987         (HaltC): New procedure implementation.
4988         (ErrorStringC): New procedure implementation.
4989         (ErrorMessageC): New procedure implementation.
4991 2023-01-16  Gaius Mulley  <gaiusmod2@gmail.com>
4993         * mc-boot-ch/Glibc.c (libc_time): New function.
4994         (libc_localtime): New function.
4995         * mc-boot/GDynamicStrings.c: Regenerate.
4996         * mc-boot/GFIO.c: Regenerate.
4997         * mc-boot/GFormatStrings.c: Regenerate.
4998         * mc-boot/GIndexing.c: Regenerate.
4999         * mc-boot/GM2Dependent.c: Regenerate.
5000         * mc-boot/GM2EXCEPTION.c: Regenerate.
5001         * mc-boot/GPushBackInput.c: Regenerate.
5002         * mc-boot/GRTExceptions.c: Regenerate.
5003         * mc-boot/GRTint.c: Regenerate.
5004         * mc-boot/GStdIO.c: Regenerate.
5005         * mc-boot/GStringConvert.c: Regenerate.
5006         * mc-boot/GSysStorage.c: Regenerate.
5007         * mc-boot/Gdecl.c: Regenerate.
5008         * mc-boot/GmcComment.c: Regenerate.
5009         * mc-boot/GmcComp.c: Regenerate.
5010         * mc-boot/GmcDebug.c: Regenerate.
5011         * mc-boot/GmcMetaError.c: Regenerate.
5012         * mc-boot/GmcOptions.c: Regenerate.
5013         * mc-boot/GmcStack.c: Regenerate.
5014         * mc-boot/GnameKey.c: Regenerate.
5015         * mc-boot/GsymbolKey.c: Regenerate.
5016         * mc-boot/Gkeyc.c: Regenerate.
5017         * mc/decl.mod (putFieldRecord): Change NulName to NulKey
5018         and fix type comparision.
5019         * mc/mcOptions.mod (YEAR): Remove.
5020         (getYear): New procedure function.
5021         (displayVersion): Use result from getYear instead of YEAR.
5022         Emit boilerplate for GPL v3.
5023         (gplBody): Use result from getYear instead of YEAR.
5024         (glplBody): Use result from getYear instead of YEAR.
5026 2023-01-16  Gaius Mulley  <gaiusmod2@gmail.com>
5028         * gm2-compiler/M2Quads.mod (AssignUnboundedVar): Check Type
5029         against NulSym and call MetaErrorT1 if necessary.
5030         (AssignUnboundedNonVar): Check Type against NulSym and
5031         call MetaErrorT1 if necessary.
5032         (BuildDesignatorPointer): Check Type1 against NulSym and
5033         call MetaErrorT1 if necessary.
5035 2023-01-16  Gaius Mulley  <gaiusmod2@gmail.com>
5037         * mc/mcOptions.mod (displayVersion): Change GPLv2 to GPLv3.
5038         (YEAR) set to 2023.
5040 2023-01-15  Gaius Mulley  <gaiusmod2@gmail.com>
5042         * gm2-compiler/M2LexBuf.mod (isSrcToken): Add block comment.
5043         Remove dead code.
5044         * gm2-compiler/M2Quads.def (BuildNot): Add notTokPos parameter.
5045         * gm2-compiler/M2Quads.mod (BuildNot): Add notTokPos parameter.
5046         Create and push virtual token.
5047         (PopBooltok): New procedure.
5048         (PushBooltok): New procedure.
5049         (PushBool): Re-implement using PushBooltok.
5050         (PopBool): Re-implement using PopBooltok.
5051         * gm2-compiler/P3Build.bnf (ConstFactor): Record token
5052         position of NOT.
5053         (Factor): Record token position of NOT.
5054         * gm2-compiler/PHBuild.bnf (ConstFactor): Record token
5055         position of NOT.
5056         (Relation): Push token position.
5057         (UnaryOrConstTerm): Push token position.
5058         (AddOperator): Push token position.
5059         (MulOperator): Push token position.
5061 2023-01-13  Iain Sandoe  <iain@sandoe.co.uk>
5063         * gm2-gcc/m2options.h (M2Options_SetVerbose): Export the
5064         function.
5065         * gm2-lang.cc: Handle OPT_v, passing it to the compiler.
5066         * lang-specs.h: Pass -v to cc1gm2.
5068 2023-01-13  Gaius Mulley  <gaiusmod2@gmail.com>
5070         * mc-boot-ch/GRTco.c (RTco_select): Add return 0.
5071         * pge-boot/GRTco.c (RTco_select): Add return 0.
5073 2023-01-10  Gaius Mulley  <gaiusmod2@gmail.com>
5075         * Make-lang.in (m2/mc-boot/$(SRC_PREFIX)%.o): Add
5076         m2/gm2-libs/gm2-libs-host.h dependency.
5077         (m2/mc-boot-ch/$(SRC_PREFIX)%.o): Add
5078         m2/gm2-libs/gm2-libs-host.h dependency.
5080 2023-01-10  Gaius Mulley  <gaiusmod2@gmail.com>
5082         * Make-lang.in (GM2_1): Change -B path to m2/stage1.
5083         ($(objdir)/m2/images/gnu.eps): Check and create dest dir
5084         if necessary.
5085         (gm2-libs.texi-check): Check and create dir m2/gm2-libs-pim,
5086         m2/gm2-libs-iso and m2/gm2-libs if necessary.
5087         ($(objdir)/m2/gm2-compiler-boot): Remove.
5088         ($(objdir)/m2/gm2-libs-boot): Remove.
5089         ($(objdir)/m2/gm2-libs-libiberty): Remove.
5090         ($(objdir)/m2/gm2-libiberty): Remove.
5091         ($(objdir)/m2/gm2-gcc): Remove.
5092         ($(objdir)/m2/gm2-compiler): Remove.
5093         ($(objdir)/m2/gm2-libs): Remove.
5094         ($(objdir)/m2/gm2-libs-iso): Remove.
5095         ($(objdir)/m2/gm2-libs-min): Remove.
5096         ($(objdir)/m2/gm2-compiler-paranoid): Remove.
5097         ($(objdir)/m2/gm2-libs-paranoid): Remove.
5098         ($(objdir)/m2/gm2-compiler-verify): Remove.
5099         ($(objdir)/m2/boot-bin): Remove.
5100         ($(objdir)/m2/gm2-libs-pim): Remove.
5101         ($(objdir)/m2/gm2-libs-coroutines): Remove.
5102         (stage1/m2): Remove.
5103         (stage2/m2): Remove.
5104         (stage3/m2): Remove.
5105         (m2.stageprofile): New rule.
5106         (m2.stagefeedback): New rule.
5107         (cc1gm2$(exeext)): Change dependent name.
5108         (m2/stage2/cc1gm2$(exeext)): Change dependent name.
5109         Check and create dest dir.
5110         (m2/stage1/cc1gm2$(exeext)): Check and create dest dir
5111         if necessary.
5112         (m2/gm2-gcc/%.o): Ditto.
5113         (m2/gm2-gcc/rtegraph.o): Ditto.
5114         (m2/gm2-gcc/$(SRC_PREFIX)%.h): Ditto.
5115         (m2/gm2-gcc/$(SRC_PREFIX)%.h): Ditto.
5116         (m2/mc-boot): Ditto.
5117         (m2/mc-boot-ch): Ditto.
5118         (m2/gm2-libs-boot): Ditto.
5119         (m2/gm2-compiler-boot): Ditto.
5120         (m2/gm2-compiler): Ditto.
5121         (m2/gm2-libiberty): Ditto.
5122         (m2/gm2-compiler): Ditto.
5123         (m2/gm2-libs-iso): Ditto.
5124         (m2/gm2-libs): Ditto.
5125         (m2/gm2-libs-min): Ditto.
5126         (m2/gm2-libs-coroutines): Ditto.
5127         (m2/boot-bin): Ditto.
5128         (m2/pge-boot): Ditto.
5129         (m2/pge-boot): Ditto.
5130         * Make-maintainer.in (m2/gm2-ppg-boot): Check and create
5131         dest dir if necessary.
5132         (m2): Ditto.
5133         (m2/gm2-ppg-boot): Ditto.
5134         (m2/gm2-pg-boot): Ditto.
5135         (m2/gm2-auto): Ditto.
5136         (m2/gm2-pg-boot): Ditto.
5137         (m2/gm2-pge-boot): Ditto.
5138         ($(objdir)/plugin): Ditto.
5139         ($(objdir)/m2/mc-boot-ch): Ditto.
5140         ($(objdir)/m2/mc-boot-gen): Ditto.
5141         (m2/boot-bin): Ditto.
5142         (m2/mc): Ditto.
5143         (m2/mc-obj): Ditto.
5144         ($(objdir)/m2/gm2-ppg-boot): Ditto.
5145         ($(objdir)/m2/gm2-pg-boot): Ditto.
5146         ($(objdir)/m2/gm2-pge-boot): Ditto.
5147         (m2/mc-boot-gen): Ditto.
5148         (m2/m2obj3): Ditto.
5149         (m2/gm2-libs-paranoid): Ditto.
5150         (m2/gm2-compiler-paranoid): Ditto.
5151         (m2/gm2-libs-paranoid): Ditto.
5152         (m2/gm2-compiler-paranoid): Ditto.
5153         (m2/gm2-libs-paranoid): Ditto.
5154         (m2/gm2-compiler-paranoid): Ditto.
5155         * config-lang.in (m2/gm2-compiler-boot): Remove mkdir.
5156         (m2/gm2-libs-boot): Ditto.
5157         (m2/gm2-ici-boot): Ditto.
5158         (m2/gm2-libiberty): Ditto.
5159         (m2/gm2-gcc): Ditto.
5160         (m2/gm2-compiler): Ditto.
5161         (m2/gm2-libs): Ditto.
5162         (m2/gm2-libs-iso): Ditto.
5163         (m2/gm2-compiler-paranoid): Ditto.
5164         (m2/gm2-libs-paranoid): Ditto.
5165         (m2/gm2-compiler-verify): Ditto.
5166         (m2/boot-bin): Ditto.
5167         (m2/gm2-libs-pim): Ditto.
5168         (m2/gm2-libs-coroutines): Ditto.
5169         (m2/gm2-libs-min): Ditto.
5170         (m2/pge-boot): Ditto.
5171         (plugin): Ditto.
5172         (stage1/m2): Ditto.
5173         (stage2/m2): Ditto.
5174         (stage3/m2): Ditto.
5175         (stage4/m2): Ditto.
5176         (m2/gm2-auto): Ditto.
5177         (m2/gm2-pg-boot): Ditto.
5178         (m2/gm2-pge-boot): Ditto.
5179         (m2/gm2-ppg-boot): Ditto.
5180         (m2/mc-boot): Ditto.
5181         (m2/mc-boot-ch): Ditto.
5182         (m2/mc-boot-gen): Ditto.
5184 2023-01-09  Gaius Mulley  <gaiusmod2@gmail.com>
5186         * Make-lang.in (m2/pge-boot/%.o): Add m2/gm2config.h.
5187         * gm2-libs/config-host: Regenerate.
5189 2023-01-07  Iain Sandoe  <iain@sandoe.co.uk>
5191         * gm2-libs-min/libc.c (abort): Update declaration to match the
5192         expected form, add no-return attribute.
5193         (exit): Add no-return attribute.
5195 2023-01-05  Iain Sandoe  <iain@sandoe.co.uk>
5197         PR modula2/107631
5198         * gm2-gcc/m2builtins.cc: Remove scalb, scalbf, scalbl,
5199         significand, significandf, significandl.
5200         * gm2-libs/Builtins.def (significand): Likewise.
5201         * gm2-libs/Builtins.mod: Likewise.
5202         * target-independent/Builtins.texi: Likewise.
5203         * gm2-libs-iso/LowLong.mod: Implement fraction with scalbn*() and
5204         ilogb*().
5205         * gm2-libs-iso/LowReal.mod: Likewise.
5206         * gm2-libs-iso/LowShort.mod: Likewise.
5208 2023-01-05  Gaius Mulley  <gaiusmod2@gmail.com>
5210         * gm2-libs-min/M2RTS.def (ConstructModules): New procedure
5211         declaration.
5212         (DeconstructModules): New procedure declaration.
5213         * gm2-libs-min/M2RTS.mod (ConstructModules): New procedure
5214         dummy implementation.
5215         (DeconstructModules): New procedure dummy implementation.
5217 2023-01-05  Iain Sandoe  <iain@sandoe.co.uk>
5219         * gm2spec.cc (lang_specific_driver): Handle static-libgm2.
5220         * lang.opt: Add static-libgm2.
5222 2023-01-05  Iain Sandoe  <iain@sandoe.co.uk>
5224         * gm2spec.cc (lang_specific_driver): Pass -static-libstdc++ on to
5225         the target driver if the linker does not support Bstatic/dynamic.
5227 2023-01-04  Iain Sandoe  <iain@sandoe.co.uk>
5229         PR modula2/108183
5230         * gm2-libs-ch/UnixArgs.cc (_M2_UnixArgs_ctor): Rework to use
5231         an extern "C" function with 'constructor' attribute.
5232         * gm2-libs-ch/dtoa.cc (_M2_dtoa_ctor): Likewise.
5233         * gm2-libs-ch/ldtoa.cc (_M2_ldtoa_ctor): Likewise.
5235 2023-01-04  Iain Sandoe  <iain@sandoe.co.uk>
5237         PR modula2/108259
5238         * gm2-gcc/m2decl.cc (m2decl_DeclareModuleCtor): Make module
5239         registration constructors visible.
5241 2023-01-04  Iain Sandoe  <iain@sandoe.co.uk>
5243         * Make-lang.in (dvi, ps, pdf): Build in the gcc/doc directory, also
5244         use the configured tools for texi -> dvi and texi -> pdf.
5246 2023-01-01  Iain Sandoe  <iain@sandoe.co.uk>
5247             Gaius Mulley  <gaiusmod2@gmail.com>
5249         PR modula2/108183
5250         * gm2-compiler/M2GCCDeclare.mod: Module registration constructors are
5251         externs to the builder of m2_link.
5253 2022-12-31  Rainer Orth  <ro@CeBiTec.Uni-Bielefeld.DE>
5254             Iain Sandoe  <iain@sandoe.co.uk>
5256         PR modula2/107612
5257         * Make-lang.in (soext): Use .dylib for Darwin.
5258         (PLUGINLDFLAGS): Use dynmic lookup, set the plugin name, and append
5259         -nodefaultlibs to suppress the linking of libstdc++.
5260         Use INCINTL in compile lines for the plugin.
5262 2022-12-21  Jakub Jelinek  <jakub@redhat.com>
5264         PR modula2/108153
5265         * gm2-gcc/m2linemap.def (location_t): Use CARDINAL instead of INTEGER.
5267 2022-12-19  Jakub Jelinek  <jakub@redhat.com>
5269         * gm2-gcc/m2linemap.cc (m2linemap_ErrorAt, m2linemap_ErrorAtf,
5270         m2linemap_WarningAtf, m2linemap_NoteAtf, m2linemap_internal_error):
5271         Call functions with "%s", message rather than just message, so that
5272         % chars in message aren't treated as format specifiers.
5274 2022-12-19  Jakub Jelinek  <jakub@redhat.com>
5276         PR modula2/108147
5277         * gm2-gcc/m2linemap.def (ErrorAtf, WarningAtf, NoteAtf):
5278         Comment out prototypes with varargs.
5279         * gm2-gcc/m2linemap.h (m2linemap_ErrorAtf, m2linemap_WarningAtf,
5280         m2linemap_NoteAtf): No longer varargs.
5281         * gm2-gcc/m2linemap.cc (m2linemap_ErrorAtf): Turned into a
5282         non-varargs wrapper around ...
5283         (m2linemap_ErrorAtf_1): ... this.  New static function.
5284         (m2linemap_WarningAtf): Turned into a non-varargs wrapper around ...
5285         (m2linemap_WarningAtf_1): ... this.  New static function.
5286         (m2linemap_NoteAtf): Turned into a non-varargs wrapper around ...
5287         (m2linemap_NoteAtf_1): ... this.  New static function.
5289 2022-12-15  Gaius Mulley  <gaiusmod2@gmail.com>
5291         * configure.ac: Stop probing for realpath.
5292         * tools-src/calcpath: Break dependency on realpath, cut
5293         and echo.
5294         * configure: Rebuilt.
5296 2022-12-15  Gaius Mulley  <gaiusmod2@gmail.com>
5298         * gm2config.h.in: Rebuilt.
5300 2022-12-14  Gaius Mulley  <gaiusmod2@gmail.com>
5302         * COPYING.FDL: New file.
5303         * COPYING.RUNTIME: New file.
5304         * COPYING3: New file.
5305         * COPYING3.LIB: New file.
5306         * Make-lang.in: New file.
5307         * Make-maintainer.in: New file.
5308         * NEWS: New file.
5309         * README: New file.
5310         * config-lang.in: New file.
5311         * config-make.in: New file.
5312         * configure.ac: New file.
5313         * gm2-compiler/CLexBuf.def: New file.
5314         * gm2-compiler/CLexBuf.mod: New file.
5315         * gm2-compiler/FifoQueue.def: New file.
5316         * gm2-compiler/FifoQueue.mod: New file.
5317         * gm2-compiler/Lists.def: New file.
5318         * gm2-compiler/Lists.mod: New file.
5319         * gm2-compiler/M2ALU.def: New file.
5320         * gm2-compiler/M2ALU.mod: New file.
5321         * gm2-compiler/M2AsmUtil.def: New file.
5322         * gm2-compiler/M2AsmUtil.mod: New file.
5323         * gm2-compiler/M2Base.def: New file.
5324         * gm2-compiler/M2Base.mod: New file.
5325         * gm2-compiler/M2BasicBlock.def: New file.
5326         * gm2-compiler/M2BasicBlock.mod: New file.
5327         * gm2-compiler/M2Batch.def: New file.
5328         * gm2-compiler/M2Batch.mod: New file.
5329         * gm2-compiler/M2Bitset.def: New file.
5330         * gm2-compiler/M2Bitset.mod: New file.
5331         * gm2-compiler/M2CaseList.def: New file.
5332         * gm2-compiler/M2CaseList.mod: New file.
5333         * gm2-compiler/M2Check.def: New file.
5334         * gm2-compiler/M2Check.mod: New file.
5335         * gm2-compiler/M2Code.def: New file.
5336         * gm2-compiler/M2Code.mod: New file.
5337         * gm2-compiler/M2ColorString.def: New file.
5338         * gm2-compiler/M2ColorString.mod: New file.
5339         * gm2-compiler/M2Comp.def: New file.
5340         * gm2-compiler/M2Comp.mod: New file.
5341         * gm2-compiler/M2Const.def: New file.
5342         * gm2-compiler/M2Const.mod: New file.
5343         * gm2-compiler/M2Debug.def: New file.
5344         * gm2-compiler/M2Debug.mod: New file.
5345         * gm2-compiler/M2DebugStack.def: New file.
5346         * gm2-compiler/M2DebugStack.mod: New file.
5347         * gm2-compiler/M2Defaults.def: New file.
5348         * gm2-compiler/M2Defaults.mod: New file.
5349         * gm2-compiler/M2DriverOptions.def: New file.
5350         * gm2-compiler/M2DriverOptions.mod: New file.
5351         * gm2-compiler/M2Emit.def: New file.
5352         * gm2-compiler/M2Emit.mod: New file.
5353         * gm2-compiler/M2Error.def: New file.
5354         * gm2-compiler/M2Error.mod: New file.
5355         * gm2-compiler/M2EvalSym.def: New file.
5356         * gm2-compiler/M2FileName.def: New file.
5357         * gm2-compiler/M2FileName.mod: New file.
5358         * gm2-compiler/M2GCCDeclare.def: New file.
5359         * gm2-compiler/M2GCCDeclare.mod: New file.
5360         * gm2-compiler/M2GenGCC.def: New file.
5361         * gm2-compiler/M2GenGCC.mod: New file.
5362         * gm2-compiler/M2Graph.def: New file.
5363         * gm2-compiler/M2Graph.mod: New file.
5364         * gm2-compiler/M2Lex.def: New file.
5365         * gm2-compiler/M2Lex.mod: New file.
5366         * gm2-compiler/M2LexBuf.def: New file.
5367         * gm2-compiler/M2LexBuf.mod: New file.
5368         * gm2-compiler/M2MetaError.def: New file.
5369         * gm2-compiler/M2MetaError.mod: New file.
5370         * gm2-compiler/M2Optimize.def: New file.
5371         * gm2-compiler/M2Optimize.mod: New file.
5372         * gm2-compiler/M2Options.def: New file.
5373         * gm2-compiler/M2Options.mod: New file.
5374         * gm2-compiler/M2Pass.def: New file.
5375         * gm2-compiler/M2Pass.mod: New file.
5376         * gm2-compiler/M2Preprocess.def: New file.
5377         * gm2-compiler/M2Preprocess.mod: New file.
5378         * gm2-compiler/M2Printf.def: New file.
5379         * gm2-compiler/M2Printf.mod: New file.
5380         * gm2-compiler/M2Quads.def: New file.
5381         * gm2-compiler/M2Quads.mod: New file.
5382         * gm2-compiler/M2Quiet.def: New file.
5383         * gm2-compiler/M2Quiet.mod: New file.
5384         * gm2-compiler/M2Range.def: New file.
5385         * gm2-compiler/M2Range.mod: New file.
5386         * gm2-compiler/M2Reserved.def: New file.
5387         * gm2-compiler/M2Reserved.mod: New file.
5388         * gm2-compiler/M2SSA.def: New file.
5389         * gm2-compiler/M2SSA.mod: New file.
5390         * gm2-compiler/M2Scaffold.def: New file.
5391         * gm2-compiler/M2Scaffold.mod: New file.
5392         * gm2-compiler/M2Scope.def: New file.
5393         * gm2-compiler/M2Scope.mod: New file.
5394         * gm2-compiler/M2Search.def: New file.
5395         * gm2-compiler/M2Search.mod: New file.
5396         * gm2-compiler/M2Size.def: New file.
5397         * gm2-compiler/M2Size.mod: New file.
5398         * gm2-compiler/M2StackAddress.def: New file.
5399         * gm2-compiler/M2StackAddress.mod: New file.
5400         * gm2-compiler/M2StackWord.def: New file.
5401         * gm2-compiler/M2StackWord.mod: New file.
5402         * gm2-compiler/M2Students.def: New file.
5403         * gm2-compiler/M2Students.mod: New file.
5404         * gm2-compiler/M2Swig.def: New file.
5405         * gm2-compiler/M2Swig.mod: New file.
5406         * gm2-compiler/M2System.def: New file.
5407         * gm2-compiler/M2System.mod: New file.
5408         * gm2-compiler/M2Version.def: New file.
5409         * gm2-compiler/NameKey.def: New file.
5410         * gm2-compiler/NameKey.mod: New file.
5411         * gm2-compiler/ObjectFiles.def: New file.
5412         * gm2-compiler/ObjectFiles.mod: New file.
5413         * gm2-compiler/Output.def: New file.
5414         * gm2-compiler/Output.mod: New file.
5415         * gm2-compiler/P0SymBuild.def: New file.
5416         * gm2-compiler/P0SymBuild.mod: New file.
5417         * gm2-compiler/P0SyntaxCheck.bnf: New file.
5418         * gm2-compiler/P0SyntaxCheck.def: New file.
5419         * gm2-compiler/P1Build.bnf: New file.
5420         * gm2-compiler/P1Build.def: New file.
5421         * gm2-compiler/P1SymBuild.def: New file.
5422         * gm2-compiler/P1SymBuild.mod: New file.
5423         * gm2-compiler/P2Build.bnf: New file.
5424         * gm2-compiler/P2Build.def: New file.
5425         * gm2-compiler/P2SymBuild.def: New file.
5426         * gm2-compiler/P2SymBuild.mod: New file.
5427         * gm2-compiler/P3Build.bnf: New file.
5428         * gm2-compiler/P3Build.def: New file.
5429         * gm2-compiler/P3SymBuild.def: New file.
5430         * gm2-compiler/P3SymBuild.mod: New file.
5431         * gm2-compiler/PCBuild.bnf: New file.
5432         * gm2-compiler/PCBuild.def: New file.
5433         * gm2-compiler/PCSymBuild.def: New file.
5434         * gm2-compiler/PCSymBuild.mod: New file.
5435         * gm2-compiler/PHBuild.bnf: New file.
5436         * gm2-compiler/PHBuild.def: New file.
5437         * gm2-compiler/README: New file.
5438         * gm2-compiler/Sets.def: New file.
5439         * gm2-compiler/Sets.mod: New file.
5440         * gm2-compiler/SymbolConversion.def: New file.
5441         * gm2-compiler/SymbolConversion.mod: New file.
5442         * gm2-compiler/SymbolKey.def: New file.
5443         * gm2-compiler/SymbolKey.mod: New file.
5444         * gm2-compiler/SymbolTable.def: New file.
5445         * gm2-compiler/SymbolTable.mod: New file.
5446         * gm2-compiler/bnflex.def: New file.
5447         * gm2-compiler/bnflex.mod: New file.
5448         * gm2-compiler/cflex.def: New file.
5449         * gm2-compiler/gm2.mod: New file.
5450         * gm2-compiler/gm2lcc.mod: New file.
5451         * gm2-compiler/gm2lgen.mod: New file.
5452         * gm2-compiler/gm2lorder.mod: New file.
5453         * gm2-compiler/m2flex.def: New file.
5454         * gm2-compiler/ppg.mod: New file.
5455         * gm2-gcc/README: New file.
5456         * gm2-gcc/dynamicstrings.h: New file.
5457         * gm2-gcc/gcc-consolidation.h: New file.
5458         * gm2-gcc/init.cc: New file.
5459         * gm2-gcc/init.def: New file.
5460         * gm2-gcc/init.h: New file.
5461         * gm2-gcc/m2assert.cc: New file.
5462         * gm2-gcc/m2assert.h: New file.
5463         * gm2-gcc/m2block.cc: New file.
5464         * gm2-gcc/m2block.def: New file.
5465         * gm2-gcc/m2block.h: New file.
5466         * gm2-gcc/m2builtins.cc: New file.
5467         * gm2-gcc/m2builtins.def: New file.
5468         * gm2-gcc/m2builtins.h: New file.
5469         * gm2-gcc/m2color.cc: New file.
5470         * gm2-gcc/m2color.def: New file.
5471         * gm2-gcc/m2color.h: New file.
5472         * gm2-gcc/m2configure.cc: New file.
5473         * gm2-gcc/m2configure.def: New file.
5474         * gm2-gcc/m2configure.h: New file.
5475         * gm2-gcc/m2convert.cc: New file.
5476         * gm2-gcc/m2convert.def: New file.
5477         * gm2-gcc/m2convert.h: New file.
5478         * gm2-gcc/m2decl.cc: New file.
5479         * gm2-gcc/m2decl.def: New file.
5480         * gm2-gcc/m2decl.h: New file.
5481         * gm2-gcc/m2except.cc: New file.
5482         * gm2-gcc/m2except.def: New file.
5483         * gm2-gcc/m2except.h: New file.
5484         * gm2-gcc/m2expr.cc: New file.
5485         * gm2-gcc/m2expr.def: New file.
5486         * gm2-gcc/m2expr.h: New file.
5487         * gm2-gcc/m2linemap.cc: New file.
5488         * gm2-gcc/m2linemap.def: New file.
5489         * gm2-gcc/m2linemap.h: New file.
5490         * gm2-gcc/m2misc.cc: New file.
5491         * gm2-gcc/m2misc.def: New file.
5492         * gm2-gcc/m2misc.h: New file.
5493         * gm2-gcc/m2options.h: New file.
5494         * gm2-gcc/m2range.h: New file.
5495         * gm2-gcc/m2search.h: New file.
5496         * gm2-gcc/m2statement.cc: New file.
5497         * gm2-gcc/m2statement.def: New file.
5498         * gm2-gcc/m2statement.h: New file.
5499         * gm2-gcc/m2top.cc: New file.
5500         * gm2-gcc/m2top.def: New file.
5501         * gm2-gcc/m2top.h: New file.
5502         * gm2-gcc/m2tree.cc: New file.
5503         * gm2-gcc/m2tree.def: New file.
5504         * gm2-gcc/m2tree.h: New file.
5505         * gm2-gcc/m2treelib.cc: New file.
5506         * gm2-gcc/m2treelib.def: New file.
5507         * gm2-gcc/m2treelib.h: New file.
5508         * gm2-gcc/m2type.cc: New file.
5509         * gm2-gcc/m2type.def: New file.
5510         * gm2-gcc/m2type.h: New file.
5511         * gm2-gcc/rtegraph.cc: New file.
5512         * gm2-gcc/rtegraph.h: New file.
5513         * gm2-ici/M2Emit.mod: New file.
5514         * gm2-ici/README: New file.
5515         * gm2-ici/m2linemap.c: New file.
5516         * gm2-internals.texi: New file.
5517         * gm2-lang.cc: New file.
5518         * gm2-lang.h: New file.
5519         * gm2-libiberty/README: New file.
5520         * gm2-libiberty/choosetemp.def: New file.
5521         * gm2-libiberty/pexecute.def: New file.
5522         * gm2-libs-ch/M2LINK.c: New file.
5523         * gm2-libs-ch/README: New file.
5524         * gm2-libs-ch/RTcodummy.c: New file.
5525         * gm2-libs-ch/RTintdummy.c: New file.
5526         * gm2-libs-ch/Selective.c: New file.
5527         * gm2-libs-ch/SysExceptions.c: New file.
5528         * gm2-libs-ch/UnixArgs.cc: New file.
5529         * gm2-libs-ch/cgetopt.c: New file.
5530         * gm2-libs-ch/choosetemp.c: New file.
5531         * gm2-libs-ch/dtoa.cc: New file.
5532         * gm2-libs-ch/errno.c: New file.
5533         * gm2-libs-ch/host.c: New file.
5534         * gm2-libs-ch/ldtoa.cc: New file.
5535         * gm2-libs-ch/m2rts.h: New file.
5536         * gm2-libs-ch/termios.c: New file.
5537         * gm2-libs-ch/tools.c: New file.
5538         * gm2-libs-ch/wrapc.c: New file.
5539         * gm2-libs-ch/xlibc.c: New file.
5540         * gm2-libs-coroutines/Debug.def: New file.
5541         * gm2-libs-coroutines/Debug.mod: New file.
5542         * gm2-libs-coroutines/Executive.def: New file.
5543         * gm2-libs-coroutines/Executive.mod: New file.
5544         * gm2-libs-coroutines/KeyBoardLEDs.def: New file.
5545         * gm2-libs-coroutines/README.texi: New file.
5546         * gm2-libs-coroutines/SYSTEM.def: New file.
5547         * gm2-libs-coroutines/SYSTEM.mod: New file.
5548         * gm2-libs-coroutines/TimerHandler.def: New file.
5549         * gm2-libs-coroutines/TimerHandler.mod: New file.
5550         * gm2-libs-iso/COROUTINES.def: New file.
5551         * gm2-libs-iso/COROUTINES.mod: New file.
5552         * gm2-libs-iso/ChanConsts.def: New file.
5553         * gm2-libs-iso/ChanConsts.h: New file.
5554         * gm2-libs-iso/ChanConsts.mod: New file.
5555         * gm2-libs-iso/CharClass.def: New file.
5556         * gm2-libs-iso/CharClass.mod: New file.
5557         * gm2-libs-iso/ClientSocket.def: New file.
5558         * gm2-libs-iso/ClientSocket.mod: New file.
5559         * gm2-libs-iso/ComplexMath.def: New file.
5560         * gm2-libs-iso/ComplexMath.mod: New file.
5561         * gm2-libs-iso/ConvStringLong.def: New file.
5562         * gm2-libs-iso/ConvStringLong.mod: New file.
5563         * gm2-libs-iso/ConvStringReal.def: New file.
5564         * gm2-libs-iso/ConvStringReal.mod: New file.
5565         * gm2-libs-iso/ConvTypes.def: New file.
5566         * gm2-libs-iso/ConvTypes.mod: New file.
5567         * gm2-libs-iso/EXCEPTIONS.def: New file.
5568         * gm2-libs-iso/EXCEPTIONS.mod: New file.
5569         * gm2-libs-iso/ErrnoCategory.def: New file.
5570         * gm2-libs-iso/GeneralUserExceptions.def: New file.
5571         * gm2-libs-iso/GeneralUserExceptions.mod: New file.
5572         * gm2-libs-iso/IOChan.def: New file.
5573         * gm2-libs-iso/IOChan.mod: New file.
5574         * gm2-libs-iso/IOConsts.def: New file.
5575         * gm2-libs-iso/IOConsts.mod: New file.
5576         * gm2-libs-iso/IOLink.def: New file.
5577         * gm2-libs-iso/IOLink.mod: New file.
5578         * gm2-libs-iso/IOResult.def: New file.
5579         * gm2-libs-iso/IOResult.mod: New file.
5580         * gm2-libs-iso/LongComplexMath.def: New file.
5581         * gm2-libs-iso/LongComplexMath.mod: New file.
5582         * gm2-libs-iso/LongConv.def: New file.
5583         * gm2-libs-iso/LongConv.mod: New file.
5584         * gm2-libs-iso/LongIO.def: New file.
5585         * gm2-libs-iso/LongIO.mod: New file.
5586         * gm2-libs-iso/LongMath.def: New file.
5587         * gm2-libs-iso/LongMath.mod: New file.
5588         * gm2-libs-iso/LongStr.def: New file.
5589         * gm2-libs-iso/LongStr.mod: New file.
5590         * gm2-libs-iso/LongWholeIO.def: New file.
5591         * gm2-libs-iso/LongWholeIO.mod: New file.
5592         * gm2-libs-iso/LowLong.def: New file.
5593         * gm2-libs-iso/LowLong.mod: New file.
5594         * gm2-libs-iso/LowReal.def: New file.
5595         * gm2-libs-iso/LowReal.mod: New file.
5596         * gm2-libs-iso/LowShort.def: New file.
5597         * gm2-libs-iso/LowShort.mod: New file.
5598         * gm2-libs-iso/M2EXCEPTION.def: New file.
5599         * gm2-libs-iso/M2EXCEPTION.mod: New file.
5600         * gm2-libs-iso/M2RTS.def: New file.
5601         * gm2-libs-iso/M2RTS.mod: New file.
5602         * gm2-libs-iso/MemStream.def: New file.
5603         * gm2-libs-iso/MemStream.mod: New file.
5604         * gm2-libs-iso/Preemptive.def: New file.
5605         * gm2-libs-iso/Preemptive.mod: New file.
5606         * gm2-libs-iso/Processes.def: New file.
5607         * gm2-libs-iso/Processes.mod: New file.
5608         * gm2-libs-iso/ProgramArgs.def: New file.
5609         * gm2-libs-iso/ProgramArgs.mod: New file.
5610         * gm2-libs-iso/README.texi: New file.
5611         * gm2-libs-iso/RTco.def: New file.
5612         * gm2-libs-iso/RTdata.def: New file.
5613         * gm2-libs-iso/RTdata.mod: New file.
5614         * gm2-libs-iso/RTentity.def: New file.
5615         * gm2-libs-iso/RTentity.mod: New file.
5616         * gm2-libs-iso/RTfio.def: New file.
5617         * gm2-libs-iso/RTfio.mod: New file.
5618         * gm2-libs-iso/RTgen.def: New file.
5619         * gm2-libs-iso/RTgen.mod: New file.
5620         * gm2-libs-iso/RTgenif.def: New file.
5621         * gm2-libs-iso/RTgenif.mod: New file.
5622         * gm2-libs-iso/RTio.def: New file.
5623         * gm2-libs-iso/RTio.mod: New file.
5624         * gm2-libs-iso/RandomNumber.def: New file.
5625         * gm2-libs-iso/RandomNumber.mod: New file.
5626         * gm2-libs-iso/RawIO.def: New file.
5627         * gm2-libs-iso/RawIO.mod: New file.
5628         * gm2-libs-iso/RealConv.def: New file.
5629         * gm2-libs-iso/RealConv.mod: New file.
5630         * gm2-libs-iso/RealIO.def: New file.
5631         * gm2-libs-iso/RealIO.mod: New file.
5632         * gm2-libs-iso/RealMath.def: New file.
5633         * gm2-libs-iso/RealMath.mod: New file.
5634         * gm2-libs-iso/RealStr.def: New file.
5635         * gm2-libs-iso/RealStr.mod: New file.
5636         * gm2-libs-iso/RndFile.def: New file.
5637         * gm2-libs-iso/RndFile.mod: New file.
5638         * gm2-libs-iso/SIOResult.def: New file.
5639         * gm2-libs-iso/SIOResult.mod: New file.
5640         * gm2-libs-iso/SLongIO.def: New file.
5641         * gm2-libs-iso/SLongIO.mod: New file.
5642         * gm2-libs-iso/SLongWholeIO.def: New file.
5643         * gm2-libs-iso/SLongWholeIO.mod: New file.
5644         * gm2-libs-iso/SRawIO.def: New file.
5645         * gm2-libs-iso/SRawIO.mod: New file.
5646         * gm2-libs-iso/SRealIO.def: New file.
5647         * gm2-libs-iso/SRealIO.mod: New file.
5648         * gm2-libs-iso/SShortIO.def: New file.
5649         * gm2-libs-iso/SShortIO.mod: New file.
5650         * gm2-libs-iso/SShortWholeIO.def: New file.
5651         * gm2-libs-iso/SShortWholeIO.mod: New file.
5652         * gm2-libs-iso/STextIO.def: New file.
5653         * gm2-libs-iso/STextIO.mod: New file.
5654         * gm2-libs-iso/SWholeIO.def: New file.
5655         * gm2-libs-iso/SWholeIO.mod: New file.
5656         * gm2-libs-iso/SYSTEM.def: New file.
5657         * gm2-libs-iso/SYSTEM.mod: New file.
5658         * gm2-libs-iso/Semaphores.def: New file.
5659         * gm2-libs-iso/Semaphores.mod: New file.
5660         * gm2-libs-iso/SeqFile.def: New file.
5661         * gm2-libs-iso/SeqFile.mod: New file.
5662         * gm2-libs-iso/ShortComplexMath.def: New file.
5663         * gm2-libs-iso/ShortComplexMath.mod: New file.
5664         * gm2-libs-iso/ShortIO.def: New file.
5665         * gm2-libs-iso/ShortIO.mod: New file.
5666         * gm2-libs-iso/ShortWholeIO.def: New file.
5667         * gm2-libs-iso/ShortWholeIO.mod: New file.
5668         * gm2-libs-iso/SimpleCipher.def: New file.
5669         * gm2-libs-iso/SimpleCipher.mod: New file.
5670         * gm2-libs-iso/StdChans.def: New file.
5671         * gm2-libs-iso/StdChans.mod: New file.
5672         * gm2-libs-iso/Storage.def: New file.
5673         * gm2-libs-iso/Storage.mod: New file.
5674         * gm2-libs-iso/StreamFile.def: New file.
5675         * gm2-libs-iso/StreamFile.mod: New file.
5676         * gm2-libs-iso/StringChan.def: New file.
5677         * gm2-libs-iso/StringChan.mod: New file.
5678         * gm2-libs-iso/Strings.def: New file.
5679         * gm2-libs-iso/Strings.mod: New file.
5680         * gm2-libs-iso/SysClock.def: New file.
5681         * gm2-libs-iso/SysClock.mod: New file.
5682         * gm2-libs-iso/TERMINATION.def: New file.
5683         * gm2-libs-iso/TERMINATION.mod: New file.
5684         * gm2-libs-iso/TermFile.def: New file.
5685         * gm2-libs-iso/TermFile.mod: New file.
5686         * gm2-libs-iso/TextIO.def: New file.
5687         * gm2-libs-iso/TextIO.mod: New file.
5688         * gm2-libs-iso/WholeConv.def: New file.
5689         * gm2-libs-iso/WholeConv.mod: New file.
5690         * gm2-libs-iso/WholeIO.def: New file.
5691         * gm2-libs-iso/WholeIO.mod: New file.
5692         * gm2-libs-iso/WholeStr.def: New file.
5693         * gm2-libs-iso/WholeStr.mod: New file.
5694         * gm2-libs-iso/wrapsock.c: New file.
5695         * gm2-libs-iso/wrapsock.def: New file.
5696         * gm2-libs-iso/wraptime.c: New file.
5697         * gm2-libs-iso/wraptime.def: New file.
5698         * gm2-libs-min/M2RTS.def: New file.
5699         * gm2-libs-min/M2RTS.mod: New file.
5700         * gm2-libs-min/SYSTEM.def: New file.
5701         * gm2-libs-min/SYSTEM.mod: New file.
5702         * gm2-libs-min/libc.c: New file.
5703         * gm2-libs-min/libc.def: New file.
5704         * gm2-libs-pim/BitBlockOps.def: New file.
5705         * gm2-libs-pim/BitBlockOps.mod: New file.
5706         * gm2-libs-pim/BitByteOps.def: New file.
5707         * gm2-libs-pim/BitByteOps.mod: New file.
5708         * gm2-libs-pim/BitWordOps.def: New file.
5709         * gm2-libs-pim/BitWordOps.mod: New file.
5710         * gm2-libs-pim/BlockOps.def: New file.
5711         * gm2-libs-pim/BlockOps.mod: New file.
5712         * gm2-libs-pim/Break.c: New file.
5713         * gm2-libs-pim/Break.def: New file.
5714         * gm2-libs-pim/CardinalIO.def: New file.
5715         * gm2-libs-pim/CardinalIO.mod: New file.
5716         * gm2-libs-pim/Conversions.def: New file.
5717         * gm2-libs-pim/Conversions.mod: New file.
5718         * gm2-libs-pim/DebugPMD.def: New file.
5719         * gm2-libs-pim/DebugPMD.mod: New file.
5720         * gm2-libs-pim/DebugTrace.def: New file.
5721         * gm2-libs-pim/DebugTrace.mod: New file.
5722         * gm2-libs-pim/Delay.def: New file.
5723         * gm2-libs-pim/Delay.mod: New file.
5724         * gm2-libs-pim/Display.def: New file.
5725         * gm2-libs-pim/Display.mod: New file.
5726         * gm2-libs-pim/ErrorCode.def: New file.
5727         * gm2-libs-pim/ErrorCode.mod: New file.
5728         * gm2-libs-pim/FileSystem.def: New file.
5729         * gm2-libs-pim/FileSystem.mod: New file.
5730         * gm2-libs-pim/FloatingUtilities.def: New file.
5731         * gm2-libs-pim/FloatingUtilities.mod: New file.
5732         * gm2-libs-pim/InOut.def: New file.
5733         * gm2-libs-pim/InOut.mod: New file.
5734         * gm2-libs-pim/Keyboard.def: New file.
5735         * gm2-libs-pim/Keyboard.mod: New file.
5736         * gm2-libs-pim/LongIO.def: New file.
5737         * gm2-libs-pim/LongIO.mod: New file.
5738         * gm2-libs-pim/NumberConversion.def: New file.
5739         * gm2-libs-pim/NumberConversion.mod: New file.
5740         * gm2-libs-pim/README.texi: New file.
5741         * gm2-libs-pim/Random.def: New file.
5742         * gm2-libs-pim/Random.mod: New file.
5743         * gm2-libs-pim/RealConversions.def: New file.
5744         * gm2-libs-pim/RealConversions.mod: New file.
5745         * gm2-libs-pim/RealInOut.def: New file.
5746         * gm2-libs-pim/RealInOut.mod: New file.
5747         * gm2-libs-pim/Strings.def: New file.
5748         * gm2-libs-pim/Strings.mod: New file.
5749         * gm2-libs-pim/Termbase.def: New file.
5750         * gm2-libs-pim/Termbase.mod: New file.
5751         * gm2-libs-pim/Terminal.def: New file.
5752         * gm2-libs-pim/Terminal.mod: New file.
5753         * gm2-libs-pim/TimeDate.def: New file.
5754         * gm2-libs-pim/TimeDate.mod: New file.
5755         * gm2-libs/ASCII.def: New file.
5756         * gm2-libs/ASCII.mod: New file.
5757         * gm2-libs/Args.def: New file.
5758         * gm2-libs/Args.mod: New file.
5759         * gm2-libs/Assertion.def: New file.
5760         * gm2-libs/Assertion.mod: New file.
5761         * gm2-libs/Break.def: New file.
5762         * gm2-libs/Break.mod: New file.
5763         * gm2-libs/Builtins.def: New file.
5764         * gm2-libs/Builtins.mod: New file.
5765         * gm2-libs/COROUTINES.def: New file.
5766         * gm2-libs/COROUTINES.mod: New file.
5767         * gm2-libs/CmdArgs.def: New file.
5768         * gm2-libs/CmdArgs.mod: New file.
5769         * gm2-libs/Debug.def: New file.
5770         * gm2-libs/Debug.mod: New file.
5771         * gm2-libs/DynamicStrings.def: New file.
5772         * gm2-libs/DynamicStrings.mod: New file.
5773         * gm2-libs/Environment.def: New file.
5774         * gm2-libs/Environment.mod: New file.
5775         * gm2-libs/FIO.def: New file.
5776         * gm2-libs/FIO.mod: New file.
5777         * gm2-libs/FormatStrings.def: New file.
5778         * gm2-libs/FormatStrings.mod: New file.
5779         * gm2-libs/FpuIO.def: New file.
5780         * gm2-libs/FpuIO.mod: New file.
5781         * gm2-libs/GetOpt.def: New file.
5782         * gm2-libs/GetOpt.mod: New file.
5783         * gm2-libs/IO.def: New file.
5784         * gm2-libs/IO.mod: New file.
5785         * gm2-libs/Indexing.def: New file.
5786         * gm2-libs/Indexing.mod: New file.
5787         * gm2-libs/LMathLib0.def: New file.
5788         * gm2-libs/LMathLib0.mod: New file.
5789         * gm2-libs/LegacyReal.def: New file.
5790         * gm2-libs/LegacyReal.mod: New file.
5791         * gm2-libs/M2Dependent.def: New file.
5792         * gm2-libs/M2Dependent.mod: New file.
5793         * gm2-libs/M2EXCEPTION.def: New file.
5794         * gm2-libs/M2EXCEPTION.mod: New file.
5795         * gm2-libs/M2LINK.def: New file.
5796         * gm2-libs/M2RTS.def: New file.
5797         * gm2-libs/M2RTS.mod: New file.
5798         * gm2-libs/MathLib0.def: New file.
5799         * gm2-libs/MathLib0.mod: New file.
5800         * gm2-libs/MemUtils.def: New file.
5801         * gm2-libs/MemUtils.mod: New file.
5802         * gm2-libs/NumberIO.def: New file.
5803         * gm2-libs/NumberIO.mod: New file.
5804         * gm2-libs/OptLib.def: New file.
5805         * gm2-libs/OptLib.mod: New file.
5806         * gm2-libs/PushBackInput.def: New file.
5807         * gm2-libs/PushBackInput.mod: New file.
5808         * gm2-libs/README.texi: New file.
5809         * gm2-libs/RTExceptions.def: New file.
5810         * gm2-libs/RTExceptions.mod: New file.
5811         * gm2-libs/RTint.def: New file.
5812         * gm2-libs/RTint.mod: New file.
5813         * gm2-libs/SArgs.def: New file.
5814         * gm2-libs/SArgs.mod: New file.
5815         * gm2-libs/SCmdArgs.def: New file.
5816         * gm2-libs/SCmdArgs.mod: New file.
5817         * gm2-libs/SEnvironment.def: New file.
5818         * gm2-libs/SEnvironment.mod: New file.
5819         * gm2-libs/SFIO.def: New file.
5820         * gm2-libs/SFIO.mod: New file.
5821         * gm2-libs/SMathLib0.def: New file.
5822         * gm2-libs/SMathLib0.mod: New file.
5823         * gm2-libs/SYSTEM.def: New file.
5824         * gm2-libs/SYSTEM.mod: New file.
5825         * gm2-libs/Scan.def: New file.
5826         * gm2-libs/Scan.mod: New file.
5827         * gm2-libs/Selective.def: New file.
5828         * gm2-libs/StdIO.def: New file.
5829         * gm2-libs/StdIO.mod: New file.
5830         * gm2-libs/Storage.def: New file.
5831         * gm2-libs/Storage.mod: New file.
5832         * gm2-libs/StrCase.def: New file.
5833         * gm2-libs/StrCase.mod: New file.
5834         * gm2-libs/StrIO.def: New file.
5835         * gm2-libs/StrIO.mod: New file.
5836         * gm2-libs/StrLib.def: New file.
5837         * gm2-libs/StrLib.mod: New file.
5838         * gm2-libs/StringConvert.def: New file.
5839         * gm2-libs/StringConvert.mod: New file.
5840         * gm2-libs/SysExceptions.def: New file.
5841         * gm2-libs/SysStorage.def: New file.
5842         * gm2-libs/SysStorage.mod: New file.
5843         * gm2-libs/TimeString.def: New file.
5844         * gm2-libs/TimeString.mod: New file.
5845         * gm2-libs/UnixArgs.def: New file.
5846         * gm2-libs/cbuiltin.def: New file.
5847         * gm2-libs/cgetopt.def: New file.
5848         * gm2-libs/config-host: New file.
5849         * gm2-libs/config-host.in: New file.
5850         * gm2-libs/cxxabi.def: New file.
5851         * gm2-libs/dtoa.def: New file.
5852         * gm2-libs/errno.def: New file.
5853         * gm2-libs/gdbif.def: New file.
5854         * gm2-libs/gdbif.mod: New file.
5855         * gm2-libs/gm2-libs-host.h.in: New file.
5856         * gm2-libs/ldtoa.def: New file.
5857         * gm2-libs/libc.def: New file.
5858         * gm2-libs/libm.def: New file.
5859         * gm2-libs/sckt.def: New file.
5860         * gm2-libs/termios.def: New file.
5861         * gm2-libs/wrapc.def: New file.
5862         * gm2config.h.in: New file.
5863         * gm2spec.cc: New file.
5864         * gm2version.h: New file.
5865         * init/README: New file.
5866         * init/mcinit: New file.
5867         * init/ppginit: New file.
5868         * lang-specs.h: New file.
5869         * lang.opt: New file.
5870         * m2-tree.def: New file.
5871         * m2-tree.h: New file.
5872         * m2.flex: New file.
5873         * m2pp.cc: New file.
5874         * m2pp.h: New file.
5875         * mc-boot-ch/GBuiltins.c: New file.
5876         * mc-boot-ch/GM2LINK.c: New file.
5877         * mc-boot-ch/GRTco.c: New file.
5878         * mc-boot-ch/GSYSTEM.c: New file.
5879         * mc-boot-ch/GSelective.c: New file.
5880         * mc-boot-ch/GSysExceptions.c: New file.
5881         * mc-boot-ch/GUnixArgs.cc: New file.
5882         * mc-boot-ch/Gabort.c: New file.
5883         * mc-boot-ch/Gcbuiltin.c: New file.
5884         * mc-boot-ch/Gdtoa.c: New file.
5885         * mc-boot-ch/Gerrno.c: New file.
5886         * mc-boot-ch/Gldtoa.c: New file.
5887         * mc-boot-ch/Glibc.c: New file.
5888         * mc-boot-ch/Glibm.c: New file.
5889         * mc-boot-ch/Gmcrts.c: New file.
5890         * mc-boot-ch/Gmcrts.h: New file.
5891         * mc-boot-ch/Gnetwork.h: New file.
5892         * mc-boot-ch/Gtermios.cc: New file.
5893         * mc-boot-ch/Gwrapc.c: New file.
5894         * mc-boot-ch/README: New file.
5895         * mc-boot-ch/m2rts.h: New file.
5896         * mc-boot-ch/network.c: New file.
5897         * mc-boot/GASCII.c: New file.
5898         * mc-boot/GASCII.h: New file.
5899         * mc-boot/GArgs.c: New file.
5900         * mc-boot/GArgs.h: New file.
5901         * mc-boot/GAssertion.c: New file.
5902         * mc-boot/GAssertion.h: New file.
5903         * mc-boot/GBreak.c: New file.
5904         * mc-boot/GBreak.h: New file.
5905         * mc-boot/GCOROUTINES.h: New file.
5906         * mc-boot/GCmdArgs.c: New file.
5907         * mc-boot/GCmdArgs.h: New file.
5908         * mc-boot/GDebug.c: New file.
5909         * mc-boot/GDebug.h: New file.
5910         * mc-boot/GDynamicStrings.c: New file.
5911         * mc-boot/GDynamicStrings.h: New file.
5912         * mc-boot/GEnvironment.c: New file.
5913         * mc-boot/GEnvironment.h: New file.
5914         * mc-boot/GFIO.c: New file.
5915         * mc-boot/GFIO.h: New file.
5916         * mc-boot/GFormatStrings.c: New file.
5917         * mc-boot/GFormatStrings.h: New file.
5918         * mc-boot/GFpuIO.c: New file.
5919         * mc-boot/GFpuIO.h: New file.
5920         * mc-boot/GIO.c: New file.
5921         * mc-boot/GIO.h: New file.
5922         * mc-boot/GIndexing.c: New file.
5923         * mc-boot/GIndexing.h: New file.
5924         * mc-boot/GM2Dependent.c: New file.
5925         * mc-boot/GM2Dependent.h: New file.
5926         * mc-boot/GM2EXCEPTION.c: New file.
5927         * mc-boot/GM2EXCEPTION.h: New file.
5928         * mc-boot/GM2LINK.h: New file.
5929         * mc-boot/GM2RTS.c: New file.
5930         * mc-boot/GM2RTS.h: New file.
5931         * mc-boot/GMemUtils.c: New file.
5932         * mc-boot/GMemUtils.h: New file.
5933         * mc-boot/GNumberIO.c: New file.
5934         * mc-boot/GNumberIO.h: New file.
5935         * mc-boot/GPushBackInput.c: New file.
5936         * mc-boot/GPushBackInput.h: New file.
5937         * mc-boot/GRTExceptions.c: New file.
5938         * mc-boot/GRTExceptions.h: New file.
5939         * mc-boot/GRTco.h: New file.
5940         * mc-boot/GRTint.c: New file.
5941         * mc-boot/GRTint.h: New file.
5942         * mc-boot/GSArgs.c: New file.
5943         * mc-boot/GSArgs.h: New file.
5944         * mc-boot/GSFIO.c: New file.
5945         * mc-boot/GSFIO.h: New file.
5946         * mc-boot/GSYSTEM.h: New file.
5947         * mc-boot/GSelective.h: New file.
5948         * mc-boot/GStdIO.c: New file.
5949         * mc-boot/GStdIO.h: New file.
5950         * mc-boot/GStorage.c: New file.
5951         * mc-boot/GStorage.h: New file.
5952         * mc-boot/GStrCase.c: New file.
5953         * mc-boot/GStrCase.h: New file.
5954         * mc-boot/GStrIO.c: New file.
5955         * mc-boot/GStrIO.h: New file.
5956         * mc-boot/GStrLib.c: New file.
5957         * mc-boot/GStrLib.h: New file.
5958         * mc-boot/GStringConvert.c: New file.
5959         * mc-boot/GStringConvert.h: New file.
5960         * mc-boot/GSysExceptions.h: New file.
5961         * mc-boot/GSysStorage.c: New file.
5962         * mc-boot/GSysStorage.h: New file.
5963         * mc-boot/GTimeString.c: New file.
5964         * mc-boot/GTimeString.h: New file.
5965         * mc-boot/GUnixArgs.h: New file.
5966         * mc-boot/Galists.c: New file.
5967         * mc-boot/Galists.h: New file.
5968         * mc-boot/Gdecl.c: New file.
5969         * mc-boot/Gdecl.h: New file.
5970         * mc-boot/Gdtoa.h: New file.
5971         * mc-boot/Gerrno.h: New file.
5972         * mc-boot/Gkeyc.c: New file.
5973         * mc-boot/Gkeyc.h: New file.
5974         * mc-boot/Gldtoa.h: New file.
5975         * mc-boot/Glibc.h: New file.
5976         * mc-boot/Glibm.h: New file.
5977         * mc-boot/Glists.c: New file.
5978         * mc-boot/Glists.h: New file.
5979         * mc-boot/GmcComment.c: New file.
5980         * mc-boot/GmcComment.h: New file.
5981         * mc-boot/GmcComp.c: New file.
5982         * mc-boot/GmcComp.h: New file.
5983         * mc-boot/GmcDebug.c: New file.
5984         * mc-boot/GmcDebug.h: New file.
5985         * mc-boot/GmcError.c: New file.
5986         * mc-boot/GmcError.h: New file.
5987         * mc-boot/GmcFileName.c: New file.
5988         * mc-boot/GmcFileName.h: New file.
5989         * mc-boot/GmcLexBuf.c: New file.
5990         * mc-boot/GmcLexBuf.h: New file.
5991         * mc-boot/GmcMetaError.c: New file.
5992         * mc-boot/GmcMetaError.h: New file.
5993         * mc-boot/GmcOptions.c: New file.
5994         * mc-boot/GmcOptions.h: New file.
5995         * mc-boot/GmcPreprocess.c: New file.
5996         * mc-boot/GmcPreprocess.h: New file.
5997         * mc-boot/GmcPretty.c: New file.
5998         * mc-boot/GmcPretty.h: New file.
5999         * mc-boot/GmcPrintf.c: New file.
6000         * mc-boot/GmcPrintf.h: New file.
6001         * mc-boot/GmcQuiet.c: New file.
6002         * mc-boot/GmcQuiet.h: New file.
6003         * mc-boot/GmcReserved.c: New file.
6004         * mc-boot/GmcReserved.h: New file.
6005         * mc-boot/GmcSearch.c: New file.
6006         * mc-boot/GmcSearch.h: New file.
6007         * mc-boot/GmcStack.c: New file.
6008         * mc-boot/GmcStack.h: New file.
6009         * mc-boot/GmcStream.c: New file.
6010         * mc-boot/GmcStream.h: New file.
6011         * mc-boot/Gmcflex.h: New file.
6012         * mc-boot/Gmcp1.c: New file.
6013         * mc-boot/Gmcp1.h: New file.
6014         * mc-boot/Gmcp2.c: New file.
6015         * mc-boot/Gmcp2.h: New file.
6016         * mc-boot/Gmcp3.c: New file.
6017         * mc-boot/Gmcp3.h: New file.
6018         * mc-boot/Gmcp4.c: New file.
6019         * mc-boot/Gmcp4.h: New file.
6020         * mc-boot/Gmcp5.c: New file.
6021         * mc-boot/Gmcp5.h: New file.
6022         * mc-boot/GnameKey.c: New file.
6023         * mc-boot/GnameKey.h: New file.
6024         * mc-boot/Gpth.h: New file.
6025         * mc-boot/GsymbolKey.c: New file.
6026         * mc-boot/GsymbolKey.h: New file.
6027         * mc-boot/Gtermios.h: New file.
6028         * mc-boot/Gtop.c: New file.
6029         * mc-boot/Gvarargs.c: New file.
6030         * mc-boot/Gvarargs.h: New file.
6031         * mc-boot/Gwlists.c: New file.
6032         * mc-boot/Gwlists.h: New file.
6033         * mc-boot/Gwrapc.h: New file.
6034         * mc-boot/README: New file.
6035         * mc/Indexing.def: New file.
6036         * mc/Indexing.mod: New file.
6037         * mc/README: New file.
6038         * mc/alists.def: New file.
6039         * mc/alists.mod: New file.
6040         * mc/decl.def: New file.
6041         * mc/decl.mod: New file.
6042         * mc/decl.mod-extra: New file.
6043         * mc/keyc.def: New file.
6044         * mc/keyc.mod: New file.
6045         * mc/lists.def: New file.
6046         * mc/lists.mod: New file.
6047         * mc/m2flex.def: New file.
6048         * mc/mc.flex: New file.
6049         * mc/mcComment.def: New file.
6050         * mc/mcComment.h: New file.
6051         * mc/mcComment.mod: New file.
6052         * mc/mcComp.def: New file.
6053         * mc/mcComp.mod: New file.
6054         * mc/mcDebug.def: New file.
6055         * mc/mcDebug.mod: New file.
6056         * mc/mcError.def: New file.
6057         * mc/mcError.mod: New file.
6058         * mc/mcFileName.def: New file.
6059         * mc/mcFileName.mod: New file.
6060         * mc/mcLexBuf.def: New file.
6061         * mc/mcLexBuf.h: New file.
6062         * mc/mcLexBuf.mod: New file.
6063         * mc/mcMetaError.def: New file.
6064         * mc/mcMetaError.mod: New file.
6065         * mc/mcOptions.def: New file.
6066         * mc/mcOptions.mod: New file.
6067         * mc/mcPreprocess.def: New file.
6068         * mc/mcPreprocess.mod: New file.
6069         * mc/mcPretty.def: New file.
6070         * mc/mcPretty.mod: New file.
6071         * mc/mcPrintf.def: New file.
6072         * mc/mcPrintf.mod: New file.
6073         * mc/mcQuiet.def: New file.
6074         * mc/mcQuiet.mod: New file.
6075         * mc/mcReserved.def: New file.
6076         * mc/mcReserved.h: New file.
6077         * mc/mcReserved.mod: New file.
6078         * mc/mcSearch.def: New file.
6079         * mc/mcSearch.mod: New file.
6080         * mc/mcStack.def: New file.
6081         * mc/mcStack.mod: New file.
6082         * mc/mcStream.def: New file.
6083         * mc/mcStream.mod: New file.
6084         * mc/mcflex.def: New file.
6085         * mc/mcp1.bnf: New file.
6086         * mc/mcp1.def: New file.
6087         * mc/mcp2.bnf: New file.
6088         * mc/mcp2.def: New file.
6089         * mc/mcp3.bnf: New file.
6090         * mc/mcp3.def: New file.
6091         * mc/mcp4.bnf: New file.
6092         * mc/mcp4.def: New file.
6093         * mc/mcp5.bnf: New file.
6094         * mc/mcp5.def: New file.
6095         * mc/nameKey.def: New file.
6096         * mc/nameKey.mod: New file.
6097         * mc/symbolKey.def: New file.
6098         * mc/symbolKey.mod: New file.
6099         * mc/top.mod: New file.
6100         * mc/varargs.def: New file.
6101         * mc/varargs.mod: New file.
6102         * mc/wlists.def: New file.
6103         * mc/wlists.mod: New file.
6104         * pge-boot/GASCII.c: New file.
6105         * pge-boot/GASCII.h: New file.
6106         * pge-boot/GArgs.c: New file.
6107         * pge-boot/GArgs.h: New file.
6108         * pge-boot/GAssertion.c: New file.
6109         * pge-boot/GAssertion.h: New file.
6110         * pge-boot/GBreak.h: New file.
6111         * pge-boot/GBuiltins.c: New file.
6112         * pge-boot/GCmdArgs.h: New file.
6113         * pge-boot/GDebug.c: New file.
6114         * pge-boot/GDebug.h: New file.
6115         * pge-boot/GDynamicStrings.c: New file.
6116         * pge-boot/GDynamicStrings.h: New file.
6117         * pge-boot/GEnvironment.h: New file.
6118         * pge-boot/GFIO.c: New file.
6119         * pge-boot/GFIO.h: New file.
6120         * pge-boot/GFormatStrings.h: New file.
6121         * pge-boot/GFpuIO.h: New file.
6122         * pge-boot/GIO.c: New file.
6123         * pge-boot/GIO.h: New file.
6124         * pge-boot/GIndexing.c: New file.
6125         * pge-boot/GIndexing.h: New file.
6126         * pge-boot/GLists.c: New file.
6127         * pge-boot/GLists.h: New file.
6128         * pge-boot/GM2Dependent.c: New file.
6129         * pge-boot/GM2Dependent.h: New file.
6130         * pge-boot/GM2EXCEPTION.c: New file.
6131         * pge-boot/GM2EXCEPTION.h: New file.
6132         * pge-boot/GM2LINK.c: New file.
6133         * pge-boot/GM2LINK.h: New file.
6134         * pge-boot/GM2RTS.c: New file.
6135         * pge-boot/GM2RTS.h: New file.
6136         * pge-boot/GNameKey.c: New file.
6137         * pge-boot/GNameKey.h: New file.
6138         * pge-boot/GNumberIO.c: New file.
6139         * pge-boot/GNumberIO.h: New file.
6140         * pge-boot/GOutput.c: New file.
6141         * pge-boot/GOutput.h: New file.
6142         * pge-boot/GPushBackInput.c: New file.
6143         * pge-boot/GPushBackInput.h: New file.
6144         * pge-boot/GRTExceptions.c: New file.
6145         * pge-boot/GRTExceptions.h: New file.
6146         * pge-boot/GRTco.c: New file.
6147         * pge-boot/GSArgs.h: New file.
6148         * pge-boot/GSEnvironment.h: New file.
6149         * pge-boot/GSFIO.c: New file.
6150         * pge-boot/GSFIO.h: New file.
6151         * pge-boot/GSYSTEM.c: New file.
6152         * pge-boot/GSYSTEM.h: New file.
6153         * pge-boot/GScan.h: New file.
6154         * pge-boot/GSelective.c: New file.
6155         * pge-boot/GStdIO.c: New file.
6156         * pge-boot/GStdIO.h: New file.
6157         * pge-boot/GStorage.c: New file.
6158         * pge-boot/GStorage.h: New file.
6159         * pge-boot/GStrCase.c: New file.
6160         * pge-boot/GStrCase.h: New file.
6161         * pge-boot/GStrIO.c: New file.
6162         * pge-boot/GStrIO.h: New file.
6163         * pge-boot/GStrLib.c: New file.
6164         * pge-boot/GStrLib.h: New file.
6165         * pge-boot/GStringConvert.h: New file.
6166         * pge-boot/GSymbolKey.c: New file.
6167         * pge-boot/GSymbolKey.h: New file.
6168         * pge-boot/GSysExceptions.c: New file.
6169         * pge-boot/GSysExceptions.h: New file.
6170         * pge-boot/GSysStorage.c: New file.
6171         * pge-boot/GSysStorage.h: New file.
6172         * pge-boot/GTimeString.h: New file.
6173         * pge-boot/GUnixArgs.cc: New file.
6174         * pge-boot/GUnixArgs.h: New file.
6175         * pge-boot/Gabort.c: New file.
6176         * pge-boot/Gbnflex.c: New file.
6177         * pge-boot/Gbnflex.h: New file.
6178         * pge-boot/Gcbuiltin.c: New file.
6179         * pge-boot/Gdtoa.c: New file.
6180         * pge-boot/Gdtoa.h: New file.
6181         * pge-boot/Gerrno.c: New file.
6182         * pge-boot/Gerrno.h: New file.
6183         * pge-boot/Gldtoa.c: New file.
6184         * pge-boot/Gldtoa.h: New file.
6185         * pge-boot/Glibc.c: New file.
6186         * pge-boot/Glibc.h: New file.
6187         * pge-boot/Glibm.c: New file.
6188         * pge-boot/Glibm.h: New file.
6189         * pge-boot/Gmcrts.c: New file.
6190         * pge-boot/Gmcrts.h: New file.
6191         * pge-boot/Gnetwork.h: New file.
6192         * pge-boot/Gpge.c: New file.
6193         * pge-boot/Gtermios.cc: New file.
6194         * pge-boot/Gtermios.h: New file.
6195         * pge-boot/Gwrapc.c: New file.
6196         * pge-boot/Gwrapc.h: New file.
6197         * pge-boot/README: New file.
6198         * pge-boot/m2rts.h: New file.
6199         * pge-boot/main.c: New file.
6200         * pge-boot/network.c: New file.
6201         * plugin/README: New file.
6202         * plugin/m2rte.cc: New file.
6203         * tools-src/README: New file.
6204         * tools-src/boilerplate.py: New file.
6205         * tools-src/buildpg: New file.
6206         * tools-src/calcpath: New file.
6207         * tools-src/def2doc.py: New file.
6208         * tools-src/makeSystem: New file.
6209         * tools-src/mklink.c: New file.
6210         * tools-src/tidydates.py: New file.
6211         * images/LICENSE.IMG: New file.
6212         * images/gnupng: New file.
6213         * images/gnu.eps: New file.
6214         * version.c: New file.
6215         * configure: Rebuilt.
6216         * target-independent/Builtins.texi: New file.
6217         * target-independent/SYSTEM-iso.texi: New file.
6218         * target-independent/SYSTEM-pim.texi: New file.
6219         * target-independent/gm2-libs.texi: New file.
6220         * target-independent/readme.txt: New file.