1165 Commits

Author SHA1 Message Date
Vadim Godunko
a7bf353161 Use overlay object to convert simple types. 2025-01-24 16:39:26 +04:00
Piotr Trojanek
8af3b9bfa1 Remove obsolete use of renamed Ada 83 package
Change use of Unchecked_Deallocation (which is obsolete since Ada 95) to
Ada.Unchecked_Deallocation to avoid warnings recently enabled in GNAT.

TN: V209-051
Change-Id: I58f1499218c1f132773892308e3d082f3cc52375
2022-06-10 11:35:55 +02:00
Vadim Godunko
8d94ecfee6 UC16-012 Generate pragma Warning to turn off warnings...
... about unnecessary with of ancestor package.

Change-Id: If8b6919e26b0a71290f899a09de6598cc7bc3e98
2021-12-31 00:05:48 +03:00
Vadim Godunko
09ce7d1465 UC16-012 Remove unnecessary pragma Unreferenced.
Change encoding of the files to UTF-8 to pass precommit check.

Change-Id: I45a5a795c6b131edfa0f6f16be84ab6a4bb502e5
2021-12-23 12:49:14 +03:00
Pascal Obry
909df49afa Remove superfluous with clauses.
Also kill redundant check for generated code from IDL.

This fixes compilation due to:

   warning: unnecessary with of ancestor [-gnatwr]

Change-Id: Iec9f29cdcc033afb4ba3d6f32d8aff7aacec6cfd
2021-12-15 11:36:46 +00:00
Dmitriy Anisimkov
338178acc1 Use project to build gnatdist
More convenient to use from an IDE

[changelog]

* compilers/gnatdist/gnatdist.gpr:
New project file.

* Makefile.in:
Use gnatdist.gpr to build gnatdist.

TN: U504-051
Change-Id: I9353267b4e708ccfd106e86b0c3e30b9336758ca
2021-06-05 16:31:53 +06:00
Eric Botcazou
f8504c3311 Fix build failure of PolyORB with GCC 11
This makes the test for introductory markers present in the preprocessed
output more robust.

[changelog]
	* compilers/iac/lexer.adb (Scan_Preprocessor_Directive): Skip all
	markers starting with line #0 in addition to special file names.

TN: U531-008
Change-Id: If5ee372bb662addf1b28054634604696e21ac7c5
2021-05-31 18:26:43 +02:00
Arnaud Charlet
93c3907c2d Convert make_nodes.py to python 3
And keep it compatible with python 2

TN: TC17-010
Change-Id: I8c949bb8a916508e01c59dee340dbf4fc9de6c12
2020-12-17 09:57:59 +01:00
Vadim Godunko
d81adbfd19 T825-011 Use Unchecked_Access to prevent fail of accessibility level checks
... in user's code.

Change-Id: Ifb9757f7f1e2ba1275e5e4d1594130252e9e3244
2020-09-01 17:17:02 +03:00
Vadim Godunko
81abc61a2d T816-068 Increase max number of character in file of predefined units 2020-08-14 16:27:57 -04:00
Thomas Quinot
1fb1ba89d5 Minor reformatting 2019-11-18 12:29:19 +01:00
Dmitriy Anisimkov
9fcf611a25 Minor comments and formatting improvement 2019-10-29 09:36:06 +01:00
Bob Duff
9f1fd57d25 Disable new warning on allocators with anonymous access type
We might want to fix this in a "better" way someday (moving to named
access types).

Fixes S325-042
2019-06-06 16:41:36 +02:00
Thomas Quinot
8630a90f08 Add support for relocatable starter
Allow partition location to be specified as a relative directory
and resolved at run time relative to the location of the starter.
This allows the starter and partition binaries to be moved around.

RA26-001
2018-11-20 10:17:02 +01:00
Oliver Kellogg
fba4400ec8 Merge remote-tracking branch 'upstream/master' 2018-07-14 01:57:32 +02:00
Thomas Quinot
36fd19d14c Fix regression caused by annotation application change
Skip_Annapp_Scan_Token must delegate error reporting to Scan_Token
for the error location to be properly displayed.
2018-07-11 11:06:26 +02:00
Oliver Kellogg
93153c2cd3 https://github.com/AdaCore/PolyORB/pull/1
- Move handling of annotation applications from lexer to parser:

compilers/iac/lexer.adb
- In procedure Scan_Token (Fatal : Boolean) case-statement decoding
  Buffer (Token_Location.Scan), reduce handling of '@' to just assign
  T_At to Token, i.e. do not advance the scan location over the
  annotation application.

compilers/iac/parser.adb
- New procedure Skip_Annapp_Scan_Token (T : Token_Type := T_Error) is
  similar to Scan_Token but skips any annotation applications that may
  exist at the scanner's current location.
  The optional parameter T is the expected token type.
  If left at its default (T_Error), no specific token type is expected.
- New procedure Skip_Annapp_Scan_Token (State : in out Location) is
  similar to the above but updates the given scanner state on skipping
  annotation applications.
- New function Skip_Annapp_Next_Token return Token_Type is similar to
  Next_Token but skip any annotation applications that may exist at the
  scanner's current location, advancing the scan location while this is
  the case.
- In function P_Attribute_Declaration replace initial Scan_Token call
  by Skip_Annapp_Scan_Token.
- In function P_Constant_Expression fix comment in loop `while not
  Is_Expression_Completed'.
- In function P_Definition replace initial Scan_Token call by
  Skip_Annapp_Scan_Token (State).
- In function P_Identifier replace call to Scan_Token (T_Identifier) by
  Skip_Annapp_Scan_Token (T_Identifier).
- In function P_Operation_Declaration replace initial calls to
  Scan_Token by calls to Skip_Annapp_Scan_Token (State).
- In function P_Simple_Type_Spec replace initial Next_Token call by
  Skip_Annapp_Next_Token.
- In function P_State_Member replace initial Scan_Token call by
  Skip_Annapp_Scan_Token (State).

testsuite/idls/annapp01/tin.idl
testsuite/idls/annapp01/test.out
testsuite/idls/MANIFEST
- Start testing annotation applications.
2018-06-18 10:22:09 +02:00
Thomas Quinot
034c14a9f1 Switch to Ada 2012 mode for compatibility with GNAT Community 2018 2018-06-14 12:04:05 +02:00
Oliver Kellogg
0df933e21d Followup to commit 2b691e0 (make IAC ignore IDL4 annotations):
Address review comment at https://github.com/AdaCore/PolyORB/pull/1,
> [...] the part between parentheses in an annotation application is a
> <const_expr>, which may itself contain nested parentheses.

compilers/iac/lexer.adb
- In procedure Scan_Token (Fatal : Boolean) case-statement decoding
  Buffer (Token_Location.Scan), at handling of '@' followed by '(',
  new counter `Parentheses' keeps track of opening/closing parentheses
  to account for embedded parentheses in the loop which skips to the
  ending ')' of the annotation application.
2018-05-31 11:47:48 +02:00
Oliver Kellogg
2b691e0b96 Make IAC ignore IDL4 annotation applications:
compilers/iac/lexer.ads
- In Token_Type add T_At.

compilers/iac/lexer.adb
- In procedure Process, in then-part of `if not Initialized' add call
    New_Token (T_At, "@");
- In procedure Scan_Token (Fatal : Boolean) case-statement decoding
  Buffer (Token_Location.Scan) add handling of '@':
  - If the following token is an identifier then skip the identifier
    and whitespace that may follow it; if the following token is '('
    then seek ')' and increment Token_Location.Scan to the index after
    the ')'.  Do not modify the value of Token.
  - Otherwise set Token to T_At.
2018-05-26 22:30:16 +02:00
Thomas Quinot
dfc0063cdb Remove useless "use type" clause in Helpers generated code
Followup on PA07-083

Subversion-branch: /trunk/polyorb
Subversion-revision: 259585
2018-01-03 11:39:12 +00:00
Bob Duff
64656024e2 fix warnings, no-tn-check
Subversion-branch: /trunk/polyorb
Subversion-revision: 257789
2017-09-18 20:51:56 +00:00
squirek
aa8c9b0259 Remove ineffective use clauses as per PA07-083 and disable some checks
for
unused entities (-gnatwu) due to generated code violating this warning.

Subversion-branch: /trunk/polyorb
Subversion-revision: 257360
2017-08-29 15:13:55 +00:00
Bob Duff
eac8338f79 The IDL-to-Ada compiler iac now ignores pragma javaPackage, as requested
by a customer. This is a convenience for those also using idlj
(idl-to-java), because idlj recognizes that pragma.

Fixes Q621-023

Subversion-branch: /trunk/polyorb
Subversion-revision: 257245
2017-08-11 21:00:17 +00:00
Thomas Quinot
f6b1d049af Remove unnecessary use-type and use-package clauses
These redundant clauses will be flagged by the compiler in the near
future (PA07-083).

Q725-034

Subversion-branch: /trunk/polyorb
Subversion-revision: 257110
2017-08-02 08:40:59 +00:00