Development Log in May 2005.

  • GNAT Pro
    May 30th, 2005

    New warning for Ada 2005 compatibility
    Warnings about Ada 2005 compatibility issues (for example the use of new keywords like Interface) are output by default. A new warning option -gnatwY (in VMS this is WARNINGS=NOADA_2005_COMPAIBILITY) can be used to turn these warnings off selectively.

  • GNAT Pro
    May 25th, 2005

    Exponentiation available with aamp5-small library
    On the AAMP target only, the run-time library units that support exponentiation operations are now included in the aamp5-small library.

  • GNAT Pro
    May 25th, 2005

    gnatdll handles non standard file extension
    gnatdll was working only with DLLs having the extension ".dll". It has been enhanced to handle non standard file name extension (like .cpl for example). So gnatdll can now create DLLs or import libraries to bind against DLLs with non standard file name extension.

  • GNAT Pro
    May 25th, 2005

    Output per-function stack usage
    A new GCC switch -fstack-usage has been implemented. It makes the compiler output stack usage information for the program, on a per-function basis, to auxiliary text files that can be easily parsed.

  • GNAT Pro
    May 25th, 2005

    Output per-file call graph info
    A new GCC switch -fcallgraph-info has been implemented. It makes the compiler output callgraph information for the program, on a per-file basis, to auxiliary text files that can be easily parsed or viewed.

  • GNAT Pro
    May 24th, 2005

    Improved Address_To_Access_Conversions
    System.Address_To_Access_Conversions is often used to create access values where the type of the target does not match the access type. Strictly speaking this is incorrect since the access type value is invalid. When compiling at -O2, the compiler may generate code that has unexpected results as a consequence. The official way to deal with this is to use -fno-strict-aliasing, or the corresponding pragma, or better to use unchecked conversion on the target values. The new feature here is that the compiler is now somewhat friendlier in that the unexpected optimization is inhibited by default even in -O2 mode in most common cases of this usage.

  • GNAT Pro
    May 22nd, 2005

    SAL Auto initialization supported on Windows
    Stand Alone Libraries auto initialization is now supported on Windows. There is one restriction, the SAL must not contain a library level task. This is due to a limitation (no thread can be created from the DllMain entry point) imposed by the Windows DLL loader.

  • GNAT Pro
    May 20th, 2005

    Enhanced variants of Non_Blocking_Spawn
    In package GNAT.OS_Lib, two new versions of the function Non_Blocking_Spawn have been added. These functions can redirect the output from the spawned program into either a file descriptor or a file.

  • Ada | Ada 2005 / 95 / 83
    May 20th, 2005

    AI-406 Aliased objects of an anonymous access type
    This extends AI-385 (DC16-079) to allow objects of an anonymous access type to be aliased.

  • Ada | Ada 2005 / 95 / 83
    May 20th, 2005

    AI-385 Stand-alone anonymous access type objects
    This AI extends the use of anonymous access types to object declarations. Previous AI's allowed anonymous access types to appear in renaming declarations and in component declarations.

  • GNAT Pro
    May 18th, 2005

    Better support for signals with tasking
    On Unix systems, when using tasking constructs and no signal handling (e.g. no use of Ada.Interrupts), the default signal behavior is now observed, as was already the case for non tasking applications.

  • Ada | Ada 2005 / 95 / 83
    May 18th, 2005

    AI-195 Streams: ‘Input and initialization
    This AI completes the definition of streams covering the following list of topics:

      1) When the predefined Input attribute creates an object, this object
         undergoes default initialization and finalization.
    
      2) For the purposes of checking legality rules, it is necessary to
         determine whether a stream-oriented attribute has been specified for
         limited type (13.13.2(9/1) and 13.13.2(36/1)). This is done by applying
         the normal visibility rules to the attribute definition clause.
    
      3) For a limited tagged type T, if Read is available then T'Input is
         available, even if it is not specified. Similarly, if Write is available
         then T'Output is available. T'Class'Read, T'Class'Write, T'Class'Input
         and T'Class'Output are available only if they are specified or the
         corresponding specific attribute is available somewhere within the same
         list of declarations as T.
    
      4) The predefined Read attribute for composite types with defaulted
         discriminants ensure that, if exceptions are raised by the Read
         attribute for some discriminant, the discriminants of the actual object
         passed to Read are not modified.
    
      5) The predefined Read attribute for composite types with defaulted
         discriminants raises Constraint_Error if the discriminants found in the
         stream differ from those of the actual parameter to Read, and this
         parameter is constrained.
    
      6) If S is a subtype of an abstract type, an attribute_reference for
         S'Input is illegal.
    

  • GNAT Pro
    May 17th, 2005

    Output per-file callgraph info
    A new GCC switch -fcallgraph-info has been implemented. It makes the compiler output callgraph information for the program, on a per-file basis, to auxiliary text files that can be easily parsed or viewed.

  • Ada | Ada 2005 / 95 / 83
    May 17th, 2005

    AI-404 Not null and all in access parameters
    This AI clarifies some uses of anonymous access types. The qualifier "all" is forbidden in the the declaration of an access parameter or access discriminant. A special check on access parameters that are controlling formals is now required when a dispatching operation renames a non-dispatching operation.

  • Ada | Ada 2005 / 95 / 83
    May 16th, 2005

    AI-344 Nested type extensions
    This AI relaxes the restrictions on type extensions to permit extending a tagged type within nested scopes, such as within subprograms, tasks and block statements. Checks on class-wide allocators, functions results and stream attributes prevent the creation of dangling references to objects of deeper types. The AI also introduces two new predefined operations in Ada.Tags, Descendant_Tag and Is_Descendant_At_Same_Level, to support checking within user-defined class-wide stream attributes.

  • Ada | Ada 2005 / 95 / 83
    May 15th, 2005

    AI-411 Equality for types derived from interfaces
    This AI is a discussion of wording only, and confirmation that every interface has an equality operation that is not abstract, and therefore does not need to be overridden by a type that implements a given interface.

  • Ada | Ada 2005 / 95 / 83
    May 15th, 2005

    AI-399 Task/protected implementing interfaces
    Allow the use of single task and single protected objects implementing interfaces. AI-345 only allows a task or protected *type* to implement interfaces and this considered an unnecessary restriction because there is no reason to make single task or protected objects less functional than types. This is especially important if users want to take advantage of interfaces in existing code.

  • Ada | Ada 2005 / 95 / 83
    May 15th, 2005

    AI-362 Recategorization of packages
    This AI recategorizes several packages as follows:

     Ada.Asynchronous_Task_Control is declared preelaborated.
     Ada.Characters.Handling is declared pure.
     Ada.Dynamic_Priorities is declared preelaborated.
     Ada.Exceptions is declared preelaborated.
     Ada.Strings.Maps is declared pure.
     Ada.Strings.Maps.Constants is declared pure.
     Ada.Synchronous_Task_Control is declared preelaborated.
     Ada.Tags is declared preelaborated.
     Ada.Task_Identification is declared preelaborated.
     System is declared pure.
     System.Storage_Elements is declared pure.
    
    
    The last two cases are allowed in Ada 95, and have always been categorized as Pure in GNAT. The others are recategorized as shown (only in Ada 2005 mode).

  • Ada | Ada 2005 / 95 / 83
    May 12th, 2005

    AI-407 Terminology and semantics of prefixed views
    This AI clarifies the description of the Object.Op notation as described in AI-252. It adds a legality rule (already implemented as part of AI-252) that the prefixed view of such notation must be a variable if the operation has an out, in-out or access-to-variable first parameter.

  • Ada | Ada 2005 / 95 / 83
    May 12th, 2005

    AI-363 Eliminating access types problems
    This AI disallows access subtypes for general access types that have defaults for their discriminants, or for any access type that completes a private view that has no discriminants. This allows for unconstrained heap objects, when the private view has no discriminants. Previously, if such a type was completed by a discriminated type with defaults, objects of the type could be freely assigned to each other, but if the objects were heap-allocated they had to be treated as constrained, and assignments would fail. This AI makes it possible to have heap-allocated objects for which a full assignment can change the value of the discriminant. Also, aliased objects and components can now generally be declared unconstrained when their type has defaulted discriminants, and such objects, which were constrained by their initial value in Ada 95, are now mutable.

  • GNAT Pro
    May 10th, 2005

    New restriction Max_Entry_Queue_Length
    This restriction defines the maximum number of calls that can be queued on an entry. Violation of this restriction results in the raising of Program_Error at the point of the call. This replaces restriction Max_Entry_Queue_Depth. The new form is the one intended to be standardized in the new revision of Ada. The form Max_Entry_Queue_Depth. is retained as a synonym for back compatibility with older versions of GNAT.

  • GNAT Pro
    May 9th, 2005

    Backtrace support for x86_64 linux
    Added support for both symbolic and non-symbolic backtraces, including backtraces on exception occurrences, for x86_64 linux targets.

  • GNAT Pro
    May 9th, 2005

    Map signals into exceptions on x86_64-linux
    Added the required machinery for translating signals (SIGSEGV, SIGFPE, etc.) into their corresponding Ada exceptions on x86_64 linux targets.

  • GNAT Pro
    May 9th, 2005

    Better exception support on Linux
    Added the required support for unwinding more reliably through signal handlers in linux distributions with recent versions of NPTL. It allows exception propagation through signal handlers when using the zero cost exception mechanism.

  • GNAT Pro
    May 9th, 2005

    New constant Sockets.Broadcast_Inet_Addr
    A new constant for type GNAT.Sockets.Inet_Addr_Type has been added to GNAT.Sockets, corresponding to the standard broadcast address 255.255.255.255.

  • Ada | Ada 2005 / 95 / 83
    May 7th, 2005

    AI-366 Relaxed rules for pure access types
    In Ada 2005, access-to-subprogram types can be declared freely in pure packages. In addition access-to-object types can also be declared in pure packages if they have no associated storage pool (the result of a Storage_Size clause specifying a zero collection size). The AI also notes that access types in generic formal parts are allowed, but these have always been allowed in GNAT.

  • Ada | Ada 2005 / 95 / 83
    May 6th, 2005

    AI-345 Protected and task interfaces
    This AI allows the use of interfaces with protected and task types. The primitive operations of the interfaces are inherited by the protected or task type. The overriding of the interface primitives is performed in the usual way, by declaring overriding primitives of the protected or task type, or by declaring entries or protected subprograms that override the primitive of the interface once it has been transformed into a "prefix" notation (AI-252).

  • Ada | Ada 2005 / 95 / 83
    May 6th, 2005

    AI-303 No library-level interrupt handler check
    The Ada 95 RM explicit forbids protected objects that contain interrupt handlers to be declared at other than library level. This AI notes that this rule is redundant, because accessibility rules are already sufficient to make the use of such protected objects illegal. The corresponding sentence has been removed from the RM, and no error message is produced for the object declaration by itself.

  • Ada | Ada 2005 / 95 / 83
    May 6th, 2005

    AI-286 Assert and Assertion_Policy pragmas
    The Ada 2005 form of the Assert pragma is upwards compatible with the form implemented by GNAT. The only addition is the optional pragma argument identifiers (Check and Message). The Assertion_Policy pragma allows control of whether Assert pragmas at the source level.

  • Ada | Ada 2005 / 95 / 83
    May 6th, 2005

    AI-251 Abstract interface types
    Ada 2005 adds "interface" types to the standard as a kind of componentless abstract tagged type. A tagged type may be derived from one or more such interfaces as well as possibly from one tagged type; this provides a limited form of multiple inheritance. Dispatching calls through the primitives of an interface dispatch to code bodies associated with specific tagged types that are derived from that interface.

  • GNAT Pro
    May 3rd, 2005

    Check for improper use of Inline_Always
    The use of 'Address or 'Access on a subprogram that is marked with pragma Inline_Always makes no sense, since the objective of this pragma is to allow the body of the subprogram to be eliminated. A check is now made for such improper usages.

  • Ada | Ada 2005 / 95 / 83
    May 2nd, 2005

    AI-241 Testing for null exception occurrence
    The original Ada 95 RM specifies that a call to function Exeption_Identity in da.Exceptions must raise Constraint_Error if the argument is the null occurrence. This means that this function cannot conveniently be used to test for the null occurrence. This AI requires that in Ada 2005 (and also in amended Ada 95), such call returns Null_Id instead of raising an exception.