------------------------------------------------------------------------------
-- This package provides the basic computational interface for the generic
--- elementary functions. The C library version interfaces with the routines
--- in the C mathematical library.
+-- elementary functions.
--- This version here is for use with normal Unix math functions.
+-- This version here delegates to interfaces that typically import as
+-- intrinsics the expected math functions.
with Ada.Numerics.Aux_Long_Long_Float;
with Ada.Numerics.Aux_Long_Float;
-- A D A . N U M E R I C S . A U X . L O N G _ L O N G _ F L O A T --
-- --
-- S p e c --
--- (C Math Library Version, Long Long Float) --
+-- (Instrinsic Version, Long Long Float) --
-- --
-- Copyright (C) 1992-2022, Free Software Foundation, Inc. --
-- --
-- --
------------------------------------------------------------------------------
--- This package provides the basic computational interface for the generic
--- elementary functions. The C library version interfaces with the routines
--- in the C mathematical library, and is thus quite portable.
+-- This package provides the basic computational interface for the
+-- generic elementary functions. With the intrinsic version, the
+-- compiler can use its knowledge of the functions to select the most
+-- suitable implementation. It is thus quite portable. These
+-- interfaces are suitable for cases in which Long Long Float and C's
+-- long double share the same representation.
with Ada.Numerics.Aux_Linker_Options;
pragma Warnings (Off, Ada.Numerics.Aux_Linker_Options);
subtype T is Long_Long_Float;
- -- We import these functions directly from C. Note that we label them
+ -- We import these functions as intrinsics. Note that we label them
-- all as pure functions, because indeed all of them are in fact pure.
function Sin (X : T) return T with
-- A D A . N U M E R I C S . A U X _ L O N G _ F L O A T --
-- --
-- S p e c --
--- (C Math Library Version, Long Float) --
+-- (Intrinsic Version, Long Float) --
-- --
-- Copyright (C) 1992-2022, Free Software Foundation, Inc. --
-- --
-- --
------------------------------------------------------------------------------
--- This package provides the basic computational interface for the generic
--- elementary functions. The C library version interfaces with the routines
--- in the C mathematical library, and is thus quite portable.
+-- This package provides the basic computational interface for the
+-- generic elementary functions. With the intrinsic version, the
+-- compiler can use its knowledge of the functions to select the most
+-- suitable implementation. It is thus quite portable. These
+-- interfaces are suitable for cases in which Long Float and C's
+-- double share the same representation.
with Ada.Numerics.Aux_Linker_Options;
pragma Warnings (Off, Ada.Numerics.Aux_Linker_Options);
subtype T is Long_Float;
- -- We import these functions directly from C. Note that we label them
+ -- We import these functions as intrinsics. Note that we label them
-- all as pure functions, because indeed all of them are in fact pure.
function Sin (X : T) return T with
-- A D A . N U M E R I C S . A U X _ F L O A T --
-- --
-- S p e c --
--- (C Math Library Version, Float) --
+-- (Intrinsic Version, Float) --
-- --
-- Copyright (C) 1992-2022, Free Software Foundation, Inc. --
-- --
-- --
------------------------------------------------------------------------------
--- This package provides the basic computational interface for the generic
--- elementary functions. The C library version interfaces with the routines
--- in the C mathematical library, and is thus quite portable.
+-- This package provides the basic computational interface for the
+-- generic elementary functions. With the intrinsic version, the
+-- compiler can use its knowledge of the functions to select the most
+-- suitable implementation. It is thus quite portable. These
+-- interfaces are suitable for cases in which Float and C's float
+-- share the same representation.
with Ada.Numerics.Aux_Linker_Options;
pragma Warnings (Off, Ada.Numerics.Aux_Linker_Options);
subtype T is Float;
- -- We import these functions directly from C. Note that we label them
+ -- We import these functions as intrinsics. Note that we label them
-- all as pure functions, because indeed all of them are in fact pure.
function Sin (X : T) return T with