CVS difference for ai12s/ai12-0135-1.txt

Differences between 1.5 and version 1.6
Log of other versions for file ai12s/ai12-0135-1.txt

--- ai12s/ai12-0135-1.txt	2015/02/25 23:02:19	1.5
+++ ai12s/ai12-0135-1.txt	2015/02/27 01:49:26	1.6
@@ -1,7 +1,9 @@
-!standard B.1(14/3)                             15-02-25   AI12-0135-1/03
+!standard B.1(14/3)                             15-02-26   AI12-0135-1/04
 !standard B.1(41/3)
-!standard B.3(65/3)
-!class Amendment 14-10-09
+!standard B.3(65)
+!class binding interpretation 15-02-26
+!status Corrigendum 2015 15-02-26
+!status ARG Approved 10-0-0  15-02-26
 !status work item 14-10-09
 !status work item 15-01-26
 !status received 14-08-18
@@ -16,19 +18,20 @@
 More detailed requirements exist for mapping Ada enumeration types to C/C++
 enum types.
 
-!problem
+!question
 
-It is convenient to map C enumeration types to Ada enumeration
-types. However, enumeration types are not eligible for
-convention C. An implementation can allow enumeration types
-to have convention C via B.1(20), but this depends on the
-implementer, and thus impacts portability.
+It is convenient to map C enumeration types to Ada enumeration types. However,
+enumeration types are not eligible for convention C. An implementation can
+allow enumeration types to have convention C via B.1(20), but this depends
+on the implementer, and thus impacts portability. Should Ada provide this
+capability? (Yes.)
 
-!proposal
+!recommendation
 
-Require support for interfacing with Ada enumeration types, so long as
+Suggest support for interfacing with Ada enumeration types, so long as
 the number of internal codes is within some implementation defined range.
-Impose more detailed requirements for C/C++.
+Impose more detailed requirements for C/C++. (That is, include it in
+the Implementation Advice at the end of B.1.)
 
 !wording
 
@@ -46,9 +49,9 @@
 
 Add after B.3(65):
 
-  * An Ada enumeration type corresponds to a C enumeration type with the
-    same enumeration literals having the same internal codes, provided the
-    internal codes fall within the range of the C int type.
+  * An Ada enumeration type corresponds to a C enumeration type with
+    corresponding enumeration literals having the same internal codes,
+    provided the internal codes fall within the range of the C int type.
 
 !discussion
 
@@ -73,11 +76,51 @@
 the C requirement.  C++ is more flexible, but there seems no reason to specify
 additional requirements for C++ interfacing.
 
+!corrigendum B.1(14/3)
+
+@dinsa
+@xbullet<Convention @i<L> has been specified for T, and T is @i<eligible for
+convention> @i<L>; that is:>
+@dinst
+@xinbull<T is an enumeration type such that all internal codes (whether assigned
+by default or explicitly) are within an implementation-defined range
+that includes at least the range of values 0 .. 2**15-1;>
+
+!corrigendum B.1(41/3)
+
+@drepl
+For each supported convention @i<L> other than Intrinsic, an implementation
+should support specifying the Import and Export aspects for objects of
+@i<L>-compatible types and for subprograms, and the Convention aspect for
+@i<L>-eligible types and for subprograms, presuming the other language has
+corresponding features. Specifying the Convention aspect need not be supported
+for scalar types. 
+@dby
+For each supported convention @i<L> other than Intrinsic, an implementation
+should support specifying the Import and Export aspects for objects of
+@i<L>-compatible types and for subprograms, and the Convention aspect for
+@i<L>-eligible types and for subprograms, presuming the other language has
+corresponding features. Specifying the Convention aspect need not be supported
+for scalar types, other than enumeration types whose internal codes fall within
+the range 0 .. 2**15-1. 
+
+!corrigendum B.3(65)
+
+@dinsa
+@xbullet<An Ada function corresponds to a non-void C function.>
+@dinst
+@xbullet<An Ada enumeration type corresponds to a C enumeration type with
+corresponding enumeration literals having the same internal codes,
+provided the internal codes fall within the range of the C int type.>
+
 !ASIS
 
 No impact.
 
 !ACATS test
+
+An ACATS test that convention C is accepted and works with some C code is
+possible.
 
 !appendix
 

Questions? Ask the ACAA Technical Agent