content
stringlengths
23
1.05M
pragma Style_Checks (Off); -- This spec has been automatically generated from ATSAMD51G19A.svd pragma Restrictions (No_Elaboration_Code); with HAL; with System; package SAM_SVD.RTC is pragma Preelaborate; --------------- -- Registers -- --------------- ---------------------------------- -- RtcMode0 cluster's Registers -- ---------------------------------- -- Operating Mode type CTRLA_MODESelect is (-- Mode 0: 32-bit Counter COUNT32, -- Mode 1: 16-bit Counter COUNT16, -- Mode 2: Clock/Calendar CLOCK) with Size => 2; for CTRLA_MODESelect use (COUNT32 => 0, COUNT16 => 1, CLOCK => 2); -- Prescaler type CTRLA_PRESCALERSelect is (-- CLK_RTC_CNT = GCLK_RTC/1 OFF, -- CLK_RTC_CNT = GCLK_RTC/1 DIV1, -- CLK_RTC_CNT = GCLK_RTC/2 DIV2, -- CLK_RTC_CNT = GCLK_RTC/4 DIV4, -- CLK_RTC_CNT = GCLK_RTC/8 DIV8, -- CLK_RTC_CNT = GCLK_RTC/16 DIV16, -- CLK_RTC_CNT = GCLK_RTC/32 DIV32, -- CLK_RTC_CNT = GCLK_RTC/64 DIV64, -- CLK_RTC_CNT = GCLK_RTC/128 DIV128, -- CLK_RTC_CNT = GCLK_RTC/256 DIV256, -- CLK_RTC_CNT = GCLK_RTC/512 DIV512, -- CLK_RTC_CNT = GCLK_RTC/1024 DIV1024) with Size => 4; for CTRLA_PRESCALERSelect use (OFF => 0, DIV1 => 1, DIV2 => 2, DIV4 => 3, DIV8 => 4, DIV16 => 5, DIV32 => 6, DIV64 => 7, DIV128 => 8, DIV256 => 9, DIV512 => 10, DIV1024 => 11); -- MODE0 Control A type RTC_CTRLA_RTC_MODE0_Register is record -- Software Reset SWRST : Boolean := False; -- Enable ENABLE : Boolean := False; -- Operating Mode MODE : CTRLA_MODESelect := SAM_SVD.RTC.COUNT32; -- unspecified Reserved_4_6 : HAL.UInt3 := 16#0#; -- Clear on Match MATCHCLR : Boolean := False; -- Prescaler PRESCALER : CTRLA_PRESCALERSelect := SAM_SVD.RTC.OFF; -- unspecified Reserved_12_12 : HAL.Bit := 16#0#; -- BKUP Registers Reset On Tamper Enable BKTRST : Boolean := False; -- GP Registers Reset On Tamper Enable GPTRST : Boolean := False; -- Count Read Synchronization Enable COUNTSYNC : Boolean := False; end record with Volatile_Full_Access, Object_Size => 16, Bit_Order => System.Low_Order_First; for RTC_CTRLA_RTC_MODE0_Register use record SWRST at 0 range 0 .. 0; ENABLE at 0 range 1 .. 1; MODE at 0 range 2 .. 3; Reserved_4_6 at 0 range 4 .. 6; MATCHCLR at 0 range 7 .. 7; PRESCALER at 0 range 8 .. 11; Reserved_12_12 at 0 range 12 .. 12; BKTRST at 0 range 13 .. 13; GPTRST at 0 range 14 .. 14; COUNTSYNC at 0 range 15 .. 15; end record; -- Debounce Freqnuency type CTRLB_DEBFSelect is (-- CLK_RTC_DEB = CLK_RTC/2 DIV2, -- CLK_RTC_DEB = CLK_RTC/4 DIV4, -- CLK_RTC_DEB = CLK_RTC/8 DIV8, -- CLK_RTC_DEB = CLK_RTC/16 DIV16, -- CLK_RTC_DEB = CLK_RTC/32 DIV32, -- CLK_RTC_DEB = CLK_RTC/64 DIV64, -- CLK_RTC_DEB = CLK_RTC/128 DIV128, -- CLK_RTC_DEB = CLK_RTC/256 DIV256) with Size => 3; for CTRLB_DEBFSelect use (DIV2 => 0, DIV4 => 1, DIV8 => 2, DIV16 => 3, DIV32 => 4, DIV64 => 5, DIV128 => 6, DIV256 => 7); -- Active Layer Freqnuency type CTRLB_ACTFSelect is (-- CLK_RTC_OUT = CLK_RTC/2 DIV2, -- CLK_RTC_OUT = CLK_RTC/4 DIV4, -- CLK_RTC_OUT = CLK_RTC/8 DIV8, -- CLK_RTC_OUT = CLK_RTC/16 DIV16, -- CLK_RTC_OUT = CLK_RTC/32 DIV32, -- CLK_RTC_OUT = CLK_RTC/64 DIV64, -- CLK_RTC_OUT = CLK_RTC/128 DIV128, -- CLK_RTC_OUT = CLK_RTC/256 DIV256) with Size => 3; for CTRLB_ACTFSelect use (DIV2 => 0, DIV4 => 1, DIV8 => 2, DIV16 => 3, DIV32 => 4, DIV64 => 5, DIV128 => 6, DIV256 => 7); -- MODE0 Control B type RTC_CTRLB_RTC_MODE0_Register is record -- General Purpose 0 Enable GP0EN : Boolean := False; -- General Purpose 2 Enable GP2EN : Boolean := False; -- unspecified Reserved_2_3 : HAL.UInt2 := 16#0#; -- Debouncer Majority Enable DEBMAJ : Boolean := False; -- Debouncer Asynchronous Enable DEBASYNC : Boolean := False; -- RTC Output Enable RTCOUT : Boolean := False; -- DMA Enable DMAEN : Boolean := False; -- Debounce Freqnuency DEBF : CTRLB_DEBFSelect := SAM_SVD.RTC.DIV2; -- unspecified Reserved_11_11 : HAL.Bit := 16#0#; -- Active Layer Freqnuency ACTF : CTRLB_ACTFSelect := SAM_SVD.RTC.DIV2; -- unspecified Reserved_15_15 : HAL.Bit := 16#0#; end record with Volatile_Full_Access, Object_Size => 16, Bit_Order => System.Low_Order_First; for RTC_CTRLB_RTC_MODE0_Register use record GP0EN at 0 range 0 .. 0; GP2EN at 0 range 1 .. 1; Reserved_2_3 at 0 range 2 .. 3; DEBMAJ at 0 range 4 .. 4; DEBASYNC at 0 range 5 .. 5; RTCOUT at 0 range 6 .. 6; DMAEN at 0 range 7 .. 7; DEBF at 0 range 8 .. 10; Reserved_11_11 at 0 range 11 .. 11; ACTF at 0 range 12 .. 14; Reserved_15_15 at 0 range 15 .. 15; end record; -- RTC_EVCTRL_RTC_MODE0_PEREO array type RTC_EVCTRL_RTC_MODE0_PEREO_Field_Array is array (0 .. 7) of Boolean with Component_Size => 1, Size => 8; -- Type definition for RTC_EVCTRL_RTC_MODE0_PEREO type RTC_EVCTRL_RTC_MODE0_PEREO_Field (As_Array : Boolean := False) is record case As_Array is when False => -- PEREO as a value Val : HAL.UInt8; when True => -- PEREO as an array Arr : RTC_EVCTRL_RTC_MODE0_PEREO_Field_Array; end case; end record with Unchecked_Union, Size => 8; for RTC_EVCTRL_RTC_MODE0_PEREO_Field use record Val at 0 range 0 .. 7; Arr at 0 range 0 .. 7; end record; -- RTC_EVCTRL_RTC_MODE0_CMPEO array type RTC_EVCTRL_RTC_MODE0_CMPEO_Field_Array is array (0 .. 1) of Boolean with Component_Size => 1, Size => 2; -- Type definition for RTC_EVCTRL_RTC_MODE0_CMPEO type RTC_EVCTRL_RTC_MODE0_CMPEO_Field (As_Array : Boolean := False) is record case As_Array is when False => -- CMPEO as a value Val : HAL.UInt2; when True => -- CMPEO as an array Arr : RTC_EVCTRL_RTC_MODE0_CMPEO_Field_Array; end case; end record with Unchecked_Union, Size => 2; for RTC_EVCTRL_RTC_MODE0_CMPEO_Field use record Val at 0 range 0 .. 1; Arr at 0 range 0 .. 1; end record; -- MODE0 Event Control type RTC_EVCTRL_RTC_MODE0_Register is record -- Periodic Interval 0 Event Output Enable PEREO : RTC_EVCTRL_RTC_MODE0_PEREO_Field := (As_Array => False, Val => 16#0#); -- Compare 0 Event Output Enable CMPEO : RTC_EVCTRL_RTC_MODE0_CMPEO_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_10_13 : HAL.UInt4 := 16#0#; -- Tamper Event Output Enable TAMPEREO : Boolean := False; -- Overflow Event Output Enable OVFEO : Boolean := False; -- Tamper Event Input Enable TAMPEVEI : Boolean := False; -- unspecified Reserved_17_31 : HAL.UInt15 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for RTC_EVCTRL_RTC_MODE0_Register use record PEREO at 0 range 0 .. 7; CMPEO at 0 range 8 .. 9; Reserved_10_13 at 0 range 10 .. 13; TAMPEREO at 0 range 14 .. 14; OVFEO at 0 range 15 .. 15; TAMPEVEI at 0 range 16 .. 16; Reserved_17_31 at 0 range 17 .. 31; end record; -- RTC_INTENCLR_RTC_MODE0_PER array type RTC_INTENCLR_RTC_MODE0_PER_Field_Array is array (0 .. 7) of Boolean with Component_Size => 1, Size => 8; -- Type definition for RTC_INTENCLR_RTC_MODE0_PER type RTC_INTENCLR_RTC_MODE0_PER_Field (As_Array : Boolean := False) is record case As_Array is when False => -- PER as a value Val : HAL.UInt8; when True => -- PER as an array Arr : RTC_INTENCLR_RTC_MODE0_PER_Field_Array; end case; end record with Unchecked_Union, Size => 8; for RTC_INTENCLR_RTC_MODE0_PER_Field use record Val at 0 range 0 .. 7; Arr at 0 range 0 .. 7; end record; -- RTC_INTENCLR_RTC_MODE0_CMP array type RTC_INTENCLR_RTC_MODE0_CMP_Field_Array is array (0 .. 1) of Boolean with Component_Size => 1, Size => 2; -- Type definition for RTC_INTENCLR_RTC_MODE0_CMP type RTC_INTENCLR_RTC_MODE0_CMP_Field (As_Array : Boolean := False) is record case As_Array is when False => -- CMP as a value Val : HAL.UInt2; when True => -- CMP as an array Arr : RTC_INTENCLR_RTC_MODE0_CMP_Field_Array; end case; end record with Unchecked_Union, Size => 2; for RTC_INTENCLR_RTC_MODE0_CMP_Field use record Val at 0 range 0 .. 1; Arr at 0 range 0 .. 1; end record; -- MODE0 Interrupt Enable Clear type RTC_INTENCLR_RTC_MODE0_Register is record -- Periodic Interval 0 Interrupt Enable PER : RTC_INTENCLR_RTC_MODE0_PER_Field := (As_Array => False, Val => 16#0#); -- Compare 0 Interrupt Enable CMP : RTC_INTENCLR_RTC_MODE0_CMP_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_10_13 : HAL.UInt4 := 16#0#; -- Tamper Enable TAMPER : Boolean := False; -- Overflow Interrupt Enable OVF : Boolean := False; end record with Volatile_Full_Access, Object_Size => 16, Bit_Order => System.Low_Order_First; for RTC_INTENCLR_RTC_MODE0_Register use record PER at 0 range 0 .. 7; CMP at 0 range 8 .. 9; Reserved_10_13 at 0 range 10 .. 13; TAMPER at 0 range 14 .. 14; OVF at 0 range 15 .. 15; end record; -- RTC_INTENSET_RTC_MODE0_PER array type RTC_INTENSET_RTC_MODE0_PER_Field_Array is array (0 .. 7) of Boolean with Component_Size => 1, Size => 8; -- Type definition for RTC_INTENSET_RTC_MODE0_PER type RTC_INTENSET_RTC_MODE0_PER_Field (As_Array : Boolean := False) is record case As_Array is when False => -- PER as a value Val : HAL.UInt8; when True => -- PER as an array Arr : RTC_INTENSET_RTC_MODE0_PER_Field_Array; end case; end record with Unchecked_Union, Size => 8; for RTC_INTENSET_RTC_MODE0_PER_Field use record Val at 0 range 0 .. 7; Arr at 0 range 0 .. 7; end record; -- RTC_INTENSET_RTC_MODE0_CMP array type RTC_INTENSET_RTC_MODE0_CMP_Field_Array is array (0 .. 1) of Boolean with Component_Size => 1, Size => 2; -- Type definition for RTC_INTENSET_RTC_MODE0_CMP type RTC_INTENSET_RTC_MODE0_CMP_Field (As_Array : Boolean := False) is record case As_Array is when False => -- CMP as a value Val : HAL.UInt2; when True => -- CMP as an array Arr : RTC_INTENSET_RTC_MODE0_CMP_Field_Array; end case; end record with Unchecked_Union, Size => 2; for RTC_INTENSET_RTC_MODE0_CMP_Field use record Val at 0 range 0 .. 1; Arr at 0 range 0 .. 1; end record; -- MODE0 Interrupt Enable Set type RTC_INTENSET_RTC_MODE0_Register is record -- Periodic Interval 0 Interrupt Enable PER : RTC_INTENSET_RTC_MODE0_PER_Field := (As_Array => False, Val => 16#0#); -- Compare 0 Interrupt Enable CMP : RTC_INTENSET_RTC_MODE0_CMP_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_10_13 : HAL.UInt4 := 16#0#; -- Tamper Enable TAMPER : Boolean := False; -- Overflow Interrupt Enable OVF : Boolean := False; end record with Volatile_Full_Access, Object_Size => 16, Bit_Order => System.Low_Order_First; for RTC_INTENSET_RTC_MODE0_Register use record PER at 0 range 0 .. 7; CMP at 0 range 8 .. 9; Reserved_10_13 at 0 range 10 .. 13; TAMPER at 0 range 14 .. 14; OVF at 0 range 15 .. 15; end record; -- RTC_INTFLAG_RTC_MODE0_PER array type RTC_INTFLAG_RTC_MODE0_PER_Field_Array is array (0 .. 7) of Boolean with Component_Size => 1, Size => 8; -- Type definition for RTC_INTFLAG_RTC_MODE0_PER type RTC_INTFLAG_RTC_MODE0_PER_Field (As_Array : Boolean := False) is record case As_Array is when False => -- PER as a value Val : HAL.UInt8; when True => -- PER as an array Arr : RTC_INTFLAG_RTC_MODE0_PER_Field_Array; end case; end record with Unchecked_Union, Size => 8; for RTC_INTFLAG_RTC_MODE0_PER_Field use record Val at 0 range 0 .. 7; Arr at 0 range 0 .. 7; end record; -- RTC_INTFLAG_RTC_MODE0_CMP array type RTC_INTFLAG_RTC_MODE0_CMP_Field_Array is array (0 .. 1) of Boolean with Component_Size => 1, Size => 2; -- Type definition for RTC_INTFLAG_RTC_MODE0_CMP type RTC_INTFLAG_RTC_MODE0_CMP_Field (As_Array : Boolean := False) is record case As_Array is when False => -- CMP as a value Val : HAL.UInt2; when True => -- CMP as an array Arr : RTC_INTFLAG_RTC_MODE0_CMP_Field_Array; end case; end record with Unchecked_Union, Size => 2; for RTC_INTFLAG_RTC_MODE0_CMP_Field use record Val at 0 range 0 .. 1; Arr at 0 range 0 .. 1; end record; -- MODE0 Interrupt Flag Status and Clear type RTC_INTFLAG_RTC_MODE0_Register is record -- Periodic Interval 0 PER : RTC_INTFLAG_RTC_MODE0_PER_Field := (As_Array => False, Val => 16#0#); -- Compare 0 CMP : RTC_INTFLAG_RTC_MODE0_CMP_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_10_13 : HAL.UInt4 := 16#0#; -- Tamper TAMPER : Boolean := False; -- Overflow OVF : Boolean := False; end record with Volatile_Full_Access, Object_Size => 16, Bit_Order => System.Low_Order_First; for RTC_INTFLAG_RTC_MODE0_Register use record PER at 0 range 0 .. 7; CMP at 0 range 8 .. 9; Reserved_10_13 at 0 range 10 .. 13; TAMPER at 0 range 14 .. 14; OVF at 0 range 15 .. 15; end record; -- Debug Control type RTC_DBGCTRL_RTC_MODE0_Register is record -- Run During Debug DBGRUN : Boolean := False; -- unspecified Reserved_1_7 : HAL.UInt7 := 16#0#; end record with Volatile_Full_Access, Object_Size => 8, Bit_Order => System.Low_Order_First; for RTC_DBGCTRL_RTC_MODE0_Register use record DBGRUN at 0 range 0 .. 0; Reserved_1_7 at 0 range 1 .. 7; end record; -- RTC_SYNCBUSY_RTC_MODE0_COMP array type RTC_SYNCBUSY_RTC_MODE0_COMP_Field_Array is array (0 .. 1) of Boolean with Component_Size => 1, Size => 2; -- Type definition for RTC_SYNCBUSY_RTC_MODE0_COMP type RTC_SYNCBUSY_RTC_MODE0_COMP_Field (As_Array : Boolean := False) is record case As_Array is when False => -- COMP as a value Val : HAL.UInt2; when True => -- COMP as an array Arr : RTC_SYNCBUSY_RTC_MODE0_COMP_Field_Array; end case; end record with Unchecked_Union, Size => 2; for RTC_SYNCBUSY_RTC_MODE0_COMP_Field use record Val at 0 range 0 .. 1; Arr at 0 range 0 .. 1; end record; -- RTC_SYNCBUSY_RTC_MODE0_GP array type RTC_SYNCBUSY_RTC_MODE0_GP_Field_Array is array (0 .. 3) of Boolean with Component_Size => 1, Size => 4; -- Type definition for RTC_SYNCBUSY_RTC_MODE0_GP type RTC_SYNCBUSY_RTC_MODE0_GP_Field (As_Array : Boolean := False) is record case As_Array is when False => -- GP as a value Val : HAL.UInt4; when True => -- GP as an array Arr : RTC_SYNCBUSY_RTC_MODE0_GP_Field_Array; end case; end record with Unchecked_Union, Size => 4; for RTC_SYNCBUSY_RTC_MODE0_GP_Field use record Val at 0 range 0 .. 3; Arr at 0 range 0 .. 3; end record; -- MODE0 Synchronization Busy Status type RTC_SYNCBUSY_RTC_MODE0_Register is record -- Read-only. Software Reset Busy SWRST : Boolean; -- Read-only. Enable Bit Busy ENABLE : Boolean; -- Read-only. FREQCORR Register Busy FREQCORR : Boolean; -- Read-only. COUNT Register Busy COUNT : Boolean; -- unspecified Reserved_4_4 : HAL.Bit; -- Read-only. COMP 0 Register Busy COMP : RTC_SYNCBUSY_RTC_MODE0_COMP_Field; -- unspecified Reserved_7_14 : HAL.UInt8; -- Read-only. Count Synchronization Enable Bit Busy COUNTSYNC : Boolean; -- Read-only. General Purpose 0 Register Busy GP : RTC_SYNCBUSY_RTC_MODE0_GP_Field; -- unspecified Reserved_20_31 : HAL.UInt12; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for RTC_SYNCBUSY_RTC_MODE0_Register use record SWRST at 0 range 0 .. 0; ENABLE at 0 range 1 .. 1; FREQCORR at 0 range 2 .. 2; COUNT at 0 range 3 .. 3; Reserved_4_4 at 0 range 4 .. 4; COMP at 0 range 5 .. 6; Reserved_7_14 at 0 range 7 .. 14; COUNTSYNC at 0 range 15 .. 15; GP at 0 range 16 .. 19; Reserved_20_31 at 0 range 20 .. 31; end record; subtype RTC_FREQCORR_RTC_MODE0_VALUE_Field is HAL.UInt7; -- Frequency Correction type RTC_FREQCORR_RTC_MODE0_Register is record -- Correction Value VALUE : RTC_FREQCORR_RTC_MODE0_VALUE_Field := 16#0#; -- Correction Sign SIGN : Boolean := False; end record with Volatile_Full_Access, Object_Size => 8, Bit_Order => System.Low_Order_First; for RTC_FREQCORR_RTC_MODE0_Register use record VALUE at 0 range 0 .. 6; SIGN at 0 range 7 .. 7; end record; -- MODE0 Compare n Value -- MODE0 Compare n Value type RTC_COMP_RTC_MODE0_Registers is array (0 .. 1) of HAL.UInt32; -- General Purpose -- General Purpose type RTC_GP_RTC_MODE0_Registers is array (0 .. 3) of HAL.UInt32; -- Tamper Input 0 Action type TAMPCTRL_IN0ACTSelect is (-- Off (Disabled) OFF, -- Wake without timestamp WAKE, -- Capture timestamp CAPTURE, -- Compare IN0 to OUT ACTL) with Size => 2; for TAMPCTRL_IN0ACTSelect use (OFF => 0, WAKE => 1, CAPTURE => 2, ACTL => 3); -- Tamper Input 1 Action type TAMPCTRL_IN1ACTSelect is (-- Off (Disabled) OFF, -- Wake without timestamp WAKE, -- Capture timestamp CAPTURE, -- Compare IN1 to OUT ACTL) with Size => 2; for TAMPCTRL_IN1ACTSelect use (OFF => 0, WAKE => 1, CAPTURE => 2, ACTL => 3); -- Tamper Input 2 Action type TAMPCTRL_IN2ACTSelect is (-- Off (Disabled) OFF, -- Wake without timestamp WAKE, -- Capture timestamp CAPTURE, -- Compare IN2 to OUT ACTL) with Size => 2; for TAMPCTRL_IN2ACTSelect use (OFF => 0, WAKE => 1, CAPTURE => 2, ACTL => 3); -- Tamper Input 3 Action type TAMPCTRL_IN3ACTSelect is (-- Off (Disabled) OFF, -- Wake without timestamp WAKE, -- Capture timestamp CAPTURE, -- Compare IN3 to OUT ACTL) with Size => 2; for TAMPCTRL_IN3ACTSelect use (OFF => 0, WAKE => 1, CAPTURE => 2, ACTL => 3); -- Tamper Input 4 Action type TAMPCTRL_IN4ACTSelect is (-- Off (Disabled) OFF, -- Wake without timestamp WAKE, -- Capture timestamp CAPTURE, -- Compare IN4 to OUT ACTL) with Size => 2; for TAMPCTRL_IN4ACTSelect use (OFF => 0, WAKE => 1, CAPTURE => 2, ACTL => 3); -- RTC_TAMPCTRL_RTC_MODE0_TAMLVL array type RTC_TAMPCTRL_RTC_MODE0_TAMLVL_Field_Array is array (0 .. 4) of Boolean with Component_Size => 1, Size => 5; -- Type definition for RTC_TAMPCTRL_RTC_MODE0_TAMLVL type RTC_TAMPCTRL_RTC_MODE0_TAMLVL_Field (As_Array : Boolean := False) is record case As_Array is when False => -- TAMLVL as a value Val : HAL.UInt5; when True => -- TAMLVL as an array Arr : RTC_TAMPCTRL_RTC_MODE0_TAMLVL_Field_Array; end case; end record with Unchecked_Union, Size => 5; for RTC_TAMPCTRL_RTC_MODE0_TAMLVL_Field use record Val at 0 range 0 .. 4; Arr at 0 range 0 .. 4; end record; -- RTC_TAMPCTRL_RTC_MODE0_DEBNC array type RTC_TAMPCTRL_RTC_MODE0_DEBNC_Field_Array is array (0 .. 4) of Boolean with Component_Size => 1, Size => 5; -- Type definition for RTC_TAMPCTRL_RTC_MODE0_DEBNC type RTC_TAMPCTRL_RTC_MODE0_DEBNC_Field (As_Array : Boolean := False) is record case As_Array is when False => -- DEBNC as a value Val : HAL.UInt5; when True => -- DEBNC as an array Arr : RTC_TAMPCTRL_RTC_MODE0_DEBNC_Field_Array; end case; end record with Unchecked_Union, Size => 5; for RTC_TAMPCTRL_RTC_MODE0_DEBNC_Field use record Val at 0 range 0 .. 4; Arr at 0 range 0 .. 4; end record; -- Tamper Control type RTC_TAMPCTRL_RTC_MODE0_Register is record -- Tamper Input 0 Action IN0ACT : TAMPCTRL_IN0ACTSelect := SAM_SVD.RTC.OFF; -- Tamper Input 1 Action IN1ACT : TAMPCTRL_IN1ACTSelect := SAM_SVD.RTC.OFF; -- Tamper Input 2 Action IN2ACT : TAMPCTRL_IN2ACTSelect := SAM_SVD.RTC.OFF; -- Tamper Input 3 Action IN3ACT : TAMPCTRL_IN3ACTSelect := SAM_SVD.RTC.OFF; -- Tamper Input 4 Action IN4ACT : TAMPCTRL_IN4ACTSelect := SAM_SVD.RTC.OFF; -- unspecified Reserved_10_15 : HAL.UInt6 := 16#0#; -- Tamper Level Select 0 TAMLVL : RTC_TAMPCTRL_RTC_MODE0_TAMLVL_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_21_23 : HAL.UInt3 := 16#0#; -- Debouncer Enable 0 DEBNC : RTC_TAMPCTRL_RTC_MODE0_DEBNC_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_29_31 : HAL.UInt3 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for RTC_TAMPCTRL_RTC_MODE0_Register use record IN0ACT at 0 range 0 .. 1; IN1ACT at 0 range 2 .. 3; IN2ACT at 0 range 4 .. 5; IN3ACT at 0 range 6 .. 7; IN4ACT at 0 range 8 .. 9; Reserved_10_15 at 0 range 10 .. 15; TAMLVL at 0 range 16 .. 20; Reserved_21_23 at 0 range 21 .. 23; DEBNC at 0 range 24 .. 28; Reserved_29_31 at 0 range 29 .. 31; end record; -- RTC_TAMPID_RTC_MODE0_TAMPID array type RTC_TAMPID_RTC_MODE0_TAMPID_Field_Array is array (0 .. 4) of Boolean with Component_Size => 1, Size => 5; -- Type definition for RTC_TAMPID_RTC_MODE0_TAMPID type RTC_TAMPID_RTC_MODE0_TAMPID_Field (As_Array : Boolean := False) is record case As_Array is when False => -- TAMPID as a value Val : HAL.UInt5; when True => -- TAMPID as an array Arr : RTC_TAMPID_RTC_MODE0_TAMPID_Field_Array; end case; end record with Unchecked_Union, Size => 5; for RTC_TAMPID_RTC_MODE0_TAMPID_Field use record Val at 0 range 0 .. 4; Arr at 0 range 0 .. 4; end record; -- Tamper ID type RTC_TAMPID_RTC_MODE0_Register is record -- Tamper Input 0 Detected TAMPID : RTC_TAMPID_RTC_MODE0_TAMPID_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_5_30 : HAL.UInt26 := 16#0#; -- Tamper Event Detected TAMPEVT : Boolean := False; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for RTC_TAMPID_RTC_MODE0_Register use record TAMPID at 0 range 0 .. 4; Reserved_5_30 at 0 range 5 .. 30; TAMPEVT at 0 range 31 .. 31; end record; -- Backup -- Backup type RTC_BKUP_RTC_MODE0_Registers is array (0 .. 7) of HAL.UInt32; -- 32-bit Counter with Single 32-bit Compare type RtcMode0_Cluster is record -- MODE0 Control A CTRLA : aliased RTC_CTRLA_RTC_MODE0_Register; -- MODE0 Control B CTRLB : aliased RTC_CTRLB_RTC_MODE0_Register; -- MODE0 Event Control EVCTRL : aliased RTC_EVCTRL_RTC_MODE0_Register; -- MODE0 Interrupt Enable Clear INTENCLR : aliased RTC_INTENCLR_RTC_MODE0_Register; -- MODE0 Interrupt Enable Set INTENSET : aliased RTC_INTENSET_RTC_MODE0_Register; -- MODE0 Interrupt Flag Status and Clear INTFLAG : aliased RTC_INTFLAG_RTC_MODE0_Register; -- Debug Control DBGCTRL : aliased RTC_DBGCTRL_RTC_MODE0_Register; -- MODE0 Synchronization Busy Status SYNCBUSY : aliased RTC_SYNCBUSY_RTC_MODE0_Register; -- Frequency Correction FREQCORR : aliased RTC_FREQCORR_RTC_MODE0_Register; -- MODE0 Counter Value COUNT : aliased HAL.UInt32; -- MODE0 Compare n Value COMP : aliased RTC_COMP_RTC_MODE0_Registers; -- General Purpose GP : aliased RTC_GP_RTC_MODE0_Registers; -- Tamper Control TAMPCTRL : aliased RTC_TAMPCTRL_RTC_MODE0_Register; -- MODE0 Timestamp TIMESTAMP : aliased HAL.UInt32; -- Tamper ID TAMPID : aliased RTC_TAMPID_RTC_MODE0_Register; -- Backup BKUP : aliased RTC_BKUP_RTC_MODE0_Registers; end record with Size => 1280; for RtcMode0_Cluster use record CTRLA at 16#0# range 0 .. 15; CTRLB at 16#2# range 0 .. 15; EVCTRL at 16#4# range 0 .. 31; INTENCLR at 16#8# range 0 .. 15; INTENSET at 16#A# range 0 .. 15; INTFLAG at 16#C# range 0 .. 15; DBGCTRL at 16#E# range 0 .. 7; SYNCBUSY at 16#10# range 0 .. 31; FREQCORR at 16#14# range 0 .. 7; COUNT at 16#18# range 0 .. 31; COMP at 16#20# range 0 .. 63; GP at 16#40# range 0 .. 127; TAMPCTRL at 16#60# range 0 .. 31; TIMESTAMP at 16#64# range 0 .. 31; TAMPID at 16#68# range 0 .. 31; BKUP at 16#80# range 0 .. 255; end record; ---------------------------------- -- RtcMode1 cluster's Registers -- ---------------------------------- -- MODE1 Control A type RTC_CTRLA_RTC_MODE1_Register is record -- Software Reset SWRST : Boolean := False; -- Enable ENABLE : Boolean := False; -- Operating Mode MODE : CTRLA_MODESelect := SAM_SVD.RTC.COUNT32; -- unspecified Reserved_4_7 : HAL.UInt4 := 16#0#; -- Prescaler PRESCALER : CTRLA_PRESCALERSelect := SAM_SVD.RTC.OFF; -- unspecified Reserved_12_12 : HAL.Bit := 16#0#; -- BKUP Registers Reset On Tamper Enable BKTRST : Boolean := False; -- GP Registers Reset On Tamper Enable GPTRST : Boolean := False; -- Count Read Synchronization Enable COUNTSYNC : Boolean := False; end record with Volatile_Full_Access, Object_Size => 16, Bit_Order => System.Low_Order_First; for RTC_CTRLA_RTC_MODE1_Register use record SWRST at 0 range 0 .. 0; ENABLE at 0 range 1 .. 1; MODE at 0 range 2 .. 3; Reserved_4_7 at 0 range 4 .. 7; PRESCALER at 0 range 8 .. 11; Reserved_12_12 at 0 range 12 .. 12; BKTRST at 0 range 13 .. 13; GPTRST at 0 range 14 .. 14; COUNTSYNC at 0 range 15 .. 15; end record; -- MODE1 Control B type RTC_CTRLB_RTC_MODE1_Register is record -- General Purpose 0 Enable GP0EN : Boolean := False; -- General Purpose 2 Enable GP2EN : Boolean := False; -- unspecified Reserved_2_3 : HAL.UInt2 := 16#0#; -- Debouncer Majority Enable DEBMAJ : Boolean := False; -- Debouncer Asynchronous Enable DEBASYNC : Boolean := False; -- RTC Output Enable RTCOUT : Boolean := False; -- DMA Enable DMAEN : Boolean := False; -- Debounce Freqnuency DEBF : CTRLB_DEBFSelect := SAM_SVD.RTC.DIV2; -- unspecified Reserved_11_11 : HAL.Bit := 16#0#; -- Active Layer Freqnuency ACTF : CTRLB_ACTFSelect := SAM_SVD.RTC.DIV2; -- unspecified Reserved_15_15 : HAL.Bit := 16#0#; end record with Volatile_Full_Access, Object_Size => 16, Bit_Order => System.Low_Order_First; for RTC_CTRLB_RTC_MODE1_Register use record GP0EN at 0 range 0 .. 0; GP2EN at 0 range 1 .. 1; Reserved_2_3 at 0 range 2 .. 3; DEBMAJ at 0 range 4 .. 4; DEBASYNC at 0 range 5 .. 5; RTCOUT at 0 range 6 .. 6; DMAEN at 0 range 7 .. 7; DEBF at 0 range 8 .. 10; Reserved_11_11 at 0 range 11 .. 11; ACTF at 0 range 12 .. 14; Reserved_15_15 at 0 range 15 .. 15; end record; -- RTC_EVCTRL_RTC_MODE1_PEREO array type RTC_EVCTRL_RTC_MODE1_PEREO_Field_Array is array (0 .. 7) of Boolean with Component_Size => 1, Size => 8; -- Type definition for RTC_EVCTRL_RTC_MODE1_PEREO type RTC_EVCTRL_RTC_MODE1_PEREO_Field (As_Array : Boolean := False) is record case As_Array is when False => -- PEREO as a value Val : HAL.UInt8; when True => -- PEREO as an array Arr : RTC_EVCTRL_RTC_MODE1_PEREO_Field_Array; end case; end record with Unchecked_Union, Size => 8; for RTC_EVCTRL_RTC_MODE1_PEREO_Field use record Val at 0 range 0 .. 7; Arr at 0 range 0 .. 7; end record; -- RTC_EVCTRL_RTC_MODE1_CMPEO array type RTC_EVCTRL_RTC_MODE1_CMPEO_Field_Array is array (0 .. 3) of Boolean with Component_Size => 1, Size => 4; -- Type definition for RTC_EVCTRL_RTC_MODE1_CMPEO type RTC_EVCTRL_RTC_MODE1_CMPEO_Field (As_Array : Boolean := False) is record case As_Array is when False => -- CMPEO as a value Val : HAL.UInt4; when True => -- CMPEO as an array Arr : RTC_EVCTRL_RTC_MODE1_CMPEO_Field_Array; end case; end record with Unchecked_Union, Size => 4; for RTC_EVCTRL_RTC_MODE1_CMPEO_Field use record Val at 0 range 0 .. 3; Arr at 0 range 0 .. 3; end record; -- MODE1 Event Control type RTC_EVCTRL_RTC_MODE1_Register is record -- Periodic Interval 0 Event Output Enable PEREO : RTC_EVCTRL_RTC_MODE1_PEREO_Field := (As_Array => False, Val => 16#0#); -- Compare 0 Event Output Enable CMPEO : RTC_EVCTRL_RTC_MODE1_CMPEO_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_12_13 : HAL.UInt2 := 16#0#; -- Tamper Event Output Enable TAMPEREO : Boolean := False; -- Overflow Event Output Enable OVFEO : Boolean := False; -- Tamper Event Input Enable TAMPEVEI : Boolean := False; -- unspecified Reserved_17_31 : HAL.UInt15 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for RTC_EVCTRL_RTC_MODE1_Register use record PEREO at 0 range 0 .. 7; CMPEO at 0 range 8 .. 11; Reserved_12_13 at 0 range 12 .. 13; TAMPEREO at 0 range 14 .. 14; OVFEO at 0 range 15 .. 15; TAMPEVEI at 0 range 16 .. 16; Reserved_17_31 at 0 range 17 .. 31; end record; -- RTC_INTENCLR_RTC_MODE1_PER array type RTC_INTENCLR_RTC_MODE1_PER_Field_Array is array (0 .. 7) of Boolean with Component_Size => 1, Size => 8; -- Type definition for RTC_INTENCLR_RTC_MODE1_PER type RTC_INTENCLR_RTC_MODE1_PER_Field (As_Array : Boolean := False) is record case As_Array is when False => -- PER as a value Val : HAL.UInt8; when True => -- PER as an array Arr : RTC_INTENCLR_RTC_MODE1_PER_Field_Array; end case; end record with Unchecked_Union, Size => 8; for RTC_INTENCLR_RTC_MODE1_PER_Field use record Val at 0 range 0 .. 7; Arr at 0 range 0 .. 7; end record; -- RTC_INTENCLR_RTC_MODE1_CMP array type RTC_INTENCLR_RTC_MODE1_CMP_Field_Array is array (0 .. 3) of Boolean with Component_Size => 1, Size => 4; -- Type definition for RTC_INTENCLR_RTC_MODE1_CMP type RTC_INTENCLR_RTC_MODE1_CMP_Field (As_Array : Boolean := False) is record case As_Array is when False => -- CMP as a value Val : HAL.UInt4; when True => -- CMP as an array Arr : RTC_INTENCLR_RTC_MODE1_CMP_Field_Array; end case; end record with Unchecked_Union, Size => 4; for RTC_INTENCLR_RTC_MODE1_CMP_Field use record Val at 0 range 0 .. 3; Arr at 0 range 0 .. 3; end record; -- MODE1 Interrupt Enable Clear type RTC_INTENCLR_RTC_MODE1_Register is record -- Periodic Interval 0 Interrupt Enable PER : RTC_INTENCLR_RTC_MODE1_PER_Field := (As_Array => False, Val => 16#0#); -- Compare 0 Interrupt Enable CMP : RTC_INTENCLR_RTC_MODE1_CMP_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_12_13 : HAL.UInt2 := 16#0#; -- Tamper Enable TAMPER : Boolean := False; -- Overflow Interrupt Enable OVF : Boolean := False; end record with Volatile_Full_Access, Object_Size => 16, Bit_Order => System.Low_Order_First; for RTC_INTENCLR_RTC_MODE1_Register use record PER at 0 range 0 .. 7; CMP at 0 range 8 .. 11; Reserved_12_13 at 0 range 12 .. 13; TAMPER at 0 range 14 .. 14; OVF at 0 range 15 .. 15; end record; -- RTC_INTENSET_RTC_MODE1_PER array type RTC_INTENSET_RTC_MODE1_PER_Field_Array is array (0 .. 7) of Boolean with Component_Size => 1, Size => 8; -- Type definition for RTC_INTENSET_RTC_MODE1_PER type RTC_INTENSET_RTC_MODE1_PER_Field (As_Array : Boolean := False) is record case As_Array is when False => -- PER as a value Val : HAL.UInt8; when True => -- PER as an array Arr : RTC_INTENSET_RTC_MODE1_PER_Field_Array; end case; end record with Unchecked_Union, Size => 8; for RTC_INTENSET_RTC_MODE1_PER_Field use record Val at 0 range 0 .. 7; Arr at 0 range 0 .. 7; end record; -- RTC_INTENSET_RTC_MODE1_CMP array type RTC_INTENSET_RTC_MODE1_CMP_Field_Array is array (0 .. 3) of Boolean with Component_Size => 1, Size => 4; -- Type definition for RTC_INTENSET_RTC_MODE1_CMP type RTC_INTENSET_RTC_MODE1_CMP_Field (As_Array : Boolean := False) is record case As_Array is when False => -- CMP as a value Val : HAL.UInt4; when True => -- CMP as an array Arr : RTC_INTENSET_RTC_MODE1_CMP_Field_Array; end case; end record with Unchecked_Union, Size => 4; for RTC_INTENSET_RTC_MODE1_CMP_Field use record Val at 0 range 0 .. 3; Arr at 0 range 0 .. 3; end record; -- MODE1 Interrupt Enable Set type RTC_INTENSET_RTC_MODE1_Register is record -- Periodic Interval 0 Interrupt Enable PER : RTC_INTENSET_RTC_MODE1_PER_Field := (As_Array => False, Val => 16#0#); -- Compare 0 Interrupt Enable CMP : RTC_INTENSET_RTC_MODE1_CMP_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_12_13 : HAL.UInt2 := 16#0#; -- Tamper Enable TAMPER : Boolean := False; -- Overflow Interrupt Enable OVF : Boolean := False; end record with Volatile_Full_Access, Object_Size => 16, Bit_Order => System.Low_Order_First; for RTC_INTENSET_RTC_MODE1_Register use record PER at 0 range 0 .. 7; CMP at 0 range 8 .. 11; Reserved_12_13 at 0 range 12 .. 13; TAMPER at 0 range 14 .. 14; OVF at 0 range 15 .. 15; end record; -- RTC_INTFLAG_RTC_MODE1_PER array type RTC_INTFLAG_RTC_MODE1_PER_Field_Array is array (0 .. 7) of Boolean with Component_Size => 1, Size => 8; -- Type definition for RTC_INTFLAG_RTC_MODE1_PER type RTC_INTFLAG_RTC_MODE1_PER_Field (As_Array : Boolean := False) is record case As_Array is when False => -- PER as a value Val : HAL.UInt8; when True => -- PER as an array Arr : RTC_INTFLAG_RTC_MODE1_PER_Field_Array; end case; end record with Unchecked_Union, Size => 8; for RTC_INTFLAG_RTC_MODE1_PER_Field use record Val at 0 range 0 .. 7; Arr at 0 range 0 .. 7; end record; -- RTC_INTFLAG_RTC_MODE1_CMP array type RTC_INTFLAG_RTC_MODE1_CMP_Field_Array is array (0 .. 3) of Boolean with Component_Size => 1, Size => 4; -- Type definition for RTC_INTFLAG_RTC_MODE1_CMP type RTC_INTFLAG_RTC_MODE1_CMP_Field (As_Array : Boolean := False) is record case As_Array is when False => -- CMP as a value Val : HAL.UInt4; when True => -- CMP as an array Arr : RTC_INTFLAG_RTC_MODE1_CMP_Field_Array; end case; end record with Unchecked_Union, Size => 4; for RTC_INTFLAG_RTC_MODE1_CMP_Field use record Val at 0 range 0 .. 3; Arr at 0 range 0 .. 3; end record; -- MODE1 Interrupt Flag Status and Clear type RTC_INTFLAG_RTC_MODE1_Register is record -- Periodic Interval 0 PER : RTC_INTFLAG_RTC_MODE1_PER_Field := (As_Array => False, Val => 16#0#); -- Compare 0 CMP : RTC_INTFLAG_RTC_MODE1_CMP_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_12_13 : HAL.UInt2 := 16#0#; -- Tamper TAMPER : Boolean := False; -- Overflow OVF : Boolean := False; end record with Volatile_Full_Access, Object_Size => 16, Bit_Order => System.Low_Order_First; for RTC_INTFLAG_RTC_MODE1_Register use record PER at 0 range 0 .. 7; CMP at 0 range 8 .. 11; Reserved_12_13 at 0 range 12 .. 13; TAMPER at 0 range 14 .. 14; OVF at 0 range 15 .. 15; end record; -- Debug Control type RTC_DBGCTRL_RTC_MODE1_Register is record -- Run During Debug DBGRUN : Boolean := False; -- unspecified Reserved_1_7 : HAL.UInt7 := 16#0#; end record with Volatile_Full_Access, Object_Size => 8, Bit_Order => System.Low_Order_First; for RTC_DBGCTRL_RTC_MODE1_Register use record DBGRUN at 0 range 0 .. 0; Reserved_1_7 at 0 range 1 .. 7; end record; -- RTC_SYNCBUSY_RTC_MODE1_COMP array type RTC_SYNCBUSY_RTC_MODE1_COMP_Field_Array is array (0 .. 3) of Boolean with Component_Size => 1, Size => 4; -- Type definition for RTC_SYNCBUSY_RTC_MODE1_COMP type RTC_SYNCBUSY_RTC_MODE1_COMP_Field (As_Array : Boolean := False) is record case As_Array is when False => -- COMP as a value Val : HAL.UInt4; when True => -- COMP as an array Arr : RTC_SYNCBUSY_RTC_MODE1_COMP_Field_Array; end case; end record with Unchecked_Union, Size => 4; for RTC_SYNCBUSY_RTC_MODE1_COMP_Field use record Val at 0 range 0 .. 3; Arr at 0 range 0 .. 3; end record; -- RTC_SYNCBUSY_RTC_MODE1_GP array type RTC_SYNCBUSY_RTC_MODE1_GP_Field_Array is array (0 .. 3) of Boolean with Component_Size => 1, Size => 4; -- Type definition for RTC_SYNCBUSY_RTC_MODE1_GP type RTC_SYNCBUSY_RTC_MODE1_GP_Field (As_Array : Boolean := False) is record case As_Array is when False => -- GP as a value Val : HAL.UInt4; when True => -- GP as an array Arr : RTC_SYNCBUSY_RTC_MODE1_GP_Field_Array; end case; end record with Unchecked_Union, Size => 4; for RTC_SYNCBUSY_RTC_MODE1_GP_Field use record Val at 0 range 0 .. 3; Arr at 0 range 0 .. 3; end record; -- MODE1 Synchronization Busy Status type RTC_SYNCBUSY_RTC_MODE1_Register is record -- Read-only. Software Reset Bit Busy SWRST : Boolean; -- Read-only. Enable Bit Busy ENABLE : Boolean; -- Read-only. FREQCORR Register Busy FREQCORR : Boolean; -- Read-only. COUNT Register Busy COUNT : Boolean; -- Read-only. PER Register Busy PER : Boolean; -- Read-only. COMP 0 Register Busy COMP : RTC_SYNCBUSY_RTC_MODE1_COMP_Field; -- unspecified Reserved_9_14 : HAL.UInt6; -- Read-only. Count Synchronization Enable Bit Busy COUNTSYNC : Boolean; -- Read-only. General Purpose 0 Register Busy GP : RTC_SYNCBUSY_RTC_MODE1_GP_Field; -- unspecified Reserved_20_31 : HAL.UInt12; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for RTC_SYNCBUSY_RTC_MODE1_Register use record SWRST at 0 range 0 .. 0; ENABLE at 0 range 1 .. 1; FREQCORR at 0 range 2 .. 2; COUNT at 0 range 3 .. 3; PER at 0 range 4 .. 4; COMP at 0 range 5 .. 8; Reserved_9_14 at 0 range 9 .. 14; COUNTSYNC at 0 range 15 .. 15; GP at 0 range 16 .. 19; Reserved_20_31 at 0 range 20 .. 31; end record; subtype RTC_FREQCORR_RTC_MODE1_VALUE_Field is HAL.UInt7; -- Frequency Correction type RTC_FREQCORR_RTC_MODE1_Register is record -- Correction Value VALUE : RTC_FREQCORR_RTC_MODE1_VALUE_Field := 16#0#; -- Correction Sign SIGN : Boolean := False; end record with Volatile_Full_Access, Object_Size => 8, Bit_Order => System.Low_Order_First; for RTC_FREQCORR_RTC_MODE1_Register use record VALUE at 0 range 0 .. 6; SIGN at 0 range 7 .. 7; end record; -- MODE1 Compare n Value -- MODE1 Compare n Value type RTC_COMP_RTC_MODE1_Registers is array (0 .. 3) of HAL.UInt16; -- General Purpose -- General Purpose type RTC_GP_RTC_MODE1_Registers is array (0 .. 3) of HAL.UInt32; -- RTC_TAMPCTRL_RTC_MODE1_TAMLVL array type RTC_TAMPCTRL_RTC_MODE1_TAMLVL_Field_Array is array (0 .. 4) of Boolean with Component_Size => 1, Size => 5; -- Type definition for RTC_TAMPCTRL_RTC_MODE1_TAMLVL type RTC_TAMPCTRL_RTC_MODE1_TAMLVL_Field (As_Array : Boolean := False) is record case As_Array is when False => -- TAMLVL as a value Val : HAL.UInt5; when True => -- TAMLVL as an array Arr : RTC_TAMPCTRL_RTC_MODE1_TAMLVL_Field_Array; end case; end record with Unchecked_Union, Size => 5; for RTC_TAMPCTRL_RTC_MODE1_TAMLVL_Field use record Val at 0 range 0 .. 4; Arr at 0 range 0 .. 4; end record; -- RTC_TAMPCTRL_RTC_MODE1_DEBNC array type RTC_TAMPCTRL_RTC_MODE1_DEBNC_Field_Array is array (0 .. 4) of Boolean with Component_Size => 1, Size => 5; -- Type definition for RTC_TAMPCTRL_RTC_MODE1_DEBNC type RTC_TAMPCTRL_RTC_MODE1_DEBNC_Field (As_Array : Boolean := False) is record case As_Array is when False => -- DEBNC as a value Val : HAL.UInt5; when True => -- DEBNC as an array Arr : RTC_TAMPCTRL_RTC_MODE1_DEBNC_Field_Array; end case; end record with Unchecked_Union, Size => 5; for RTC_TAMPCTRL_RTC_MODE1_DEBNC_Field use record Val at 0 range 0 .. 4; Arr at 0 range 0 .. 4; end record; -- Tamper Control type RTC_TAMPCTRL_RTC_MODE1_Register is record -- Tamper Input 0 Action IN0ACT : TAMPCTRL_IN0ACTSelect := SAM_SVD.RTC.OFF; -- Tamper Input 1 Action IN1ACT : TAMPCTRL_IN1ACTSelect := SAM_SVD.RTC.OFF; -- Tamper Input 2 Action IN2ACT : TAMPCTRL_IN2ACTSelect := SAM_SVD.RTC.OFF; -- Tamper Input 3 Action IN3ACT : TAMPCTRL_IN3ACTSelect := SAM_SVD.RTC.OFF; -- Tamper Input 4 Action IN4ACT : TAMPCTRL_IN4ACTSelect := SAM_SVD.RTC.OFF; -- unspecified Reserved_10_15 : HAL.UInt6 := 16#0#; -- Tamper Level Select 0 TAMLVL : RTC_TAMPCTRL_RTC_MODE1_TAMLVL_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_21_23 : HAL.UInt3 := 16#0#; -- Debouncer Enable 0 DEBNC : RTC_TAMPCTRL_RTC_MODE1_DEBNC_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_29_31 : HAL.UInt3 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for RTC_TAMPCTRL_RTC_MODE1_Register use record IN0ACT at 0 range 0 .. 1; IN1ACT at 0 range 2 .. 3; IN2ACT at 0 range 4 .. 5; IN3ACT at 0 range 6 .. 7; IN4ACT at 0 range 8 .. 9; Reserved_10_15 at 0 range 10 .. 15; TAMLVL at 0 range 16 .. 20; Reserved_21_23 at 0 range 21 .. 23; DEBNC at 0 range 24 .. 28; Reserved_29_31 at 0 range 29 .. 31; end record; subtype RTC_TIMESTAMP_RTC_MODE1_COUNT_Field is HAL.UInt16; -- MODE1 Timestamp type RTC_TIMESTAMP_RTC_MODE1_Register is record -- Read-only. Count Timestamp Value COUNT : RTC_TIMESTAMP_RTC_MODE1_COUNT_Field; -- unspecified Reserved_16_31 : HAL.UInt16; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for RTC_TIMESTAMP_RTC_MODE1_Register use record COUNT at 0 range 0 .. 15; Reserved_16_31 at 0 range 16 .. 31; end record; -- RTC_TAMPID_RTC_MODE1_TAMPID array type RTC_TAMPID_RTC_MODE1_TAMPID_Field_Array is array (0 .. 4) of Boolean with Component_Size => 1, Size => 5; -- Type definition for RTC_TAMPID_RTC_MODE1_TAMPID type RTC_TAMPID_RTC_MODE1_TAMPID_Field (As_Array : Boolean := False) is record case As_Array is when False => -- TAMPID as a value Val : HAL.UInt5; when True => -- TAMPID as an array Arr : RTC_TAMPID_RTC_MODE1_TAMPID_Field_Array; end case; end record with Unchecked_Union, Size => 5; for RTC_TAMPID_RTC_MODE1_TAMPID_Field use record Val at 0 range 0 .. 4; Arr at 0 range 0 .. 4; end record; -- Tamper ID type RTC_TAMPID_RTC_MODE1_Register is record -- Tamper Input 0 Detected TAMPID : RTC_TAMPID_RTC_MODE1_TAMPID_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_5_30 : HAL.UInt26 := 16#0#; -- Tamper Event Detected TAMPEVT : Boolean := False; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for RTC_TAMPID_RTC_MODE1_Register use record TAMPID at 0 range 0 .. 4; Reserved_5_30 at 0 range 5 .. 30; TAMPEVT at 0 range 31 .. 31; end record; -- Backup -- Backup type RTC_BKUP_RTC_MODE1_Registers is array (0 .. 7) of HAL.UInt32; -- 16-bit Counter with Two 16-bit Compares type RtcMode1_Cluster is record -- MODE1 Control A CTRLA : aliased RTC_CTRLA_RTC_MODE1_Register; -- MODE1 Control B CTRLB : aliased RTC_CTRLB_RTC_MODE1_Register; -- MODE1 Event Control EVCTRL : aliased RTC_EVCTRL_RTC_MODE1_Register; -- MODE1 Interrupt Enable Clear INTENCLR : aliased RTC_INTENCLR_RTC_MODE1_Register; -- MODE1 Interrupt Enable Set INTENSET : aliased RTC_INTENSET_RTC_MODE1_Register; -- MODE1 Interrupt Flag Status and Clear INTFLAG : aliased RTC_INTFLAG_RTC_MODE1_Register; -- Debug Control DBGCTRL : aliased RTC_DBGCTRL_RTC_MODE1_Register; -- MODE1 Synchronization Busy Status SYNCBUSY : aliased RTC_SYNCBUSY_RTC_MODE1_Register; -- Frequency Correction FREQCORR : aliased RTC_FREQCORR_RTC_MODE1_Register; -- MODE1 Counter Value COUNT : aliased HAL.UInt16; -- MODE1 Counter Period PER : aliased HAL.UInt16; -- MODE1 Compare n Value COMP : aliased RTC_COMP_RTC_MODE1_Registers; -- General Purpose GP : aliased RTC_GP_RTC_MODE1_Registers; -- Tamper Control TAMPCTRL : aliased RTC_TAMPCTRL_RTC_MODE1_Register; -- MODE1 Timestamp TIMESTAMP : aliased RTC_TIMESTAMP_RTC_MODE1_Register; -- Tamper ID TAMPID : aliased RTC_TAMPID_RTC_MODE1_Register; -- Backup BKUP : aliased RTC_BKUP_RTC_MODE1_Registers; end record with Size => 1280; for RtcMode1_Cluster use record CTRLA at 16#0# range 0 .. 15; CTRLB at 16#2# range 0 .. 15; EVCTRL at 16#4# range 0 .. 31; INTENCLR at 16#8# range 0 .. 15; INTENSET at 16#A# range 0 .. 15; INTFLAG at 16#C# range 0 .. 15; DBGCTRL at 16#E# range 0 .. 7; SYNCBUSY at 16#10# range 0 .. 31; FREQCORR at 16#14# range 0 .. 7; COUNT at 16#18# range 0 .. 15; PER at 16#1C# range 0 .. 15; COMP at 16#20# range 0 .. 63; GP at 16#40# range 0 .. 127; TAMPCTRL at 16#60# range 0 .. 31; TIMESTAMP at 16#64# range 0 .. 31; TAMPID at 16#68# range 0 .. 31; BKUP at 16#80# range 0 .. 255; end record; ---------------------------------- -- RtcMode2 cluster's Registers -- ---------------------------------- -- MODE2 Control A type RTC_CTRLA_RTC_MODE2_Register is record -- Software Reset SWRST : Boolean := False; -- Enable ENABLE : Boolean := False; -- Operating Mode MODE : CTRLA_MODESelect := SAM_SVD.RTC.COUNT32; -- unspecified Reserved_4_5 : HAL.UInt2 := 16#0#; -- Clock Representation CLKREP : Boolean := False; -- Clear on Match MATCHCLR : Boolean := False; -- Prescaler PRESCALER : CTRLA_PRESCALERSelect := SAM_SVD.RTC.OFF; -- unspecified Reserved_12_12 : HAL.Bit := 16#0#; -- BKUP Registers Reset On Tamper Enable BKTRST : Boolean := False; -- GP Registers Reset On Tamper Enable GPTRST : Boolean := False; -- Clock Read Synchronization Enable CLOCKSYNC : Boolean := False; end record with Volatile_Full_Access, Object_Size => 16, Bit_Order => System.Low_Order_First; for RTC_CTRLA_RTC_MODE2_Register use record SWRST at 0 range 0 .. 0; ENABLE at 0 range 1 .. 1; MODE at 0 range 2 .. 3; Reserved_4_5 at 0 range 4 .. 5; CLKREP at 0 range 6 .. 6; MATCHCLR at 0 range 7 .. 7; PRESCALER at 0 range 8 .. 11; Reserved_12_12 at 0 range 12 .. 12; BKTRST at 0 range 13 .. 13; GPTRST at 0 range 14 .. 14; CLOCKSYNC at 0 range 15 .. 15; end record; -- MODE2 Control B type RTC_CTRLB_RTC_MODE2_Register is record -- General Purpose 0 Enable GP0EN : Boolean := False; -- General Purpose 2 Enable GP2EN : Boolean := False; -- unspecified Reserved_2_3 : HAL.UInt2 := 16#0#; -- Debouncer Majority Enable DEBMAJ : Boolean := False; -- Debouncer Asynchronous Enable DEBASYNC : Boolean := False; -- RTC Output Enable RTCOUT : Boolean := False; -- DMA Enable DMAEN : Boolean := False; -- Debounce Freqnuency DEBF : CTRLB_DEBFSelect := SAM_SVD.RTC.DIV2; -- unspecified Reserved_11_11 : HAL.Bit := 16#0#; -- Active Layer Freqnuency ACTF : CTRLB_ACTFSelect := SAM_SVD.RTC.DIV2; -- unspecified Reserved_15_15 : HAL.Bit := 16#0#; end record with Volatile_Full_Access, Object_Size => 16, Bit_Order => System.Low_Order_First; for RTC_CTRLB_RTC_MODE2_Register use record GP0EN at 0 range 0 .. 0; GP2EN at 0 range 1 .. 1; Reserved_2_3 at 0 range 2 .. 3; DEBMAJ at 0 range 4 .. 4; DEBASYNC at 0 range 5 .. 5; RTCOUT at 0 range 6 .. 6; DMAEN at 0 range 7 .. 7; DEBF at 0 range 8 .. 10; Reserved_11_11 at 0 range 11 .. 11; ACTF at 0 range 12 .. 14; Reserved_15_15 at 0 range 15 .. 15; end record; -- RTC_EVCTRL_RTC_MODE2_PEREO array type RTC_EVCTRL_RTC_MODE2_PEREO_Field_Array is array (0 .. 7) of Boolean with Component_Size => 1, Size => 8; -- Type definition for RTC_EVCTRL_RTC_MODE2_PEREO type RTC_EVCTRL_RTC_MODE2_PEREO_Field (As_Array : Boolean := False) is record case As_Array is when False => -- PEREO as a value Val : HAL.UInt8; when True => -- PEREO as an array Arr : RTC_EVCTRL_RTC_MODE2_PEREO_Field_Array; end case; end record with Unchecked_Union, Size => 8; for RTC_EVCTRL_RTC_MODE2_PEREO_Field use record Val at 0 range 0 .. 7; Arr at 0 range 0 .. 7; end record; -- RTC_EVCTRL_RTC_MODE2_ALARMEO array type RTC_EVCTRL_RTC_MODE2_ALARMEO_Field_Array is array (0 .. 1) of Boolean with Component_Size => 1, Size => 2; -- Type definition for RTC_EVCTRL_RTC_MODE2_ALARMEO type RTC_EVCTRL_RTC_MODE2_ALARMEO_Field (As_Array : Boolean := False) is record case As_Array is when False => -- ALARMEO as a value Val : HAL.UInt2; when True => -- ALARMEO as an array Arr : RTC_EVCTRL_RTC_MODE2_ALARMEO_Field_Array; end case; end record with Unchecked_Union, Size => 2; for RTC_EVCTRL_RTC_MODE2_ALARMEO_Field use record Val at 0 range 0 .. 1; Arr at 0 range 0 .. 1; end record; -- MODE2 Event Control type RTC_EVCTRL_RTC_MODE2_Register is record -- Periodic Interval 0 Event Output Enable PEREO : RTC_EVCTRL_RTC_MODE2_PEREO_Field := (As_Array => False, Val => 16#0#); -- Alarm 0 Event Output Enable ALARMEO : RTC_EVCTRL_RTC_MODE2_ALARMEO_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_10_13 : HAL.UInt4 := 16#0#; -- Tamper Event Output Enable TAMPEREO : Boolean := False; -- Overflow Event Output Enable OVFEO : Boolean := False; -- Tamper Event Input Enable TAMPEVEI : Boolean := False; -- unspecified Reserved_17_31 : HAL.UInt15 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for RTC_EVCTRL_RTC_MODE2_Register use record PEREO at 0 range 0 .. 7; ALARMEO at 0 range 8 .. 9; Reserved_10_13 at 0 range 10 .. 13; TAMPEREO at 0 range 14 .. 14; OVFEO at 0 range 15 .. 15; TAMPEVEI at 0 range 16 .. 16; Reserved_17_31 at 0 range 17 .. 31; end record; -- RTC_INTENCLR_RTC_MODE2_PER array type RTC_INTENCLR_RTC_MODE2_PER_Field_Array is array (0 .. 7) of Boolean with Component_Size => 1, Size => 8; -- Type definition for RTC_INTENCLR_RTC_MODE2_PER type RTC_INTENCLR_RTC_MODE2_PER_Field (As_Array : Boolean := False) is record case As_Array is when False => -- PER as a value Val : HAL.UInt8; when True => -- PER as an array Arr : RTC_INTENCLR_RTC_MODE2_PER_Field_Array; end case; end record with Unchecked_Union, Size => 8; for RTC_INTENCLR_RTC_MODE2_PER_Field use record Val at 0 range 0 .. 7; Arr at 0 range 0 .. 7; end record; -- RTC_INTENCLR_RTC_MODE2_ALARM array type RTC_INTENCLR_RTC_MODE2_ALARM_Field_Array is array (0 .. 1) of Boolean with Component_Size => 1, Size => 2; -- Type definition for RTC_INTENCLR_RTC_MODE2_ALARM type RTC_INTENCLR_RTC_MODE2_ALARM_Field (As_Array : Boolean := False) is record case As_Array is when False => -- ALARM as a value Val : HAL.UInt2; when True => -- ALARM as an array Arr : RTC_INTENCLR_RTC_MODE2_ALARM_Field_Array; end case; end record with Unchecked_Union, Size => 2; for RTC_INTENCLR_RTC_MODE2_ALARM_Field use record Val at 0 range 0 .. 1; Arr at 0 range 0 .. 1; end record; -- MODE2 Interrupt Enable Clear type RTC_INTENCLR_RTC_MODE2_Register is record -- Periodic Interval 0 Interrupt Enable PER : RTC_INTENCLR_RTC_MODE2_PER_Field := (As_Array => False, Val => 16#0#); -- Alarm 0 Interrupt Enable ALARM : RTC_INTENCLR_RTC_MODE2_ALARM_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_10_13 : HAL.UInt4 := 16#0#; -- Tamper Enable TAMPER : Boolean := False; -- Overflow Interrupt Enable OVF : Boolean := False; end record with Volatile_Full_Access, Object_Size => 16, Bit_Order => System.Low_Order_First; for RTC_INTENCLR_RTC_MODE2_Register use record PER at 0 range 0 .. 7; ALARM at 0 range 8 .. 9; Reserved_10_13 at 0 range 10 .. 13; TAMPER at 0 range 14 .. 14; OVF at 0 range 15 .. 15; end record; -- RTC_INTENSET_RTC_MODE2_PER array type RTC_INTENSET_RTC_MODE2_PER_Field_Array is array (0 .. 7) of Boolean with Component_Size => 1, Size => 8; -- Type definition for RTC_INTENSET_RTC_MODE2_PER type RTC_INTENSET_RTC_MODE2_PER_Field (As_Array : Boolean := False) is record case As_Array is when False => -- PER as a value Val : HAL.UInt8; when True => -- PER as an array Arr : RTC_INTENSET_RTC_MODE2_PER_Field_Array; end case; end record with Unchecked_Union, Size => 8; for RTC_INTENSET_RTC_MODE2_PER_Field use record Val at 0 range 0 .. 7; Arr at 0 range 0 .. 7; end record; -- RTC_INTENSET_RTC_MODE2_ALARM array type RTC_INTENSET_RTC_MODE2_ALARM_Field_Array is array (0 .. 1) of Boolean with Component_Size => 1, Size => 2; -- Type definition for RTC_INTENSET_RTC_MODE2_ALARM type RTC_INTENSET_RTC_MODE2_ALARM_Field (As_Array : Boolean := False) is record case As_Array is when False => -- ALARM as a value Val : HAL.UInt2; when True => -- ALARM as an array Arr : RTC_INTENSET_RTC_MODE2_ALARM_Field_Array; end case; end record with Unchecked_Union, Size => 2; for RTC_INTENSET_RTC_MODE2_ALARM_Field use record Val at 0 range 0 .. 1; Arr at 0 range 0 .. 1; end record; -- MODE2 Interrupt Enable Set type RTC_INTENSET_RTC_MODE2_Register is record -- Periodic Interval 0 Enable PER : RTC_INTENSET_RTC_MODE2_PER_Field := (As_Array => False, Val => 16#0#); -- Alarm 0 Interrupt Enable ALARM : RTC_INTENSET_RTC_MODE2_ALARM_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_10_13 : HAL.UInt4 := 16#0#; -- Tamper Enable TAMPER : Boolean := False; -- Overflow Interrupt Enable OVF : Boolean := False; end record with Volatile_Full_Access, Object_Size => 16, Bit_Order => System.Low_Order_First; for RTC_INTENSET_RTC_MODE2_Register use record PER at 0 range 0 .. 7; ALARM at 0 range 8 .. 9; Reserved_10_13 at 0 range 10 .. 13; TAMPER at 0 range 14 .. 14; OVF at 0 range 15 .. 15; end record; -- RTC_INTFLAG_RTC_MODE2_PER array type RTC_INTFLAG_RTC_MODE2_PER_Field_Array is array (0 .. 7) of Boolean with Component_Size => 1, Size => 8; -- Type definition for RTC_INTFLAG_RTC_MODE2_PER type RTC_INTFLAG_RTC_MODE2_PER_Field (As_Array : Boolean := False) is record case As_Array is when False => -- PER as a value Val : HAL.UInt8; when True => -- PER as an array Arr : RTC_INTFLAG_RTC_MODE2_PER_Field_Array; end case; end record with Unchecked_Union, Size => 8; for RTC_INTFLAG_RTC_MODE2_PER_Field use record Val at 0 range 0 .. 7; Arr at 0 range 0 .. 7; end record; -- RTC_INTFLAG_RTC_MODE2_ALARM array type RTC_INTFLAG_RTC_MODE2_ALARM_Field_Array is array (0 .. 1) of Boolean with Component_Size => 1, Size => 2; -- Type definition for RTC_INTFLAG_RTC_MODE2_ALARM type RTC_INTFLAG_RTC_MODE2_ALARM_Field (As_Array : Boolean := False) is record case As_Array is when False => -- ALARM as a value Val : HAL.UInt2; when True => -- ALARM as an array Arr : RTC_INTFLAG_RTC_MODE2_ALARM_Field_Array; end case; end record with Unchecked_Union, Size => 2; for RTC_INTFLAG_RTC_MODE2_ALARM_Field use record Val at 0 range 0 .. 1; Arr at 0 range 0 .. 1; end record; -- MODE2 Interrupt Flag Status and Clear type RTC_INTFLAG_RTC_MODE2_Register is record -- Periodic Interval 0 PER : RTC_INTFLAG_RTC_MODE2_PER_Field := (As_Array => False, Val => 16#0#); -- Alarm 0 ALARM : RTC_INTFLAG_RTC_MODE2_ALARM_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_10_13 : HAL.UInt4 := 16#0#; -- Tamper TAMPER : Boolean := False; -- Overflow OVF : Boolean := False; end record with Volatile_Full_Access, Object_Size => 16, Bit_Order => System.Low_Order_First; for RTC_INTFLAG_RTC_MODE2_Register use record PER at 0 range 0 .. 7; ALARM at 0 range 8 .. 9; Reserved_10_13 at 0 range 10 .. 13; TAMPER at 0 range 14 .. 14; OVF at 0 range 15 .. 15; end record; -- Debug Control type RTC_DBGCTRL_RTC_MODE2_Register is record -- Run During Debug DBGRUN : Boolean := False; -- unspecified Reserved_1_7 : HAL.UInt7 := 16#0#; end record with Volatile_Full_Access, Object_Size => 8, Bit_Order => System.Low_Order_First; for RTC_DBGCTRL_RTC_MODE2_Register use record DBGRUN at 0 range 0 .. 0; Reserved_1_7 at 0 range 1 .. 7; end record; -- RTC_SYNCBUSY_RTC_MODE2_ALARM array type RTC_SYNCBUSY_RTC_MODE2_ALARM_Field_Array is array (0 .. 1) of Boolean with Component_Size => 1, Size => 2; -- Type definition for RTC_SYNCBUSY_RTC_MODE2_ALARM type RTC_SYNCBUSY_RTC_MODE2_ALARM_Field (As_Array : Boolean := False) is record case As_Array is when False => -- ALARM as a value Val : HAL.UInt2; when True => -- ALARM as an array Arr : RTC_SYNCBUSY_RTC_MODE2_ALARM_Field_Array; end case; end record with Unchecked_Union, Size => 2; for RTC_SYNCBUSY_RTC_MODE2_ALARM_Field use record Val at 0 range 0 .. 1; Arr at 0 range 0 .. 1; end record; -- RTC_SYNCBUSY_RTC_MODE2_MASK array type RTC_SYNCBUSY_RTC_MODE2_MASK_Field_Array is array (0 .. 1) of Boolean with Component_Size => 1, Size => 2; -- Type definition for RTC_SYNCBUSY_RTC_MODE2_MASK type RTC_SYNCBUSY_RTC_MODE2_MASK_Field (As_Array : Boolean := False) is record case As_Array is when False => -- MASK as a value Val : HAL.UInt2; when True => -- MASK as an array Arr : RTC_SYNCBUSY_RTC_MODE2_MASK_Field_Array; end case; end record with Unchecked_Union, Size => 2; for RTC_SYNCBUSY_RTC_MODE2_MASK_Field use record Val at 0 range 0 .. 1; Arr at 0 range 0 .. 1; end record; -- RTC_SYNCBUSY_RTC_MODE2_GP array type RTC_SYNCBUSY_RTC_MODE2_GP_Field_Array is array (0 .. 3) of Boolean with Component_Size => 1, Size => 4; -- Type definition for RTC_SYNCBUSY_RTC_MODE2_GP type RTC_SYNCBUSY_RTC_MODE2_GP_Field (As_Array : Boolean := False) is record case As_Array is when False => -- GP as a value Val : HAL.UInt4; when True => -- GP as an array Arr : RTC_SYNCBUSY_RTC_MODE2_GP_Field_Array; end case; end record with Unchecked_Union, Size => 4; for RTC_SYNCBUSY_RTC_MODE2_GP_Field use record Val at 0 range 0 .. 3; Arr at 0 range 0 .. 3; end record; -- MODE2 Synchronization Busy Status type RTC_SYNCBUSY_RTC_MODE2_Register is record -- Read-only. Software Reset Bit Busy SWRST : Boolean; -- Read-only. Enable Bit Busy ENABLE : Boolean; -- Read-only. FREQCORR Register Busy FREQCORR : Boolean; -- Read-only. CLOCK Register Busy CLOCK : Boolean; -- unspecified Reserved_4_4 : HAL.Bit; -- Read-only. ALARM 0 Register Busy ALARM : RTC_SYNCBUSY_RTC_MODE2_ALARM_Field; -- unspecified Reserved_7_10 : HAL.UInt4; -- Read-only. MASK 0 Register Busy MASK : RTC_SYNCBUSY_RTC_MODE2_MASK_Field; -- unspecified Reserved_13_14 : HAL.UInt2; -- Read-only. Clock Synchronization Enable Bit Busy CLOCKSYNC : Boolean; -- Read-only. General Purpose 0 Register Busy GP : RTC_SYNCBUSY_RTC_MODE2_GP_Field; -- unspecified Reserved_20_31 : HAL.UInt12; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for RTC_SYNCBUSY_RTC_MODE2_Register use record SWRST at 0 range 0 .. 0; ENABLE at 0 range 1 .. 1; FREQCORR at 0 range 2 .. 2; CLOCK at 0 range 3 .. 3; Reserved_4_4 at 0 range 4 .. 4; ALARM at 0 range 5 .. 6; Reserved_7_10 at 0 range 7 .. 10; MASK at 0 range 11 .. 12; Reserved_13_14 at 0 range 13 .. 14; CLOCKSYNC at 0 range 15 .. 15; GP at 0 range 16 .. 19; Reserved_20_31 at 0 range 20 .. 31; end record; subtype RTC_FREQCORR_RTC_MODE2_VALUE_Field is HAL.UInt7; -- Frequency Correction type RTC_FREQCORR_RTC_MODE2_Register is record -- Correction Value VALUE : RTC_FREQCORR_RTC_MODE2_VALUE_Field := 16#0#; -- Correction Sign SIGN : Boolean := False; end record with Volatile_Full_Access, Object_Size => 8, Bit_Order => System.Low_Order_First; for RTC_FREQCORR_RTC_MODE2_Register use record VALUE at 0 range 0 .. 6; SIGN at 0 range 7 .. 7; end record; subtype RTC_CLOCK_RTC_MODE2_SECOND_Field is HAL.UInt6; subtype RTC_CLOCK_RTC_MODE2_MINUTE_Field is HAL.UInt6; -- Hour type CLOCK_HOURSelect is (-- AM when CLKREP in 12-hour AM, -- PM when CLKREP in 12-hour PM) with Size => 5; for CLOCK_HOURSelect use (AM => 0, PM => 16); subtype RTC_CLOCK_RTC_MODE2_DAY_Field is HAL.UInt5; subtype RTC_CLOCK_RTC_MODE2_MONTH_Field is HAL.UInt4; subtype RTC_CLOCK_RTC_MODE2_YEAR_Field is HAL.UInt6; -- MODE2 Clock Value type RTC_CLOCK_RTC_MODE2_Register is record -- Second SECOND : RTC_CLOCK_RTC_MODE2_SECOND_Field := 16#0#; -- Minute MINUTE : RTC_CLOCK_RTC_MODE2_MINUTE_Field := 16#0#; -- Hour HOUR : CLOCK_HOURSelect := SAM_SVD.RTC.AM; -- Day DAY : RTC_CLOCK_RTC_MODE2_DAY_Field := 16#0#; -- Month MONTH : RTC_CLOCK_RTC_MODE2_MONTH_Field := 16#0#; -- Year YEAR : RTC_CLOCK_RTC_MODE2_YEAR_Field := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for RTC_CLOCK_RTC_MODE2_Register use record SECOND at 0 range 0 .. 5; MINUTE at 0 range 6 .. 11; HOUR at 0 range 12 .. 16; DAY at 0 range 17 .. 21; MONTH at 0 range 22 .. 25; YEAR at 0 range 26 .. 31; end record; subtype ALARM_SECOND_Field is HAL.UInt6; subtype ALARM_MINUTE_Field is HAL.UInt6; -- Hour type ALARM0_HOURSelect is (-- Morning hour AM, -- Afternoon hour PM) with Size => 5; for ALARM0_HOURSelect use (AM => 0, PM => 16); subtype ALARM_DAY_Field is HAL.UInt5; subtype ALARM_MONTH_Field is HAL.UInt4; subtype ALARM_YEAR_Field is HAL.UInt6; -- MODE2_ALARM Alarm n Value type ALARM_Register is record -- Second SECOND : ALARM_SECOND_Field := 16#0#; -- Minute MINUTE : ALARM_MINUTE_Field := 16#0#; -- Hour HOUR : ALARM0_HOURSelect := SAM_SVD.RTC.AM; -- Day DAY : ALARM_DAY_Field := 16#0#; -- Month MONTH : ALARM_MONTH_Field := 16#0#; -- Year YEAR : ALARM_YEAR_Field := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for ALARM_Register use record SECOND at 0 range 0 .. 5; MINUTE at 0 range 6 .. 11; HOUR at 0 range 12 .. 16; DAY at 0 range 17 .. 21; MONTH at 0 range 22 .. 25; YEAR at 0 range 26 .. 31; end record; -- Alarm Mask Selection type MASK0_SELSelect is (-- Alarm Disabled OFF, -- Match seconds only SS, -- Match seconds and minutes only MMSS, -- Match seconds, minutes, and hours only HHMMSS, -- Match seconds, minutes, hours, and days only DDHHMMSS, -- Match seconds, minutes, hours, days, and months only MMDDHHMMSS, -- Match seconds, minutes, hours, days, months, and years YYMMDDHHMMSS) with Size => 3; for MASK0_SELSelect use (OFF => 0, SS => 1, MMSS => 2, HHMMSS => 3, DDHHMMSS => 4, MMDDHHMMSS => 5, YYMMDDHHMMSS => 6); -- MODE2_ALARM Alarm n Mask type MASK_Register is record -- Alarm Mask Selection SEL : MASK0_SELSelect := SAM_SVD.RTC.OFF; -- unspecified Reserved_3_7 : HAL.UInt5 := 16#0#; end record with Volatile_Full_Access, Object_Size => 8, Bit_Order => System.Low_Order_First; for MASK_Register use record SEL at 0 range 0 .. 2; Reserved_3_7 at 0 range 3 .. 7; end record; -- General Purpose -- General Purpose type RTC_GP_RTC_MODE2_Registers is array (0 .. 3) of HAL.UInt32; -- RTC_TAMPCTRL_RTC_MODE2_TAMLVL array type RTC_TAMPCTRL_RTC_MODE2_TAMLVL_Field_Array is array (0 .. 4) of Boolean with Component_Size => 1, Size => 5; -- Type definition for RTC_TAMPCTRL_RTC_MODE2_TAMLVL type RTC_TAMPCTRL_RTC_MODE2_TAMLVL_Field (As_Array : Boolean := False) is record case As_Array is when False => -- TAMLVL as a value Val : HAL.UInt5; when True => -- TAMLVL as an array Arr : RTC_TAMPCTRL_RTC_MODE2_TAMLVL_Field_Array; end case; end record with Unchecked_Union, Size => 5; for RTC_TAMPCTRL_RTC_MODE2_TAMLVL_Field use record Val at 0 range 0 .. 4; Arr at 0 range 0 .. 4; end record; -- RTC_TAMPCTRL_RTC_MODE2_DEBNC array type RTC_TAMPCTRL_RTC_MODE2_DEBNC_Field_Array is array (0 .. 4) of Boolean with Component_Size => 1, Size => 5; -- Type definition for RTC_TAMPCTRL_RTC_MODE2_DEBNC type RTC_TAMPCTRL_RTC_MODE2_DEBNC_Field (As_Array : Boolean := False) is record case As_Array is when False => -- DEBNC as a value Val : HAL.UInt5; when True => -- DEBNC as an array Arr : RTC_TAMPCTRL_RTC_MODE2_DEBNC_Field_Array; end case; end record with Unchecked_Union, Size => 5; for RTC_TAMPCTRL_RTC_MODE2_DEBNC_Field use record Val at 0 range 0 .. 4; Arr at 0 range 0 .. 4; end record; -- Tamper Control type RTC_TAMPCTRL_RTC_MODE2_Register is record -- Tamper Input 0 Action IN0ACT : TAMPCTRL_IN0ACTSelect := SAM_SVD.RTC.OFF; -- Tamper Input 1 Action IN1ACT : TAMPCTRL_IN1ACTSelect := SAM_SVD.RTC.OFF; -- Tamper Input 2 Action IN2ACT : TAMPCTRL_IN2ACTSelect := SAM_SVD.RTC.OFF; -- Tamper Input 3 Action IN3ACT : TAMPCTRL_IN3ACTSelect := SAM_SVD.RTC.OFF; -- Tamper Input 4 Action IN4ACT : TAMPCTRL_IN4ACTSelect := SAM_SVD.RTC.OFF; -- unspecified Reserved_10_15 : HAL.UInt6 := 16#0#; -- Tamper Level Select 0 TAMLVL : RTC_TAMPCTRL_RTC_MODE2_TAMLVL_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_21_23 : HAL.UInt3 := 16#0#; -- Debouncer Enable 0 DEBNC : RTC_TAMPCTRL_RTC_MODE2_DEBNC_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_29_31 : HAL.UInt3 := 16#0#; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for RTC_TAMPCTRL_RTC_MODE2_Register use record IN0ACT at 0 range 0 .. 1; IN1ACT at 0 range 2 .. 3; IN2ACT at 0 range 4 .. 5; IN3ACT at 0 range 6 .. 7; IN4ACT at 0 range 8 .. 9; Reserved_10_15 at 0 range 10 .. 15; TAMLVL at 0 range 16 .. 20; Reserved_21_23 at 0 range 21 .. 23; DEBNC at 0 range 24 .. 28; Reserved_29_31 at 0 range 29 .. 31; end record; subtype RTC_TIMESTAMP_RTC_MODE2_SECOND_Field is HAL.UInt6; subtype RTC_TIMESTAMP_RTC_MODE2_MINUTE_Field is HAL.UInt6; -- Hour Timestamp Value type TIMESTAMP_HOURSelect is (-- AM when CLKREP in 12-hour AM, -- PM when CLKREP in 12-hour PM) with Size => 5; for TIMESTAMP_HOURSelect use (AM => 0, PM => 16); subtype RTC_TIMESTAMP_RTC_MODE2_DAY_Field is HAL.UInt5; subtype RTC_TIMESTAMP_RTC_MODE2_MONTH_Field is HAL.UInt4; subtype RTC_TIMESTAMP_RTC_MODE2_YEAR_Field is HAL.UInt6; -- MODE2 Timestamp type RTC_TIMESTAMP_RTC_MODE2_Register is record -- Read-only. Second Timestamp Value SECOND : RTC_TIMESTAMP_RTC_MODE2_SECOND_Field; -- Read-only. Minute Timestamp Value MINUTE : RTC_TIMESTAMP_RTC_MODE2_MINUTE_Field; -- Read-only. Hour Timestamp Value HOUR : TIMESTAMP_HOURSelect; -- Read-only. Day Timestamp Value DAY : RTC_TIMESTAMP_RTC_MODE2_DAY_Field; -- Read-only. Month Timestamp Value MONTH : RTC_TIMESTAMP_RTC_MODE2_MONTH_Field; -- Read-only. Year Timestamp Value YEAR : RTC_TIMESTAMP_RTC_MODE2_YEAR_Field; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for RTC_TIMESTAMP_RTC_MODE2_Register use record SECOND at 0 range 0 .. 5; MINUTE at 0 range 6 .. 11; HOUR at 0 range 12 .. 16; DAY at 0 range 17 .. 21; MONTH at 0 range 22 .. 25; YEAR at 0 range 26 .. 31; end record; -- RTC_TAMPID_RTC_MODE2_TAMPID array type RTC_TAMPID_RTC_MODE2_TAMPID_Field_Array is array (0 .. 4) of Boolean with Component_Size => 1, Size => 5; -- Type definition for RTC_TAMPID_RTC_MODE2_TAMPID type RTC_TAMPID_RTC_MODE2_TAMPID_Field (As_Array : Boolean := False) is record case As_Array is when False => -- TAMPID as a value Val : HAL.UInt5; when True => -- TAMPID as an array Arr : RTC_TAMPID_RTC_MODE2_TAMPID_Field_Array; end case; end record with Unchecked_Union, Size => 5; for RTC_TAMPID_RTC_MODE2_TAMPID_Field use record Val at 0 range 0 .. 4; Arr at 0 range 0 .. 4; end record; -- Tamper ID type RTC_TAMPID_RTC_MODE2_Register is record -- Tamper Input 0 Detected TAMPID : RTC_TAMPID_RTC_MODE2_TAMPID_Field := (As_Array => False, Val => 16#0#); -- unspecified Reserved_5_30 : HAL.UInt26 := 16#0#; -- Tamper Event Detected TAMPEVT : Boolean := False; end record with Volatile_Full_Access, Object_Size => 32, Bit_Order => System.Low_Order_First; for RTC_TAMPID_RTC_MODE2_Register use record TAMPID at 0 range 0 .. 4; Reserved_5_30 at 0 range 5 .. 30; TAMPEVT at 0 range 31 .. 31; end record; -- Backup -- Backup type RTC_BKUP_RTC_MODE2_Registers is array (0 .. 7) of HAL.UInt32; -- Clock/Calendar with Alarm type RtcMode2_Cluster is record -- MODE2 Control A CTRLA : aliased RTC_CTRLA_RTC_MODE2_Register; -- MODE2 Control B CTRLB : aliased RTC_CTRLB_RTC_MODE2_Register; -- MODE2 Event Control EVCTRL : aliased RTC_EVCTRL_RTC_MODE2_Register; -- MODE2 Interrupt Enable Clear INTENCLR : aliased RTC_INTENCLR_RTC_MODE2_Register; -- MODE2 Interrupt Enable Set INTENSET : aliased RTC_INTENSET_RTC_MODE2_Register; -- MODE2 Interrupt Flag Status and Clear INTFLAG : aliased RTC_INTFLAG_RTC_MODE2_Register; -- Debug Control DBGCTRL : aliased RTC_DBGCTRL_RTC_MODE2_Register; -- MODE2 Synchronization Busy Status SYNCBUSY : aliased RTC_SYNCBUSY_RTC_MODE2_Register; -- Frequency Correction FREQCORR : aliased RTC_FREQCORR_RTC_MODE2_Register; -- MODE2 Clock Value CLOCK : aliased RTC_CLOCK_RTC_MODE2_Register; -- MODE2_ALARM Alarm n Value ALARM0 : aliased ALARM_Register; -- MODE2_ALARM Alarm n Mask MASK0 : aliased MASK_Register; -- MODE2_ALARM Alarm n Value ALARM1 : aliased ALARM_Register; -- MODE2_ALARM Alarm n Mask MASK1 : aliased MASK_Register; -- General Purpose GP : aliased RTC_GP_RTC_MODE2_Registers; -- Tamper Control TAMPCTRL : aliased RTC_TAMPCTRL_RTC_MODE2_Register; -- MODE2 Timestamp TIMESTAMP : aliased RTC_TIMESTAMP_RTC_MODE2_Register; -- Tamper ID TAMPID : aliased RTC_TAMPID_RTC_MODE2_Register; -- Backup BKUP : aliased RTC_BKUP_RTC_MODE2_Registers; end record with Size => 1280; for RtcMode2_Cluster use record CTRLA at 16#0# range 0 .. 15; CTRLB at 16#2# range 0 .. 15; EVCTRL at 16#4# range 0 .. 31; INTENCLR at 16#8# range 0 .. 15; INTENSET at 16#A# range 0 .. 15; INTFLAG at 16#C# range 0 .. 15; DBGCTRL at 16#E# range 0 .. 7; SYNCBUSY at 16#10# range 0 .. 31; FREQCORR at 16#14# range 0 .. 7; CLOCK at 16#18# range 0 .. 31; ALARM0 at 16#20# range 0 .. 31; MASK0 at 16#24# range 0 .. 7; ALARM1 at 16#28# range 0 .. 31; MASK1 at 16#2C# range 0 .. 7; GP at 16#40# range 0 .. 127; TAMPCTRL at 16#60# range 0 .. 31; TIMESTAMP at 16#64# range 0 .. 31; TAMPID at 16#68# range 0 .. 31; BKUP at 16#80# range 0 .. 255; end record; ----------------- -- Peripherals -- ----------------- type RTC_Disc is (Val_0, Val_1, Val_2); -- Real-Time Counter type RTC_Peripheral (Discriminent : RTC_Disc := Val_0) is record case Discriminent is when Val_0 => -- 32-bit Counter with Single 32-bit Compare RTC_MODE0 : aliased RtcMode0_Cluster; when Val_1 => -- 16-bit Counter with Two 16-bit Compares RTC_MODE1 : aliased RtcMode1_Cluster; when Val_2 => -- Clock/Calendar with Alarm RTC_MODE2 : aliased RtcMode2_Cluster; end case; end record with Unchecked_Union, Volatile; for RTC_Peripheral use record RTC_MODE0 at 0 range 0 .. 1279; RTC_MODE1 at 0 range 0 .. 1279; RTC_MODE2 at 0 range 0 .. 1279; end record; -- Real-Time Counter RTC_Periph : aliased RTC_Peripheral with Import, Address => RTC_Base; end SAM_SVD.RTC;
-- SPDX-FileCopyrightText: 2019 Max Reznik <reznikmm@gmail.com> -- -- SPDX-License-Identifier: MIT ------------------------------------------------------------- with Program.Lexical_Elements; with Program.Elements.Defining_Operator_Symbols; with Program.Element_Visitors; package Program.Nodes.Defining_Operator_Symbols is pragma Preelaborate; type Defining_Operator_Symbol is new Program.Nodes.Node and Program.Elements.Defining_Operator_Symbols .Defining_Operator_Symbol and Program.Elements.Defining_Operator_Symbols .Defining_Operator_Symbol_Text with private; function Create (Operator_Symbol_Token : not null Program.Lexical_Elements .Lexical_Element_Access) return Defining_Operator_Symbol; type Implicit_Defining_Operator_Symbol is new Program.Nodes.Node and Program.Elements.Defining_Operator_Symbols .Defining_Operator_Symbol with private; function Create (Is_Part_Of_Implicit : Boolean := False; Is_Part_Of_Inherited : Boolean := False; Is_Part_Of_Instance : Boolean := False) return Implicit_Defining_Operator_Symbol with Pre => Is_Part_Of_Implicit or Is_Part_Of_Inherited or Is_Part_Of_Instance; private type Base_Defining_Operator_Symbol is abstract new Program.Nodes.Node and Program.Elements.Defining_Operator_Symbols.Defining_Operator_Symbol with null record; procedure Initialize (Self : in out Base_Defining_Operator_Symbol'Class); overriding procedure Visit (Self : not null access Base_Defining_Operator_Symbol; Visitor : in out Program.Element_Visitors.Element_Visitor'Class); overriding function Is_Defining_Operator_Symbol (Self : Base_Defining_Operator_Symbol) return Boolean; overriding function Is_Defining_Name (Self : Base_Defining_Operator_Symbol) return Boolean; type Defining_Operator_Symbol is new Base_Defining_Operator_Symbol and Program.Elements.Defining_Operator_Symbols .Defining_Operator_Symbol_Text with record Operator_Symbol_Token : not null Program.Lexical_Elements .Lexical_Element_Access; end record; overriding function To_Defining_Operator_Symbol_Text (Self : in out Defining_Operator_Symbol) return Program.Elements.Defining_Operator_Symbols .Defining_Operator_Symbol_Text_Access; overriding function Operator_Symbol_Token (Self : Defining_Operator_Symbol) return not null Program.Lexical_Elements.Lexical_Element_Access; overriding function Image (Self : Defining_Operator_Symbol) return Text; type Implicit_Defining_Operator_Symbol is new Base_Defining_Operator_Symbol with record Is_Part_Of_Implicit : Boolean; Is_Part_Of_Inherited : Boolean; Is_Part_Of_Instance : Boolean; end record; overriding function To_Defining_Operator_Symbol_Text (Self : in out Implicit_Defining_Operator_Symbol) return Program.Elements.Defining_Operator_Symbols .Defining_Operator_Symbol_Text_Access; overriding function Is_Part_Of_Implicit (Self : Implicit_Defining_Operator_Symbol) return Boolean; overriding function Is_Part_Of_Inherited (Self : Implicit_Defining_Operator_Symbol) return Boolean; overriding function Is_Part_Of_Instance (Self : Implicit_Defining_Operator_Symbol) return Boolean; overriding function Image (Self : Implicit_Defining_Operator_Symbol) return Text; end Program.Nodes.Defining_Operator_Symbols;
-- This file is covered by the Internet Software Consortium (ISC) License -- Reference: ../License.txt private with Replicant.Platform; package PortScan.Packages is -- This routine first removes all invalid packages (package from removed -- port or older version) and inserts the origins of the remaining packages -- into the port list for a limited tree scan. procedure preclean_repository (repository : String); -- If performing a limited build run (likely 99% of the use cases), only -- the queued packages will be checked. The checks are limited to finding -- options changes and dependency changes. Obsolete packages (related or -- unrelated to upcoming build) are not removed; this would occur in -- clean_repository(). These old packages will not interfere at this step. procedure limited_sanity_check (repository : String; dry_run : Boolean; suppress_remote : Boolean); -- Iterate through the final build queue to remove any packages that -- match the current package names (currently unused) procedure remove_queue_packages (repository : String); -- This procedure empties the given repository without discrimination. -- (Well, it's limited to "*.txz" matches, but normally that's everything) -- (currently unused) procedure wipe_out_repository (repository : String); -- Sometimes, especially with the single ports-mgmt/pkg check, there is -- nothing left to do after the sanity check. Let's provide a way to -- detect that case. function queue_is_empty return Boolean; -- Returns the size of the queue before it was pared down. function original_queue_size return Natural; -- After the initial queue is created, and before the limited sanity -- check, we go through each port and check if it has cached options. -- If it does, then it's checked for validity. If it has too many or -- too few options, or an option's name doesn't match, the port is -- printed to stdout. The rest of the ports are checked, but at that -- point the function has failed. function limited_cached_options_check return Boolean; -- Returns True on success; stores value in global external_repository function located_external_repository return Boolean; -- Returns the value of the stored external repository function top_external_repository return String; -- Given the full path of a package, query it for the port origin function query_origin (fullpath : String) return String; -- Given the full path of a package plus its port origin, return origin(@flavor) function query_full_origin (fullpath, origin : String) return String; -- Given the full path of a package, query it for the package base name function query_pkgbase (fullpath : String) return String; private type dim_packages is array (scanners) of string_crate.Vector; stored_packages : dim_packages; stored_origins : dim_packages; pkgscan_progress : dim_progress := (others => 0); pkgscan_total : Natural := 0; abi_formats : Replicant.package_abi; external_repository : JT.Text; original_queue_len : AC.Count_Type; obsolete_pkg_log : TIO.File_Type; obsolete_log_open : Boolean := False; -- Debugging purposes only, can be turned on by environment variable debug_dep_check : Boolean := False; debug_opt_check : Boolean := False; -- This function returns "True" if the scanned options exactly match -- the options in the already-built package. Usually it's already known -- that a package exists before the function is called, but an existence -- check will be performed just in case (failure returns "False") function passed_option_check (repository : String; id : port_id; skip_exist_check : Boolean := False) return Boolean; -- This function returns "True" if the scanned dependencies match exactly -- what the current ports tree has. function passed_dependency_check (query_result : JT.Text; id : port_id) return Boolean; -- This function returns "True" if the scanned package has the expected -- package ABI, e.g. dragonfly:4.6:x86:64, freebsd:10:amd64 function passed_abi_check (repository : String; id : port_id; skip_exist_check : Boolean := False) return Boolean; -- This calculates the ABI for the platform and stores it. The value is -- used by passed_abi_check() procedure establish_package_architecture; -- Scan directory that contains the packages (*.txz) and stores the -- file names in the container. Returns False if no packages are found. function scan_repository (repository : String) return Boolean; -- standard method to spawn commands in this package (and get output) function generic_system_command (command : String) return JT.Text; -- Evaluates the stored options. If none exists, return True -- If Exists and all the options match exactly what has already been -- scanned for the port (names, not values) then return True else False. function passed_options_cache_check (id : port_id) return Boolean; -- For each package in the query, check the ABI and options (this is the -- only time they are checked). If those pass, query the dependencies, -- store the result, and check them. Set the "deletion" flag as needed. -- The dependency check is NOT performed yet. procedure initial_package_scan (repository : String; id : port_id); -- Same as above, but for packages in the external repository procedure remote_package_scan (id : port_id); -- The result of the dependency query giving "id" port_id function result_of_dependency_query (repository : String; id : port_id) return JT.Text; -- Using the same make_queue as was used to scan the ports, use tasks -- (up to 32) to do the initial scanning of the ports, including getting -- the pkg dependency query. procedure parallel_package_scan (repository : String; remote_scan : Boolean; show_progress : Boolean); -- Prior to this procedure, the list of existing packages is split as -- a balanced array so this scan will query the package for its origin -- and package name. If the origin still exists, the port will be -- scanned for the current package name. If either check fails, the -- package will be deleted, otherwise the origin will be preserved for -- a further in-depth check. procedure parallel_preliminary_package_scan (repository : String; show_progress : Boolean); -- given a port_id, return the package name (no .txz extension!) function id2pkgname (id : port_id) return String; -- Turn on option and dependency debug checks programmatically procedure activate_debugging_code; -- Given an origin (already validated) and the name of the package in -- focus, return True if "make -V PKGFILE:T" matches the filename function current_package_name (origin, file_name : String) return Boolean; -- Dedicated progress meter for prescanning packages function package_scan_progress return String; -- Open log to document packages that get deleted and the reason why procedure start_obsolete_package_logging; -- Write to log if open and optionally output a copy to screen. procedure obsolete_notice (message : String; write_to_screen : Boolean); end PortScan.Packages;
package test_image_p is type type1 is tagged private; type type3 is limited private; type type5 is tagged limited private; type a_type5_class is access all type5'Class; task type task_t (arg : access type3) is entry entry1; end task_t; function to_type1 (arg1 : in Integer) return type1; private type array_t is array (Positive range <>) of type1; type array_t2 is array (1 .. 3) of Boolean; type type1 is tagged record f2 : array_t2; end record; type type3 is limited record the_task : aliased task_t (type3'Access); the_array : array_t (1 .. 10) := (others => to_type1 (-1)); end record; type type5 is tagged limited record f3 : type3; end record; end;
------------------------------------------------------------------------------ -- -- -- Copyright (C) 2015-2019, AdaCore -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions are -- -- met: -- -- 1. Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- 2. Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in -- -- the documentation and/or other materials provided with the -- -- distribution. -- -- 3. Neither the name of the copyright holder nor the names of its -- -- contributors may be used to endorse or promote products derived -- -- from this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -- -- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -- -- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -- -- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -- -- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -- -- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- This packages provide a low level driver for the FAT file system -- architecture. It is recommended to _not_ use this interface directly but to -- access the file system using the File_IO package. For more info, see the -- file system chapter of the documentation. with System; with Interfaces; use Interfaces; with HAL; use HAL; with HAL.Block_Drivers; use HAL.Block_Drivers; with HAL.Filesystem; use HAL.Filesystem; package Filesystem.FAT is MAX_VOLUMES : constant := 1; -- Maximum number of mounted volumes MAX_FILENAME_LENGTH : constant := 255; -- Maximum size of a file or directory name MAX_FILE_HANDLES : constant := 10; -- Maximum number of handles opened simultaneously. MAX_DIR_HANDLES : constant := 10; -- Maximum number of handles opened simultaneously. type FAT_Name is private; type FAT_Filesystem is limited new Filesystem_Driver with private; type FAT_Filesystem_Access is access all FAT_Filesystem; type FAT_Node is new Node_Handle with private; ----------------------- -- PATH MANIPULATION -- ----------------------- function "-" (Name : FAT_Name) return String; function "-" (Name : String) return FAT_Name with Pre => Name'Length < MAX_FILENAME_LENGTH; overriding function "=" (Name1, Name2 : FAT_Name) return Boolean; function Is_Root (Path : String) return Boolean with Inline_Always; function Parent (Path : String) return String; function Basename (Path : String) return String; function Normalize (Path : String; Ensure_Dir : Boolean := False) return String; ------------------------ -- DIRECTORY HANDLING -- ------------------------ overriding function Open (FS : in out FAT_Filesystem; Path : String; Handle : out Any_Directory_Handle) return Status_Code; overriding function Root_Node (FS : in out FAT_Filesystem; As : String; Handle : out Any_Node_Handle) return Status_Code; function Long_Name (E : FAT_Node) return FAT_Name; function Short_Name (E : FAT_Node) return FAT_Name; overriding function Basename (E : FAT_Node) return String; overriding function Is_Read_Only (E : FAT_Node) return Boolean; overriding function Is_Hidden (E : FAT_Node) return Boolean; function Is_System_File (E : FAT_Node) return Boolean; overriding function Is_Symlink (E : FAT_Node) return Boolean; overriding function Is_Subdirectory (E : FAT_Node) return Boolean; function Is_Archive (E : FAT_Node) return Boolean; overriding function Size (E : FAT_Node) return File_Size; overriding procedure Close (E : in out FAT_Node); overriding function Get_FS (E : FAT_Node) return Any_Filesystem_Driver; ------------------- -- FILE HANDLING -- ------------------- overriding function Open (FS : in out FAT_Filesystem; Path : String; Mode : File_Mode; Handle : out Any_File_Handle) return Status_Code; overriding function Open (Parent : FAT_Node; Name : String; Mode : File_Mode; Handle : out Any_File_Handle) return Status_Code with Pre => Name'Length <= MAX_FILENAME_LENGTH; -------------------- -- FAT FILESYSTEM -- -------------------- function Open (Controller : HAL.Block_Drivers.Any_Block_Driver; LBA : Block_Number; FS : in out FAT_Filesystem) return Status_Code; -- Opens a FAT partition at the given LBA overriding procedure Close (FS : in out FAT_Filesystem); ----------------------- -- FAT FS PROPERTIES -- ----------------------- type FAT_Version is (FAT16, FAT32); function Version (FS : FAT_Filesystem) return FAT_Version; -- The FAT version of the volume function OEM_Name (FS : FAT_Filesystem) return String; -- The OEM Name of the Volume. Different from the Volume Label. function Is_Volume (FS : FAT_Filesystem) return Boolean; function Volume_ID (FS : FAT_Filesystem) return Unsigned_32; function Volume_Label (FS : FAT_Filesystem) return String; function File_System_Type (FS : FAT_Filesystem) return String; private type Cluster_Type is new Interfaces.Unsigned_32; subtype Valid_Cluster is Cluster_Type range 2 .. 16#0FFF_FFFF#; type Block_Offset is new Interfaces.Unsigned_32; type FAT_File_Size is new Interfaces.Unsigned_32; -- FAT Filesystem does not support files >= 4GB (e.g. 2**32) INVALID_CLUSTER : constant Cluster_Type := 0; FREE_CLUSTER_VALUE : constant Cluster_Type := 16#0000_0000#; LAST_CLUSTER_VALUE : constant Cluster_Type := 16#0FFF_FFFF#; BAD_CLUSTER_VALUE : constant Cluster_Type := 16#0FFF_FFF7#; function Get_Start_Cluster (E : FAT_Node) return Cluster_Type; function Size (E : FAT_Node) return FAT_File_Size; function Block_Size (FS : FAT_Filesystem) return FAT_File_Size; function Blocks_Per_Cluster (FS : FAT_Filesystem) return Block_Offset; function Cluster_Size (FS : FAT_Filesystem) return FAT_File_Size; function Reserved_Blocks (FS : FAT_Filesystem) return Unsigned_16; function Number_Of_FATs (FS : FAT_Filesystem) return Unsigned_8; function Total_Number_Of_Blocks (FS : FAT_Filesystem) return Unsigned_32; function FAT_Table_Size_In_Blocks (FS : FAT_Filesystem) return Unsigned_32; function Number_Of_Hidden_Blocks (FS : FAT_Filesystem) return Unsigned_32; function Root_Dir_Cluster (FS : FAT_Filesystem) return Cluster_Type; function FAT16_Root_Dir_Num_Entries (FS : FAT_Filesystem) return Unsigned_16; function Flags_For_FAT_Mirroring (FS : FAT_Filesystem) return Unsigned_16 with Pre => Version (FS) = FAT32; function FS_Version_Number (FS : FAT_Filesystem) return Unsigned_16 with Pre => Version (FS) = FAT32; function FSInfo_Block_Number (FS : FAT_Filesystem) return Unsigned_16 with Pre => Version (FS) = FAT32; function Boot_Block_Backup_Block_Number (FS : FAT_Filesystem) return Unsigned_16 with Pre => Version (FS) = FAT32; function Last_Known_Free_Data_Clusters_Number (FS : FAT_Filesystem) return Unsigned_32 with Pre => Version (FS) = FAT32; function Most_Recently_Allocated_Cluster (FS : FAT_Filesystem) return Cluster_Type with Pre => Version (FS) = FAT32; type FAT_Name is record Name : String (1 .. MAX_FILENAME_LENGTH); Len : Natural := 0; end record; type FAT_Disk_Parameter is record OEM_Name : String (1 .. 8); Block_Size_In_Bytes : Unsigned_16; Blocks_Per_Cluster : Unsigned_8; Reserved_Blocks : Unsigned_16; Number_Of_FATs : Unsigned_8; Root_Dir_Entries_Fat16 : Unsigned_16; Number_Of_Blocks_Fat16 : Unsigned_16; Removable_Drive : Boolean; Table_Size_Fat16 : Unsigned_16; Blocks_Per_Cylinder : Unsigned_16; Number_Of_Heads : Unsigned_16; Hidden_Blocks : Unsigned_32; Number_Of_Blocks_Fat32 : Unsigned_32; Table_Size_Fat32 : Unsigned_32; Fat_Mirroring_Flags : Unsigned_16; FS_Version_Number : Unsigned_16; Root_Directory_Cluster : Cluster_Type; FSInfo_Block_Number : Unsigned_16; Boot_Block_Backup_Block : Unsigned_16; Drive_Number_Fat32 : Unsigned_8; Current_Head_Fat32 : Unsigned_8; Boot_Signature_Fat32 : Unsigned_8; Volume_Id_Fat32 : Unsigned_32; Volume_Label_Fat32 : String (1 .. 11); FS_Type_Fat32 : String (1 .. 8); end record with Size => 92 * 8; for FAT_Disk_Parameter use record OEM_Name at 16#03# range 0 .. 63; Block_Size_In_Bytes at 16#0B# range 0 .. 15; Blocks_Per_Cluster at 16#0D# range 0 .. 7; Reserved_Blocks at 16#0E# range 0 .. 15; Number_Of_FATs at 16#10# range 0 .. 7; Root_Dir_Entries_Fat16 at 16#11# range 0 .. 15; Number_Of_Blocks_Fat16 at 16#13# range 0 .. 15; Removable_Drive at 16#15# range 2 .. 2; Table_Size_Fat16 at 16#16# range 0 .. 15; Blocks_Per_Cylinder at 16#18# range 0 .. 15; Number_Of_Heads at 16#1A# range 0 .. 15; Hidden_Blocks at 16#1C# range 0 .. 31; Number_Of_Blocks_Fat32 at 16#20# range 0 .. 31; Table_Size_Fat32 at 16#24# range 0 .. 31; Fat_Mirroring_Flags at 16#28# range 0 .. 15; FS_Version_Number at 16#2A# range 0 .. 15; Root_Directory_Cluster at 16#2C# range 0 .. 31; FSInfo_Block_Number at 16#30# range 0 .. 15; Boot_Block_Backup_Block at 16#32# range 0 .. 15; Drive_Number_Fat32 at 16#40# range 0 .. 7; Current_Head_Fat32 at 16#41# range 0 .. 7; Boot_Signature_Fat32 at 16#42# range 0 .. 7; Volume_Id_Fat32 at 16#43# range 0 .. 31; Volume_Label_Fat32 at 16#47# range 0 .. 87; FS_Type_Fat32 at 16#52# range 0 .. 63; end record; function Trim (S : String) return String; type FAT_FS_Info is record Signature : String (1 .. 4); Free_Clusters : Unsigned_32; Last_Allocated_Cluster : Cluster_Type; end record; for FAT_FS_Info use record Signature at 0 range 0 .. 31; Free_Clusters at 4 range 0 .. 31; Last_Allocated_Cluster at 8 range 0 .. 31; end record; type FAT_Filesystem is limited new Filesystem_Driver with record Initialized : Boolean := False; Disk_Parameters : FAT_Disk_Parameter; LBA : Block_Number; Controller : Any_Block_Driver; FSInfo : FAT_FS_Info; FSInfo_Changed : Boolean := False; Root_Dir_Area : Block_Offset := 0; Data_Area : Block_Offset; -- address to the data area, rel. to LBA FAT_Addr : Block_Offset; -- address to the FAT table, rel. to LBA Num_Clusters : Cluster_Type; Window_Block : Block_Offset := Block_Offset'Last; Window : Block (0 .. 511); FAT_Block : Block_Offset := Block_Offset'Last; FAT_Window : Block (0 .. 511); Root_Entry : aliased FAT_Node; end record; function Ensure_Block (FS : in out FAT_Filesystem; Block : Block_Offset) return Status_Code; -- Ensures the block is visible within the FS window. -- Block_Base_OFfset returns the index within the FS window of the block function Write_Window (FS : in out FAT_Filesystem) return Status_Code; function Cluster_To_Block (FS : FAT_Filesystem; Cluster : Cluster_Type) return Block_Offset is (FS.Data_Area + Block_Offset (Cluster - 2) * FS.Blocks_Per_Cluster); function "+" (Base : Block_Number; Off : Block_Offset) return Block_Number is (Base + Block_Number (Off)); function Get_FAT (FS : in out FAT_Filesystem; Cluster : Cluster_Type) return Cluster_Type; function Set_FAT (FS : in out FAT_Filesystem; Cluster : Cluster_Type; Value : Cluster_Type) return Status_Code; function Get_Free_Cluster (FS : in out FAT_Filesystem; Previous : Cluster_Type := INVALID_CLUSTER) return Cluster_Type; -- Retrieve a free cluster from the filesystem. -- Returns INVALID_CLUSTER in case the filesystem is full. procedure Write_FSInfo (FS : in out FAT_Filesystem); -- Writes back the FSInfo structure on the Filesystem function Is_Last_Cluster (FS : FAT_Filesystem; Ent : Cluster_Type) return Boolean is (case Version (FS) is when FAT16 => (Ent and 16#FFF8#) = 16#FFF8#, when FAT32 => (Ent and 16#0FFF_FFF8#) = 16#0FFF_FFF8#); -- return true if this is the last cluster for an entry function Is_Reserved_Cluster (FS : FAT_Filesystem; Ent : Cluster_Type) return Boolean is (case Version (FS) is when FAT16 => Ent > FS.Num_Clusters and Ent <= 16#FFF6#, when FAT32 => Ent > FS.Num_Clusters and Ent <= 16#0FFF_FFF6#); -- return true if this cluster is reserved function Is_Bad_Cluster (FS : FAT_Filesystem; Ent : Cluster_Type) return Boolean is (case Version (FS) is when FAT16 => (Ent and 16#FFF7#) = 16#FFF7#, when FAT32 => (Ent and 16#FFFF_FFF7#) = 16#FFFF_FFF7#); -- return true if this cluster is defective function Is_Free_Cluster (FS : FAT_Filesystem; Ent : Cluster_Type) return Boolean is ((Ent and 16#0FFF_FFFF#) = FREE_CLUSTER_VALUE); -- return true if the FAT entry indicates the cluster being unused function New_Cluster (FS : in out FAT_Filesystem) return Cluster_Type; function New_Cluster (FS : in out FAT_Filesystem; Previous : Cluster_Type) return Cluster_Type; type Entry_Index is new Unsigned_16; Null_Index : Entry_Index := 16#FFFF#; type FAT_Directory_Handle is limited new Directory_Handle with record Is_Free : Boolean := True; FS : FAT_Filesystem_Access; Current_Index : Entry_Index; Start_Cluster : Cluster_Type; Current_Cluster : Cluster_Type; Current_Block : Block_Offset; Current_Node : aliased FAT_Node; end record; type FAT_Directory_Handle_Access is access all FAT_Directory_Handle; type Any_FAT_Directory_Handle is access all FAT_Directory_Handle'Class; overriding function Get_FS (Dir : FAT_Directory_Handle) return Any_Filesystem_Driver; overriding function Read (Dir : in out FAT_Directory_Handle; Handle : out Any_Node_Handle) return Status_Code; overriding procedure Reset (Dir : in out FAT_Directory_Handle); overriding procedure Close (Dir : in out FAT_Directory_Handle); overriding function Create_File (This : in out FAT_Filesystem; Path : String) return Status_Code; overriding function Unlink (This : in out FAT_Filesystem; Path : String) return Status_Code; overriding function Remove_Directory (This : in out FAT_Filesystem; Path : String) return Status_Code; function FAT_Open (FS : in out FAT_Filesystem; Path : String; Handle : out FAT_Directory_Handle_Access) return Status_Code; function FAT_Open (D_Entry : FAT_Node; Handle : out FAT_Directory_Handle_Access) return Status_Code; type FAT_Directory_Entry_Attribute is record Read_Only : Boolean; Hidden : Boolean; System_File : Boolean; Volume_Label : Boolean; Subdirectory : Boolean; Archive : Boolean; end record with Size => 8, Pack; type FAT_Node is new Node_Handle with record FS : FAT_Filesystem_Access; L_Name : FAT_Name; S_Name : String (1 .. 8); S_Name_Ext : String (1 .. 3); Attributes : FAT_Directory_Entry_Attribute; Start_Cluster : Cluster_Type; -- The content of this entry Size : FAT_File_Size; Index : Entry_Index; -- Index of the FAT_Directory_Intry within Parent's content Is_Root : Boolean := False; -- Is it the root directory ? Is_Dirty : Boolean := False; -- Whether changes need to be written on disk end record; type FAT_File_Handle is limited new File_Handle with record Is_Free : Boolean := True; FS : FAT_Filesystem_Access; Mode : File_Mode; -- The current cluster from which we read or write Current_Cluster : Cluster_Type := 0; -- The current block from which we read or write, offset from -- current_cluster base block Current_Block : Block_Offset := 0; -- Buffer with the content of the current block Buffer : Block (0 .. 511); -- How much data in Buffer is meaningful Buffer_Filled : Boolean := False; -- Whether there's a discrepency between the disk data and the buffer Buffer_Dirty : Boolean := False; -- The actual file index File_Index : FAT_File_Size := 0; -- The associated directory entry D_Entry : FAT_Node; -- The parent's directory directory entry Parent : FAT_Node; end record; type FAT_File_Handle_Access is access all FAT_File_Handle; overriding function Get_FS (File : in out FAT_File_Handle) return Any_Filesystem_Driver; overriding function Size (File : FAT_File_Handle) return File_Size; overriding function Mode (File : FAT_File_Handle) return File_Mode; overriding function Read (File : in out FAT_File_Handle; Addr : System.Address; Length : in out File_Size) return Status_Code; -- read data from file. -- @return number of bytes read (at most Data'Length), or -1 on error. overriding function Offset (File : FAT_File_Handle) return File_Size; -- Current index within the file overriding function Write (File : in out FAT_File_Handle; Addr : System.Address; Length : File_Size) return Status_Code; -- write to file -- @return number of bytes written (at most Data'Length), or -1 on error. overriding function Flush (File : in out FAT_File_Handle) return Status_Code; -- force writing file to disk at this very moment (slow!) overriding function Seek (File : in out FAT_File_Handle; Origin : Seek_Mode; Amount : in out File_Size) return Status_Code; -- Moves the current file position to "Amount", according to the Origin -- parameter. If the command makes the file pointer move outside of the -- file, it stops at the file boundary and returns the actual amount of -- bytes moved. overriding procedure Close (File : in out FAT_File_Handle); -- invalidates the handle, and ensures that -- everything is flushed to the disk -- Type definition for implementation details, make them visible to all -- children of the package type FAT_Directory_Entry is record Filename : String (1 .. 8); Extension : String (1 .. 3); Attributes : FAT_Directory_Entry_Attribute; Reserved : String (1 .. 8); Cluster_H : Unsigned_16; Time : Unsigned_16; Date : Unsigned_16; Cluster_L : Unsigned_16; Size : FAT_File_Size; end record with Size => 32 * 8; for FAT_Directory_Entry use record Filename at 16#00# range 0 .. 63; Extension at 16#08# range 0 .. 23; Attributes at 16#0B# range 0 .. 7; Reserved at 16#0C# range 0 .. 63; Cluster_H at 16#14# range 0 .. 15; Time at 16#16# range 0 .. 15; Date at 16#18# range 0 .. 15; Cluster_L at 16#1A# range 0 .. 15; Size at 16#1C# range 0 .. 31; end record; VFAT_Directory_Entry_Attribute : constant FAT_Directory_Entry_Attribute := (Subdirectory => False, Archive => False, others => True); -- Attrite value 16#F0# defined at offset 16#0B# and identifying a VFAT -- entry rather than a regular directory entry type VFAT_Sequence_Number is mod 2 ** 6 with Size => 6; type VFAT_Sequence is record Sequence : VFAT_Sequence_Number; Stop_Bit : Boolean; end record with Size => 8; for VFAT_Sequence use record Sequence at 0 range 0 .. 5; Stop_Bit at 0 range 6 .. 7; end record; type VFAT_Directory_Entry is record VFAT_Attr : VFAT_Sequence; Name_1 : Wide_String (1 .. 5); Attribute : FAT_Directory_Entry_Attribute; Reserved : Unsigned_8 := 0; Checksum : Unsigned_8; Name_2 : Wide_String (1 .. 6); Cluster : Unsigned_16 := 0; Name_3 : Wide_String (1 .. 2); end record with Pack, Size => 32 * 8; -------------------------------------------------- -- Inlined implementations of utility functions -- -------------------------------------------------- function Version (FS : FAT_Filesystem) return FAT_Version is (if FS.Disk_Parameters.Root_Dir_Entries_Fat16 /= 0 then FAT16 else FAT32); function OEM_Name (FS : FAT_Filesystem) return String is (FS.Disk_Parameters.OEM_Name); function Block_Size (FS : FAT_Filesystem) return FAT_File_Size is (FAT_File_Size (FS.Disk_Parameters.Block_Size_In_Bytes)); function Blocks_Per_Cluster (FS : FAT_Filesystem) return Block_Offset is (Block_Offset (FS.Disk_Parameters.Blocks_Per_Cluster)); function Cluster_Size (FS : FAT_Filesystem) return FAT_File_Size is (FAT_File_Size (FS.Blocks_Per_Cluster) * FS.Block_Size); function Reserved_Blocks (FS : FAT_Filesystem) return Unsigned_16 is (FS.Disk_Parameters.Reserved_Blocks); function Number_Of_FATs (FS : FAT_Filesystem) return Unsigned_8 is (FS.Disk_Parameters.Number_Of_FATs); function Total_Number_Of_Blocks (FS : FAT_Filesystem) return Unsigned_32 is (FS.Disk_Parameters.Number_Of_Blocks_Fat32); function FAT_Table_Size_In_Blocks (FS : FAT_Filesystem) return Unsigned_32 is ((if FS.Version = FAT16 then Unsigned_32 (FS.Disk_Parameters.Table_Size_Fat16) else FS.Disk_Parameters.Table_Size_Fat32)); function Number_Of_Hidden_Blocks (FS : FAT_Filesystem) return Unsigned_32 is (FS.Disk_Parameters.Hidden_Blocks); function Is_Volume (FS : FAT_Filesystem) return Boolean is (FS.Disk_Parameters.Boot_Signature_Fat32 = 16#29#); function Volume_ID (FS : FAT_Filesystem) return Unsigned_32 is (if not Is_Volume (FS) then 0 else FS.Disk_Parameters.Volume_Id_Fat32); function Volume_Label (FS : FAT_Filesystem) return String is (if FS.Version = FAT16 then "UNKNOWN" elsif not Is_Volume (FS) then "UNKNOWN" else Trim (FS.Disk_Parameters.Volume_Label_Fat32)); function File_System_Type (FS : FAT_Filesystem) return String is (if FS.Version = FAT16 then "FAT16" elsif not Is_Volume (FS) then "FAT32" else Trim (FS.Disk_Parameters.FS_Type_Fat32)); function Flags_For_FAT_Mirroring (FS : FAT_Filesystem) return Unsigned_16 is (FS.Disk_Parameters.Fat_Mirroring_Flags); function FS_Version_Number (FS : FAT_Filesystem) return Unsigned_16 is (FS.Disk_Parameters.FS_Version_Number); function Root_Dir_Cluster (FS : FAT_Filesystem) return Cluster_Type is (FS.Disk_Parameters.Root_Directory_Cluster); function FAT16_Root_Dir_Num_Entries (FS : FAT_Filesystem) return Unsigned_16 is (FS.Disk_Parameters.Root_Dir_Entries_Fat16); function FSInfo_Block_Number (FS : FAT_Filesystem) return Unsigned_16 is (FS.Disk_Parameters.FSInfo_Block_Number); function Boot_Block_Backup_Block_Number (FS : FAT_Filesystem) return Unsigned_16 is (FS.Disk_Parameters.Boot_Block_Backup_Block); function Last_Known_Free_Data_Clusters_Number (FS : FAT_Filesystem) return Unsigned_32 is (FS.FSInfo.Free_Clusters); function Most_Recently_Allocated_Cluster (FS : FAT_Filesystem) return Cluster_Type is (FS.FSInfo.Last_Allocated_Cluster); function Get_Num_VFAT_Entries (Name : FAT_Name) return Natural is ((Name.Len + 12) / 13); -- Returns the number of VFAT Entries needed to encode 'Name' -- There's 13 characters in each entry, and we need Name.Len + 2 characters -- for the trailing ASCII.NUL + 0xFFFF sequence. overriding function Get_FS (Dir : FAT_Directory_Handle) return Any_Filesystem_Driver is (Any_Filesystem_Driver (Dir.FS)); overriding function Get_FS (File : in out FAT_File_Handle) return Any_Filesystem_Driver is (Any_Filesystem_Driver (File.FS)); overriding function Get_FS (E : FAT_Node) return Any_Filesystem_Driver is (Any_Filesystem_Driver (E.FS)); function Long_Name (E : FAT_Node) return FAT_Name is (if E.L_Name.Len > 0 then E.L_Name else Short_Name (E)); function Short_Name (E : FAT_Node) return FAT_Name is (-(Trim (E.S_Name) & (if E.S_Name_Ext /= " " then "." & E.S_Name_Ext else ""))); overriding function Basename (E : FAT_Node) return String is (-E.Long_Name); overriding function Is_Read_Only (E : FAT_Node) return Boolean is (E.Attributes.Read_Only); overriding function Is_Hidden (E : FAT_Node) return Boolean is (E.Attributes.Hidden); function Is_System_File (E : FAT_Node) return Boolean is (E.Attributes.System_File); overriding function Is_Subdirectory (E : FAT_Node) return Boolean is (E.Attributes.Subdirectory); function Is_Archive (E : FAT_Node) return Boolean is (E.Attributes.Archive); function Get_Start_Cluster (E : FAT_Node) return Cluster_Type is (E.Start_Cluster); function Size (E : FAT_Node) return FAT_File_Size is (E.Size); overriding function Is_Symlink (E : FAT_Node) return Boolean is (False); end Filesystem.FAT;
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME COMPONENTS -- -- -- -- ADA.STRINGS.TEXT_BUFFERS -- -- -- -- S p e c -- -- -- -- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. In accordance with the copyright of that document, you can freely -- -- copy and modify this specification, provided that if you redistribute a -- -- modified version, any changes that you have made are clearly indicated. -- -- -- ------------------------------------------------------------------------------ with Ada.Strings.UTF_Encoding; package Ada.Strings.Text_Buffers with Pure is type Text_Buffer_Count is range 0 .. Integer'Last; New_Line_Count : constant Text_Buffer_Count := 1; -- There is no support for two-character CR/LF line endings. type Root_Buffer_Type is abstract tagged limited private with Default_Initial_Condition => Current_Indent (Root_Buffer_Type) = 0; procedure Put (Buffer : in out Root_Buffer_Type; Item : String) is abstract; procedure Wide_Put (Buffer : in out Root_Buffer_Type; Item : Wide_String) is abstract; procedure Wide_Wide_Put (Buffer : in out Root_Buffer_Type; Item : Wide_Wide_String) is abstract; procedure Put_UTF_8 (Buffer : in out Root_Buffer_Type; Item : UTF_Encoding.UTF_8_String) is abstract; procedure Wide_Put_UTF_16 (Buffer : in out Root_Buffer_Type; Item : UTF_Encoding.UTF_16_Wide_String) is abstract; procedure New_Line (Buffer : in out Root_Buffer_Type) is abstract; Standard_Indent : constant Text_Buffer_Count := 3; function Current_Indent (Buffer : Root_Buffer_Type) return Text_Buffer_Count; procedure Increase_Indent (Buffer : in out Root_Buffer_Type; Amount : Text_Buffer_Count := Standard_Indent) with Post'Class => Current_Indent (Buffer) = Current_Indent (Buffer)'Old + Amount; procedure Decrease_Indent (Buffer : in out Root_Buffer_Type; Amount : Text_Buffer_Count := Standard_Indent) with Pre'Class => Current_Indent (Buffer) >= Amount -- or else raise Constraint_Error, or else Boolean'Val (Current_Indent (Buffer) - Amount), Post'Class => Current_Indent (Buffer) = Current_Indent (Buffer)'Old - Amount; private type Root_Buffer_Type is abstract tagged limited record Indentation : Natural := 0; -- Current indentation Indent_Pending : Boolean := True; -- Set by calls to New_Line, cleared when indentation emitted. UTF_8_Length : Natural := 0; -- Count of UTF_8 characters in the buffer UTF_8_Column : Positive := 1; -- Column in which next character will be written. -- Calling New_Line resets to 1. All_7_Bits : Boolean := True; -- True if all characters seen so far fit in 7 bits All_8_Bits : Boolean := True; -- True if all characters seen so far fit in 8 bits end record; generic -- This generic allows a client to extend Root_Buffer_Type without -- having to implement any of the abstract subprograms other than -- Put_UTF_8 (i.e., Put, Wide_Put, Wide_Wide_Put, Wide_Put_UTF_16, -- and New_Line). Without this generic, each client would have to -- duplicate the implementations of those 5 subprograms. -- This generic also takes care of handling indentation, thereby -- avoiding further code duplication. The name "Output_Mapping" isn't -- wonderful, but it refers to the idea that this package knows how -- to implement all the other output operations in terms of -- just Put_UTF_8. -- -- The classwide parameter type here is somewhat tricky; -- there are no dispatching calls associated with this parameter. -- It would be more accurate to say that the parameter is of type -- Output_Mapping.Buffer_Type'Class, but that type hasn't been declared -- yet. Instantiators will typically declare a non-abstract extension, -- B2, of the buffer type, B1, declared in their instantiation. The -- actual Put_UTF_8_Implementation parameter may then have a -- precondition "Buffer in B2'Class" and that subprogram can safely -- access components declared as part of the declaration of B2. with procedure Put_UTF_8_Implementation (Buffer : in out Root_Buffer_Type'Class; Item : UTF_Encoding.UTF_8_String); package Output_Mapping is type Buffer_Type is abstract new Root_Buffer_Type with null record; overriding procedure Put (Buffer : in out Buffer_Type; Item : String); overriding procedure Wide_Put (Buffer : in out Buffer_Type; Item : Wide_String); overriding procedure Wide_Wide_Put (Buffer : in out Buffer_Type; Item : Wide_Wide_String); overriding procedure Put_UTF_8 (Buffer : in out Buffer_Type; Item : UTF_Encoding.UTF_8_String); overriding procedure Wide_Put_UTF_16 (Buffer : in out Buffer_Type; Item : UTF_Encoding.UTF_16_Wide_String); overriding procedure New_Line (Buffer : in out Buffer_Type); end Output_Mapping; end Ada.Strings.Text_Buffers;
-- This file is covered by the Internet Software Consortium (ISC) License -- Reference: ../License.txt with Definitions; use Definitions; package Repository is -- returns True if CONSERVATIVE_UPGRADE option on host pkg(8) is enabled function host_pkg8_conservative_upgrade_set return Boolean; -- Create a pkg repo conf file (requires root permission) function write_pkg_repos_configuration_file return Boolean; -- Rebuild the local repository with pkg(8) procedure rebuild_local_respository (remove_invalid_packages : Boolean); private bad_command : exception; sorry : constant String := "The generated repository will not be signed due " & "to the misconfiguration."; -- Return the contents of the profile's signing command function signing_command return String; -- Return the contents of the profile's fingerprint function profile_fingerprint return String; -- The check for existence of both [profile]-signing_command and -- [profile]-fingerprint. If only one exists, a non-fatal notice is -- emitted without signing the repository. Returns True if both files -- exist and aren't empty. function valid_signing_command return Boolean; -- This checks for existence of both [profile]-public.key and -- [profile]-private.key. If only one exists, a non-fatal notice is -- emitted saying signing configuration is incomplete (repo will not be -- signed). The permissions for the private key will be checked, and if -- not 400 and owned by root, it will fail fatally. -- Returns False with fatal fail, otherwises it always returns True function acceptable_RSA_signing_support return Boolean; -- Return True if repo is configured to be built with RSA function set_raven_conf_with_RSA return Boolean; -- Returns ${LOCALBASE}/etc/raven/[profile]- function get_file_prefix return String; -- Returns octal failure of file permissions or "000" upon command failure function file_permissions (full_path : String) return String; -- Query pkg(8)'s repos_dir configuration instead of assuming default function get_repos_dir return String; -- This routine first removes all invalid packages (package from removed -- port or older version) and inserts the origins of the remaining packages -- into the port list for a limited tree scan. procedure preclean_repository (repository : String); -- The actual command to build a local repository (Returns True on success) function build_repository (sign_command : String := "") return Boolean; -- generic command, throws exception if exit code is not zero procedure silent_exec (command : String); end Repository;
with Ada.Text_IO; use Ada.Text_IO; with GNAT.Sockets; use GNAT.Sockets; with Ada.Strings.Unbounded; use Ada.Strings.Unbounded; with Plugin_Management; use Plugin_Management; with Ada.Command_Line; use Ada.Command_Line; with Plugin; with IRC; with Config; with Ada.Streams; use type Ada.Streams.Stream_Element_Count; procedure Byron is Invalid_Arguments : exception; Verbose : Boolean := False; begin if Argument_Count < 1 then raise Invalid_Arguments; elsif Argument (1) = "-v" then if Argument_Count < 2 then raise Invalid_Arguments; else Verbose := True; Config.Parse (Argument (2)); end if; else Config.Parse (Argument (1)); end if; declare Address : constant Sock_Addr_Type := (Addr => Addresses (Get_Host_By_Name (To_String (Config.Server))), Port => Port_Type (Config.Port), Family => Family_Inet); begin IRC.Connect_To (Address); IRC.Set_Nick (To_String (Config.Nick)); IRC.Identify (To_String (Config.Password)); for C in Plugin.Vectors.Iterate (Config.Channels) loop IRC.Join_Channel ('#' & To_String (Plugin.Vectors.Element (C))); end loop; loop declare Line : constant String := To_String (IRC.Get_Line); Message : constant IRC.Message := IRC.Get_Message; begin if Verbose then Put_Line (Line); end if; IRC.Pong; if Message.Mode = IRC.Modes (IRC.Privmsg) then Execute_Commands (Message, Config.Owner, Config.Prefix); end if; end; end loop; end; exception when Invalid_Arguments => Put_Line ("Usage: byron [-v] CONFIG_FILE"); Put_Line ("-v verbose mode"); end Byron;
-- Copyright 2016-2021 Bartek thindil Jasicki -- -- This file is part of Steam Sky. -- -- Steam Sky is free software: you can redistribute it and/or modify -- it under the terms of the GNU General Public License as published by -- the Free Software Foundation, either version 3 of the License, or -- (at your option) any later version. -- -- Steam Sky is distributed in the hope that it will be useful, -- but WITHOUT ANY WARRANTY; without even the implied warranty of -- MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -- GNU General Public License for more details. -- -- You should have received a copy of the GNU General Public License -- along with Steam Sky. If not, see <http://www.gnu.org/licenses/>. with Ada.Strings.Unbounded; use Ada.Strings.Unbounded; with Ada.Containers.Vectors; use Ada.Containers; with Ships; use Ships; with Game; use Game; -- ****h* Combat/Combat -- FUNCTION -- Provide code for ship to ship combat -- SOURCE package Combat is -- **** -- ****v* Combat/Combat.EnemyName -- FUNCTION -- Name of enemy -- SOURCE EnemyName: Unbounded_String := Null_Unbounded_String; -- **** -- ****v* Combat/Combat.PilotOrder, Combat.EngineerOrder -- FUNCTION -- Orders for crew members -- SOURCE PilotOrder, EngineerOrder: Natural := 0; -- **** -- ****t* Combat/Combat.GunsInfoArray -- FUNCTION -- Data structure for gun information: 1 - Gun index in ship modules -- list, 2 - Gunner order, 3 - Amount of shoots from the gun, value below -- zero means that gun shoot once per that amount of rounds -- SOURCE type GunsInfoArray is array(1 .. 3) of Integer with Default_Component_Value => 0; -- **** -- ****t* Combat/Combat.Guns_Container -- FUNCTION -- Used to store data for player ship guns -- SOURCE package Guns_Container is new Vectors(Positive, GunsInfoArray); -- **** -- ****v* Combat/Combat.Guns -- FUNCTION -- List of guns installed on player ship -- SOURCE Guns: Guns_Container.Vector; -- **** -- ****v* Combat/Combat.BoardingOrders -- FUNCTION -- List of orders for boarding party -- SOURCE BoardingOrders: Integer_Container.Vector; -- **** -- ****s* Combat/Combat.Enemy_Record -- FUNCTION -- Data structure for enemies -- PARAMETERS -- Ship - Ship data for enemy -- Accuracy - Bonus to accuracy -- Distance - Current distance to enemy -- CombatAI - Enemy in combat AI type -- Evasion - Bonus to evasion -- Loot - Amount of loot(money) looted from ship -- Perception - Bonus to perception -- HarpoonDuration - How long (amount of rounds) ship will be stopped by -- player harpoon -- Guns - List of guns installed on the enemy ship -- SOURCE type Enemy_Record is record Ship: Ship_Record; Accuracy: Natural := 0; Distance: Integer := 0; CombatAI: Ship_Combat_Ai; Evasion: Natural := 0; Loot: Natural := 0; Perception: Natural := 0; HarpoonDuration: Natural := 0; Guns: Guns_Container.Vector; end record; -- **** -- ****v* Combat/Combat.Enemy -- FUNCTION -- Enemy information -- SOURCE Enemy: Enemy_Record; -- **** -- ****v* Combat/Combat.EndCombat -- FUNCTION -- True if combat ends -- SOURCE EndCombat: Boolean; -- **** -- ****v* Combat/Combat.MessagesStarts -- FUNCTION -- Start index for showing messages -- SOURCE MessagesStarts: Natural; -- **** -- ****v* Combat/Combat.OldSpeed -- FUNCTION -- Speed of player ship before combat -- SOURCE OldSpeed: Ship_Speed := FULL_SPEED; -- **** -- ****v* Combat/Combat.HarpoonDuration -- FUNCTION -- How long (amount of rounds) player ship will be stopped by enemy harpoon -- SOURCE HarpoonDuration: Natural; -- **** -- ****v* Combat/Combat.EnemyShipIndex -- FUNCTION -- Prototype index of enemy ship -- SOURCE EnemyShipIndex: Unbounded_String; -- **** -- ****f* Combat/Combat.StartCombat -- FUNCTION -- Generate enemy and start battle -- PARAMETERS -- EnemyIndex - Index of prototype ship of enemy which will be created -- NewCombat - If true, it is a new combat. Default is true. -- RESULT -- True if combat starts, otherwise false -- SOURCE function StartCombat (EnemyIndex: Unbounded_String; NewCombat: Boolean := True) return Boolean with Pre => Proto_Ships_Container.Contains(Proto_Ships_List, EnemyIndex), Test_Case => (Name => "Test_StartCombat", Mode => Nominal); -- **** -- ****f* Combat/Combat.CombatTurn -- FUNCTION -- Count damage/ships actions, etc -- SOURCE procedure CombatTurn with Test_Case => (Name => "Test_CombatTurn", Mode => Robustness); -- **** end Combat;
package body agar.gui.widget.hsvpal is function widget (hsvpal : hsvpal_access_t) return widget_access_t is begin return hsvpal.widget'access; end widget; end agar.gui.widget.hsvpal;
-------------------------------------------------------------------------- -- ASnip Source Code Decorator -- Copyright (C) 2006, Georg Bauhaus -- -- 1. Permission is hereby granted to use, copy, modify and/or distribute -- this package, provided that: -- * copyright notices are retained unchanged, -- * any distribution of this package, whether modified or not, -- includes this license text. -- 2. Permission is hereby also granted to distribute binary programs which -- depend on this package. If the binary program depends on a modified -- version of this package, you are encouraged to publicly release the -- modified version of this package. -- -- THIS PACKAGE IS PROVIDED "AS IS" AND WITHOUT WARRANTY. ANY EXPRESS OR -- IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED -- WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE -- DISCLAIMED. IN NO EVENT SHALL THE AUTHORS BE LIABLE TO ANY PARTY FOR -- ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL -- DAMAGES ARISING IN ANY WAY OUT OF THE USE OF THIS PACKAGE. -------------------------------------------------------------------------- -- eMail: bauhaus@arcor.de with Ada.Text_IO; with standard_input_stream, standard_output_stream; with Ada.Command_Line; with Ada.Characters.Handling; with Ada.Exceptions; with ASnip.Token.Ada_Scanner; with ASnip.Printing.Ada_Like; with ASnip.IO; with Formatter.Ada_Like.HTML, Formatter.Ada_Like.Plain_Text, Formatter.Ada_Like.WEB, Formatter.Ada_Like.WiKiBook; with ASnip.Lang_Token.Sequences; procedure ASnip.main is use Ada.Text_IO, Token; input: IO.STREAM_ACCESS; output: IO.STREAM_ACCESS; lang: SUPPORTED_LANGUAGE; format: Formatter.SUPPORTED_FORMAT; invalid_command_line: exception; begin -- `ASnip.main` -- ---------------------------------------------------------------- -- Scan the command line. First, choose input language and output -- format from respective arguments, if possible. Then assign the -- reader and writer procedures. Start the machine using these -- settings. -- ---------------------------------------------------------------- if Ada.Command_Line.argument_count = 4 or Ada.Command_Line.argument_count = 6 then declare use Ada.Command_Line; lang_word: constant STRING := Ada.Characters.Handling.to_lower(argument(2)); format_word: constant STRING := Ada.Characters.Handling.to_upper(argument(4)); begin if argument(1) /= "from" or argument(3) /= "generate" then raise invalid_command_line; end if; if lang_word = "ada" then lang := L_Ada; else raise invalid_command_line; end if; if format_word = "HTML" then format := Formatter.HTML; elsif format_word = "TEXT" then format := Formatter.Plain_Text; elsif format_word = "TEX" then format := Formatter.TeX; elsif format_word = "WIKIBOOK" then format := Formatter.WiKiBook; else raise invalid_command_line; end if; end; else raise invalid_command_line; end if; if Ada.Command_Line.argument_count = 6 then -- an encoding has been specified force_enc: declare use Ada.Command_Line; begin if argument(5) /= "encoding" then raise invalid_command_line; end if; if argument(6) = "UTF-16" or argument(6) = "UTF-16LE" or argument(6) = "UTF-8" or (argument(6)'length >= 8 and then argument(6)(1..8) = "ISO-8859") then IO.set_reader(argument(6)); IO.set_writer(argument(6)); else raise invalid_command_line; end if; end force_enc; else IO.set_writer; IO.set_reader; end if; open_files: begin input := standard_input_stream; output := standard_output_stream; exception when e: Use_Error | Name_Error => put_line("Failed opening input file or output file"); put_line(Ada.Exceptions.exception_information(e)); end open_files; IO.set_output(output); -- `input` will be part of the scanner object pragma assert(lang'valid); pragma assert(format'valid); run: declare scanner: Ada_Scanner.ADA_SCANNER_OBJ(input); atoks: Lang_Token.Sequences.VECTOR; begin case lang is when L_Ada => format_Ada: declare --use Lang_Token.Ada_Like; begin Ada_Scanner.produce_simple_tokens(scanner); Ada_Scanner.produce_Ada_tokens(scanner, atoks); case format is when Formatter.HTML => declare use Formatter.Ada_Like.HTML; package HTML_Printers is new ASnip.Printing.Ada_Like; procedure tok_to_HTML is new IO.write_ada_like(HTML_Printers); procedure print_as_HTML is new Printing.visit_all_Ada_tokens(tok_to_HTML); begin print_as_HTML(atoks); end; when Formatter.Plain_Text => declare use Formatter.Ada_Like.Plain_Text; package Identities is new ASnip.Printing.Ada_Like; procedure tok_to_text is new IO.write_ada_like(Printers => Identities); procedure print_as_text is new Printing.visit_all_Ada_tokens(tok_to_text); begin print_as_text(atoks); end; when Formatter.TeX => declare use Formatter.Ada_Like.WEB; package Macros is new ASnip.Printing.Ada_Like; procedure tok_to_TeX is new IO.write_ada_like(Printers => Macros); procedure print_as_TeX is new Printing.visit_all_Ada_tokens(tok_to_TeX); begin print_as_TeX(atoks); end; when Formatter.WiKiBook => declare use Formatter.Ada_Like.WiKiBook; package Templates is new ASnip.Printing.Ada_Like; procedure tok_to_WiKi is new IO.write_ada_like(Printers => Templates); procedure print_as_WiKi is new Printing.visit_all_Ada_tokens(tok_to_WiKi); begin print_as_WiKi(atoks); IO.print_special(check_eot); end; end case; end format_Ada; end case; end run; exception when e: invalid_command_line => put_line(current_error, -- $Format: " \"ASnip $ProjectVersion$ ($ProjectDate$)\");"$ "ASnip R1.1 (Tue, 23 May 2006 13:24:56 +0200)"); put_line(current_error, "usage: asnip from {lang} generate {format}" & " [encoding {encoding}]"); new_line(current_error); put_line(current_error, Ada.Exceptions.exception_name(e)); end ASnip.main;
-- Test LU decomposition on a real valued square matrix. with Ada.Numerics.Generic_elementary_functions; with Crout_LU; with Text_IO; use Text_IO; with Test_Matrices; procedure crout_lu_tst_1 is type Real is digits 15; type Index is range 0..69; Starting_Index : constant Index := Index'First + 0; Final_Index : Index := Index'Last - 0; type Matrix is array(Index, Index) of Real; type Real_Extended is digits 18; -- use 18 on Intel for better error estimates. package math is new Ada.Numerics.Generic_elementary_functions(Real); --for Sqrt use math; package lu is new crout_lu (Real, Index, Matrix); use lu; package rio is new Float_IO(Real); use rio; package iio is new Integer_IO(Integer); use iio; package Make_Square_Matrix is new Test_Matrices (Real, Index, Matrix); use Make_Square_Matrix; e_Sum : Real_Extended; Sum : Real; Permute : Rearrangement; Scale : Scale_Vectors; Zero : constant Real := +0.0; One : constant Real := +1.0; Two : constant Real := +2.0; Min_Allowed_Real : constant Real := Two**(Real'Machine_Emin - Real'Machine_Emin / 8); Zero_Vector : constant Row_Vector := (others => Zero); A, A_LU, Err, L, U : Matrix := (others => (others => Zero)); Relative_Err : Real; IO_Final_Index : Integer := 4; Scale_the_Matrix : constant Boolean := True; ----------- -- Pause -- ----------- procedure Pause (s1,s2,s3,s4,s5,s6,s7,s8 : string := "") is Continue : Character := ' '; begin New_Line; if S1 /= "" then put_line (S1); end if; if S2 /= "" then put_line (S2); end if; if S3 /= "" then put_line (S3); end if; if S4 /= "" then put_line (S4); end if; if S5 /= "" then put_line (S5); end if; if S6 /= "" then put_line (S6); end if; if S7 /= "" then put_line (S7); end if; if S8 /= "" then put_line (S8); end if; new_line; begin put ("Enter a character to continue: "); get_immediate (Continue); new_line; exception when others => null; end; end pause; -------------------- -- Frobenius_Norm -- -------------------- function Frobenius_Norm (A : in Matrix; Final_Row : in Index := Final_Index; Final_Col : in Index := Final_Index; Starting_Row : in Index := Starting_Index; Starting_Col : in Index := Starting_Index) return Real is Max_A_Val : Real := Zero; Sum, Scaling, tmp : Real := Zero; begin Max_A_Val := Zero; for Row in Starting_Row .. Final_Row loop for Col in Starting_Col .. Final_Col loop if Max_A_Val < Abs A(Row, Col) then Max_A_Val := Abs A(Row, Col); end if; end loop; end loop; Scaling := One / (Max_A_Val + Min_Allowed_Real); Sum := Zero; for Row in Starting_Row .. Final_Row loop for Col in Starting_Col .. Final_Col loop tmp := Scaling * A(Row, Col); Sum := Sum + tmp * tmp; end loop; end loop; return Sqrt (Sum) * Max_A_Val; end Frobenius_Norm; begin put("Maximum matrix size is "& Integer'Image (Zero_Vector'length-(Integer(Starting_Index)-Integer(Index'First)))); new_Line; put("Input Size Of Matrix To Invert (enter an Integer)"); new_Line; get(IO_Final_Index); Final_Index := Index (Integer(Starting_Index) + IO_Final_Index - 1); Pause( "Test1: LU Decomposition of matrix A = P*L*U, where P is the permutation", "matrix that comes from Row pivoting. If 15 digit Reals are used, then we", "expect the error in the calculation of A = P*L*U to be (hopefully) a few", "parts per 10**15. In other words ||P*L*U - A|| / ||A|| should be a few", "multiples of 10**(-15). Here |*| denotes the Frobenius Norm. Other matrix", "norms give slightly different answers, so its an order of magnitude estimate.", " ", "Note: LU Decomp. with row pivoting always fails on (large) Peters_2 matrices." ); new_line; for Chosen_Matrix in Matrix_id loop put("For matrix of type "); put(Matrix_id'Image(Chosen_Matrix)); Put(":"); new_line; -- Get A: Init_Matrix (A, Chosen_Matrix, Starting_Index, Final_Index); -- Get A = P * L * U: A_LU := A; LU_decompose (A => A_LU, Scalings => Scale, Row_Permutation => Permute, Final_Index => Final_Index, Starting_Index => Starting_Index, Scaling_Desired => Scale_the_Matrix); -- if matrix A was scaled, then the L*U equals the scaled A. if Scale_the_Matrix then Scale_Cols_Then_Rows (A => A, Scalings => Scale, Final_Index => Final_Index, Starting_Index => Starting_Index); end if; for Row in Index loop for Col in Row .. Index'Last loop U(Row, Col) := A_LU(Row, Col); end loop; end loop; for Col in Index loop for Row in Col .. Index'Last loop L(Row, Col) := A_LU(Row, Col); end loop; end loop; for Col in Index loop L(Col, Col) := One; end loop; -- Multiply Original L and U as test. Get Max error: for I in Starting_Index .. Final_Index loop for J in Starting_Index .. Final_Index loop e_Sum := +0.0; for K in Starting_Index .. Final_Index loop e_Sum := e_Sum + Real_Extended (L(I, K)) * Real_Extended (U(K, J)); end loop; Sum:= Real(e_Sum); -- Product(I,J) := Sum; -- Calculate the error: Err(i, j) := Sum - A(Permute(i), j); end loop; end loop; Relative_Err := Frobenius_Norm (Err) / (Frobenius_Norm (A) + Min_Allowed_Real); put(" Err in A - P*L*U is ~ ||A - P*L*U|| / ||A|| ="); put(Relative_Err); new_line; end loop; -- Matrix_id end;
------------------------------------------------------------------------------ -- -- -- Matreshka Project -- -- -- -- Ada Modeling Framework -- -- -- -- Runtime Library Component -- -- -- ------------------------------------------------------------------------------ -- -- -- Copyright © 2012, Vadim Godunko <vgodunko@gmail.com> -- -- All rights reserved. -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions -- -- are met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in the -- -- documentation and/or other materials provided with the distribution. -- -- -- -- * Neither the name of the Vadim Godunko, IE nor the names of its -- -- contributors may be used to endorse or promote products derived from -- -- this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- -- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- -- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- -- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- -- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- -- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- $Revision$ $Date$ ------------------------------------------------------------------------------ -- This file is generated, don't edit it. ------------------------------------------------------------------------------ with AMF.Standard_Profile_L2.Auxiliaries; with AMF.Standard_Profile_L2.Calls; with AMF.Standard_Profile_L2.Creates; with AMF.Standard_Profile_L2.Derives; with AMF.Standard_Profile_L2.Destroies; with AMF.Standard_Profile_L2.Documents; with AMF.Standard_Profile_L2.Entities; with AMF.Standard_Profile_L2.Executables; with AMF.Standard_Profile_L2.Focuses; with AMF.Standard_Profile_L2.Frameworks; with AMF.Standard_Profile_L2.Implementation_Classes; with AMF.Standard_Profile_L2.Implements; with AMF.Standard_Profile_L2.Instantiates; with AMF.Standard_Profile_L2.Libraries; with AMF.Standard_Profile_L2.Metaclasses; with AMF.Standard_Profile_L2.Model_Libraries; with AMF.Standard_Profile_L2.Processes; with AMF.Standard_Profile_L2.Realizations; with AMF.Standard_Profile_L2.Refines; with AMF.Standard_Profile_L2.Responsibilities; with AMF.Standard_Profile_L2.Scripts; with AMF.Standard_Profile_L2.Sends; with AMF.Standard_Profile_L2.Services; with AMF.Standard_Profile_L2.Sources; with AMF.Standard_Profile_L2.Specifications; with AMF.Standard_Profile_L2.Subsystems; with AMF.Standard_Profile_L2.Traces; with AMF.Standard_Profile_L2.Types; with AMF.Standard_Profile_L2.Utilities; package AMF.Visitors.Standard_Profile_L2_Visitors is pragma Preelaborate; type Standard_Profile_L2_Visitor is limited interface and AMF.Visitors.Abstract_Visitor; not overriding procedure Enter_Auxiliary (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Auxiliaries.Standard_Profile_L2_Auxiliary_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Auxiliary (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Auxiliaries.Standard_Profile_L2_Auxiliary_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Call (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Calls.Standard_Profile_L2_Call_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Call (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Calls.Standard_Profile_L2_Call_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Create (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Creates.Standard_Profile_L2_Create_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Create (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Creates.Standard_Profile_L2_Create_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Derive (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Derives.Standard_Profile_L2_Derive_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Derive (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Derives.Standard_Profile_L2_Derive_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Destroy (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Destroies.Standard_Profile_L2_Destroy_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Destroy (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Destroies.Standard_Profile_L2_Destroy_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Document (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Documents.Standard_Profile_L2_Document_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Document (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Documents.Standard_Profile_L2_Document_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Entity (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Entities.Standard_Profile_L2_Entity_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Entity (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Entities.Standard_Profile_L2_Entity_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Executable (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Executables.Standard_Profile_L2_Executable_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Executable (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Executables.Standard_Profile_L2_Executable_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Focus (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Focuses.Standard_Profile_L2_Focus_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Focus (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Focuses.Standard_Profile_L2_Focus_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Framework (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Frameworks.Standard_Profile_L2_Framework_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Framework (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Frameworks.Standard_Profile_L2_Framework_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Implement (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Implements.Standard_Profile_L2_Implement_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Implement (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Implements.Standard_Profile_L2_Implement_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Implementation_Class (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Implementation_Classes.Standard_Profile_L2_Implementation_Class_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Implementation_Class (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Implementation_Classes.Standard_Profile_L2_Implementation_Class_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Instantiate (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Instantiates.Standard_Profile_L2_Instantiate_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Instantiate (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Instantiates.Standard_Profile_L2_Instantiate_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Library (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Libraries.Standard_Profile_L2_Library_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Library (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Libraries.Standard_Profile_L2_Library_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Metaclass (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Metaclasses.Standard_Profile_L2_Metaclass_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Metaclass (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Metaclasses.Standard_Profile_L2_Metaclass_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Model_Library (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Model_Libraries.Standard_Profile_L2_Model_Library_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Model_Library (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Model_Libraries.Standard_Profile_L2_Model_Library_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Process (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Processes.Standard_Profile_L2_Process_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Process (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Processes.Standard_Profile_L2_Process_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Realization (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Realizations.Standard_Profile_L2_Realization_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Realization (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Realizations.Standard_Profile_L2_Realization_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Refine (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Refines.Standard_Profile_L2_Refine_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Refine (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Refines.Standard_Profile_L2_Refine_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Responsibility (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Responsibilities.Standard_Profile_L2_Responsibility_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Responsibility (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Responsibilities.Standard_Profile_L2_Responsibility_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Script (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Scripts.Standard_Profile_L2_Script_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Script (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Scripts.Standard_Profile_L2_Script_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Send (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Sends.Standard_Profile_L2_Send_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Send (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Sends.Standard_Profile_L2_Send_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Service (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Services.Standard_Profile_L2_Service_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Service (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Services.Standard_Profile_L2_Service_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Source (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Sources.Standard_Profile_L2_Source_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Source (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Sources.Standard_Profile_L2_Source_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Specification (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Specifications.Standard_Profile_L2_Specification_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Specification (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Specifications.Standard_Profile_L2_Specification_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Subsystem (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Subsystems.Standard_Profile_L2_Subsystem_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Subsystem (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Subsystems.Standard_Profile_L2_Subsystem_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Trace (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Traces.Standard_Profile_L2_Trace_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Trace (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Traces.Standard_Profile_L2_Trace_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Type (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Types.Standard_Profile_L2_Type_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Type (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Types.Standard_Profile_L2_Type_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Enter_Utility (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Utilities.Standard_Profile_L2_Utility_Access; Control : in out AMF.Visitors.Traverse_Control) is null; not overriding procedure Leave_Utility (Self : in out Standard_Profile_L2_Visitor; Element : not null AMF.Standard_Profile_L2.Utilities.Standard_Profile_L2_Utility_Access; Control : in out AMF.Visitors.Traverse_Control) is null; end AMF.Visitors.Standard_Profile_L2_Visitors;
--////////////////////////////////////////////////////////// -- SFML - Simple and Fast Multimedia Library -- Copyright (C) 2007-2018 Laurent Gomila (laurent@sfml-dev.org) -- This software is provided 'as-is', without any express or implied warranty. -- In no event will the authors be held liable for any damages arising from the use of this software. -- Permission is granted to anyone to use this software for any purpose, -- including commercial applications, and to alter it and redistribute it freely, -- subject to the following restrictions: -- 1. The origin of this software must not be misrepresented; -- you must not claim that you wrote the original software. -- If you use this software in a product, an acknowledgment -- in the product documentation would be appreciated but is not required. -- 2. Altered source versions must be plainly marked as such, -- and must not be misrepresented as being the original software. -- 3. This notice may not be removed or altered from any source distribution. --////////////////////////////////////////////////////////// with Sf.System.Vector2; with Sf.Graphics.Transform; with Sf.Graphics.Color; with Sf.Graphics.Rect; package Sf.Graphics.Text is --////////////////////////////////////////////////////////// --/ sfText styles --////////////////////////////////////////////////////////// --/< Regular characters, no style --/< Bold characters --/< Italic characters --/< Underlined characters --/< Strike through characters subtype sfTextStyle is sfUint32; sfTextRegular : constant sfTextStyle := 0; sfTextBold : constant sfTextStyle := 1; sfTextItalic : constant sfTextStyle := 2; sfTextUnderlined : constant sfTextStyle := 4; sfTextStrikeThrough : constant sfTextStyle := 8; --////////////////////////////////////////////////////////// --/ @brief Create a new text --/ --/ @return A new sfText object, or NULL if it failed --/ --////////////////////////////////////////////////////////// function create return sfText_Ptr; --////////////////////////////////////////////////////////// --/ @brief Copy an existing text --/ --/ @param text Text to copy --/ --/ @return Copied object --/ --////////////////////////////////////////////////////////// function copy (text : sfText_Ptr) return sfText_Ptr; --////////////////////////////////////////////////////////// --/ @brief Destroy an existing text --/ --/ @param text Text to delete --/ --////////////////////////////////////////////////////////// procedure destroy (text : sfText_Ptr); --////////////////////////////////////////////////////////// --/ @brief Set the position of a text --/ --/ This function completely overwrites the previous position. --/ See sfText_move to apply an offset based on the previous position instead. --/ The default position of a text Text object is (0, 0). --/ --/ @param text Text object --/ @param position New position --/ --////////////////////////////////////////////////////////// procedure setPosition (text : sfText_Ptr; position : Sf.System.Vector2.sfVector2f); --////////////////////////////////////////////////////////// --/ @brief Set the orientation of a text --/ --/ This function completely overwrites the previous rotation. --/ See sfText_rotate to add an angle based on the previous rotation instead. --/ The default rotation of a text Text object is 0. --/ --/ @param text Text object --/ @param angle New rotation, in degrees --/ --////////////////////////////////////////////////////////// procedure setRotation (text : sfText_Ptr; angle : float); --////////////////////////////////////////////////////////// --/ @brief Set the scale factors of a text --/ --/ This function completely overwrites the previous scale. --/ See sfText_scale to add a factor based on the previous scale instead. --/ The default scale of a text Text object is (1, 1). --/ --/ @param text Text object --/ @param scale New scale factors --/ --////////////////////////////////////////////////////////// procedure setScale (text : sfText_Ptr; scale : Sf.System.Vector2.sfVector2f); --////////////////////////////////////////////////////////// --/ @brief Set the local origin of a text --/ --/ The origin of an object defines the center point for --/ all transformations (position, scale, rotation). --/ The coordinates of this point must be relative to the --/ top-left corner of the object, and ignore all --/ transformations (position, scale, rotation). --/ The default origin of a text object is (0, 0). --/ --/ @param text Text object --/ @param origin New origin --/ --////////////////////////////////////////////////////////// procedure setOrigin (text : sfText_Ptr; origin : Sf.System.Vector2.sfVector2f); --////////////////////////////////////////////////////////// --/ @brief Get the position of a text --/ --/ @param text Text object --/ --/ @return Current position --/ --////////////////////////////////////////////////////////// function getPosition (text : sfText_Ptr) return Sf.System.Vector2.sfVector2f; --////////////////////////////////////////////////////////// --/ @brief Get the orientation of a text --/ --/ The rotation is always in the range [0, 360]. --/ --/ @param text Text object --/ --/ @return Current rotation, in degrees --/ --////////////////////////////////////////////////////////// function getRotation (text : sfText_Ptr) return float; --////////////////////////////////////////////////////////// --/ @brief Get the current scale of a text --/ --/ @param text Text object --/ --/ @return Current scale factors --/ --////////////////////////////////////////////////////////// function getScale (text : sfText_Ptr) return Sf.System.Vector2.sfVector2f; --////////////////////////////////////////////////////////// --/ @brief Get the local origin of a text --/ --/ @param text Text object --/ --/ @return Current origin --/ --////////////////////////////////////////////////////////// function getOrigin (text : sfText_Ptr) return Sf.System.Vector2.sfVector2f; --////////////////////////////////////////////////////////// --/ @brief Move a text by a given offset --/ --/ This function adds to the current position of the object, --/ unlike sfText_setPosition which overwrites it. --/ --/ @param text Text object --/ @param offset Offset --/ --////////////////////////////////////////////////////////// procedure move (text : sfText_Ptr; offset : Sf.System.Vector2.sfVector2f); --////////////////////////////////////////////////////////// --/ @brief Rotate a text --/ --/ This function adds to the current rotation of the object, --/ unlike sfText_setRotation which overwrites it. --/ --/ @param text Text object --/ @param angle Angle of rotation, in degrees --/ --////////////////////////////////////////////////////////// procedure rotate (text : sfText_Ptr; angle : float); --////////////////////////////////////////////////////////// --/ @brief Scale a text --/ --/ This function multiplies the current scale of the object, --/ unlike sfText_setScale which overwrites it. --/ --/ @param text Text object --/ @param factors Scale factors --/ --////////////////////////////////////////////////////////// procedure scale (text : sfText_Ptr; factors : Sf.System.Vector2.sfVector2f); --////////////////////////////////////////////////////////// --/ @brief Get the combined transform of a text --/ --/ @param text Text object --/ --/ @return Transform combining the position/rotation/scale/origin of the object --/ --////////////////////////////////////////////////////////// function getTransform (text : sfText_Ptr) return Sf.Graphics.Transform.sfTransform; --////////////////////////////////////////////////////////// --/ @brief Get the inverse of the combined transform of a text --/ --/ @param text Text object --/ --/ @return Inverse of the combined transformations applied to the object --/ --////////////////////////////////////////////////////////// function getInverseTransform (text : sfText_Ptr) return Sf.Graphics.Transform.sfTransform; --////////////////////////////////////////////////////////// --/ @brief Set the string of a text (from an ANSI string) --/ --/ A text's string is empty by default. --/ --/ @param text Text object --/ @param str New string --/ --////////////////////////////////////////////////////////// procedure setString (text : sfText_Ptr; str : String); --////////////////////////////////////////////////////////// --/ @brief Set the string of a text (from a unicode string) --/ --/ @param text Text object --/ @param str New string --/ --////////////////////////////////////////////////////////// procedure setUnicodeString (text : sfText_Ptr; str : access sfUint32); --////////////////////////////////////////////////////////// --/ @brief Set the font of a text --/ --/ The @a font argument refers to a texture that must --/ exist as long as the text uses it. Indeed, the text --/ doesn't store its own copy of the font, but rather keeps --/ a pointer to the one that you passed to this function. --/ If the font is destroyed and the text tries to --/ use it, the behaviour is undefined. --/ --/ @param text Text object --/ @param font New font --/ --////////////////////////////////////////////////////////// procedure setFont (text : sfText_Ptr; font : sfFont_Ptr); --////////////////////////////////////////////////////////// --/ @brief Set the character size of a text --/ --/ The default size is 30. --/ --/ @param text Text object --/ @param size New character size, in pixels --/ --////////////////////////////////////////////////////////// procedure setCharacterSize (text : sfText_Ptr; size : sfUint32); --////////////////////////////////////////////////////////// --/ @brief Set the line spacing factor --/ --/ The default spacing between lines is defined by the font. --/ This method enables you to set a factor for the spacing --/ between lines. By default the line spacing factor is 1. --/ --/ @param text Text object --/ @param spacingFactor New line spacing factor --/ --/ @see sfText_getLineSpacing --/ --////////////////////////////////////////////////////////// procedure setLineSpacing (text : sfText_Ptr; spacingFactor : float); --////////////////////////////////////////////////////////// --/ @brief Set the letter spacing factor --/ --/ The default spacing between letters is defined by the font. --/ This factor doesn't directly apply to the existing --/ spacing between each character, it rather adds a fixed --/ space between them which is calculated from the font --/ metrics and the character size. --/ Note that factors below 1 (including negative numbers) bring --/ characters closer to each other. --/ By default the letter spacing factor is 1. --/ --/ @param text Text object --/ @param spacingFactor New letter spacing factor --/ --/ @see sfText_getLetterSpacing --/ --////////////////////////////////////////////////////////// procedure setLetterSpacing (text : sfText_Ptr; spacingFactor : float); --////////////////////////////////////////////////////////// --/ @brief Set the style of a text --/ --/ You can pass a combination of one or more styles, for --/ example sfTextBold | sfTextItalic. --/ The default style is sfTextRegular. --/ --/ @param text Text object --/ @param style New style --/ --////////////////////////////////////////////////////////// procedure setStyle (text : sfText_Ptr; style : sfTextStyle); --////////////////////////////////////////////////////////// --/ @brief Set the fill color of a text --/ --/ By default, the text's fill color is opaque white. --/ Setting the fill color to a transparent color with an outline --/ will cause the outline to be displayed in the fill area of the text. --/ --/ @param text Text object --/ @param color New fill color of the text --/ --/ @deprecated This function is deprecated and may be removed in future releases. --/ Use sfText_setFillColor instead. --/ --////////////////////////////////////////////////////////// procedure setColor (text : sfText_Ptr; color : Sf.Graphics.Color.sfColor); --////////////////////////////////////////////////////////// --/ @brief Set the fill color of a text --/ --/ By default, the text's fill color is opaque white. --/ Setting the fill color to a transparent color with an outline --/ will cause the outline to be displayed in the fill area of the text. --/ --/ @param text Text object --/ @param color New fill color of the text --/ --////////////////////////////////////////////////////////// procedure setFillColor (text : sfText_Ptr; color : Sf.Graphics.Color.sfColor); --////////////////////////////////////////////////////////// --/ @brief Set the outline color of the text --/ --/ By default, the text's outline color is opaque black. --/ --/ @param text Text object --/ @param color New outline color of the text --/ --////////////////////////////////////////////////////////// procedure setOutlineColor (text : sfText_Ptr; color : Sf.Graphics.Color.sfColor); --////////////////////////////////////////////////////////// --/ @brief Set the thickness of the text's outline --/ --/ By default, the outline thickness is 0. --/ --/ Be aware that using a negative value for the outline --/ thickness will cause distorted rendering. --/ --/ @param thickness New outline thickness, in pixels --/ --/ @see getOutlineThickness --/ --////////////////////////////////////////////////////////// procedure setOutlineThickness (text : sfText_Ptr; thickness : float); --////////////////////////////////////////////////////////// --/ @brief Get the string of a text (returns an ANSI string) --/ --/ @param text Text object --/ --/ @return String as a locale-dependant ANSI string --/ --////////////////////////////////////////////////////////// function getString (text : sfText_Ptr) return String; --////////////////////////////////////////////////////////// --/ @brief Get the string of a text (returns a unicode string) --/ --/ @param text Text object --/ --/ @return String as UTF-32 --/ --////////////////////////////////////////////////////////// function getUnicodeString (text : sfText_Ptr) return access sfUint32; --////////////////////////////////////////////////////////// --/ @brief Get the font used by a text --/ --/ If the text has no font attached, a NULL pointer is returned. --/ The returned pointer is const, which means that you can't --/ modify the font when you retrieve it with this function. --/ --/ @param text Text object --/ --/ @return Pointer to the font --/ --////////////////////////////////////////////////////////// function getFont (text : sfText_Ptr) return sfFont_Ptr; --////////////////////////////////////////////////////////// --/ @brief Get the size of the characters of a text --/ --/ @param text Text object --/ --/ @return Size of the characters --/ --////////////////////////////////////////////////////////// function getCharacterSize (text : sfText_Ptr) return sfUint32; --////////////////////////////////////////////////////////// --/ @brief Get the size of the letter spacing factor --/ --/ @param text Text object --/ --/ @return Size of the letter spacing factor --/ --/ @see sfText_setLetterSpacing --/ --////////////////////////////////////////////////////////// function getLetterSpacing (text : sfText_Ptr) return float; --////////////////////////////////////////////////////////// --/ @brief Get the size of the line spacing factor --/ --/ @param text Text object --/ --/ @return Size of the line spacing factor --/ --/ @see sfText_setLineSpacing --/ --////////////////////////////////////////////////////////// function getLineSpacing (text : sfText_Ptr) return float; --////////////////////////////////////////////////////////// --/ @brief Get the style of a text --/ --/ @param text Text object --/ --/ @return Current string style (see sfTextStyle enum) --/ --////////////////////////////////////////////////////////// function getStyle (text : sfText_Ptr) return sfTextStyle; --////////////////////////////////////////////////////////// --/ @brief Get the fill color of a text --/ --/ @param text Text object --/ --/ @return Fill color of the text --/ --/ @deprecated This function is deprecated and may be removed in future releases. --/ Use sfText_getFillColor instead. --/ --////////////////////////////////////////////////////////// function getColor (text : sfText_Ptr) return Sf.Graphics.Color.sfColor; --////////////////////////////////////////////////////////// --/ @brief Get the fill color of a text --/ --/ @param text Text object --/ --/ @return Fill color of the text --/ --////////////////////////////////////////////////////////// function getFillColor (text : sfText_Ptr) return Sf.Graphics.Color.sfColor; --////////////////////////////////////////////////////////// --/ @brief Get the outline color of a text --/ --/ @param text Text object --/ --/ @return Outline color of the text --/ --////////////////////////////////////////////////////////// function getOutlineColor (text : sfText_Ptr) return Sf.Graphics.Color.sfColor; --////////////////////////////////////////////////////////// --/ @brief Get the outline thickness of a text --/ --/ @param text Text object --/ --/ @return Outline thickness of a text, in pixels --/ --////////////////////////////////////////////////////////// function getOutlineThickness (text : sfText_Ptr) return float; --////////////////////////////////////////////////////////// --/ @brief Return the position of the @a index-th character in a text --/ --/ This function computes the visual position of a character --/ from its index in the string. The returned position is --/ in global coordinates (translation, rotation, scale and --/ origin are applied). --/ If @a index is out of range, the position of the end of --/ the string is returned. --/ --/ @param text Text object --/ @param index Index of the character --/ --/ @return Position of the character --/ --////////////////////////////////////////////////////////// function findCharacterPos (text : sfText_Ptr; index : sfSize_t) return Sf.System.Vector2.sfVector2f; --////////////////////////////////////////////////////////// --/ @brief Get the local bounding rectangle of a text --/ --/ The returned rectangle is in local coordinates, which means --/ that it ignores the transformations (translation, rotation, --/ scale, ...) that are applied to the entity. --/ In other words, this function returns the bounds of the --/ entity in the entity's coordinate system. --/ --/ @param text Text object --/ --/ @return Local bounding rectangle of the entity --/ --////////////////////////////////////////////////////////// function getLocalBounds (text : sfText_Ptr) return Sf.Graphics.Rect.sfFloatRect; --////////////////////////////////////////////////////////// --/ @brief Get the global bounding rectangle of a text --/ --/ The returned rectangle is in global coordinates, which means --/ that it takes in account the transformations (translation, --/ rotation, scale, ...) that are applied to the entity. --/ In other words, this function returns the bounds of the --/ text in the global 2D world's coordinate system. --/ --/ @param text Text object --/ --/ @return Global bounding rectangle of the entity --/ --////////////////////////////////////////////////////////// function getGlobalBounds (text : sfText_Ptr) return Sf.Graphics.Rect.sfFloatRect; private pragma Import (C, create, "sfText_create"); pragma Import (C, copy, "sfText_copy"); pragma Import (C, destroy, "sfText_destroy"); pragma Import (C, setPosition, "sfText_setPosition"); pragma Import (C, setRotation, "sfText_setRotation"); pragma Import (C, setScale, "sfText_setScale"); pragma Import (C, setOrigin, "sfText_setOrigin"); pragma Import (C, getPosition, "sfText_getPosition"); pragma Import (C, getRotation, "sfText_getRotation"); pragma Import (C, getScale, "sfText_getScale"); pragma Import (C, getOrigin, "sfText_getOrigin"); pragma Import (C, move, "sfText_move"); pragma Import (C, rotate, "sfText_rotate"); pragma Import (C, scale, "sfText_scale"); pragma Import (C, getTransform, "sfText_getTransform"); pragma Import (C, getInverseTransform, "sfText_getInverseTransform"); pragma Import (C, setUnicodeString, "sfText_setUnicodeString"); pragma Import (C, setFont, "sfText_setFont"); pragma Import (C, setCharacterSize, "sfText_setCharacterSize"); pragma Import (C, setLineSpacing, "sfText_setLineSpacing"); pragma Import (C, setLetterSpacing, "sfText_setLetterSpacing"); pragma Import (C, setStyle, "sfText_setStyle"); pragma Import (C, setColor, "sfText_setColor"); pragma Import (C, setFillColor, "sfText_setFillColor"); pragma Import (C, setOutlineColor, "sfText_setOutlineColor"); pragma Import (C, setOutlineThickness, "sfText_setOutlineThickness"); pragma Import (C, getUnicodeString, "sfText_getUnicodeString"); pragma Import (C, getFont, "sfText_getFont"); pragma Import (C, getCharacterSize, "sfText_getCharacterSize"); pragma Import (C, getLetterSpacing, "sfText_getLetterSpacing"); pragma Import (C, getLineSpacing, "getLineSpacing"); pragma Import (C, getStyle, "sfText_getStyle"); pragma Import (C, getColor, "sfText_getColor"); pragma Import (C, getFillColor, "sfText_getFillColor"); pragma Import (C, getOutlineColor, "sfText_getOutlineColor"); pragma Import (C, getOutlineThickness, "sfText_getOutlineThickness"); pragma Import (C, findCharacterPos, "sfText_findCharacterPos"); pragma Import (C, getLocalBounds, "sfText_getLocalBounds"); pragma Import (C, getGlobalBounds, "sfText_getGlobalBounds"); end Sf.Graphics.Text;
procedure Hello is begin I := 5+12; num := 5+12+val; I := 5-12; num := 5-12-val; num := 5*val; num := 5*val*max; num := 5/val; num := index/val/max; num := index+val/max; num := index*val-max; num := (index+val)*max; num := index+val/max*min; num := index+val*max/min; num := index+val*(max/min); num := index+val*max+min; end Hello;
with Ada.Text_IO; use Ada.Text_IO; with Ada.Integer_Text_IO; with Ada.Environment_Variables; with GNAT.String_Split; package body Loga is ---------------- -- New_Logger -- ---------------- Current_Color : Natural range Colors_As_Integer (Colors'Val (1)) .. Colors_As_Integer (Colors'Last) := Colors_As_Integer (Red); function New_Logger (Name : String; Color : Colors := Normal) return Logger is Result : Logger; package Env renames Ada.Environment_Variables; Debug_Env_Var : Unbounded_String; Vars_In_Debug_Env_Var : GNAT.String_Split.Slice_Set; function Contains_Wildcard (Var : String; Index : out Positive) return Boolean; function Contains_Wildcard (Var : String; Index : out Positive) return Boolean is begin for I in Var'Range loop if Var (I) = '*' then Index := I; return True; end if; end loop; return False; end Contains_Wildcard; begin begin Debug_Env_Var := To_Unbounded_String (Env.Value ("DEBUG")); exception when Constraint_Error => Result.Disabled := True; return Result; end; GNAT.String_Split.Create (S => Vars_In_Debug_Env_Var, From => To_String (Debug_Env_Var), Separators => ",", Mode => GNAT.String_Split.Multiple); for I in 1 .. GNAT.String_Split.Slice_Count (Vars_In_Debug_Env_Var) loop declare Var : constant String := GNAT.String_Split.Slice (Vars_In_Debug_Env_Var, I); Index_Of_Wildcard : Positive; begin if Name'Length >= Var'Length - 1 and then Contains_Wildcard (Var, Index_Of_Wildcard) then if Index_Of_Wildcard = 1 and then Var (2 .. Var'Length) = Name (Name'Last - Var'Length + 2 .. Name'Last) then Result.Disabled := False; elsif Index_Of_Wildcard = Var'Last and then Var (Var'First .. Var'Last - 1) = Name (Name'First .. Var'Length - 1) then Result.Disabled := False; end if; elsif Var = Name then Result.Disabled := False; exit; end if; end; end loop; if Result.Disabled then return Result; end if; Result.Name := To_Unbounded_String (Name); if Current_Color > Colors_As_Integer (Colors'Last) then Current_Color := Colors_As_Integer (Colors'Val (1)); end if; if Color /= Normal then Result.Color := Color; else Result.Color := Colors'Val (Current_Color - 30); end if; Current_Color := Current_Color + 1; return Result; end New_Logger; --------- -- Log -- --------- procedure Log (Self : Logger; Message : String) is procedure Colorize_Output (Color : Colors); function Start_Bold return String; function End_Bold return String; procedure Colorize_Output (Color : Colors) is use Ada.Integer_Text_IO; begin Put (Character'Val (27) & "["); Put (Colors_As_Integer (Color), Width => 0); Put ("m"); end Colorize_Output; function Start_Bold return String is begin return Character'Val (27) & "[1m"; end Start_Bold; function End_Bold return String is begin return Character'Val (27) & "[0m"; end End_Bold; begin if not Self.Disabled then Colorize_Output (Self.Color); Put (Start_Bold & " " & To_String (Self.Name) & End_Bold & " "); Colorize_Output (Normal); Put_Line (Message); end if; end Log; --------------- -- Get_Color -- --------------- function Get_Color (Self : Logger) return Colors is begin return Self.Color; end Get_Color; end Loga;
------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- S E M _ C H 2 -- -- -- -- B o d y -- -- -- -- Copyright (C) 1992-2020, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -- -- for more details. You should have received a copy of the GNU General -- -- Public License distributed with GNAT; see file COPYING3. If not, go to -- -- http://www.gnu.org/licenses for a complete copy of the license. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ with Atree; use Atree; with Einfo; use Einfo; with Namet; use Namet; with Opt; use Opt; with Restrict; use Restrict; with Rident; use Rident; with Sem_Ch8; use Sem_Ch8; with Sem_Dim; use Sem_Dim; with Sinfo; use Sinfo; with Stand; use Stand; with Uintp; use Uintp; package body Sem_Ch2 is ------------------------------- -- Analyze_Character_Literal -- ------------------------------- procedure Analyze_Character_Literal (N : Node_Id) is begin -- The type is eventually inherited from the context. If expansion -- has already established the proper type, do not modify it. if No (Etype (N)) then Set_Etype (N, Any_Character); end if; Set_Is_Static_Expression (N); if Comes_From_Source (N) and then not In_Character_Range (UI_To_CC (Char_Literal_Value (N))) then Check_Restriction (No_Wide_Characters, N); end if; end Analyze_Character_Literal; ------------------------ -- Analyze_Identifier -- ------------------------ procedure Analyze_Identifier (N : Node_Id) is begin -- Ignore call if prior errors, and identifier has no name, since -- this is the result of some kind of previous error generating a -- junk identifier. if not Is_Valid_Name (Chars (N)) and then Total_Errors_Detected /= 0 then return; else Find_Direct_Name (N); end if; Analyze_Dimension (N); end Analyze_Identifier; ----------------------------- -- Analyze_Integer_Literal -- ----------------------------- procedure Analyze_Integer_Literal (N : Node_Id) is begin -- As a lexical element, an integer literal has type Universal_Integer, -- i.e., is compatible with any integer type. This is semantically -- consistent and simplifies type checking and subsequent constant -- folding when needed. An exception is caused by 64-bit modular types, -- whose upper bound is not representable in a nonstatic context that -- will use 64-bit integers at run time. For such cases, we need to -- preserve the information that the analyzed literal has that modular -- type. For simplicity, we preserve the information for all integer -- literals that result from a modular operation. This happens after -- prior analysis (or construction) of the literal, and after type -- checking and resolution. if No (Etype (N)) or else not Is_Modular_Integer_Type (Etype (N)) then Set_Etype (N, Universal_Integer); end if; Set_Is_Static_Expression (N); end Analyze_Integer_Literal; -------------------------- -- Analyze_Real_Literal -- -------------------------- procedure Analyze_Real_Literal (N : Node_Id) is begin Set_Etype (N, Universal_Real); Set_Is_Static_Expression (N); end Analyze_Real_Literal; ---------------------------- -- Analyze_String_Literal -- ---------------------------- procedure Analyze_String_Literal (N : Node_Id) is begin -- The type is eventually inherited from the context. If expansion -- has already established the proper type, do not modify it. if No (Etype (N)) then Set_Etype (N, Any_String); end if; -- String literals are static in Ada 95. Note that if the subtype -- turns out to be non-static, then the Is_Static_Expression flag -- will be reset in Eval_String_Literal. if Ada_Version >= Ada_95 then Set_Is_Static_Expression (N); end if; if Comes_From_Source (N) and then Has_Wide_Character (N) then Check_Restriction (No_Wide_Characters, N); end if; end Analyze_String_Literal; end Sem_Ch2;
------------------------------------------------------------------------------- -- Copyright 2021, The Septum Developers (see AUTHORS file) -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- http://www.apache.org/licenses/LICENSE-2.0 -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ------------------------------------------------------------------------------- with SP.Strings; with Ada.Containers.Ordered_Maps; with Ada.Strings.Unbounded; -- Super simple text file caching. -- -- While `Async_File_Cache` provides parallel loading, access to the cache -- itself is protected. -- -- Provides a means to load entire directory structures into memory and then -- use it as needed. This is intended for text files only, in particular, to -- speed text searches of large read-only code bases. -- -- This is super simple and straightforward, but works well enough. -- It probably better done with mmap to load files directly to memory. It -- eliminates line-splitting when printing output. If this were in C++, -- it would be possible to do something like store the file as a huge byte -- block with mmap and then replace newlines with '\0' and store byte counts -- to the initial part of every string. -- package SP.Cache is use Ada.Strings.Unbounded; use SP.Strings; package File_Maps is new Ada.Containers.Ordered_Maps ( Key_Type => Ada.Strings.Unbounded.Unbounded_String, Element_Type => String_Vectors.Vector, "<" => Ada.Strings.Unbounded."<", "=" => String_Vectors."="); -- The available in-memory contents of files loaded from files. -- -- Files are stored by full path name, with the OS's preference for path -- separators. -- -- TODO: Add monitoring of files for changes. protected type Async_File_Cache is procedure Clear; -- Cache the contents of a file, replacing any existing contents. procedure Cache_File (File_Name : Unbounded_String; Lines : String_Vectors.Vector); -- The total number of loaded files in the file cache. function Num_Files return Natural; -- The total number of loaded lines in the file cache. function Num_Lines return Natural; function Lines (File_Name : Unbounded_String) return String_Vectors.Vector; function Files return String_Vectors.Vector; function File_Line (File_Name : Unbounded_String; Line : Positive) return Unbounded_String; private -- A list of all top level directories which need to be searched. Top_Level_Directories : SP.Strings.String_Sets.Set; Contents : File_Maps.Map; end Async_File_Cache; -- Adds a directory and all of its recursive subdirectories into the file cache. function Add_Directory_Recursively (A : in out Async_File_Cache; Dir : String) return Boolean; end SP.Cache;
with Ada.Text_IO; use Ada.Text_IO; with Ada.Strings.Unbounded; use Ada.Strings.Unbounded; package Synchronous_Concurrent is task Printer is entry Put(Item : in String); entry Get_Count(Count : out Natural); end Printer; end Synchronous_Concurrent;
-- part of OpenGLAda, (c) 2017 Felix Krause -- released under the terms of the MIT license, see the file "COPYING" with Glfw.API; package body Glfw.Display.Modes is function Available_Modes return Mode_List is Max_Modes : Integer := 32; Mode_Count : Integer; begin loop declare Raw_Modes : API.Video_Mode_List (1 .. Max_Modes); begin Mode_Count := Integer (API.Get_Video_Modes (Raw_Modes (1) (1)'Address, C.int (Max_Modes))); if (Mode_Count < Max_Modes) then declare Return_List : Mode_List (1 .. Mode_Count); begin for Index in Return_List'Range loop Return_List (Index) := Mode'(Width => Natural (Raw_Modes (Index) (1)), Height => Natural (Raw_Modes (Index) (2)), Red_Bits => Natural (Raw_Modes (Index) (3)), Green_Bits => Natural (Raw_Modes (Index) (4)), Blue_Bits => Natural (Raw_Modes (Index) (5))); end loop; return Return_List; end; end if; end; Max_Modes := Max_Modes * 2; end loop; end Available_Modes; function Desktop_Mode return Mode is Raw_Mode : aliased API.Raw_Video_Mode; begin API.Get_Desktop_Mode (Raw_Mode (1)'Access); return Mode'(Width => Natural (Raw_Mode (1)), Height => Natural (Raw_Mode (2)), Red_Bits => Natural (Raw_Mode (3)), Green_Bits => Natural (Raw_Mode (4)), Blue_Bits => Natural (Raw_Mode (5))); end Desktop_Mode; end Glfw.Display.Modes;
with Tkmrpc.Servers.Ike; with Tkmrpc.Response.Ike.Tkm_Version.Convert; package body Tkmrpc.Operation_Handlers.Ike.Tkm_Version is ------------------------------------------------------------------------- procedure Handle (Req : Request.Data_Type; Res : out Response.Data_Type) is pragma Unreferenced (Req); Specific_Res : Response.Ike.Tkm_Version.Response_Type; begin Specific_Res := Response.Ike.Tkm_Version.Null_Response; Servers.Ike.Tkm_Version (Result => Specific_Res.Header.Result, Version => Specific_Res.Data.Version); Res := Response.Ike.Tkm_Version.Convert.To_Response (S => Specific_Res); end Handle; end Tkmrpc.Operation_Handlers.Ike.Tkm_Version;
private with Interfaces.C.Strings, System; package FLTK.Widgets.Inputs is type Input is new Widget with private; type Input_Reference (Data : not null access Input'Class) is limited null record with Implicit_Dereference => Data; type Input_Kind is (Normal_Kind, Float_Kind, Integer_Kind, Multiline_Kind, Secret_Kind, Readonly_Kind, Wrap_Kind); package Forge is function Create (X, Y, W, H : in Integer; Text : in String) return Input; end Forge; procedure Copy (This : in out Input); procedure Cut (This : in out Input); procedure Cut (This : in out Input; Num_Bytes : in Integer); procedure Cut (This : in out Input; Start, Finish : in Integer); procedure Copy_Cuts (This : in out Input); procedure Undo (This : in out Input); function Has_Changed (This : in Input) return Boolean; procedure Clear_Changed (This : in out Input); function Is_Readonly (This : in Input) return Boolean; procedure Set_Readonly (This : in out Input; To : in Boolean); function Is_Tab_Nav (This : in Input) return Boolean; procedure Set_Tab_Nav (This : in out Input; To : in Boolean); function Is_Wrap (This : in Input) return Boolean; procedure Set_Wrap (This : in out Input; To : in Boolean); function Get_Input_Type (This : in Input) return Input_Kind; function Get_Shortcut_Key (This : in Input) return Key_Combo; procedure Set_Shortcut_Key (This : in out Input; To : in Key_Combo); function Get_Mark (This : in Input) return Natural; procedure Set_Mark (This : in out Input; To : in Natural); function Get_Position (This : in Input) return Natural; procedure Set_Position (This : in out Input; To : in Natural); function Index (This : in Input; Place : in Integer) return Character; procedure Insert (This : in out Input; Str : in String); procedure Replace (This : in out Input; From, To : in Natural; New_Text : in String); function Get_Value (This : in Input) return String; procedure Set_Value (This : in out Input; To : in String); function Get_Maximum_Size (This : in Input) return Natural; procedure Set_Maximum_Size (This : in out Input; To : in Natural); function Size (This : in Input) return Natural; function Get_Cursor_Color (This : in Input) return Color; procedure Set_Cursor_Color (This : in out Input; To : in Color); function Get_Text_Color (This : in Input) return Color; procedure Set_Text_Color (This : in out Input; To : in Color); function Get_Text_Font (This : in Input) return Font_Kind; procedure Set_Text_Font (This : in out Input; To : in Font_Kind); function Get_Text_Size (This : in Input) return Font_Size; procedure Set_Text_Size (This : in out Input; To : in Font_Size); procedure Resize (This : in out Input; W, H : in Integer); procedure Draw (This : in out Input); function Handle (This : in out Input; Event : in Event_Kind) return Event_Outcome; package Extra is procedure Set_Input_Type (This : in out Input; To : in Input_Kind); end Extra; private type Input is new Widget with record Was_Changed : Boolean := False; end record; overriding procedure Finalize (This : in out Input); pragma Inline (Copy); pragma Inline (Cut); pragma Inline (Copy_Cuts); pragma Inline (Undo); pragma Inline (Has_Changed); pragma Inline (Clear_Changed); pragma Inline (Is_Readonly); pragma Inline (Set_Readonly); pragma Inline (Is_Tab_Nav); pragma Inline (Set_Tab_Nav); pragma Inline (Is_Wrap); pragma Inline (Set_Wrap); pragma Inline (Get_Input_Type); pragma Inline (Get_Shortcut_Key); pragma Inline (Set_Shortcut_Key); pragma Inline (Get_Mark); pragma Inline (Set_Mark); pragma Inline (Get_Position); pragma Inline (Set_Position); pragma Inline (Index); pragma Inline (Insert); pragma Inline (Replace); pragma Inline (Get_Value); pragma Inline (Set_Value); pragma Inline (Get_Maximum_Size); pragma Inline (Set_Maximum_Size); pragma Inline (Size); pragma Inline (Get_Cursor_Color); pragma Inline (Set_Cursor_Color); pragma Inline (Get_Text_Color); pragma Inline (Set_Text_Color); pragma Inline (Get_Text_Font); pragma Inline (Set_Text_Font); pragma Inline (Get_Text_Size); pragma Inline (Set_Text_Size); pragma Inline (Resize); pragma Inline (Draw); pragma Inline (Handle); Input_Kind_Values : array (Input_Kind) of Interfaces.C.int := (Normal_Kind => 0, Float_Kind => 1, Integer_Kind => 2, Multiline_Kind => 4, Secret_Kind => 5, Readonly_Kind => 8, Wrap_Kind => 16); function fl_input_get_value (F : in System.Address) return Interfaces.C.Strings.chars_ptr; pragma Import (C, fl_input_get_value, "fl_input_get_value"); pragma Inline (fl_input_get_value); end FLTK.Widgets.Inputs;
with OpenAL.Thin; package body OpenAL.Source is use type Types.Size_t; -- -- Delete_Sources -- procedure Delete_Sources (Sources : in Source_Array_t) is begin Thin.Delete_Sources (Size => Sources'Length, Sources => Sources (Sources'First)'Address); end Delete_Sources; -- -- Generate_Sources -- procedure Generate_Sources (Sources : in out Source_Array_t) is begin Thin.Gen_Sources (Size => Sources'Length, Sources => Sources (Sources'First)'Address); end Generate_Sources; -- -- Get_Buffers_* -- procedure Get_Buffers_Processed (Source : in Source_t; Buffers : out Natural) is Value : aliased Types.Unsigned_Integer_t; begin Thin.Get_Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_BUFFERS_PROCESSED, Value => Value'Address); Buffers := Natural (Value); end Get_Buffers_Processed; procedure Get_Buffers_Queued (Source : in Source_t; Buffers : out Natural) is Value : aliased Types.Unsigned_Integer_t; begin Thin.Get_Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_BUFFERS_QUEUED, Value => Value'Address); Buffers := Natural (Value); end Get_Buffers_Queued; -- -- Get_Byte_Offset_* -- procedure Get_Byte_Offset_Discrete (Source : in Source_t; Distance : out Types.Integer_t) is Value : Types.Integer_t; begin Thin.Get_Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_BYTE_OFFSET, Value => Value'Address); Distance := Value; end Get_Byte_Offset_Discrete; procedure Get_Byte_Offset_Float (Source : in Source_t; Distance : out Types.Float_t) is Value : Types.Float_t; begin Thin.Get_Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_BYTE_OFFSET, Value => Value'Address); Distance := Value; end Get_Byte_Offset_Float; -- -- Get_Cone_Inner_Angle_* -- procedure Get_Cone_Inner_Angle_Discrete (Source : in Source_t; Distance : out Types.Integer_t) is Value : Types.Integer_t; begin Thin.Get_Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_CONE_INNER_ANGLE, Value => Value'Address); Distance := Value; end Get_Cone_Inner_Angle_Discrete; procedure Get_Cone_Inner_Angle_Float (Source : in Source_t; Distance : out Types.Float_t) is Value : Types.Float_t; begin Thin.Get_Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_CONE_INNER_ANGLE, Value => Value'Address); Distance := Value; end Get_Cone_Inner_Angle_Float; -- -- Get_Cone_Outer_Angle_* -- procedure Get_Cone_Outer_Angle_Discrete (Source : in Source_t; Distance : out Types.Integer_t) is Value : Types.Integer_t; begin Thin.Get_Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_CONE_OUTER_ANGLE, Value => Value'Address); Distance := Value; end Get_Cone_Outer_Angle_Discrete; procedure Get_Cone_Outer_Angle_Float (Source : in Source_t; Distance : out Types.Float_t) is Value : Types.Float_t; begin Thin.Get_Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_CONE_OUTER_ANGLE, Value => Value'Address); Distance := Value; end Get_Cone_Outer_Angle_Float; -- -- Get_Cone_Outer_Gain -- procedure Get_Cone_Outer_Gain (Source : in Source_t; Gain : out Types.Float_t) is Value : aliased Types.Float_t; begin Thin.Get_Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_CONE_OUTER_GAIN, Value => Value'Address); Gain := Value; end Get_Cone_Outer_Gain; -- -- Get_Current_Buffer -- procedure Get_Current_Buffer (Source : in Source_t; Buffer : out OpenAL.Buffer.Buffer_t) is Value : aliased Types.Unsigned_Integer_t; begin Thin.Get_Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_BUFFER, Value => Value'Address); Buffer := OpenAL.Buffer.From_Integer (Value); end Get_Current_Buffer; -- -- Get_Direction_* -- procedure Get_Direction_Discrete (Source : in Source_t; X : out Types.Integer_t; Y : out Types.Integer_t; Z : out Types.Integer_t) is V : aliased Types.Vector_3i_t; begin Get_Direction_Discrete_List (Source, V); X := V (1); Y := V (2); Z := V (3); end Get_Direction_Discrete; procedure Get_Direction_Discrete_List (Source : in Source_t; Direction : out Types.Vector_3i_t) is begin Thin.Get_Sourceiv (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_DIRECTION, Values => Direction (Direction'First)'Address); end Get_Direction_Discrete_List; procedure Get_Direction_Float (Source : in Source_t; X : out Types.Float_t; Y : out Types.Float_t; Z : out Types.Float_t) is V : aliased Types.Vector_3f_t; begin Get_Direction_Float_List (Source, V); X := V (1); Y := V (2); Z := V (3); end Get_Direction_Float; procedure Get_Direction_Float_List (Source : in Source_t; Direction : out Types.Vector_3f_t) is begin Thin.Get_Sourcefv (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_DIRECTION, Values => Direction (Direction'First)'Address); end Get_Direction_Float_List; -- -- Get_Gain -- procedure Get_Gain (Source : in Source_t; Gain : out Types.Float_t) is Value : aliased Types.Float_t; begin Thin.Get_Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_GAIN, Value => Value'Address); Gain := Value; end Get_Gain; -- -- Get_Looping -- procedure Get_Looping (Source : in Source_t; Looping : out Boolean) is Value : aliased Types.Integer_t; begin Thin.Get_Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_LOOPING, Value => Value'Address); Looping := Boolean'Val (Value); end Get_Looping; -- -- Get_Maximum_Distance_* -- procedure Get_Maximum_Distance_Discrete (Source : in Source_t; Distance : out Types.Integer_t) is Value : Types.Integer_t; begin Thin.Get_Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_MAX_DISTANCE, Value => Value'Address); Distance := Value; end Get_Maximum_Distance_Discrete; procedure Get_Maximum_Distance_Float (Source : in Source_t; Distance : out Types.Float_t) is Value : Types.Float_t; begin Thin.Get_Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_MAX_DISTANCE, Value => Value'Address); Distance := Value; end Get_Maximum_Distance_Float; -- -- Get_Maximum_Gain -- procedure Get_Maximum_Gain (Source : in Source_t; Gain : out Gain_t) is Value : aliased Gain_t; begin Thin.Get_Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_MAX_GAIN, Value => Value'Address); Gain := Value; end Get_Maximum_Gain; -- -- Get_Minimum_Gain -- procedure Get_Minimum_Gain (Source : in Source_t; Gain : out Gain_t) is Value : aliased Gain_t; begin Thin.Get_Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_MIN_GAIN, Value => Value'Address); Gain := Value; end Get_Minimum_Gain; -- -- Get_Pitch -- procedure Get_Pitch (Source : in Source_t; Pitch : out Pitch_t) is Value : aliased Pitch_t; begin Thin.Get_Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_PITCH, Value => Value'Address); Pitch := Value; end Get_Pitch; -- -- Get_Position_* -- procedure Get_Position_Discrete (Source : in Source_t; X : out Types.Integer_t; Y : out Types.Integer_t; Z : out Types.Integer_t) is V : aliased Types.Vector_3i_t; begin Get_Position_Discrete_List (Source, V); X := V (1); Y := V (2); Z := V (3); end Get_Position_Discrete; procedure Get_Position_Discrete_List (Source : in Source_t; Position : out Types.Vector_3i_t) is begin Thin.Get_Sourceiv (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_POSITION, Values => Position (Position'First)'Address); end Get_Position_Discrete_List; procedure Get_Position_Float (Source : in Source_t; X : out Types.Float_t; Y : out Types.Float_t; Z : out Types.Float_t) is V : aliased Types.Vector_3f_t; begin Get_Position_Float_List (Source, V); X := V (1); Y := V (2); Z := V (3); end Get_Position_Float; procedure Get_Position_Float_List (Source : in Source_t; Position : out Types.Vector_3f_t) is begin Thin.Get_Sourcefv (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_POSITION, Values => Position (Position'First)'Address); end Get_Position_Float_List; procedure Get_Positioning (Source : in Source_t; Relative : out Boolean) is Value : aliased Types.Integer_t; begin Thin.Get_Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_SOURCE_RELATIVE, Value => Value'Address); Relative := Boolean'Val (Value); end Get_Positioning; -- -- Get_Reference_Distance_* -- procedure Get_Reference_Distance_Discrete (Source : in Source_t; Distance : out Types.Integer_t) is Value : Types.Integer_t; begin Thin.Get_Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_REFERENCE_DISTANCE, Value => Value'Address); Distance := Value; end Get_Reference_Distance_Discrete; procedure Get_Reference_Distance_Float (Source : in Source_t; Distance : out Types.Float_t) is Value : Types.Float_t; begin Thin.Get_Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_REFERENCE_DISTANCE, Value => Value'Address); Distance := Value; end Get_Reference_Distance_Float; -- -- Get_Rolloff_Factor_* -- procedure Get_Rolloff_Factor_Discrete (Source : in Source_t; Distance : out Types.Integer_t) is Value : Types.Integer_t; begin Thin.Get_Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_ROLLOFF_FACTOR, Value => Value'Address); Distance := Value; end Get_Rolloff_Factor_Discrete; procedure Get_Rolloff_Factor_Float (Source : in Source_t; Distance : out Types.Float_t) is Value : Types.Float_t; begin Thin.Get_Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_ROLLOFF_FACTOR, Value => Value'Address); Distance := Value; end Get_Rolloff_Factor_Float; -- -- Get_Sample_Offset_* -- procedure Get_Sample_Offset_Discrete (Source : in Source_t; Distance : out Types.Integer_t) is Value : Types.Integer_t; begin Thin.Get_Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_SAMPLE_OFFSET, Value => Value'Address); Distance := Value; end Get_Sample_Offset_Discrete; procedure Get_Sample_Offset_Float (Source : in Source_t; Distance : out Types.Float_t) is Value : Types.Float_t; begin Thin.Get_Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_SAMPLE_OFFSET, Value => Value'Address); Distance := Value; end Get_Sample_Offset_Float; -- -- Get_Seconds_Offset_* -- procedure Get_Seconds_Offset_Discrete (Source : in Source_t; Distance : out Types.Integer_t) is Value : Types.Integer_t; begin Thin.Get_Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_SEC_OFFSET, Value => Value'Address); Distance := Value; end Get_Seconds_Offset_Discrete; procedure Get_Seconds_Offset_Float (Source : in Source_t; Distance : out Types.Float_t) is Value : Types.Float_t; begin Thin.Get_Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_SEC_OFFSET, Value => Value'Address); Distance := Value; end Get_Seconds_Offset_Float; -- -- Get_Type -- procedure Get_Type (Source : in Source_t; Source_Type : out Source_Type_t) is Value : aliased Types.Integer_t; begin Thin.Get_Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_SOURCE_TYPE, Value => Value'Address); case Value is when Thin.AL_UNDETERMINED => Source_Type := Undetermined; when Thin.AL_STATIC => Source_Type := Static; when Thin.AL_STREAMING => Source_Type := Streaming; when others => Source_Type := Unknown; end case; end Get_Type; -- -- Get_Velocity_* -- procedure Get_Velocity_Discrete (Source : in Source_t; X : out Types.Integer_t; Y : out Types.Integer_t; Z : out Types.Integer_t) is V : aliased Types.Vector_3i_t; begin Get_Velocity_Discrete_List (Source, V); X := V (1); Y := V (2); Z := V (3); end Get_Velocity_Discrete; procedure Get_Velocity_Discrete_List (Source : in Source_t; Velocity : out Types.Vector_3i_t) is begin Thin.Get_Sourceiv (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_VELOCITY, Values => Velocity (Velocity'First)'Address); end Get_Velocity_Discrete_List; procedure Get_Velocity_Float (Source : in Source_t; X : out Types.Float_t; Y : out Types.Float_t; Z : out Types.Float_t) is V : aliased Types.Vector_3f_t; begin Get_Velocity_Float_List (Source, V); X := V (1); Y := V (2); Z := V (3); end Get_Velocity_Float; procedure Get_Velocity_Float_List (Source : in Source_t; Velocity : out Types.Vector_3f_t) is begin Thin.Get_Sourcefv (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_VELOCITY, Values => Velocity (Velocity'First)'Address); end Get_Velocity_Float_List; -- -- Is_Valid -- function Is_Valid (Source : in Source_t) return Boolean is begin return Boolean (Thin.Is_Source (Types.Unsigned_Integer_t (Source))); end Is_Valid; -- -- Pause -- procedure Pause (Source : in Source_t) is begin Thin.Source_Pause (Types.Unsigned_Integer_t (Source)); end Pause; procedure Pause_List (Sources : in Source_Array_t) is begin Thin.Source_Pausev (Size => Sources'Length, Source_IDs => Sources (Sources'First)'Address); end Pause_List; -- -- Play -- procedure Play (Source : in Source_t) is begin Thin.Source_Play (Types.Unsigned_Integer_t (Source)); end Play; procedure Play_List (Sources : in Source_Array_t) is begin Thin.Source_Playv (Size => Sources'Length, Source_IDs => Sources (Sources'First)'Address); end Play_List; -- -- Queue_Buffers -- procedure Queue_Buffers (Source : in Source_t; Buffers : in OpenAL.Buffer.Buffer_Array_t) is begin Thin.Source_Queue_Buffers (Source_ID => Types.Unsigned_Integer_t (Source), Size => Buffers'Length, Buffer_IDs => Buffers (Buffers'First)'Address); end Queue_Buffers; -- -- Rewind -- procedure Rewind (Source : in Source_t) is begin Thin.Source_Rewind (Types.Unsigned_Integer_t (Source)); end Rewind; procedure Rewind_List (Sources : in Source_Array_t) is begin Thin.Source_Rewindv (Size => Sources'Length, Source_IDs => Sources (Sources'First)'Address); end Rewind_List; -- -- Set_Byte_Offset_* -- procedure Set_Byte_Offset_Discrete (Source : in Source_t; Distance : in Types.Integer_t) is begin Thin.Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_BYTE_OFFSET, Value => Distance); end Set_Byte_Offset_Discrete; procedure Set_Byte_Offset_Float (Source : in Source_t; Distance : in Types.Float_t) is begin Thin.Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_BYTE_OFFSET, Value => Distance); end Set_Byte_Offset_Float; -- -- Set_Cone_Inner_Angle_* -- procedure Set_Cone_Inner_Angle_Discrete (Source : in Source_t; Distance : in Types.Integer_t) is begin Thin.Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_CONE_INNER_ANGLE, Value => Distance); end Set_Cone_Inner_Angle_Discrete; procedure Set_Cone_Inner_Angle_Float (Source : in Source_t; Distance : in Types.Float_t) is begin Thin.Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_CONE_INNER_ANGLE, Value => Distance); end Set_Cone_Inner_Angle_Float; -- -- Set_Cone_Outer_Angle_* -- procedure Set_Cone_Outer_Angle_Discrete (Source : in Source_t; Distance : in Types.Integer_t) is begin Thin.Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_CONE_OUTER_ANGLE, Value => Distance); end Set_Cone_Outer_Angle_Discrete; procedure Set_Cone_Outer_Angle_Float (Source : in Source_t; Distance : in Types.Float_t) is begin Thin.Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_CONE_OUTER_ANGLE, Value => Distance); end Set_Cone_Outer_Angle_Float; -- -- Set_Cone_Outer_Gain -- procedure Set_Cone_Outer_Gain (Source : in Source_t; Gain : in Types.Float_t) is begin Thin.Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_CONE_OUTER_GAIN, Value => Gain); end Set_Cone_Outer_Gain; -- -- Set_Current_Buffer -- procedure Set_Current_Buffer (Source : in Source_t; Buffer : in OpenAL.Buffer.Buffer_t) is begin Thin.Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_BUFFER, Value => Types.Integer_t (OpenAL.Buffer.To_Integer (Buffer))); end Set_Current_Buffer; -- -- Set_Direction_* -- procedure Set_Direction_Discrete (Source : in Source_t; X : in Types.Integer_t; Y : in Types.Integer_t; Z : in Types.Integer_t) is begin Thin.Source_3i (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_DIRECTION, Value_1 => X, Value_2 => Y, Value_3 => Z); end Set_Direction_Discrete; procedure Set_Direction_Discrete_List (Source : in Source_t; Direction : in Types.Vector_3i_t) is begin Thin.Sourceiv (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_DIRECTION, Values => Direction (Direction'First)'Address); end Set_Direction_Discrete_List; procedure Set_Direction_Float (Source : in Source_t; X : in Types.Float_t; Y : in Types.Float_t; Z : in Types.Float_t) is begin Thin.Source_3f (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_DIRECTION, Value_1 => X, Value_2 => Y, Value_3 => Z); end Set_Direction_Float; procedure Set_Direction_Float_List (Source : in Source_t; Direction : in Types.Vector_3f_t) is begin Thin.Sourcefv (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_DIRECTION, Values => Direction (Direction'First)'Address); end Set_Direction_Float_List; -- -- Set_Gain -- procedure Set_Gain (Source : in Source_t; Gain : in Types.Float_t) is begin Thin.Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_GAIN, Value => Gain); end Set_Gain; -- -- Set_Looping -- procedure Set_Looping (Source : in Source_t; Looping : in Boolean) is begin Thin.Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_LOOPING, Value => Boolean'Pos (Looping)); end Set_Looping; -- -- Set_Maximum_Distance_* -- procedure Set_Maximum_Distance_Discrete (Source : in Source_t; Distance : in Types.Integer_t) is begin Thin.Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_MAX_DISTANCE, Value => Distance); end Set_Maximum_Distance_Discrete; procedure Set_Maximum_Distance_Float (Source : in Source_t; Distance : in Types.Float_t) is begin Thin.Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_MAX_DISTANCE, Value => Distance); end Set_Maximum_Distance_Float; -- -- Set_Maximum_Gain -- procedure Set_Maximum_Gain (Source : in Source_t; Gain : in Gain_t) is begin Thin.Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_MAX_GAIN, Value => Gain); end Set_Maximum_Gain; -- -- Set_Minimum_Gain -- procedure Set_Minimum_Gain (Source : in Source_t; Gain : in Gain_t) is begin Thin.Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_MIN_GAIN, Value => Gain); end Set_Minimum_Gain; -- -- Set_Pitch -- procedure Set_Pitch (Source : in Source_t; Pitch : in Pitch_t) is begin Thin.Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_PITCH, Value => Pitch); end Set_Pitch; -- -- Set_Position_* -- procedure Set_Position_Discrete (Source : in Source_t; X : in Types.Integer_t; Y : in Types.Integer_t; Z : in Types.Integer_t) is begin Thin.Source_3i (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_POSITION, Value_1 => X, Value_2 => Y, Value_3 => Z); end Set_Position_Discrete; procedure Set_Position_Discrete_List (Source : in Source_t; Position : in Types.Vector_3i_t) is begin Thin.Sourceiv (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_POSITION, Values => Position (Position'First)'Address); end Set_Position_Discrete_List; procedure Set_Position_Float (Source : in Source_t; X : in Types.Float_t; Y : in Types.Float_t; Z : in Types.Float_t) is begin Thin.Source_3f (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_POSITION, Value_1 => X, Value_2 => Y, Value_3 => Z); end Set_Position_Float; procedure Set_Position_Float_List (Source : in Source_t; Position : in Types.Vector_3f_t) is begin Thin.Sourcefv (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_POSITION, Values => Position (Position'First)'Address); end Set_Position_Float_List; procedure Set_Positioning (Source : in Source_t; Relative : in Boolean) is begin Thin.Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_SOURCE_RELATIVE, Value => Boolean'Pos (Relative)); end Set_Positioning; -- -- Set_Reference_Distance_* -- procedure Set_Reference_Distance_Discrete (Source : in Source_t; Distance : in Types.Integer_t) is begin Thin.Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_REFERENCE_DISTANCE, Value => Distance); end Set_Reference_Distance_Discrete; procedure Set_Reference_Distance_Float (Source : in Source_t; Distance : in Types.Float_t) is begin Thin.Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_REFERENCE_DISTANCE, Value => Distance); end Set_Reference_Distance_Float; -- -- Set_Rolloff_Factor_* -- procedure Set_Rolloff_Factor_Discrete (Source : in Source_t; Distance : in Types.Integer_t) is begin Thin.Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_ROLLOFF_FACTOR, Value => Distance); end Set_Rolloff_Factor_Discrete; procedure Set_Rolloff_Factor_Float (Source : in Source_t; Distance : in Types.Float_t) is begin Thin.Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_ROLLOFF_FACTOR, Value => Distance); end Set_Rolloff_Factor_Float; -- -- Set_Sample_Offset_* -- procedure Set_Sample_Offset_Discrete (Source : in Source_t; Distance : in Types.Integer_t) is begin Thin.Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_SAMPLE_OFFSET, Value => Distance); end Set_Sample_Offset_Discrete; procedure Set_Sample_Offset_Float (Source : in Source_t; Distance : in Types.Float_t) is begin Thin.Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_SAMPLE_OFFSET, Value => Distance); end Set_Sample_Offset_Float; -- -- Set_Seconds_Offset_* -- procedure Set_Seconds_Offset_Discrete (Source : in Source_t; Distance : in Types.Integer_t) is begin Thin.Sourcei (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_SEC_OFFSET, Value => Distance); end Set_Seconds_Offset_Discrete; procedure Set_Seconds_Offset_Float (Source : in Source_t; Distance : in Types.Float_t) is begin Thin.Sourcef (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_SEC_OFFSET, Value => Distance); end Set_Seconds_Offset_Float; -- -- Set_Velocity_* -- procedure Set_Velocity_Discrete (Source : in Source_t; X : in Types.Integer_t; Y : in Types.Integer_t; Z : in Types.Integer_t) is begin Thin.Source_3i (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_VELOCITY, Value_1 => X, Value_2 => Y, Value_3 => Z); end Set_Velocity_Discrete; procedure Set_Velocity_Discrete_List (Source : in Source_t; Velocity : in Types.Vector_3i_t) is begin Thin.Sourceiv (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_VELOCITY, Values => Velocity (Velocity'First)'Address); end Set_Velocity_Discrete_List; procedure Set_Velocity_Float (Source : in Source_t; X : in Types.Float_t; Y : in Types.Float_t; Z : in Types.Float_t) is begin Thin.Source_3f (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_VELOCITY, Value_1 => X, Value_2 => Y, Value_3 => Z); end Set_Velocity_Float; procedure Set_Velocity_Float_List (Source : in Source_t; Velocity : in Types.Vector_3f_t) is begin Thin.Sourcefv (Source_ID => Types.Unsigned_Integer_t (Source), Parameter => Thin.AL_VELOCITY, Values => Velocity (Velocity'First)'Address); end Set_Velocity_Float_List; -- -- Stop -- procedure Stop (Source : in Source_t) is begin Thin.Source_Stop (Types.Unsigned_Integer_t (Source)); end Stop; procedure Stop_List (Sources : in Source_Array_t) is begin Thin.Source_Stopv (Size => Sources'Length, Source_IDs => Sources (Sources'First)'Address); end Stop_List; -- -- To_Integer -- function To_Integer (Source : in Source_t) return Types.Unsigned_Integer_t is begin return Types.Unsigned_Integer_t (Source); end To_Integer; -- -- Unqueue_Buffers -- procedure Unqueue_Buffers (Source : in Source_t; Buffers : in OpenAL.Buffer.Buffer_Array_t) is begin Thin.Source_Unqueue_Buffers (Source_ID => Types.Unsigned_Integer_t (Source), Size => Buffers'Length, Buffer_IDs => Buffers (Buffers'First)'Address); end Unqueue_Buffers; end OpenAL.Source;
with Program.Parsers.On_Reduce_1; with Program.Parsers.On_Reduce_501; with Program.Parsers.On_Reduce_1001; with Program.Parsers.On_Reduce_1501; with Program.Parsers.On_Reduce_2001; procedure Program.Parsers.On_Reduce (Self : access Parse_Context; Prod : Anagram.Grammars.Production_Index; Nodes : in out Program.Parsers.Nodes.Node_Array) is begin case Prod is when 1 .. 500 => On_Reduce_1 (Self, Prod, Nodes); when 501 .. 1000 => On_Reduce_501 (Self, Prod, Nodes); when 1001 .. 1500 => On_Reduce_1001 (Self, Prod, Nodes); when 1501 .. 2000 => On_Reduce_1501 (Self, Prod, Nodes); when 2001 .. 2239 => On_Reduce_2001 (Self, Prod, Nodes); when others => raise Constraint_Error; end case; end Program.Parsers.On_Reduce;
-- Weather proxy device with Ada.Command_Line; with Ada.Text_IO; with GNAT.Formatted_String; with Ada.Calendar; with ZMQ; procedure WUPRoxy is use type Ada.Calendar.Time; use type GNAT.Formatted_String.Formatted_String; function Main return Ada.Command_Line.Exit_Status is begin declare Context : ZMQ.Context_Type := ZMQ.New_Context; -- This is where the weather server sits Frontend : ZMQ.Socket_Type'Class := Context.New_Socket (ZMQ.ZMQ_XSUB); -- This is our public endpoint for subscribers Backend : ZMQ.Socket_Type'Class := Context.New_Socket (ZMQ.ZMQ_XPUB); begin Frontend.Connect ("tcp://192.168.55.210:5556"); Backend.Bind ("tcp://10.1.1.0:8100"); -- Run the proxy until the user interrupts us ZMQ.Proxy (Frontend, Backend); -- We never get here... Backend.Close; Frontend.Close; Context.Term; end; return 0; end Main; begin Ada.Command_Line.Set_Exit_Status (Main); end WUPRoxy;
generic package any_Math.any_Analysis is pragma Pure; pragma Optimize (Time); end any_Math.any_Analysis;
with Lv.Style; with System; package Lv.Objx.Preload is subtype Instance is Obj_T; type Type_T is (Type_Spinning_Arc); type Style_T is (Style_Main); -- Create a pre loader objects -- @param par pointer to an object, it will be the parent of the new pre loader -- @param copy pointer to a pre loader object, if not NULL then the new object will be copied from it -- @return pointer to the created pre loader function Create (Parent : Obj_T; Copy : Instance) return Instance; ---------------------- -- Setter functions -- ---------------------- -- Set the length of the spinning arc in degrees -- @param self pointer to a preload object -- @param deg length of the arc procedure Set_Arc_Length (Self : Instance; Deg : Uint16_T); -- Set the spin time of the arc -- @param self pointer to a preload object -- @param time time of one round in milliseconds procedure Set_Spin_Time (Self : Instance; Time : Uint16_T); -- Set a style of a pre loader. -- @param self pointer to pre loader object -- @param type which style should be set -- @param style pointer to a style procedure Set_Style (Self : Instance; Type_P : Style_T; Style : access Lv.Style.Style); ---------------------- -- Getter functions -- ---------------------- -- Get the arc length [degree] of the a pre loader -- @param self pointer to a pre loader object function Get_Arc_Length (Self : Instance) return Uint16_T; -- Get the spin time of the arc -- @param self pointer to a pre loader object [milliseconds] function Get_Spin_Time (Self : Instance) return Uint16_T; -- Get style of a pre loader. -- @param self pointer to pre loader object -- @param type which style should be get -- @return style pointer to the style function Get_Style (Self : Instance; Type_P : Style_T) return access Lv.Style.Style; --------------------- -- Other functions -- --------------------- procedure Spinner_Animation (Arg1 : System.Address; Arg2 : Int32_T); ------------- -- Imports -- ------------- pragma Import (C, Create, "lv_preload_create"); pragma Import (C, Set_Arc_Length, "lv_preload_set_arc_length"); pragma Import (C, Set_Spin_Time, "lv_preload_set_spin_time"); pragma Import (C, Set_Style, "lv_preload_set_style"); pragma Import (C, Get_Arc_Length, "lv_preload_get_arc_length"); pragma Import (C, Get_Spin_Time, "lv_preload_get_spin_time"); pragma Import (C, Get_Style, "lv_preload_get_style"); pragma Import (C, Spinner_Animation, "lv_preload_spinner_animation"); for Type_T'Size use 8; for Type_T use (Type_Spinning_Arc => 0); for Style_T'Size use 8; for Style_T use (Style_Main => 0); end Lv.Objx.Preload;
-- -- 5.3 If Statements -- -- if_statement ::= -- if condition then -- sequence_of_statements -- {elsif condition then -- sequence_of_statements} -- [else -- sequence_of_statements] -- end if; -- -- condition ::= boolean_expression -- -- NOTE: This module is not compilation is used only for testing purposes -- procedure If_Statement is begin if (Month = December and Day = 31) then Month := January; Day := 1; Year := Year + 1; end if; if Line_Too_Short then raise Layout_Error; elsif Line_Full then New_Line; Put(Item); else Put(Item); end if; if My_Car.Owner.Vehicle /= My_Car then -- see 3.10.1 Report ("Incorrect data"); end if; end;
package body Employee is procedure Set_Attribute (O : in out Person_T; Value : String) is begin null; end Set_Attribute; function Get_Attribute (O : Person_T) return String is begin return ""; end Get_Attribute; procedure Print (O : Person_T) is begin null; end Print; end Employee;
with FSmaker.TOML; package body FSmaker.Commands.Build is ------------- -- Execute -- ------------- overriding procedure Execute (This : in out Instance; Args : AAA.Strings.Vector) is begin if Args.Count /= 2 then This.Failure ("takes exactly two arguments"); end if; FSmaker.TOML.Build_From_TOML (Args (1), Args (2)); end Execute; -------------------- -- Setup_Switches -- -------------------- overriding procedure Setup_Switches (This : in out Instance; Config : in out CLIC.Subcommand.Switches_Configuration) is begin null; end Setup_Switches; end FSmaker.Commands.Build;
with Ada.Text_IO.Unbounded_IO; use Ada.Text_IO.Unbounded_IO; with Ada.Strings.Unbounded; use Ada.Strings.Unbounded; with Ada.Numerics; with Ada.Numerics.Discrete_Random; procedure Hello is starts : array(1..4) of Ada.Strings.Unbounded.Unbounded_String; middles : array(1..4) of Ada.Strings.Unbounded.Unbounded_String; qualifiers : array(1..4) of Ada.Strings.Unbounded.Unbounded_String; finishes : array(1..4) of Ada.Strings.Unbounded.Unbounded_String; subtype Rand_Idx_Range is integer range 1 .. 4; package Rand_Idx is new Ada.Numerics.Discrete_Random(Rand_Idx_Range); use Rand_Idx; seed : Rand_Idx.Generator; idx : Rand_Idx_Range; begin Rand_Idx.Reset(seed); starts(1) := Ada.Strings.Unbounded.To_Unbounded_String ("Experiential truth "); starts(2) := Ada.Strings.Unbounded.To_Unbounded_String ("The physical world "); starts(3) := Ada.Strings.Unbounded.To_Unbounded_String ("Non-judgment "); starts(4) := Ada.Strings.Unbounded.To_Unbounded_String ("Quantum physics "); middles(1) := Ada.Strings.Unbounded.To_Unbounded_String ("nurtures an "); middles(2) := Ada.Strings.Unbounded.To_Unbounded_String ("projects onto "); middles(3) := Ada.Strings.Unbounded.To_Unbounded_String ("imparts reality to "); middles(4) := Ada.Strings.Unbounded.To_Unbounded_String ("constructs with "); qualifiers(1) := Ada.Strings.Unbounded.To_Unbounded_String ("abundance of "); qualifiers(2) := Ada.Strings.Unbounded.To_Unbounded_String ("the barrier of "); qualifiers(3) := Ada.Strings.Unbounded.To_Unbounded_String ("self-righteous "); qualifiers(4) := Ada.Strings.Unbounded.To_Unbounded_String ("potential "); finishes(1) := Ada.Strings.Unbounded.To_Unbounded_String ("marvel."); finishes(2) := Ada.Strings.Unbounded.To_Unbounded_String ("choices."); finishes(3) := Ada.Strings.Unbounded.To_Unbounded_String ("creativity."); finishes(4) := Ada.Strings.Unbounded.To_Unbounded_String ("actions."); Put( starts (Rand_Idx.Random(seed) ) ); Put( middles (Rand_Idx.Random(seed) ) ); Put( qualifiers (Rand_Idx.Random(seed) ) ); Put_Line( finishes (Rand_Idx.Random(seed) ) ); end Hello;
generic type Number is digits <>; package Euler is type Waveform is array (Integer range <>) of Number; function Solve ( F : not null access function (T, Y : Number) return Number; Y0 : Number; T0, T1 : Number; N : Positive ) return Waveform; end Euler;
----------------------------------------------------------------------- -- gen-utils-gnat -- GNAT utilities -- Copyright (C) 2011, 2012, 2014 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with Util.Log.Loggers; with Gen.Configs; with Csets; with Snames; with Namet; with Prj.Pars; with Prj.Tree; with Prj.Env; with Prj.Util; with Makeutl; with Output; package body Gen.Utils.GNAT is use Util.Log; Log : constant Loggers.Logger := Loggers.Create ("Gen.Utils.GNAT"); Project_Node_Tree : Prj.Tree.Project_Node_Tree_Ref; Main_Project : Prj.Project_Id; -- ------------------------------ -- Initialize the GNAT project runtime for reading the GNAT project tree. -- Configure it according to the dynamo configuration properties. -- ------------------------------ procedure Initialize (Config : in Util.Properties.Manager'Class) is Project_Dirs : constant String := Config.Get (Gen.Configs.GEN_GNAT_PROJECT_DIRS, DEFAULT_GNAT_PROJECT_DIR); begin Log.Info ("Initializing GNAT runtime to read projects from: {0}", Project_Dirs); Project_Node_Tree := new Prj.Tree.Project_Node_Tree_Data; Prj.Tree.Initialize (Project_Node_Tree); Output.Set_Standard_Error; Csets.Initialize; Snames.Initialize; Prj.Initialize (Makeutl.Project_Tree); Prj.Env.Add_Directories (Project_Node_Tree.Project_Path, Project_Dirs); end Initialize; -- ------------------------------ -- Read the GNAT project file identified by <b>Project_File_Name</b> and get -- in <b>Project_List</b> an ordered list of absolute project paths used by -- the root project. -- ------------------------------ procedure Read_GNAT_Project_List (Project_File_Name : in String; Project_List : out Project_Info_Vectors.Vector) is procedure Recursive_Add (Proj : in Prj.Project_Id; Dummy : in out Boolean); function Get_Variable_Value (Proj : in Prj.Project_Id; Name : in String) return String; function Get_Project_Name (Proj : in Prj.Project_Id) return String; -- Get the variable value represented by the name <b>Name</b>. -- ??? There are probably other efficient ways to get this but I couldn't find them. function Get_Variable_Value (Proj : in Prj.Project_Id; Name : in String) return String is use type Prj.Variable_Id; Current : Prj.Variable_Id; The_Variable : Prj.Variable; In_Tree : constant Prj.Project_Tree_Ref := Makeutl.Project_Tree; begin Current := Proj.Decl.Variables; while Current /= Prj.No_Variable loop The_Variable := In_Tree.Variable_Elements.Table (Current); if Namet.Get_Name_String (The_Variable.Name) = Name then return Prj.Util.Value_Of (The_Variable.Value, ""); end if; Current := The_Variable.Next; end loop; return ""; end Get_Variable_Value; -- ------------------------------ -- Get the project name from the GNAT project name or from the "name" project variable. -- ------------------------------ function Get_Project_Name (Proj : in Prj.Project_Id) return String is Name : constant String := Get_Variable_Value (Proj, "name"); begin if Name'Length > 0 then return Name; else return Namet.Get_Name_String (Proj.Name); end if; end Get_Project_Name; -- ------------------------------ -- Add the full path of the GNAT project in the project list. -- ------------------------------ procedure Recursive_Add (Proj : in Prj.Project_Id; Dummy : in out Boolean) is pragma Unreferenced (Dummy); Path : constant String := Namet.Get_Name_String (Proj.Path.Name); Name : constant String := Get_Project_Name (Proj); Project : Project_Info; begin Log.Info ("Using GNAT project: {0} - {1}", Path, Name); Project.Path := To_Unbounded_String (Path); Project.Name := To_Unbounded_String (Name); Project_List.Append (Project); end Recursive_Add; procedure For_All_Projects is new Prj.For_Every_Project_Imported (Boolean, Recursive_Add); use type Prj.Project_Id; begin Log.Info ("Reading GNAT project {0}", Project_File_Name); -- Parse the GNAT project files and build the tree. Prj.Pars.Parse (Project => Main_Project, In_Tree => Makeutl.Project_Tree, Project_File_Name => Project_File_Name, Flags => Prj.Gnatmake_Flags, In_Node_Tree => Project_Node_Tree); if Main_Project /= Prj.No_Project then declare Dummy : Boolean := False; begin -- Scan the tree to get the list of projects (in dependency order). For_All_Projects (Main_Project, Dummy, Imported_First => True); end; end if; end Read_GNAT_Project_List; end Gen.Utils.GNAT;
with Shell.Directory_Iteration, Ada.Directories, Ada.Text_IO; procedure Test_Iterate_Directory is use Ada.Text_IO; begin Put_Line ("Begin 'Iterate_Directory' test."); New_Line (2); declare use Shell.Directory_Iteration, Ada .Directories; begin for Each of To_Directory ("..", Recurse => True) loop Put_Line (Full_Name (Each)); -- Display the full name of each file. end loop; end; New_Line (2); Put_Line ("End 'Iterate_Directory' test."); end Test_Iterate_Directory;
------------------------------------------------------------------------------ -- -- -- ASIS-for-GNAT IMPLEMENTATION COMPONENTS -- -- -- -- A 4 G . C O N T T . D P -- -- -- -- S p e c -- -- -- -- Copyright (c) 1995-2006, Free Software Foundation, Inc. -- -- -- -- ASIS-for-GNAT is free software; you can redistribute it and/or modify it -- -- under terms of the GNU General Public License as published by the Free -- -- Software Foundation; either version 2, or (at your option) any later -- -- version. ASIS-for-GNAT is distributed in the hope that it will be use- -- -- ful, but WITHOUT ANY WARRANTY; without even the implied warranty of MER- -- -- CHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General -- -- Public License for more details. You should have received a copy of the -- -- GNU General Public License distributed with ASIS-for-GNAT; see file -- -- COPYING. If not, write to the Free Software Foundation, 51 Franklin -- -- Street, Fifth Floor, Boston, MA 02110-1301, USA. -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- ASIS-for-GNAT was originally developed by the ASIS-for-GNAT team at the -- -- Software Engineering Laboratory of the Swiss Federal Institute of -- -- Technology (LGL-EPFL) in Lausanne, Switzerland, in cooperation with the -- -- Scientific Research Computer Center of Moscow State University (SRCC -- -- MSU), Russia, with funding partially provided by grants from the Swiss -- -- National Science Foundation and the Swiss Academy of Engineering -- -- Sciences. ASIS-for-GNAT is now maintained by AdaCore -- -- (http://www.adacore.com). -- -- -- ------------------------------------------------------------------------------ -- This package defines routines for computing and setting semantic -- dependencies between ASIS Compilation Units with Asis; use Asis; with Asis.Extensions; use Asis.Extensions; package A4G.Contt.Dp is -- Context_Table.DePendencies -- All the subprograms defined in this package are supposed, that -- (1) they are called at most once (depending on the unit kind) for any -- unit stored in the Context Unit table -- (2) the caller is responsible, that these subprograms are called for -- the actuals of appropriate kinds -- OPEN PROBLEMS: -- -- 1. DOCUMENTATION!!! -- -- 2. The idea is to *compute from the tree* only direct dependencies, -- and for all the indirect dependencies, to compute them from -- the direct dependencies using their transitive nature. procedure Set_Supporters (C : Context_Id; U : Unit_Id; Top : Node_Id); -- This procedure sets the **direct** supporters for U. For now, -- the idea is to set *from the tree* only the direct dependencies, -- as being the function of the source text of a Unit (???). All -- the indirect dependencies should be set from direct ones using -- the transitive nature of the dependencies. -- -- So, for now, only Direct_Supporters, Direct_Dependants and -- Implicit_Supporters (representing only direct implicit dependencies -- imposed by implicit with clauses) are set by this procedure. -- -- OPEN PROBLEM: If we set only **direct* dependencies, may be, -- we need only ONE function to do this? do we really need -- Set_Ancestors, Set_Childs, ???? ? procedure Set_Subunits (C : Context_Id; U : Unit_Id; Top : Node_Id); -- Sets the full list of the subunit for a given body (that is, adds -- nonexistent units for missed subunits) procedure Process_Stub (C : Context_Id; U : Unit_Id; Stub : Node_Id); -- Taking the node for a body stub, this function checks if the -- corresponding subunit exists in the Context C. If it does not exist, -- a unit of A_Nonexistent_Body kind is allocated in the Context Unit -- table and appended to the list of subunits of U. -- -- This procedure supposes, that before it is called, the normalized -- name of U has been already set in A_Name_Buffer. When returning from -- this procedure, A_Name_Buffer and A_Name_Len are remained in the -- same state as before the call. procedure Append_Subunit_Name (Def_S_Name : Node_Id); -- Supposing that A_Name_Buf contains the name of the parent body, and -- Def_S_Name points to the defining identifier obtained from the body -- stub, this procedure forms in A_Name_Buffer the name of the subunit procedure Set_Withed_Units (C : Context_Id; U : Unit_Id; Top : Node_Id); -- This procedure sets the Direct_Supporters and Implicit_Supporters -- dependency lists on the base of with clauses explicicitly presented -- in unit's source and generated by the compiler respectively. procedure Set_Direct_Dependents (U : Unit_Id); -- This procedure is supposed to be called for U just after -- Set_Withed_Units has done its work. For any unit U1 included -- in the list of direct supporters for U, U is included in the list -- of direct dependers of U1. procedure Add_To_Parent (C : Context_Id; U : Unit_Id); -- Adds U to the list of children for its parent unit declaration. -- U is added to the list only it is consistent with the parent procedure Set_All_Dependencies (Use_First_New_Unit : Boolean := False); -- Sets all supportiers and all dependants for units contained in the -- argument Context. Should be called when all the units are already set. -- If Use_First_New_Unit is set ON (this may happen for Incremental -- Context only), completes the dependencies only for new units from the -- new tree (see the body of A4G.Get_Unit.Fetch_Unit_By_Ada_Name) procedure Set_All_Ancestors (Compilation_Units : Asis.Compilation_Unit_List; Result : in out Compilation_Unit_List_Access); -- This procedure takes the arguments of -- Asis.Compilation_Units.Relations.Semantic_Dependence_Order query in -- case when Relation parameter is set to Ancestors and computes the -- consistent part of the result.(???) procedure Set_All_Descendants (Compilation_Units : Asis.Compilation_Unit_List; Result : in out Compilation_Unit_List_Access); -- This procedure takes the arguments of -- Asis.Compilation_Units.Relations.Semantic_Dependence_Order query in -- case when Relation parameter is set to Descendants and computes the -- consistent part of the result.(???) procedure Set_All_Supporters (Compilation_Units : Asis.Compilation_Unit_List; Result : in out Compilation_Unit_List_Access); -- This procedure takes the arguments of -- Asis.Compilation_Units.Relations.Semantic_Dependence_Order query in -- case when Relation parameter is set to Supporters and -- computes the consistent part of the result.(???) procedure Set_All_Dependents (Compilation_Units : Asis.Compilation_Unit_List; Dependent_Units : Asis.Compilation_Unit_List; Result : in out Compilation_Unit_List_Access); -- This procedure takes the arguments of -- Asis.Compilation_Units.Relations.Semantic_Dependence_Order query in -- case when Relation parameter is set to Dependents and computes the -- consistent part of the result.(???) procedure Set_All_Families (Compilation_Units : Asis.Compilation_Unit_List; Result : in out Compilation_Unit_List_Access); -- This procedure takes the arguments of -- Asis.Compilation_Units.Relations.Semantic_Dependence_Order query in -- case when Relation parameter is set to Family and -- computes the consistent part of the result.(???) procedure Set_All_Needed_Units (Compilation_Units : Asis.Compilation_Unit_List; Result : in out Compilation_Unit_List_Access; Missed : in out Compilation_Unit_List_Access); -- This procedure takes the arguments of -- Asis.Compilation_Units.Relations.Semantic_Dependence_Order query in -- case when Relation parameter is set to Needed_Units and -- computes the consistent part of the result and missed units.(???) end A4G.Contt.Dp;
------------------------------------------------------------------------------- -- BUILD FILE : apass -- -- Description : A CLI password generator written in Ada. -- -- Author : Simon Rowe <simon@wiremoons.com> -- -- License : MIT Open Source. -- ------------------------------------------------------------------------------- with Ada.Text_IO; use Ada.Text_IO; with Ada.Strings.Unbounded; use Ada.Strings.Unbounded; with Ada.Command_Line; use Ada.Command_Line; -- use local packages with Password_Manager; with Cmd_Flags; procedure Apass is -------------------------- -- MAIN -------------------------- Full_Password_Str : Unbounded_String := Null_Unbounded_String; Total_Passwords : Integer := 3; Number_Of_Words : constant Integer := 3; begin -- print info on how to compile a 'release' version pragma Debug (Put_Line (Standard_Error, "[DEBUG] build a 'release' version with: gprclean && gprbuild -XBUILD=release")); -- Check if any command line options were used and if they are they will be executed -- and then the program can exit here if Cmd_Flags.Command_Line_Flags_Exist then Set_Exit_Status (Success); pragma Debug (Put_Line (Standard_Error, "[DEBUG] exit with 'success'.")); return; -- exit as flags found and executed else -- Set_Exit_Status (Failure); -- failed as no database found -- pragma Debug (Put_Line (Standard_Error, "[DEBUG] exit with 'failure'.")); Put_Line ("Program 'apass' running..."); Put_Line ("Total words available to construct passwords: " & Password_Manager.Total_Words); Put_Line ("Number of suggested passwords per group:" & Integer'Image (Total_Passwords)); Put_Line ("Number of words to use per password string:" & Integer'Image (Number_Of_Words)); New_Line (1); -- output of mixed lowercase with two punctuation marks and two random numbers surrounding the string while Total_Passwords > 0 loop Full_Password_Str := To_Unbounded_String (Password_Manager.Get_Random_Number); --Full_Password_Str := Full_Password_Str & To_Unbounded_String (Password_Manager.Get_Random_Mark); Append (Full_Password_Str, To_Unbounded_String (Password_Manager.Get_Random_Mark)); Append (Full_Password_Str, To_Unbounded_String (Password_Manager.Basic_Password (Number_Of_Words))); Append (Full_Password_Str, To_Unbounded_String (Password_Manager.Get_Random_Mark)); Append (Full_Password_Str, To_Unbounded_String (Password_Manager.Get_Random_Number)); Password_Manager.Print_Password (To_String (Full_Password_Str)); Total_Passwords := Total_Passwords - 1; end loop; Put_Line (" "); New_Line (1); Total_Passwords := 3; -- output of mixed lowercase with two punctuation marks and two random numbers surrounding the string while Total_Passwords > 0 loop Full_Password_Str := To_Unbounded_String (Password_Manager.Basic_Password (Number_Of_Words)); Append (Full_Password_Str, To_Unbounded_String (Password_Manager.Get_Random_Mark)); Append (Full_Password_Str, To_Unbounded_String (Password_Manager.Get_Random_Number)); Password_Manager.Print_Password (To_String (Full_Password_Str)); Total_Passwords := Total_Passwords - 1; end loop; Put_Line (" "); New_Line (1); Total_Passwords := 3; -- output of mixed lowercase with two punctuation marks and two random numbers surrounding the string while Total_Passwords > 0 loop Full_Password_Str := To_Unbounded_String (Password_Manager.Capitilised_Password (Number_Of_Words)); Append (Full_Password_Str, To_Unbounded_String (Password_Manager.Get_Random_Mark)); Append (Full_Password_Str, To_Unbounded_String (Password_Manager.Get_Random_Number)); Password_Manager.Print_Password (To_String (Full_Password_Str)); Total_Passwords := Total_Passwords - 1; end loop; Put_Line (" "); end if; Set_Exit_Status (Success); pragma Debug (Put_Line (Standard_Error, "[DEBUG] exit with 'success'.")); return; -- exit as flags found and executed end Apass;
with Ada.Interrupts.Names; with STM32GD.USB; generic with function EP0_Reset_Callback (BTable_Offset : Integer) return Integer is STM32GD.USB.EP_Unused_Reset; with function EP1_Reset_Callback (BTable_Offset : Integer) return Integer is STM32GD.USB.EP_Unused_Reset; with function EP2_Reset_Callback (BTable_Offset : Integer) return Integer is STM32GD.USB.EP_Unused_Reset; with function EP3_Reset_Callback (BTable_Offset : Integer) return Integer is STM32GD.USB.EP_Unused_Reset; with function EP4_Reset_Callback (BTable_Offset : Integer) return Integer is STM32GD.USB.EP_Unused_Reset; with function EP5_Reset_Callback (BTable_Offset : Integer) return Integer is STM32GD.USB.EP_Unused_Reset; with function EP6_Reset_Callback (BTable_Offset : Integer) return Integer is STM32GD.USB.EP_Unused_Reset; with function EP7_Reset_Callback (BTable_Offset : Integer) return Integer is STM32GD.USB.EP_Unused_Reset; with procedure EP0_Handler_Callback (Out_Transaction : Boolean) is STM32GD.USB.EP_Unused_Handler; with procedure EP1_Handler_Callback (Out_Transaction : Boolean) is STM32GD.USB.EP_Unused_Handler; with procedure EP2_Handler_Callback (Out_Transaction : Boolean) is STM32GD.USB.EP_Unused_Handler; with procedure EP3_Handler_Callback (Out_Transaction : Boolean) is STM32GD.USB.EP_Unused_Handler; with procedure EP4_Handler_Callback (Out_Transaction : Boolean) is STM32GD.USB.EP_Unused_Handler; with procedure EP5_Handler_Callback (Out_Transaction : Boolean) is STM32GD.USB.EP_Unused_Handler; with procedure EP6_Handler_Callback (Out_Transaction : Boolean) is STM32GD.USB.EP_Unused_Handler; with procedure EP7_Handler_Callback (Out_Transaction : Boolean) is STM32GD.USB.EP_Unused_Handler; package STM32GD.USB.Peripheral is procedure Init; procedure Handle_Reset; protected Handler is pragma Interrupt_Priority; private procedure IRQ_Handler; pragma Attach_Handler (IRQ_Handler, Ada.Interrupts.Names.USB_LP_CAN_RX0); end Handler; end STM32GD.USB.Peripheral;
-------------------------------------------------------------------------------- -- MIT License -- -- Copyright (c) 2020 Zane Myers -- -- Permission is hereby granted, free of charge, to any person obtaining a copy -- of this software and associated documentation files (the "Software"), to deal -- in the Software without restriction, including without limitation the rights -- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -- copies of the Software, and to permit persons to whom the Software is -- furnished to do so, subject to the following conditions: -- -- The above copyright notice and this permission notice shall be included in all -- copies or substantial portions of the Software. -- -- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -- SOFTWARE. -------------------------------------------------------------------------------- with Interfaces.C; with Interfaces.C.Strings; with Interfaces.C.Pointers; with Glfw.Error; with Glfw.Window_Hints; private package Glfw.Api is type Char_Ptr_Array is Array(Natural range <>) of aliased Interfaces.C.Strings.Chars_Ptr; package Char_Ptr_Array_Ptrs is new Interfaces.C.Pointers ( index => Natural, Element => Interfaces.C.Strings.Chars_Ptr, Element_Array => Char_Ptr_Array, Default_Terminator => Interfaces.C.Strings.Null_Ptr) ; subtype Char_Ptr_Array_Ptr is Char_Ptr_Array_Ptrs.Pointer; ---------------------------------------------------------------------------- -- Platform Level Functions ---------------------------------------------------------------------------- -- Import the glfwInit() function from the GLFW C library. function glfwInit return Glfw_Bool; pragma Import (Convention => C, Entity => glfwInit, External_Name => "glfwInit"); -- Import the glfwTerminate() function from the GLFW C library. procedure glfwTerminate; pragma Import (Convention => C, Entity => glfwTerminate, External_Name => "glfwTerminate"); -- Import the glfwGetError() function from the GLFW C library. function glfwGetError ( message : out Interfaces.C.Strings.chars_ptr ) return Error.Enum_Return_Codes; pragma Import (Convention => C, Entity => glfwGetError, External_Name => "glfwGetError"); -- Import the glfwPollEvents() function from the GLFW C library procedure glfwPollEvents; pragma Import (Convention => C, Entity => glfwPollEvents, External_Name => "glfwPollEvents"); ---------------------------------------------------------------------------- -- Window Level Functions ---------------------------------------------------------------------------- -- Import the glfwWindowHint() function from the GLFW C library procedure glfwWindowHint ( window_hint : in Glfw.Window_Hints.Enum_Window_Hints; window_hint_value : in Glfw.Glfw_Bool ); procedure glfwWindowHint ( window_hint : in Glfw.Window_Hints.Enum_Window_Hints; window_hint_value : in Glfw.Glfw_Int ); procedure glfwWindowHint ( window_hint : in Glfw.Window_Hints.Enum_Window_Hints; window_hint_value : in Glfw.Enum_Client_Api ); procedure glfwWindowHint ( window_hint : in Glfw.Window_Hints.Enum_Window_Hints; window_hint_value : in Glfw.Enum_Context_Api ); procedure glfwWindowHint ( window_hint : in Glfw.Window_Hints.Enum_Window_Hints; window_hint_value : in Glfw.Enum_Context_Robustness ); procedure glfwWindowHint ( window_hint : in Glfw.Window_Hints.Enum_Window_Hints; window_hint_value : in Glfw.Enum_Context_Release_Behavior ); procedure glfwWindowHint ( window_hint : in Glfw.Window_Hints.Enum_Window_Hints; window_hint_value : in Glfw.Enum_OpenGl_Profile ); pragma Import (Convention => C, Entity => glfwWindowHint, External_Name => "glfwWindowHint"); -- Import the glfwWindHintString() function from the GLFW Library. procedure glfwWindowHintString ( window_hint : in Glfw.Window_Hints.Enum_Window_Hints; window_hint_value : in Interfaces.C.Strings.chars_ptr ); pragma Import (Convention => C, Entity => glfwWindowHintString, External_Name => "glfwWindowHintString"); -- Import the glfwCreateWindow() function from the GLFW Library. function glfwCreateWindow ( width : in Window_Dimmension; height : in Window_Dimmension; title : in Interfaces.C.Strings.chars_ptr; monitor : in Glfw_Monitor; window : in Glfw_Window ) return Glfw_Window; pragma Import (Convention => C, Entity => glfwCreateWindow, External_Name => "glfwCreateWindow"); -- Import the glfwWindowShouldClose() function from the GLFW Library. function glfwWindowShouldClose ( window : in Glfw_Window ) return Glfw_Bool; pragma Import (Convention => C, Entity => glfwWindowShouldClose, External_Name => "glfwWindowShouldClose"); -- Import the glfwDestroyWindow() function from the GLFW Library. procedure glfwDestroyWindow ( window : in Glfw_Window ); pragma Import (Convention => C, Entity => glfwDestroyWindow, External_Name => "glfwDestroyWindow"); function glfwGetRequiredInstanceExtensions ( p_extension_count : out Interfaces.C.unsigned ) return Char_Ptr_Array_Ptr; pragma Import (Convention => C, Entity => glfwGetRequiredInstanceExtensions, External_Name => "glfwGetRequiredInstanceExtensions"); end Glfw.Api;
------------------------------------------------------------------------------ -- A d a r u n - t i m e s p e c i f i c a t i o n -- -- ASIS implementation for Gela project, a portable Ada compiler -- -- http://gela.ada-ru.org -- -- - - - - - - - - - - - - - - - -- -- Read copyright and license at the end of ada.ads file -- ------------------------------------------------------------------------------ -- $Revision: 209 $ $Date: 2013-11-30 21:03:24 +0200 (Сб., 30 нояб. 2013) $ with Ada.Calendar.Time_Zones; package Ada.Calendar.Formatting is -- Day of the week: type Day_Name is (Monday, Tuesday, Wednesday, Thursday, Friday, Saturday, Sunday); function Day_of_Week (Date : in Time) return Day_Name; -- Hours:Minutes:Seconds access: subtype Hour_Number is Natural range 0 .. 23; subtype Minute_Number is Natural range 0 .. 59; subtype Second_Number is Natural range 0 .. 59; subtype Second_Duration is Day_Duration range 0.0 .. 1.0; function Year (Date : in Time; Time_Zone : in Time_Zones.Time_Offset := 0) return Year_Number; function Month (Date : in Time; Time_Zone : in Time_Zones.Time_Offset := 0) return Month_Number; function Day (Date : in Time; Time_Zone : in Time_Zones.Time_Offset := 0) return Day_Number; function Hour (Date : in Time; Time_Zone : in Time_Zones.Time_Offset := 0) return Hour_Number; function Minute (Date : in Time; Time_Zone : in Time_Zones.Time_Offset := 0) return Minute_Number; function Second (Date : in Time) return Second_Number; function Sub_Second (Date : in Time) return Second_Duration; function Seconds_Of (Hour : in Hour_Number; Minute : in Minute_Number; Second : in Second_Number := 0; Sub_Second : in Second_Duration := 0.0) return Day_Duration; procedure Split (Seconds : in Day_Duration; Hour : out Hour_Number; Minute : out Minute_Number; Second : out Second_Number; Sub_Second : out Second_Duration); function Time_Of (Year : in Year_Number; Month : in Month_Number; Day : in Day_Number; Hour : in Hour_Number; Minute : in Minute_Number; Second : in Second_Number; Sub_Second : in Second_Duration := 0.0; Leap_Second : in Boolean := False; Time_Zone : in Time_Zones.Time_Offset := 0) return Time; function Time_Of (Year : in Year_Number; Month : in Month_Number; Day : in Day_Number; Seconds : in Day_Duration := 0.0; Leap_Second : in Boolean := False; Time_Zone : in Time_Zones.Time_Offset := 0) return Time; procedure Split (Date : in Time; Year : out Year_Number; Month : out Month_Number; Day : out Day_Number; Hour : out Hour_Number; Minute : out Minute_Number; Second : out Second_Number; Sub_Second : out Second_Duration; Time_Zone : in Time_Zones.Time_Offset := 0); procedure Split (Date : in Time; Year : out Year_Number; Month : out Month_Number; Day : out Day_Number; Hour : out Hour_Number; Minute : out Minute_Number; Second : out Second_Number; Sub_Second : out Second_Duration; Leap_Second : out Boolean; Time_Zone : in Time_Zones.Time_Offset := 0); procedure Split (Date : in Time; Year : out Year_Number; Month : out Month_Number; Day : out Day_Number; Seconds : out Day_Duration; Leap_Second : out Boolean; Time_Zone : in Time_Zones.Time_Offset := 0); -- Simple image and value: function Image (Date : in Time; Include_Time_Fraction : in Boolean := False; Time_Zone : in Time_Zones.Time_Offset := 0) return String; function Value (Date : in String; Time_Zone : in Time_Zones.Time_Offset := 0) return Time; function Image (Elapsed_Time : in Duration; Include_Time_Fraction : in Boolean := False) return String; function Value (Elapsed_Time : in String) return Duration; end Ada.Calendar.Formatting;
pragma License (Unrestricted); with Ada.Iterator_Interfaces; private with Ada.Finalization; private with System.Native_Environment_Variables; package Ada.Environment_Variables is pragma Preelaborate; function Value (Name : String) return String; function Value (Name : String; Default : String) return String; pragma Inline (Value); -- renamed function Exists (Name : String) return Boolean; pragma Inline (Exists); -- renamed procedure Set (Name : String; Value : String); pragma Inline (Set); -- renamed procedure Clear (Name : String); procedure Clear; pragma Inline (Clear); -- renamed procedure Iterate ( Process : not null access procedure (Name, Value : String)); -- extended from here -- There is a simple iterator: type Cursor is private; -- moved from below pragma Preelaborable_Initialization (Cursor); function Has_Element (Position : Cursor) return Boolean; pragma Inline (Has_Element); function Name (Position : Cursor) return String; function Value (Position : Cursor) return String; pragma Inline (Name); pragma Inline (Value); package Iterator_Interfaces is new Ada.Iterator_Interfaces (Cursor, Has_Element); function Iterate return Iterator_Interfaces.Forward_Iterator'Class; -- to here -- package Name_Value_Pairs is -- type Name_Value_Pair_Type is tagged limited private; -- Operations on Name_Value_Pairs -- function Name (Name_Value_Pair : Name_Value_Pair_Type) return String; -- function Value (Name_Value_Pair : Name_Value_Pair_Type) return String; -- Note: If it follows AI12-0009-1/06 strictly, these is no way to make -- a value of Name_Value_Pair_Type, because it is declared as private -- and in the nested package Name_Value_Pairs. -- Perhaps, Current_Variable should be moved here. -- private -- not specified by the languages -- end Name_Value_Pairs; -- use Name_Value_Pairs; -- type Environment_Variable_Listing is tagged limited private -- with -- Constant_Indexing => Current_Variable, -- Default_Iterator => Iterate, -- Iterator_Element => Name_Value_Pairs.Name_Value_Pair_Type; -- pragma Preelaborable_Initialization (Environment_Variable_Listing); -- function Environment return Environment_Variable_Listing; -- type Cursor is private; -- declared in above -- pragma Preelaborable_Initialization (Cursor); -- function Has_Environment_Variable (Position : Cursor) return Boolean -- renames Has_Element; -- package Environment_Variable_Iterators -- renames Iterator_Interfaces; -- function Iterate (Listing : Environment_Variable_Listing) -- return Environment_Variable_Iterators.Forward_Iterator'Class; -- function Current_Variable ( -- Variables : Environment_Variable_Listing; -- Position : Cursor) -- return Name_Value_Pairs.Name_Value_Pair_Type; -- with Pre => Has_Environment_Variable (Position); -- Note: These "renames" should be unified when the AI have been decided. private function Value (Name : String) return String renames System.Native_Environment_Variables.Value; function Value (Name : String; Default : String) return String renames System.Native_Environment_Variables.Value; function Exists (Name : String) return Boolean renames System.Native_Environment_Variables.Exists; procedure Set (Name : String; Value : String) renames System.Native_Environment_Variables.Set; procedure Clear (Name : String) renames System.Native_Environment_Variables.Clear; procedure Clear renames System.Native_Environment_Variables.Clear; type Cursor is new System.Native_Environment_Variables.Cursor; type Iterator is limited new Finalization.Limited_Controlled and Iterator_Interfaces.Forward_Iterator with record Block : System.Address := System.Null_Address; end record with Disable_Controlled => System.Native_Environment_Variables.Disable_Controlled; overriding procedure Finalize (Object : in out Iterator); overriding function First (Object : Iterator) return Cursor; overriding function Next (Object : Iterator; Position : Cursor) return Cursor; end Ada.Environment_Variables;
----------------------------------------------------------------------- -- volume_servlet -- Servlet example to compute some volumes -- Copyright (C) 2010, 2018 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with Servlet.Core; with Servlet.Requests; with Servlet.Responses; package Volume_Servlet is use Servlet; -- The <b>Servlet</b> represents the component that will handle -- an HTTP request received by the server. type Servlet is new Core.Servlet with null record; -- Called by the servlet container when a GET request is received. -- Display the volume form page. procedure Do_Get (Server : in Servlet; Request : in out Requests.Request'Class; Response : in out Responses.Response'Class); -- Called by the servlet container when a POST request is received. -- Computes the cylinder volume and display the result page. procedure Do_Post (Server : in Servlet; Request : in out Requests.Request'Class; Response : in out Responses.Response'Class); end Volume_Servlet;
------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- I N L I N E -- -- -- -- B o d y -- -- -- -- Copyright (C) 1992-2005, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 2, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -- -- for more details. You should have received a copy of the GNU General -- -- Public License distributed with GNAT; see file COPYING. If not, write -- -- to the Free Software Foundation, 51 Franklin Street, Fifth Floor, -- -- Boston, MA 02110-1301, USA. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ with Atree; use Atree; with Einfo; use Einfo; with Elists; use Elists; with Errout; use Errout; with Exp_Ch7; use Exp_Ch7; with Exp_Tss; use Exp_Tss; with Fname; use Fname; with Fname.UF; use Fname.UF; with Lib; use Lib; with Nlists; use Nlists; with Opt; use Opt; with Sem_Ch8; use Sem_Ch8; with Sem_Ch10; use Sem_Ch10; with Sem_Ch12; use Sem_Ch12; with Sem_Util; use Sem_Util; with Sinfo; use Sinfo; with Snames; use Snames; with Stand; use Stand; with Uname; use Uname; package body Inline is -------------------- -- Inlined Bodies -- -------------------- -- Inlined functions are actually placed in line by the backend if the -- corresponding bodies are available (i.e. compiled). Whenever we find -- a call to an inlined subprogram, we add the name of the enclosing -- compilation unit to a worklist. After all compilation, and after -- expansion of generic bodies, we traverse the list of pending bodies -- and compile them as well. package Inlined_Bodies is new Table.Table ( Table_Component_Type => Entity_Id, Table_Index_Type => Int, Table_Low_Bound => 0, Table_Initial => Alloc.Inlined_Bodies_Initial, Table_Increment => Alloc.Inlined_Bodies_Increment, Table_Name => "Inlined_Bodies"); ----------------------- -- Inline Processing -- ----------------------- -- For each call to an inlined subprogram, we make entries in a table -- that stores caller and callee, and indicates a prerequisite from -- one to the other. We also record the compilation unit that contains -- the callee. After analyzing the bodies of all such compilation units, -- we produce a list of subprograms in topological order, for use by the -- back-end. If P2 is a prerequisite of P1, then P1 calls P2, and for -- proper inlining the back-end must analyze the body of P2 before that of -- P1. The code below guarantees that the transitive closure of inlined -- subprograms called from the main compilation unit is made available to -- the code generator. Last_Inlined : Entity_Id := Empty; -- For each entry in the table we keep a list of successors in topological -- order, i.e. callers of the current subprogram. type Subp_Index is new Nat; No_Subp : constant Subp_Index := 0; -- The subprogram entities are hashed into the Inlined table Num_Hash_Headers : constant := 512; Hash_Headers : array (Subp_Index range 0 .. Num_Hash_Headers - 1) of Subp_Index; type Succ_Index is new Nat; No_Succ : constant Succ_Index := 0; type Succ_Info is record Subp : Subp_Index; Next : Succ_Index; end record; -- The following table stores list elements for the successor lists. -- These lists cannot be chained directly through entries in the Inlined -- table, because a given subprogram can appear in several such lists. package Successors is new Table.Table ( Table_Component_Type => Succ_Info, Table_Index_Type => Succ_Index, Table_Low_Bound => 1, Table_Initial => Alloc.Successors_Initial, Table_Increment => Alloc.Successors_Increment, Table_Name => "Successors"); type Subp_Info is record Name : Entity_Id := Empty; First_Succ : Succ_Index := No_Succ; Count : Integer := 0; Listed : Boolean := False; Main_Call : Boolean := False; Next : Subp_Index := No_Subp; Next_Nopred : Subp_Index := No_Subp; end record; package Inlined is new Table.Table ( Table_Component_Type => Subp_Info, Table_Index_Type => Subp_Index, Table_Low_Bound => 1, Table_Initial => Alloc.Inlined_Initial, Table_Increment => Alloc.Inlined_Increment, Table_Name => "Inlined"); ----------------------- -- Local Subprograms -- ----------------------- function Scope_In_Main_Unit (Scop : Entity_Id) return Boolean; -- Return True if Scop is in the main unit or its spec, or in a -- parent of the main unit if it is a child unit. procedure Add_Call (Called : Entity_Id; Caller : Entity_Id := Empty); -- Make two entries in Inlined table, for an inlined subprogram being -- called, and for the inlined subprogram that contains the call. If -- the call is in the main compilation unit, Caller is Empty. function Add_Subp (E : Entity_Id) return Subp_Index; -- Make entry in Inlined table for subprogram E, or return table index -- that already holds E. function Has_Initialized_Type (E : Entity_Id) return Boolean; -- If a candidate for inlining contains type declarations for types with -- non-trivial initialization procedures, they are not worth inlining. function Is_Nested (E : Entity_Id) return Boolean; -- If the function is nested inside some other function, it will -- always be compiled if that function is, so don't add it to the -- inline list. We cannot compile a nested function outside the -- scope of the containing function anyway. This is also the case if -- the function is defined in a task body or within an entry (for -- example, an initialization procedure). procedure Add_Inlined_Subprogram (Index : Subp_Index); -- Add subprogram to Inlined List once all of its predecessors have been -- placed on the list. Decrement the count of all its successors, and -- add them to list (recursively) if count drops to zero. ------------------------------ -- Deferred Cleanup Actions -- ------------------------------ -- The cleanup actions for scopes that contain instantiations is delayed -- until after expansion of those instantiations, because they may -- contain finalizable objects or tasks that affect the cleanup code. -- A scope that contains instantiations only needs to be finalized once, -- even if it contains more than one instance. We keep a list of scopes -- that must still be finalized, and call cleanup_actions after all the -- instantiations have been completed. To_Clean : Elist_Id; procedure Add_Scope_To_Clean (Inst : Entity_Id); -- Build set of scopes on which cleanup actions must be performed procedure Cleanup_Scopes; -- Complete cleanup actions on scopes that need it -------------- -- Add_Call -- -------------- procedure Add_Call (Called : Entity_Id; Caller : Entity_Id := Empty) is P1 : constant Subp_Index := Add_Subp (Called); P2 : Subp_Index; J : Succ_Index; begin if Present (Caller) then P2 := Add_Subp (Caller); -- Add P2 to the list of successors of P1, if not already there. -- Note that P2 may contain more than one call to P1, and only -- one needs to be recorded. J := Inlined.Table (P1).First_Succ; while J /= No_Succ loop if Successors.Table (J).Subp = P2 then return; end if; J := Successors.Table (J).Next; end loop; -- On exit, make a successor entry for P2 Successors.Increment_Last; Successors.Table (Successors.Last).Subp := P2; Successors.Table (Successors.Last).Next := Inlined.Table (P1).First_Succ; Inlined.Table (P1).First_Succ := Successors.Last; Inlined.Table (P2).Count := Inlined.Table (P2).Count + 1; else Inlined.Table (P1).Main_Call := True; end if; end Add_Call; ---------------------- -- Add_Inlined_Body -- ---------------------- procedure Add_Inlined_Body (E : Entity_Id) is Pack : Entity_Id; function Must_Inline return Boolean; -- Inlining is only done if the call statement N is in the main unit, -- or within the body of another inlined subprogram. ----------------- -- Must_Inline -- ----------------- function Must_Inline return Boolean is Scop : Entity_Id := Current_Scope; Comp : Node_Id; begin -- Check if call is in main unit while Scope (Scop) /= Standard_Standard and then not Is_Child_Unit (Scop) loop Scop := Scope (Scop); end loop; Comp := Parent (Scop); while Nkind (Comp) /= N_Compilation_Unit loop Comp := Parent (Comp); end loop; if Comp = Cunit (Main_Unit) or else Comp = Library_Unit (Cunit (Main_Unit)) then Add_Call (E); return True; end if; -- Call is not in main unit. See if it's in some inlined -- subprogram. Scop := Current_Scope; while Scope (Scop) /= Standard_Standard and then not Is_Child_Unit (Scop) loop if Is_Overloadable (Scop) and then Is_Inlined (Scop) then Add_Call (E, Scop); return True; end if; Scop := Scope (Scop); end loop; return False; end Must_Inline; -- Start of processing for Add_Inlined_Body begin -- Find unit containing E, and add to list of inlined bodies if needed. -- If the body is already present, no need to load any other unit. This -- is the case for an initialization procedure, which appears in the -- package declaration that contains the type. It is also the case if -- the body has already been analyzed. Finally, if the unit enclosing -- E is an instance, the instance body will be analyzed in any case, -- and there is no need to add the enclosing unit (whose body might not -- be available). -- Library-level functions must be handled specially, because there is -- no enclosing package to retrieve. In this case, it is the body of -- the function that will have to be loaded. if not Is_Abstract (E) and then not Is_Nested (E) and then Convention (E) /= Convention_Protected then Pack := Scope (E); if Must_Inline and then Ekind (Pack) = E_Package then Set_Is_Called (E); if Pack = Standard_Standard then -- Library-level inlined function. Add function iself to -- list of needed units. Inlined_Bodies.Increment_Last; Inlined_Bodies.Table (Inlined_Bodies.Last) := E; elsif Is_Generic_Instance (Pack) then null; elsif not Is_Inlined (Pack) and then not Has_Completion (E) and then not Scope_In_Main_Unit (Pack) then Set_Is_Inlined (Pack); Inlined_Bodies.Increment_Last; Inlined_Bodies.Table (Inlined_Bodies.Last) := Pack; end if; end if; end if; end Add_Inlined_Body; ---------------------------- -- Add_Inlined_Subprogram -- ---------------------------- procedure Add_Inlined_Subprogram (Index : Subp_Index) is E : constant Entity_Id := Inlined.Table (Index).Name; Succ : Succ_Index; Subp : Subp_Index; function Back_End_Cannot_Inline (Subp : Entity_Id) return Boolean; -- There are various conditions under which back-end inlining cannot -- be done reliably: -- -- a) If a body has handlers, it must not be inlined, because this -- may violate program semantics, and because in zero-cost exception -- mode it will lead to undefined symbols at link time. -- -- b) If a body contains inlined function instances, it cannot be -- inlined under ZCX because the numerix suffix generated by gigi -- will be different in the body and the place of the inlined call. -- -- This procedure must be carefully coordinated with the back end ---------------------------- -- Back_End_Cannot_Inline -- ---------------------------- function Back_End_Cannot_Inline (Subp : Entity_Id) return Boolean is Decl : constant Node_Id := Unit_Declaration_Node (Subp); Body_Ent : Entity_Id; Ent : Entity_Id; begin if Nkind (Decl) = N_Subprogram_Declaration and then Present (Corresponding_Body (Decl)) then Body_Ent := Corresponding_Body (Decl); else return False; end if; -- If subprogram is marked Inline_Always, inlining is mandatory if Is_Always_Inlined (Subp) then return False; end if; if Present (Exception_Handlers (Handled_Statement_Sequence (Unit_Declaration_Node (Corresponding_Body (Decl))))) then return True; end if; Ent := First_Entity (Body_Ent); while Present (Ent) loop if Is_Subprogram (Ent) and then Is_Generic_Instance (Ent) then return True; end if; Next_Entity (Ent); end loop; return False; end Back_End_Cannot_Inline; -- Start of processing for Add_Inlined_Subprogram begin -- Insert the current subprogram in the list of inlined subprograms, -- if it can actually be inlined by the back-end. if not Scope_In_Main_Unit (E) and then Is_Inlined (E) and then not Is_Nested (E) and then not Has_Initialized_Type (E) then if Back_End_Cannot_Inline (E) then Set_Is_Inlined (E, False); else if No (Last_Inlined) then Set_First_Inlined_Subprogram (Cunit (Main_Unit), E); else Set_Next_Inlined_Subprogram (Last_Inlined, E); end if; Last_Inlined := E; end if; end if; Inlined.Table (Index).Listed := True; Succ := Inlined.Table (Index).First_Succ; while Succ /= No_Succ loop Subp := Successors.Table (Succ).Subp; Inlined.Table (Subp).Count := Inlined.Table (Subp).Count - 1; if Inlined.Table (Subp).Count = 0 then Add_Inlined_Subprogram (Subp); end if; Succ := Successors.Table (Succ).Next; end loop; end Add_Inlined_Subprogram; ------------------------ -- Add_Scope_To_Clean -- ------------------------ procedure Add_Scope_To_Clean (Inst : Entity_Id) is Scop : constant Entity_Id := Enclosing_Dynamic_Scope (Inst); Elmt : Elmt_Id; begin -- If the instance appears in a library-level package declaration, -- all finalization is global, and nothing needs doing here. if Scop = Standard_Standard then return; end if; -- If the instance appears within a generic subprogram there is nothing -- to finalize either. declare S : Entity_Id; begin S := Scope (Inst); while Present (S) and then S /= Standard_Standard loop if Is_Generic_Subprogram (S) then return; end if; S := Scope (S); end loop; end; Elmt := First_Elmt (To_Clean); while Present (Elmt) loop if Node (Elmt) = Scop then return; end if; Elmt := Next_Elmt (Elmt); end loop; Append_Elmt (Scop, To_Clean); end Add_Scope_To_Clean; -------------- -- Add_Subp -- -------------- function Add_Subp (E : Entity_Id) return Subp_Index is Index : Subp_Index := Subp_Index (E) mod Num_Hash_Headers; J : Subp_Index; procedure New_Entry; -- Initialize entry in Inlined table procedure New_Entry is begin Inlined.Increment_Last; Inlined.Table (Inlined.Last).Name := E; Inlined.Table (Inlined.Last).First_Succ := No_Succ; Inlined.Table (Inlined.Last).Count := 0; Inlined.Table (Inlined.Last).Listed := False; Inlined.Table (Inlined.Last).Main_Call := False; Inlined.Table (Inlined.Last).Next := No_Subp; Inlined.Table (Inlined.Last).Next_Nopred := No_Subp; end New_Entry; -- Start of processing for Add_Subp begin if Hash_Headers (Index) = No_Subp then New_Entry; Hash_Headers (Index) := Inlined.Last; return Inlined.Last; else J := Hash_Headers (Index); while J /= No_Subp loop if Inlined.Table (J).Name = E then return J; else Index := J; J := Inlined.Table (J).Next; end if; end loop; -- On exit, subprogram was not found. Enter in table. Index is -- the current last entry on the hash chain. New_Entry; Inlined.Table (Index).Next := Inlined.Last; return Inlined.Last; end if; end Add_Subp; ---------------------------- -- Analyze_Inlined_Bodies -- ---------------------------- procedure Analyze_Inlined_Bodies is Comp_Unit : Node_Id; J : Int; Pack : Entity_Id; S : Succ_Index; begin Analyzing_Inlined_Bodies := False; if Serious_Errors_Detected = 0 then New_Scope (Standard_Standard); J := 0; while J <= Inlined_Bodies.Last and then Serious_Errors_Detected = 0 loop Pack := Inlined_Bodies.Table (J); while Present (Pack) and then Scope (Pack) /= Standard_Standard and then not Is_Child_Unit (Pack) loop Pack := Scope (Pack); end loop; Comp_Unit := Parent (Pack); while Present (Comp_Unit) and then Nkind (Comp_Unit) /= N_Compilation_Unit loop Comp_Unit := Parent (Comp_Unit); end loop; -- Load the body, unless it the main unit, or is an instance -- whose body has already been analyzed. if Present (Comp_Unit) and then Comp_Unit /= Cunit (Main_Unit) and then Body_Required (Comp_Unit) and then (Nkind (Unit (Comp_Unit)) /= N_Package_Declaration or else No (Corresponding_Body (Unit (Comp_Unit)))) then declare Bname : constant Unit_Name_Type := Get_Body_Name (Get_Unit_Name (Unit (Comp_Unit))); OK : Boolean; begin if not Is_Loaded (Bname) then Load_Needed_Body (Comp_Unit, OK); if not OK then Error_Msg_Unit_1 := Bname; Error_Msg_N ("one or more inlined subprograms accessed in $!", Comp_Unit); Error_Msg_Name_1 := Get_File_Name (Bname, Subunit => False); Error_Msg_N ("\but file{ was not found!", Comp_Unit); raise Unrecoverable_Error; end if; end if; end; end if; J := J + 1; end loop; -- The analysis of required bodies may have produced additional -- generic instantiations. To obtain further inlining, we perform -- another round of generic body instantiations. Establishing a -- fully recursive loop between inlining and generic instantiations -- is unlikely to yield more than this one additional pass. Instantiate_Bodies; -- The list of inlined subprograms is an overestimate, because -- it includes inlined functions called from functions that are -- compiled as part of an inlined package, but are not themselves -- called. An accurate computation of just those subprograms that -- are needed requires that we perform a transitive closure over -- the call graph, starting from calls in the main program. Here -- we do one step of the inverse transitive closure, and reset -- the Is_Called flag on subprograms all of whose callers are not. for Index in Inlined.First .. Inlined.Last loop S := Inlined.Table (Index).First_Succ; if S /= No_Succ and then not Inlined.Table (Index).Main_Call then Set_Is_Called (Inlined.Table (Index).Name, False); while S /= No_Succ loop if Is_Called (Inlined.Table (Successors.Table (S).Subp).Name) or else Inlined.Table (Successors.Table (S).Subp).Main_Call then Set_Is_Called (Inlined.Table (Index).Name); exit; end if; S := Successors.Table (S).Next; end loop; end if; end loop; -- Now that the units are compiled, chain the subprograms within -- that are called and inlined. Produce list of inlined subprograms -- sorted in topological order. Start with all subprograms that -- have no prerequisites, i.e. inlined subprograms that do not call -- other inlined subprograms. for Index in Inlined.First .. Inlined.Last loop if Is_Called (Inlined.Table (Index).Name) and then Inlined.Table (Index).Count = 0 and then not Inlined.Table (Index).Listed then Add_Inlined_Subprogram (Index); end if; end loop; -- Because Add_Inlined_Subprogram treats recursively nodes that have -- no prerequisites left, at the end of the loop all subprograms -- must have been listed. If there are any unlisted subprograms -- left, there must be some recursive chains that cannot be inlined. for Index in Inlined.First .. Inlined.Last loop if Is_Called (Inlined.Table (Index).Name) and then Inlined.Table (Index).Count /= 0 and then not Is_Predefined_File_Name (Unit_File_Name (Get_Source_Unit (Inlined.Table (Index).Name))) then Error_Msg_N ("& cannot be inlined?", Inlined.Table (Index).Name); -- A warning on the first one might be sufficient ??? end if; end loop; Pop_Scope; end if; end Analyze_Inlined_Bodies; ----------------------------- -- Check_Body_For_Inlining -- ----------------------------- procedure Check_Body_For_Inlining (N : Node_Id; P : Entity_Id) is Bname : Unit_Name_Type; E : Entity_Id; OK : Boolean; begin if Is_Compilation_Unit (P) and then not Is_Generic_Instance (P) then Bname := Get_Body_Name (Get_Unit_Name (Unit (N))); E := First_Entity (P); while Present (E) loop if Is_Always_Inlined (E) or else (Front_End_Inlining and then Has_Pragma_Inline (E)) then if not Is_Loaded (Bname) then Load_Needed_Body (N, OK); if OK then -- Check that we are not trying to inline a parent -- whose body depends on a child, when we are compiling -- the body of the child. Otherwise we have a potential -- elaboration circularity with inlined subprograms and -- with Taft-Amendment types. declare Comp : Node_Id; -- Body just compiled Child_Spec : Entity_Id; -- Spec of main unit Ent : Entity_Id; -- For iteration With_Clause : Node_Id; -- Context of body. begin if Nkind (Unit (Cunit (Main_Unit))) = N_Package_Body and then Present (Body_Entity (P)) then Child_Spec := Defining_Entity ( (Unit (Library_Unit (Cunit (Main_Unit))))); Comp := Parent (Unit_Declaration_Node (Body_Entity (P))); With_Clause := First (Context_Items (Comp)); -- Check whether the context of the body just -- compiled includes a child of itself, and that -- child is the spec of the main compilation. while Present (With_Clause) loop if Nkind (With_Clause) = N_With_Clause and then Scope (Entity (Name (With_Clause))) = P and then Entity (Name (With_Clause)) = Child_Spec then Error_Msg_Node_2 := Child_Spec; Error_Msg_NE ("body of & depends on child unit&?", With_Clause, P); Error_Msg_N ("\subprograms in body cannot be inlined?", With_Clause); -- Disable further inlining from this unit, -- and keep Taft-amendment types incomplete. Ent := First_Entity (P); while Present (Ent) loop if Is_Type (Ent) and then Has_Completion_In_Body (Ent) then Set_Full_View (Ent, Empty); elsif Is_Subprogram (Ent) then Set_Is_Inlined (Ent, False); end if; Next_Entity (Ent); end loop; return; end if; Next (With_Clause); end loop; end if; end; elsif Ineffective_Inline_Warnings then Error_Msg_Unit_1 := Bname; Error_Msg_N ("unable to inline subprograms defined in $?", P); Error_Msg_N ("\body not found?", P); return; end if; end if; return; end if; Next_Entity (E); end loop; end if; end Check_Body_For_Inlining; -------------------- -- Cleanup_Scopes -- -------------------- procedure Cleanup_Scopes is Elmt : Elmt_Id; Decl : Node_Id; Scop : Entity_Id; begin Elmt := First_Elmt (To_Clean); while Present (Elmt) loop Scop := Node (Elmt); if Ekind (Scop) = E_Entry then Scop := Protected_Body_Subprogram (Scop); elsif Is_Subprogram (Scop) and then Is_Protected_Type (Scope (Scop)) and then Present (Protected_Body_Subprogram (Scop)) then -- If a protected operation contains an instance, its -- cleanup operations have been delayed, and the subprogram -- has been rewritten in the expansion of the enclosing -- protected body. It is the corresponding subprogram that -- may require the cleanup operations. Set_Uses_Sec_Stack (Protected_Body_Subprogram (Scop), Uses_Sec_Stack (Scop)); Scop := Protected_Body_Subprogram (Scop); end if; if Ekind (Scop) = E_Block then Decl := Parent (Block_Node (Scop)); else Decl := Unit_Declaration_Node (Scop); if Nkind (Decl) = N_Subprogram_Declaration or else Nkind (Decl) = N_Task_Type_Declaration or else Nkind (Decl) = N_Subprogram_Body_Stub then Decl := Unit_Declaration_Node (Corresponding_Body (Decl)); end if; end if; New_Scope (Scop); Expand_Cleanup_Actions (Decl); End_Scope; Elmt := Next_Elmt (Elmt); end loop; end Cleanup_Scopes; -------------------------- -- Has_Initialized_Type -- -------------------------- function Has_Initialized_Type (E : Entity_Id) return Boolean is E_Body : constant Node_Id := Get_Subprogram_Body (E); Decl : Node_Id; begin if No (E_Body) then -- imported subprogram return False; else Decl := First (Declarations (E_Body)); while Present (Decl) loop if Nkind (Decl) = N_Full_Type_Declaration and then Present (Init_Proc (Defining_Identifier (Decl))) then return True; end if; Next (Decl); end loop; end if; return False; end Has_Initialized_Type; ---------------- -- Initialize -- ---------------- procedure Initialize is begin Analyzing_Inlined_Bodies := False; Pending_Descriptor.Init; Pending_Instantiations.Init; Inlined_Bodies.Init; Successors.Init; Inlined.Init; for J in Hash_Headers'Range loop Hash_Headers (J) := No_Subp; end loop; end Initialize; ------------------------ -- Instantiate_Bodies -- ------------------------ -- Generic bodies contain all the non-local references, so an -- instantiation does not need any more context than Standard -- itself, even if the instantiation appears in an inner scope. -- Generic associations have verified that the contract model is -- satisfied, so that any error that may occur in the analysis of -- the body is an internal error. procedure Instantiate_Bodies is J : Int; Info : Pending_Body_Info; begin if Serious_Errors_Detected = 0 then Expander_Active := (Operating_Mode = Opt.Generate_Code); New_Scope (Standard_Standard); To_Clean := New_Elmt_List; if Is_Generic_Unit (Cunit_Entity (Main_Unit)) then Start_Generic; end if; -- A body instantiation may generate additional instantiations, so -- the following loop must scan to the end of a possibly expanding -- set (that's why we can't simply use a FOR loop here). J := 0; while J <= Pending_Instantiations.Last and then Serious_Errors_Detected = 0 loop Info := Pending_Instantiations.Table (J); -- If the instantiation node is absent, it has been removed -- as part of unreachable code. if No (Info.Inst_Node) then null; elsif Nkind (Info.Act_Decl) = N_Package_Declaration then Instantiate_Package_Body (Info); Add_Scope_To_Clean (Defining_Entity (Info.Act_Decl)); else Instantiate_Subprogram_Body (Info); end if; J := J + 1; end loop; -- Reset the table of instantiations. Additional instantiations -- may be added through inlining, when additional bodies are -- analyzed. Pending_Instantiations.Init; -- We can now complete the cleanup actions of scopes that contain -- pending instantiations (skipped for generic units, since we -- never need any cleanups in generic units). -- pending instantiations. if Expander_Active and then not Is_Generic_Unit (Main_Unit_Entity) then Cleanup_Scopes; elsif Is_Generic_Unit (Cunit_Entity (Main_Unit)) then End_Generic; end if; Pop_Scope; end if; end Instantiate_Bodies; --------------- -- Is_Nested -- --------------- function Is_Nested (E : Entity_Id) return Boolean is Scop : Entity_Id := Scope (E); begin while Scop /= Standard_Standard loop if Ekind (Scop) in Subprogram_Kind then return True; elsif Ekind (Scop) = E_Task_Type or else Ekind (Scop) = E_Entry or else Ekind (Scop) = E_Entry_Family then return True; end if; Scop := Scope (Scop); end loop; return False; end Is_Nested; ---------- -- Lock -- ---------- procedure Lock is begin Pending_Instantiations.Locked := True; Inlined_Bodies.Locked := True; Successors.Locked := True; Inlined.Locked := True; Pending_Instantiations.Release; Inlined_Bodies.Release; Successors.Release; Inlined.Release; end Lock; -------------------------- -- Remove_Dead_Instance -- -------------------------- procedure Remove_Dead_Instance (N : Node_Id) is J : Int; begin J := 0; while J <= Pending_Instantiations.Last loop if Pending_Instantiations.Table (J).Inst_Node = N then Pending_Instantiations.Table (J).Inst_Node := Empty; return; end if; J := J + 1; end loop; end Remove_Dead_Instance; ------------------------ -- Scope_In_Main_Unit -- ------------------------ function Scope_In_Main_Unit (Scop : Entity_Id) return Boolean is Comp : Node_Id; S : Entity_Id := Scop; Ent : Entity_Id := Cunit_Entity (Main_Unit); begin -- The scope may be within the main unit, or it may be an ancestor -- of the main unit, if the main unit is a child unit. In both cases -- it makes no sense to process the body before the main unit. In -- the second case, this may lead to circularities if a parent body -- depends on a child spec, and we are analyzing the child. while Scope (S) /= Standard_Standard and then not Is_Child_Unit (S) loop S := Scope (S); end loop; Comp := Parent (S); while Present (Comp) and then Nkind (Comp) /= N_Compilation_Unit loop Comp := Parent (Comp); end loop; if Is_Child_Unit (Ent) then while Present (Ent) and then Is_Child_Unit (Ent) loop if Scope (Ent) = S then return True; end if; Ent := Scope (Ent); end loop; end if; return Comp = Cunit (Main_Unit) or else Comp = Library_Unit (Cunit (Main_Unit)); end Scope_In_Main_Unit; end Inline;
with Ada.Containers.Doubly_Linked_Lists; package body Silo is use Ada.Containers; package Label_Container is new Doubly_Linked_Lists (Label_Data); type Label_List is new Label_Container.List with null record; theStack : Label_List; procedure Push (Data : Label_Data) is begin Append (theStack, Data); end Push; -- ----------------------------------------------------------------- function Pull return Label_Data is Data : Label_Data; begin if Is_Empty (theStack) then raise Empty_Stack; end if; Data := First_Element (theStack); Delete_First (theStack); return Data; end Pull; -- ----------------------------------------------------------------- function Set_Data (Label_String : Unbounded_String; Label_Position : GL.Types.Singles.Vector2) return Label_Data is begin return (Label_String, Label_Position); end Set_Data; -- ----------------------------------------------------------------- procedure Get_Data (Label_String : out Unbounded_String; Label_Position : out GL.Types.Singles.Vector2) is theData : Label_Data := Pull; begin Label_String:= theData.Label_String; Label_Position := theData.Label_Position; end Get_Data; -- ----------------------------------------------------------------- function Size return Integer is begin return Integer (Length (theStack)); end Size; -- ----------------------------------------------------------------- end Silo;
-- SPDX-License-Identifier: Apache-2.0 -- -- Copyright (c) 2021 onox <denkpadje@gmail.com> -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. with EGL.Objects.Displays; package EGL.Objects.Configs is pragma Preelaborate; type Sample_Size is range 0 .. 16 with Static_Predicate => Sample_Size in 0 | 2 | 4 | 8 | 16; type Config_State is record Red, Green, Blue, Alpha : Natural; Depth, Stencil : Natural; Samples : Sample_Size; end record; type Config is new EGL_Object with private; function State (Object : Config) return Config_State; type Config_Array is array (Positive range <>) of Config; function Get_Configs (Display : Displays.Display; Red, Green, Blue, Alpha : Natural; Depth, Stencil : Natural; Samples : Sample_Size) return Config_Array with Pre => Display.Is_Initialized, Post => (for all Config of Get_Configs'Result => Config.Is_Initialized); private type Config is new EGL_Object with record State : Config_State; end record; end EGL.Objects.Configs;
package Swapping is procedure Swap (X, Y: in out Positive); procedure Identity (X, Y: in out Positive) with Depends => (X => X, Y => Y); end Swapping;
with Ada.Text_IO; procedure Strip_ASCII is Full: String := 'a' & Character'Val(11) & 'b' & Character'Val(166) & 'c' & Character'Val(127) & Character'Val(203) & Character'Val(202) & "de"; -- 5 ordinary characters ('a' .. 'e') -- 2 control characters (11, 127); note that 11 is the "vertical tab" -- 3 extended characters (166, 203, 202) function Filter(S: String; From: Character := ' '; To: Character := Character'Val(126); Above: Character := Character'Val(127)) return String is begin if S'Length = 0 then return ""; elsif (S(S'First) >= From and then S(S'First) <= To) or else S(S'First) > Above then return S(S'First) & Filter(S(S'First+1 .. S'Last), From, To, Above); else return Filter(S(S'First+1 .. S'Last), From, To, Above); end if; end Filter; procedure Put_Line(Text, S: String) is begin Ada.Text_IO.Put_Line(Text & " """ & S & """, Length:" & Integer'Image(S'Length)); end Put_Line; begin Put_Line("The full string :", Full); Put_Line("No Control Chars:", Filter(Full)); -- default values for From, To, and Above Put_Line("Neither_Extended:", Filter(Full, Above => Character'Last)); -- defaults for From and To end Strip_ASCII;
PROCEDURE Procedure_Instantiation2 IS PACKAGE PKG IS GENERIC PROCEDURE P20 ; -- OK. END PKG; PACKAGE BODY PKG IS PROCEDURE P20 IS BEGIN null; END P20; END PKG; PACKAGE INSTANCES IS PROCEDURE NP20 IS NEW PKG.P20; END INSTANCES; BEGIN null; END Procedure_Instantiation2;
------------------------------------------------------------------------------ -- Copyright (c) 2013-2014, Natacha Porté -- -- -- -- Permission to use, copy, modify, and distribute this software for any -- -- purpose with or without fee is hereby granted, provided that the above -- -- copyright notice and this permission notice appear in all copies. -- -- -- -- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -- -- WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -- -- MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR -- -- ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -- -- WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -- -- ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF -- -- OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. -- ------------------------------------------------------------------------------ ------------------------------------------------------------------------------ -- Sxcat concatenates and pretty prints input S-expressions to standard -- -- output. -- -- Pretty printer options can be given through command-line options or -- -- loaded from a S-expression file. -- ------------------------------------------------------------------------------ with Ada.Command_Line; with Ada.Streams.Stream_IO; with Ada.Strings.Fixed; with Ada.Strings.Maps; with Ada.Text_IO.Text_Streams; with Natools.Getopt_Long; with Natools.S_Expressions.Atom_Buffers; with Natools.S_Expressions.Encodings; with Natools.S_Expressions.File_Readers; with Natools.S_Expressions.Lockable; with Natools.S_Expressions.Parsers; with Natools.S_Expressions.Printers.Pretty.Config; procedure Sxcat is package SE renames Natools.S_Expressions; Param : SE.Printers.Pretty.Parameters := (Char_Encoding => SE.Printers.Pretty.ASCII, Fallback => SE.Printers.Pretty.Hexadecimal, Hex_Casing => SE.Encodings.Upper, Indent => SE.Printers.Pretty.Tabs, Indentation => 1, Newline => SE.Printers.Pretty.LF, Newline_At => (SE.Printers.Pretty.Opening => (SE.Printers.Pretty.Opening => True, SE.Printers.Pretty.Atom_Data => False, SE.Printers.Pretty.Closing => False), SE.Printers.Pretty.Atom_Data => (SE.Printers.Pretty.Opening => True, SE.Printers.Pretty.Atom_Data => True, SE.Printers.Pretty.Closing => True), SE.Printers.Pretty.Closing => (SE.Printers.Pretty.Opening => True, SE.Printers.Pretty.Atom_Data => True, SE.Printers.Pretty.Closing => True)), Quoted => SE.Printers.Pretty.When_Shorter, Quoted_Escape => SE.Printers.Pretty.Octal_Escape, Space_At => (others => (others => False)), Tab_Stop => 8, Token => SE.Printers.Pretty.Standard_Token, Width => 79); To_Print : SE.Printers.Pretty.Parameters := Param; Output_Stream : constant Ada.Text_IO.Text_Streams.Stream_Access := Ada.Text_IO.Text_Streams.Stream (Ada.Text_IO.Current_Output); function Is_Natural (Argument : in String) return Boolean; package Options is type Id is (ASCII, Atom, Base64_Expr, Base64_Atom, Canonical, Dos_Newline, Dump_Config, Eight_Bit, Extended_Token, Load_Config, Hex_Atom, Hex_Escape, Help, Newline_At, Newline_Encoding, No_Indent, No_Quoted, No_Token, Indent, Octal_Escape, Quoted_Single_Line, Quoted_When_Shorter, Space_At, Tab_Stop, Token, Unix_Newline, UTF_8, Verbatim, Width, Upper_Hex, Lower_Hex, Atom_List); type Action is (Error, Print_Help, Run, Run_Base64, Print_Atom, Print_Atom_List, Print_Config); end Options; package Getopt is new Natools.Getopt_Long (Options.Id); function Getopt_Config return Getopt.Configuration; type Callback is new Getopt.Handlers.Callback with record Action : Options.Action := Options.Run; Arg_Count : Natural := 0; end record; overriding procedure Option (Handler : in out Callback; Id : in Options.Id; Argument : in String); overriding procedure Argument (Handler : in out Callback; Argument : in String); procedure Parse_Separator (Separator : in out SE.Printers.Pretty.Entity_Separator; Image : in String); procedure Process (Handler : in Callback'Class; Input : access Ada.Streams.Root_Stream_Type'Class); procedure Process (Printer : in out SE.Printers.Pretty.Stream_Printer; Input : access Ada.Streams.Root_Stream_Type'Class; Parse : in Boolean := True); procedure Print_Help (Opt : in Getopt.Configuration; Output : in Ada.Text_IO.File_Type); type Base64_Stream (Backend : access Ada.Streams.Root_Stream_Type'Class) is new Ada.Streams.Root_Stream_Type with record Buffer : Ada.Streams.Stream_Element_Array (1 .. 3); Cursor : Ada.Streams.Stream_Element_Offset := 1; end record; procedure Read (Stream : in out Base64_Stream; Item : out Ada.Streams.Stream_Element_Array; Last : out Ada.Streams.Stream_Element_Offset); procedure Write (Stream : in out Base64_Stream; Item : in Ada.Streams.Stream_Element_Array); procedure Open (Stream : in out Base64_Stream'Class); procedure Close (Stream : in out Base64_Stream'Class); function Is_Natural (Argument : in String) return Boolean is begin if Argument = "" then return False; end if; for I in Argument'Range loop if Argument (I) not in '0' .. '9' then return False; end if; end loop; return True; end Is_Natural; function Getopt_Config return Getopt.Configuration is use Getopt; Result : Getopt.Configuration; begin Result.Add_Option ("8-bit", '8', No_Argument, Options.Eight_Bit); Result.Add_Option ("ASCII", 'A', No_Argument, Options.ASCII); Result.Add_Option ("atom", 'a', No_Argument, Options.Atom); Result.Add_Option ("brace", 'B', No_Argument, Options.Base64_Expr); Result.Add_Option ("base64", 'b', No_Argument, Options.Base64_Atom); Result.Add_Option ("canonical", 'c', No_Argument, Options.Canonical); Result.Add_Option ("dos-newline", 'D', No_Argument, Options.Dos_Newline); Result.Add_Option ("dump-config", 'd', No_Argument, Options.Dump_Config); Result.Add_Option ("escape-hex", 'E', No_Argument, Options.Hex_Escape); Result.Add_Option ("ext-token", 'e', No_Argument, Options.Extended_Token); Result.Add_Option ("config", 'f', Required_Argument, Options.Load_Config); Result.Add_Option ("hex-atom", 'H', No_Argument, Options.Hex_Atom); Result.Add_Option ("help", 'h', No_Argument, Options.Help); Result.Add_Option ("no-indent", 'I', No_Argument, Options.No_Indent); Result.Add_Option ("indent", 'i', Required_Argument, Options.Indent); Result.Add_Option ("single-line", 'l', No_Argument, Options.Quoted_Single_Line); Result.Add_Option ("newline-at", 'N', Required_Argument, Options.Newline_At); Result.Add_Option ("nl-encoding", 'n', Required_Argument, Options.Newline_Encoding); Result.Add_Option ("escape-octal", 'o', No_Argument, Options.Octal_Escape); Result.Add_Option ("no-quoted", 'Q', No_Argument, Options.No_Quoted); Result.Add_Option ("quoted", 'q', No_Argument, Options.Quoted_When_Shorter); Result.Add_Option ("space-at", 'S', Required_Argument, Options.Space_At); Result.Add_Option ("tab-stop", 's', Required_Argument, Options.Tab_Stop); Result.Add_Option ("no-token", 'T', No_Argument, Options.No_Token); Result.Add_Option ("token", 't', No_Argument, Options.Token); Result.Add_Option ("unix-newline", 'U', No_Argument, Options.Unix_Newline); Result.Add_Option ("utf-8", 'u', No_Argument, Options.UTF_8); Result.Add_Option ("verbatim", 'v', No_Argument, Options.Verbatim); Result.Add_Option ("width", 'w', Required_Argument, Options.Width); Result.Add_Option ("upper-hex", 'X', No_Argument, Options.Upper_Hex); Result.Add_Option ("lower-hex", 'x', No_Argument, Options.Lower_Hex); Result.Add_Option ("atom-list", No_Argument, Options.Atom_List); return Result; end Getopt_Config; overriding procedure Option (Handler : in out Callback; Id : in Options.Id; Argument : in String) is use type Options.Action; begin case Id is when Options.ASCII => Param.Char_Encoding := SE.Printers.Pretty.ASCII; when Options.Atom => if Handler.Action in Options.Run .. Options.Print_Config then Handler.Action := Options.Print_Atom; end if; when Options.Atom_List => if Handler.Action in Options.Run .. Options.Print_Config then Handler.Action := Options.Print_Atom_List; end if; when Options.Base64_Atom => Param.Quoted := SE.Printers.Pretty.No_Quoted; Param.Fallback := SE.Printers.Pretty.Base64; when Options.Base64_Expr => if Handler.Action in Options.Run .. Options.Print_Config then Handler.Action := Options.Run_Base64; end if; when Options.Canonical => Param.Width := 0; Param.Newline_At := (others => (others => False)); Param.Space_At := (others => (others => False)); Param.Indentation := 0; Param.Quoted := SE.Printers.Pretty.No_Quoted; Param.Token := SE.Printers.Pretty.No_Token; Param.Fallback := SE.Printers.Pretty.Verbatim; when Options.Dos_Newline => Param.Newline := SE.Printers.Pretty.CR_LF; when Options.Dump_Config => if Handler.Action in Options.Run .. Options.Print_Config then To_Print := Param; Handler.Action := Options.Print_Config; end if; when Options.Eight_Bit => Param.Char_Encoding := SE.Printers.Pretty.Latin; when Options.Extended_Token => Param.Token := SE.Printers.Pretty.Extended_Token; when Options.Indent => declare package Fixed renames Ada.Strings.Fixed; package Maps renames Ada.Strings.Maps; Last : constant Natural := Fixed.Index (Source => Argument, Set => Maps.To_Set ("0123456789"), Going => Ada.Strings.Backward); begin if Last = 0 then Handler.Action := Options.Error; elsif Last = Argument'Last then Param.Indentation := SE.Printers.Pretty.Screen_Offset'Value (Argument); elsif Argument (Last + 1 .. Argument'Last) = "t" or else Argument (Last + 1 .. Argument'Last) = "T" then Param.Indentation := SE.Printers.Pretty.Screen_Offset'Value (Argument (Argument'First .. Last)); Param.Indent := SE.Printers.Pretty.Tabs; elsif Argument (Last + 1 .. Argument'Last) = "s" or else Argument (Last + 1 .. Argument'Last) = "S" then Param.Indentation := SE.Printers.Pretty.Screen_Offset'Value (Argument (Argument'First .. Last)); Param.Indent := SE.Printers.Pretty.Spaces; elsif Argument (Last + 1 .. Argument'Last) = "ts" or else Argument (Last + 1 .. Argument'Last) = "TS" or else Argument (Last + 1 .. Argument'Last) = "st" or else Argument (Last + 1 .. Argument'Last) = "ST" then Param.Indentation := SE.Printers.Pretty.Screen_Offset'Value (Argument (Argument'First .. Last)); Param.Indent := SE.Printers.Pretty.Tabs_And_Spaces; else Handler.Action := Options.Error; end if; exception when Constraint_Error => Handler.Action := Options.Error; end; when Options.Hex_Atom => Param.Fallback := SE.Printers.Pretty.Hexadecimal; when Options.Hex_Escape => Param.Quoted_Escape := SE.Printers.Pretty.Hex_Escape; when Options.Help => Handler.Action := Options.Print_Help; when Options.Load_Config => declare Conf : SE.Lockable.Descriptor'Class := SE.File_Readers.Reader (Argument); begin SE.Printers.Pretty.Config.Update (Param, Conf); end; when Options.Newline_At => Parse_Separator (Param.Newline_At, Argument); when Options.Newline_Encoding => begin case Argument'Length is when 2 => Param.Newline := SE.Printers.Pretty.Newline_Encoding'Value (Argument); when 4 | 5 => Param.Newline := SE.Printers.Pretty.Newline_Encoding'Value (Argument (Argument'First .. Argument'First + 1) & '_' & Argument (Argument'Last - 1 .. Argument'Last)); when others => raise Constraint_Error; end case; exception when Constraint_Error => Ada.Text_IO.Put_Line (Ada.Text_IO.Current_Error, "Invalid newline encoding """ & Argument & '"'); Handler.Action := Options.Error; end; when Options.No_Quoted => Param.Quoted := SE.Printers.Pretty.No_Quoted; when Options.No_Indent => Param.Indentation := 0; when Options.No_Token => Param.Token := SE.Printers.Pretty.No_Token; when Options.Octal_Escape => Param.Quoted_Escape := SE.Printers.Pretty.Octal_Escape; when Options.Quoted_Single_Line => Param.Quoted := SE.Printers.Pretty.Single_Line; when Options.Quoted_When_Shorter => Param.Quoted := SE.Printers.Pretty.When_Shorter; when Options.Space_At => Parse_Separator (Param.Space_At, Argument); when Options.Tab_Stop => if Is_Natural (Argument) then Param.Tab_Stop := SE.Printers.Pretty.Screen_Offset'Value (Argument); else Handler.Action := Options.Error; end if; when Options.Token => Param.Token := SE.Printers.Pretty.Standard_Token; when Options.Unix_Newline => Param.Newline := SE.Printers.Pretty.LF; when Options.UTF_8 => Param.Char_Encoding := SE.Printers.Pretty.UTF_8; when Options.Verbatim => Param.Fallback := SE.Printers.Pretty.Verbatim; when Options.Width => if Is_Natural (Argument) then Param.Width := SE.Printers.Pretty.Screen_Offset'Value (Argument); else Handler.Action := Options.Error; end if; when Options.Upper_Hex => Param.Hex_Casing := SE.Encodings.Upper; when Options.Lower_Hex => Param.Hex_Casing := SE.Encodings.Lower; end case; end Option; overriding procedure Argument (Handler : in out Callback; Argument : in String) is use type Options.Action; begin Handler.Arg_Count := Handler.Arg_Count + 1; if Handler.Action not in Options.Run .. Options.Print_Config then return; end if; if Argument = "-" then Process (Handler, Ada.Text_IO.Text_Streams.Stream (Ada.Text_IO.Current_Input)); else declare File : Ada.Streams.Stream_IO.File_Type; begin Ada.Streams.Stream_IO.Open (File, Ada.Streams.Stream_IO.In_File, Argument); Process (Handler, Ada.Streams.Stream_IO.Stream (File)); Ada.Streams.Stream_IO.Close (File); end; end if; end Argument; procedure Parse_Separator (Separator : in out SE.Printers.Pretty.Entity_Separator; Image : in String) is procedure Parse (C : in Character; Entity : out SE.Printers.Pretty.Entity; Valid : out Boolean); procedure Parse (C : in Character; Entity : out SE.Printers.Pretty.Entity; Valid : out Boolean) is begin case C is when '(' | 'o' | 'O' => Entity := SE.Printers.Pretty.Opening; Valid := True; when ')' | 'c' | 'C' => Entity := SE.Printers.Pretty.Closing; Valid := True; when 'a' | 'A' | 'd' | 'D' | 'x' | 'X' => Entity := SE.Printers.Pretty.Atom_Data; Valid := True; when others => Valid := False; end case; end Parse; I : Positive := Image'First; Before, After : SE.Printers.Pretty.Entity := SE.Printers.Pretty.Opening; Valid : Boolean; Result : SE.Printers.Pretty.Entity_Separator := (others => (others => False)); begin while I + 1 in Image'Range loop Parse (Image (I), Before, Valid); if Valid then Parse (Image (I + 1), After, Valid); if Valid then Result (Before, After) := True; end if; I := I + 1; end if; I := I + 1; end loop; Separator := Result; end Parse_Separator; Printer_Direct : SE.Printers.Pretty.Stream_Printer (Output_Stream); Base64_Output : aliased Base64_Stream (Output_Stream); Printer_Base64 : SE.Printers.Pretty.Stream_Printer (Base64_Output'Access); First_Atom_In_List : Boolean := True; procedure Process (Handler : in Callback'Class; Input : access Ada.Streams.Root_Stream_Type'Class) is begin case Handler.Action is when Options.Error | Options.Print_Help | Options.Print_Config => raise Program_Error; when Options.Run => Printer_Direct.Set_Parameters (Param); Process (Printer_Direct, Input, True); when Options.Run_Base64 => if Handler.Arg_Count = 1 then Open (Base64_Output); end if; Printer_Base64.Set_Parameters (Param); Process (Printer_Base64, Input, True); when Options.Print_Atom => Printer_Direct.Set_Parameters (Param); Process (Printer_Direct, Input, False); when Options.Print_Atom_List => if First_Atom_In_List then Printer_Direct.Open_List; First_Atom_In_List := False; end if; Printer_Direct.Set_Parameters (Param); Process (Printer_Direct, Input, False); end case; end Process; procedure Process (Printer : in out SE.Printers.Pretty.Stream_Printer; Input : access Ada.Streams.Root_Stream_Type'Class; Parse : in Boolean := True) is Parser : SE.Parsers.Stream_Parser (Input); Event : SE.Events.Event; begin if Parse then loop Parser.Next (Event); case Event is when SE.Events.Error => raise Program_Error; when SE.Events.Open_List => Printer.Open_List; when SE.Events.Close_List => Printer.Close_List; when SE.Events.Add_Atom => Printer.Append_Atom (Parser.Current_Atom); when SE.Events.End_Of_Input => exit; end case; end loop; else declare use type Ada.Streams.Stream_Element_Offset; Buffer : SE.Atom_Buffers.Atom_Buffer; Chunk : Ada.Streams.Stream_Element_Array (1 .. 1024); Last : Ada.Streams.Stream_Element_Offset; begin loop Input.Read (Chunk, Last); exit when Last + 1 = Chunk'First; Buffer.Append (Chunk (1 .. Last)); exit when Last < Chunk'Last; end loop; Printer.Append_Atom (Buffer.Data (Buffer.Data'First .. Buffer.Data'First + Buffer.Length - 1)); end; end if; end Process; procedure Print_Help (Opt : in Getopt.Configuration; Output : in Ada.Text_IO.File_Type) is use Ada.Text_IO; Indent : constant String := " "; begin Put_Line (Output, "Usage:"); for Id in Options.Id loop Put (Output, Indent & Opt.Format_Names (Id)); case Id is when Options.ASCII => New_Line (Output); Put_Line (Output, Indent & Indent & "Assume ASCII encoding of output"); when Options.Atom => New_Line (Output); Put_Line (Output, Indent & Indent & "Treat intputs as individual atoms"); when Options.Atom_List => New_Line (Output); Put_Line (Output, Indent & Indent & "Treat intputs as a list of individual atoms"); when Options.Base64_Expr => New_Line (Output); Put_Line (Output, Indent & Indent & "Output the expression in base-64 encoding"); when Options.Base64_Atom => New_Line (Output); Put_Line (Output, Indent & Indent & "Output atoms using base-64 encoding"); when Options.Canonical => New_Line (Output); Put_Line (Output, Indent & Indent & "Output canonical representation"); when Options.Dos_Newline => New_Line (Output); Put_Line (Output, Indent & Indent & "Use DOS newlines (CR+LF)"); when Options.Dump_Config => New_Line (Output); Put_Line (Output, Indent & Indent & "Output printer configuration instead of input"); when Options.Eight_Bit => New_Line (Output); Put_Line (Output, Indent & Indent & "Assume 8-bit wide encoding of output (e.g. ISO-8859-*)"); when Options.Extended_Token => New_Line (Output); Put_Line (Output, Indent & Indent & "Output atoms as extended tokens when possible"); when Options.Hex_Atom => New_Line (Output); Put_Line (Output, Indent & Indent & "Use hexadecimal encoding for atoms"); when Options.Hex_Escape => New_Line (Output); Put_Line (Output, Indent & Indent & "Use hexadecimal escape sequences in quoted strings"); when Options.Help => New_Line (Output); Put_Line (Output, Indent & Indent & "Display help"); when Options.Indent => Put_Line (Output, " <number>[st]"); Put_Line (Output, Indent & Indent & "Set indentation to that number of spaces or tabs or both"); when Options.Load_Config => Put_Line (Output, " <filename>"); Put_Line (Output, Indent & Indent & "Load printer configuration from file"); when Options.Newline_At => Put_Line (Output, " <position list>"); Put_Line (Output, Indent & Indent & "Insert newlines at the given positions"); when Options.Newline_Encoding => Put_Line (Output, " <newline encoding>"); Put_Line (Output, Indent & Indent & "Use given newline encoding (CR, LF, CR_LF or LF_CR)"); when Options.No_Quoted => New_Line (Output); Put_Line (Output, Indent & Indent & "Disable quoted-string encoding for atoms"); when Options.No_Indent => New_Line (Output); Put_Line (Output, Indent & Indent & "Disable indentation"); when Options.No_Token => New_Line (Output); Put_Line (Output, Indent & Indent & "Disable token encoding for atoms"); when Options.Octal_Escape => New_Line (Output); Put_Line (Output, Indent & Indent & "Use octal escape sequences in quoted strings"); when Options.Quoted_Single_Line => New_Line (Output); Put_Line (Output, Indent & Indent & "Use quoted-string atom encoding when it fits on the line"); when Options.Quoted_When_Shorter => New_Line (Output); Put_Line (Output, Indent & Indent & "Use quoted-string atom encoding when shorter"); when Options.Space_At => Put_Line (Output, " <position list>"); Put_Line (Output, Indent & Indent & "Insert a space at the given positions"); when Options.Tab_Stop => Put_Line (Output, " <columns>"); Put_Line (Output, Indent & Indent & "Place tab stops at each multiple of given length"); when Options.Token => New_Line (Output); Put_Line (Output, Indent & Indent & "Output atoms as standard tokens when possible"); when Options.Unix_Newline => New_Line (Output); Put_Line (Output, Indent & Indent & "Use UNIX newlines (LF)"); when Options.UTF_8 => New_Line (Output); Put_Line (Output, Indent & Indent & "Assume UTF-8 encoding of output"); when Options.Verbatim => New_Line (Output); Put_Line (Output, Indent & Indent & "Output atoms using verbatim encoding"); when Options.Width => Put_Line (Output, " <columns>"); Put_Line (Output, Indent & Indent & "Maximum width of output (0 to disable width limit)"); when Options.Upper_Hex => New_Line (Output); Put_Line (Output, Indent & Indent & "Output atoms using upper-case hexadecimal encoding"); when Options.Lower_Hex => New_Line (Output); Put_Line (Output, Indent & Indent & "Output atoms using lower-case hexadecimal encoding"); end case; end loop; end Print_Help; procedure Read (Stream : in out Base64_Stream; Item : out Ada.Streams.Stream_Element_Array; Last : out Ada.Streams.Stream_Element_Offset) is begin Stream.Backend.Read (Item, Last); end Read; procedure Write (Stream : in out Base64_Stream; Item : in Ada.Streams.Stream_Element_Array) is use type Ada.Streams.Stream_Element_Offset; I : Ada.Streams.Stream_Element_Offset := Item'First; begin while Stream.Cursor in Stream.Buffer'Range loop if I not in Item'Range then return; end if; Stream.Buffer (Stream.Cursor) := Item (I); Stream.Cursor := Stream.Cursor + 1; I := I + 1; end loop; loop Stream.Backend.Write (SE.Encodings.Encode_Base64 (Stream.Buffer)); exit when I + Stream.Buffer'Length - 1 not in Item'Range; Stream.Buffer := Item (I .. I + Stream.Buffer'Length - 1); I := I + Stream.Buffer'Length; end loop; Stream.Cursor := Stream.Buffer'First; while I in Item'Range loop Stream.Buffer (Stream.Cursor) := Item (I); Stream.Cursor := Stream.Cursor + 1; I := I + 1; end loop; end Write; procedure Open (Stream : in out Base64_Stream'Class) is begin Stream.Backend.Write ((1 => SE.Encodings.Base64_Expr_Begin)); end Open; procedure Close (Stream : in out Base64_Stream'Class) is use type Ada.Streams.Stream_Element_Offset; begin if Stream.Cursor > Stream.Buffer'First then Stream.Backend.Write (SE.Encodings.Encode_Base64 (Stream.Buffer (Stream.Buffer'First .. Stream.Cursor - 1))); end if; Stream.Backend.Write ((1 => SE.Encodings.Base64_Expr_End)); end Close; Opt_Config : constant Getopt.Configuration := Getopt_Config; Handler : Callback; begin Opt_Config.Process (Handler); case Handler.Action is when Options.Error => Ada.Command_Line.Set_Exit_Status (Ada.Command_Line.Failure); Print_Help (Opt_Config, Ada.Text_IO.Current_Error); when Options.Print_Help => Print_Help (Opt_Config, Ada.Text_IO.Current_Output); when Options.Print_Config => Printer_Direct.Set_Parameters (Param); SE.Printers.Pretty.Config.Print (Printer_Direct, To_Print); when Options.Run .. Options.Print_Atom_List => if Handler.Arg_Count = 0 then Handler.Argument ("-"); end if; if Options."=" (Handler.Action, Options.Run_Base64) then Close (Base64_Output); elsif Options."=" (Handler.Action, Options.Print_Atom_List) then if First_Atom_In_List then Printer_Direct.Open_List; end if; Printer_Direct.Close_List; end if; end case; end Sxcat;
Src : String := "Hello"; Dest : String := Src;
-- SPDX-License-Identifier: Apache-2.0 -- -- Copyright (c) 2017 onox <denkpadje@gmail.com> -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. with Ada.Finalization; with GL.Low_Level; package GL.Fences is pragma Preelaborate; type Wait_Status is (Already_Signaled, Timeout_Expired, Condition_Satisfied, Wait_Failed); type Signaled_Status is (Unset, Set, Signaled); type Fence is new Ada.Finalization.Controlled with private; overriding procedure Initialize (Object : in out Fence); -- Create the object in OpenGL memory overriding procedure Adjust (Object : in out Fence); -- Increase the reference count overriding procedure Finalize (Object : in out Fence); -- Decrease the reference count, deleting the sync object when it -- reaches zero procedure Set_Fence (Object : in out Fence) with Pre => Object.Status /= Set, Post => Object.Initialized and Object.Status = Set; -- Insert a new fence sync object into the OpenGL command stream -- -- Any previously associated fence will be deleted procedure Delete (Object : in out Fence) with Post => not Object.Initialized and Object.Status = Unset; function Initialized (Object : Fence) return Boolean; -- Return True if a fence sync object is associated, False otherwise function Status (Object : Fence) return Signaled_Status; function Signaled (Object : Fence) return Boolean with Pre => Object.Initialized and Object.Status /= Unset; function Client_Wait (Object : Fence; Timeout : Duration) return Wait_Status with Pre => Object.Initialized and Object.Status = Set; -- Let the client block and wait until the fence becomes signaled or the -- timeout expires -- -- Does not delete the fence if it has been signaled. procedure Server_Wait (Object : Fence) with Pre => Object.Initialized and Object.Status = Set; -- Let the server block and wait until the fence becomes signaled or the -- video driver-dependent maximum timeout expires -- -- Does not delete the fence. Call Signaled to find out -- whether the fence was signaled or the timeout expired. overriding function "=" (Left, Right : Fence) return Boolean; private type Sync_Object_Reference is record Sync_ID : Low_Level.Sync; Reference_Count : Natural; Status : Signaled_Status; end record; type Sync_Object_Reference_Access is access all Sync_Object_Reference; type Fence is new Ada.Finalization.Controlled with record Reference : Sync_Object_Reference_Access; end record; for Wait_Status use (Already_Signaled => 16#911A#, Timeout_Expired => 16#911B#, Condition_Satisfied => 16#911C#, Wait_Failed => 16#911D#); for Wait_Status'Size use Low_Level.Enum'Size; end GL.Fences;
package body Sinu is function Norm (Y : Dynamical_Variable) return Real is Sum : Real := +0.0; begin for i in Dyn_Index loop Sum := Sum + Abs Y(i); --Sum := Sum + Y(i) * Y(i); end loop; return Sum; end Norm; function "-" (Left : Dynamical_Variable; Right : Dynamical_Variable) return Dynamical_Variable is Result : Dynamical_Variable; begin for I in Dyn_Index loop Result(I) := Left(I) - Right(I); end loop; return Result; end "-"; function "*" (Left : Real; Right : Dynamical_Variable) return Dynamical_Variable is Result : Dynamical_Variable; begin for I in Dyn_Index loop Result(I) := Left * Right(I); end loop; return Result; end "*"; function "+" (Left : Dynamical_Variable; Right : Dynamical_Variable) return Dynamical_Variable is Result : Dynamical_Variable; begin for I in Dyn_Index loop Result(I) := Left(I) + Right(I); end loop; return Result; end "+"; -- The differential equation is dY/dt = F (t, Y) function F (Time : Real; Y : Dynamical_Variable) return Dynamical_Variable is Deriv : Dynamical_Variable; SpringConstant : Constant Real := 1.0; --MaxForce : Constant Real := 5.0; --WellWidthInverse : Constant Real := 10.0; --WellCenter : Constant Real := 0.0; begin Deriv(0) := Y(1); Deriv(1) := -SpringConstant*Y(0); return Deriv; end F; end Sinu;
------------------------------------------------------------------------------ -- -- -- Matreshka Project -- -- -- -- XML Processor -- -- -- -- Runtime Library Component -- -- -- ------------------------------------------------------------------------------ -- -- -- Copyright © 2014, Vadim Godunko <vgodunko@gmail.com> -- -- All rights reserved. -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions -- -- are met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in the -- -- documentation and/or other materials provided with the distribution. -- -- -- -- * Neither the name of the Vadim Godunko, IE nor the names of its -- -- contributors may be used to endorse or promote products derived from -- -- this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- -- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- -- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- -- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- -- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- -- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- $Revision$ $Date$ ------------------------------------------------------------------------------ with League.Strings; with XML.DOM.Nodes; limited with XML.DOM.Elements; package XML.DOM.Attributes is pragma Preelaborate; type DOM_Attribute is limited interface and XML.DOM.Nodes.DOM_Node; type DOM_Attribute_Access is access all DOM_Attribute'Class with Storage_Size => 0; not overriding function Get_Name (Self : not null access constant DOM_Attribute) return League.Strings.Universal_String is abstract; -- Returns the name of this attribute. If Node.localName is different from -- null, this attribute is a qualified name. not overriding function Get_Value (Self : not null access constant DOM_Attribute) return League.Strings.Universal_String is abstract; not overriding procedure Set_Value (Self : not null access DOM_Attribute; New_Value : League.Strings.Universal_String) is abstract; -- On retrieval, the value of the attribute is returned as a string. -- Character and general entity references are replaced with their values. -- See also the method getAttribute on the Element interface. -- -- On setting, this creates a Text node with the unparsed contents of the -- string, i.e. any characters that an XML processor would recognize as -- markup are instead treated as literal text. See also the method -- Element.setAttribute(). -- -- Some specialized implementations, such as some [SVG 1.1] -- implementations, may do normalization automatically, even after -- mutation; in such case, the value on retrieval may differ from the value -- on setting. -- -- Exceptions on setting -- -- DOMException -- -- NO_MODIFICATION_ALLOWED_ERR: Raised when the node is readonly. not overriding function Get_Owner_Element (Self : not null access constant DOM_Attribute) return XML.DOM.Elements.DOM_Element_Access is abstract; -- The Element node this attribute is attached to or null if this attribute -- is not in use. end XML.DOM.Attributes;
------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- L I B . W R I T -- -- -- -- B o d y -- -- -- -- $Revision$ -- -- -- Copyright (C) 1992-2001 Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 2, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -- -- for more details. You should have received a copy of the GNU General -- -- Public License distributed with GNAT; see file COPYING. If not, write -- -- to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, -- -- MA 02111-1307, USA. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ with ALI; use ALI; with Atree; use Atree; with Casing; use Casing; with Einfo; use Einfo; with Errout; use Errout; with Fname; use Fname; with Fname.UF; use Fname.UF; with Lib.Util; use Lib.Util; with Lib.Xref; use Lib.Xref; with Namet; use Namet; with Nlists; use Nlists; with Gnatvsn; use Gnatvsn; with Opt; use Opt; with Osint; use Osint; with Par; with Restrict; use Restrict; with Scn; use Scn; with Sinfo; use Sinfo; with Sinput; use Sinput; with Stringt; use Stringt; with Targparm; use Targparm; with Uname; use Uname; with System.WCh_Con; use System.WCh_Con; package body Lib.Writ is ------------------------------ -- Ensure_System_Dependency -- ------------------------------ procedure Ensure_System_Dependency is Discard : List_Id; System_Uname : Unit_Name_Type; -- Unit name for system spec if needed for dummy entry System_Fname : File_Name_Type; -- File name for system spec if needed for dummy entry begin -- Nothing to do if we already compiled System for Unum in Units.First .. Last_Unit loop if Units.Table (Unum).Source_Index = System_Source_File_Index then return; end if; end loop; -- If no entry for system.ads in the units table, then add a entry -- to the units table for system.ads, which will be referenced when -- the ali file is generated. We need this because every unit depends -- on system as a result of Targparm scanning the system.ads file to -- determine the target dependent parameters for the compilation. Name_Len := 6; Name_Buffer (1 .. 6) := "system"; System_Uname := Name_To_Unit_Name (Name_Enter); System_Fname := File_Name (System_Source_File_Index); Units.Increment_Last; Units.Table (Units.Last) := ( Unit_File_Name => System_Fname, Unit_Name => System_Uname, Expected_Unit => System_Uname, Source_Index => System_Source_File_Index, Cunit => Empty, Cunit_Entity => Empty, Dependency_Num => 0, Dependent_Unit => True, Dynamic_Elab => False, Fatal_Error => False, Generate_Code => False, Has_RACW => False, Ident_String => Empty, Loading => False, Main_Priority => -1, Serial_Number => 0, Version => 0, Error_Location => No_Location); -- Parse system.ads so that the checksum is set right Initialize_Scanner (Units.Last, System_Source_File_Index); Discard := Par (Configuration_Pragmas => False); end Ensure_System_Dependency; --------------- -- Write_ALI -- --------------- procedure Write_ALI (Object : Boolean) is ---------------- -- Local Data -- ---------------- Last_Unit : constant Unit_Number_Type := Units.Last; -- Record unit number of last unit. We capture this in case we -- have to add a dummy entry to the unit table for package System. With_Flags : array (Units.First .. Last_Unit) of Boolean; -- Array of flags to show which units are with'ed Elab_Flags : array (Units.First .. Last_Unit) of Boolean; -- Array of flags to show which units have pragma Elaborate set Elab_All_Flags : array (Units.First .. Last_Unit) of Boolean; -- Array of flags to show which units have pragma Elaborate All set Elab_Des_Flags : array (Units.First .. Last_Unit) of Boolean; -- Array of flags to show which units have Elaborate_All_Desirable set Sdep_Table : Unit_Ref_Table (1 .. Pos (Last_Unit - Units.First + 2)); -- Sorted table of source dependencies. One extra entry in case we -- have to add a dummy entry for System. Num_Sdep : Nat := 0; -- Number of active entries in Sdep_Table ----------------------- -- Local Subprograms -- ----------------------- procedure Collect_Withs (Cunit : Node_Id); -- Collect with lines for entries in the context clause of the -- given compilation unit, Cunit. procedure Update_Tables_From_ALI_File; -- Given an up to date ALI file (see Up_To_Date_ALI_file_Exists -- function), update tables from the ALI information, including -- specifically the Compilation_Switches table. function Up_To_Date_ALI_File_Exists return Boolean; -- If there exists an ALI file that is up to date, then this function -- initializes the tables in the ALI spec to contain information on -- this file (using Scan_ALI) and returns True. If no file exists, -- or the file is not up to date, then False is returned. procedure Write_Unit_Information (Unit_Num : Unit_Number_Type); -- Write out the library information for one unit for which code is -- generated (includes unit line and with lines). procedure Write_With_Lines; -- Write out with lines collected by calls to Collect_Withs ------------------- -- Collect_Withs -- ------------------- procedure Collect_Withs (Cunit : Node_Id) is Item : Node_Id; Unum : Unit_Number_Type; begin Item := First (Context_Items (Cunit)); while Present (Item) loop if Nkind (Item) = N_With_Clause then Unum := Get_Cunit_Unit_Number (Library_Unit (Item)); With_Flags (Unum) := True; if Elaborate_Present (Item) then Elab_Flags (Unum) := True; end if; if Elaborate_All_Present (Item) then Elab_All_Flags (Unum) := True; end if; if Elaborate_All_Desirable (Cunit_Entity (Unum)) then Elab_Des_Flags (Unum) := True; end if; end if; Next (Item); end loop; end Collect_Withs; -------------------------------- -- Up_To_Date_ALI_File_Exists -- -------------------------------- function Up_To_Date_ALI_File_Exists return Boolean is Name : File_Name_Type; Text : Text_Buffer_Ptr; Id : Sdep_Id; Sind : Source_File_Index; begin Opt.Check_Object_Consistency := True; Read_Library_Info (Name, Text); -- Return if we could not find an ALI file if Text = null then return False; end if; -- Return if ALI file has bad format Initialize_ALI; if Scan_ALI (Name, Text, False, Err => True) = No_ALI_Id then return False; end if; -- If we have an OK ALI file, check if it is up to date -- Note that we assume that the ALI read has all the entries -- we have in our table, plus some additional ones (that can -- come from expansion). Id := First_Sdep_Entry; for J in 1 .. Num_Sdep loop Sind := Units.Table (Sdep_Table (J)).Source_Index; while Sdep.Table (Id).Sfile /= File_Name (Sind) loop if Id = Sdep.Last then return False; else Id := Id + 1; end if; end loop; if Sdep.Table (Id).Stamp /= Time_Stamp (Sind) then return False; end if; end loop; return True; end Up_To_Date_ALI_File_Exists; --------------------------------- -- Update_Tables_From_ALI_File -- --------------------------------- procedure Update_Tables_From_ALI_File is begin -- Build Compilation_Switches table Compilation_Switches.Init; for J in First_Arg_Entry .. Args.Last loop Compilation_Switches.Increment_Last; Compilation_Switches.Table (Compilation_Switches.Last) := Args.Table (J); end loop; end Update_Tables_From_ALI_File; ---------------------------- -- Write_Unit_Information -- ---------------------------- procedure Write_Unit_Information (Unit_Num : Unit_Number_Type) is Unode : constant Node_Id := Cunit (Unit_Num); Ukind : constant Node_Kind := Nkind (Unit (Unode)); Uent : constant Entity_Id := Cunit_Entity (Unit_Num); Pnode : Node_Id; begin Write_Info_Initiate ('U'); Write_Info_Char (' '); Write_Info_Name (Unit_Name (Unit_Num)); Write_Info_Tab (25); Write_Info_Name (Unit_File_Name (Unit_Num)); Write_Info_Tab (49); Write_Info_Str (Version_Get (Unit_Num)); if Dynamic_Elab (Unit_Num) then Write_Info_Str (" DE"); end if; -- We set the Elaborate_Body indication if either an explicit pragma -- was present, or if this is an instantiation. RM 12.3(20) requires -- that the body be immediately elaborated after the spec. We would -- normally do that anyway, but the EB we generate here ensures that -- this gets done even when we use the -p gnatbind switch. if Has_Pragma_Elaborate_Body (Uent) or else (Ukind = N_Package_Declaration and then Is_Generic_Instance (Uent) and then Present (Corresponding_Body (Unit (Unode)))) then Write_Info_Str (" EB"); end if; -- Now see if we should tell the binder that an elaboration entity -- is present, which must be reset to true during elaboration. We -- generate the indication if the following condition is met: -- If this is a spec ... if (Is_Subprogram (Uent) or else Ekind (Uent) = E_Package or else Is_Generic_Unit (Uent)) -- and an elaboration entity was declared ... and then Present (Elaboration_Entity (Uent)) -- and either the elaboration flag is required ... and then (Elaboration_Entity_Required (Uent) -- or this unit has elaboration code ... or else not Has_No_Elaboration_Code (Unode) -- or this unit has a separate body and this -- body has elaboration code. or else (Ekind (Uent) = E_Package and then Present (Body_Entity (Uent)) and then not Has_No_Elaboration_Code (Parent (Declaration_Node (Body_Entity (Uent)))))) then Write_Info_Str (" EE"); end if; if Has_No_Elaboration_Code (Unode) then Write_Info_Str (" NE"); end if; if Is_Preelaborated (Uent) then Write_Info_Str (" PR"); end if; if Is_Pure (Uent) then Write_Info_Str (" PU"); end if; if Has_RACW (Unit_Num) then Write_Info_Str (" RA"); end if; if Is_Remote_Call_Interface (Uent) then Write_Info_Str (" RC"); end if; if Is_Remote_Types (Uent) then Write_Info_Str (" RT"); end if; if Is_Shared_Passive (Uent) then Write_Info_Str (" SP"); end if; if Ukind = N_Subprogram_Declaration or else Ukind = N_Subprogram_Body then Write_Info_Str (" SU"); elsif Ukind = N_Package_Declaration or else Ukind = N_Package_Body then -- If this is a wrapper package for a subprogram instantiation, -- the user view is the subprogram. Note that in this case the -- ali file contains both the spec and body of the instance. if Is_Wrapper_Package (Uent) then Write_Info_Str (" SU"); else Write_Info_Str (" PK"); end if; elsif Ukind = N_Generic_Package_Declaration then Write_Info_Str (" PK"); end if; if Ukind in N_Generic_Declaration or else (Present (Library_Unit (Unode)) and then Nkind (Unit (Library_Unit (Unode))) in N_Generic_Declaration) then Write_Info_Str (" GE"); end if; if not Is_Internal_File_Name (Unit_File_Name (Unit_Num), True) then case Identifier_Casing (Source_Index (Unit_Num)) is when All_Lower_Case => Write_Info_Str (" IL"); when All_Upper_Case => Write_Info_Str (" IU"); when others => null; end case; case Keyword_Casing (Source_Index (Unit_Num)) is when Mixed_Case => Write_Info_Str (" KM"); when All_Upper_Case => Write_Info_Str (" KU"); when others => null; end case; end if; if Initialize_Scalars then Write_Info_Str (" IS"); end if; Write_Info_EOL; -- Generate with lines, first those that are directly with'ed for J in With_Flags'Range loop With_Flags (J) := False; Elab_Flags (J) := False; Elab_All_Flags (J) := False; Elab_Des_Flags (J) := False; end loop; Collect_Withs (Unode); -- For a body, we must also check for any subunits which belong to -- it and which have context clauses of their own, since these -- with'ed units are part of its own elaboration dependencies. if Nkind (Unit (Unode)) in N_Unit_Body then for S in Units.First .. Last_Unit loop -- We are only interested in subunits if Nkind (Unit (Cunit (S))) = N_Subunit then Pnode := Library_Unit (Cunit (S)); -- In gnatc mode, the errors in the subunits will not -- have been recorded, but the analysis of the subunit -- may have failed. There is no information to add to -- ALI file in this case. if No (Pnode) then exit; end if; -- Find ultimate parent of the subunit while Nkind (Unit (Pnode)) = N_Subunit loop Pnode := Library_Unit (Pnode); end loop; -- See if it belongs to current unit, and if so, include -- its with_clauses. if Pnode = Unode then Collect_Withs (Cunit (S)); end if; end if; end loop; end if; Write_With_Lines; end Write_Unit_Information; ---------------------- -- Write_With_Lines -- ---------------------- procedure Write_With_Lines is With_Table : Unit_Ref_Table (1 .. Pos (Last_Unit - Units.First + 1)); Num_Withs : Int := 0; Unum : Unit_Number_Type; Cunit : Node_Id; Cunite : Entity_Id; Uname : Unit_Name_Type; Fname : File_Name_Type; Pname : constant Unit_Name_Type := Get_Parent_Spec_Name (Unit_Name (Main_Unit)); Body_Fname : File_Name_Type; begin -- Loop to build the with table. A with on the main unit itself -- is ignored (AARM 10.2(14a)). Such a with-clause can occur if -- the main unit is a subprogram with no spec, and a subunit of -- it unecessarily withs the parent. for J in Units.First + 1 .. Last_Unit loop -- Add element to with table if it is with'ed or if it is the -- parent spec of the main unit (case of main unit is a child -- unit). The latter with is not needed for semantic purposes, -- but is required by the binder for elaboration purposes. if (With_Flags (J) or else Unit_Name (J) = Pname) and then Units.Table (J).Dependent_Unit then Num_Withs := Num_Withs + 1; With_Table (Num_Withs) := J; end if; end loop; -- Sort and output the table Sort (With_Table (1 .. Num_Withs)); for J in 1 .. Num_Withs loop Unum := With_Table (J); Cunit := Units.Table (Unum).Cunit; Cunite := Units.Table (Unum).Cunit_Entity; Uname := Units.Table (Unum).Unit_Name; Fname := Units.Table (Unum).Unit_File_Name; Write_Info_Initiate ('W'); Write_Info_Char (' '); Write_Info_Name (Uname); -- Now we need to figure out the names of the files that contain -- the with'ed unit. These will usually be the files for the body, -- except in the case of a package that has no body. if (Nkind (Unit (Cunit)) not in N_Generic_Declaration and then Nkind (Unit (Cunit)) not in N_Generic_Renaming_Declaration) or else Generic_Separately_Compiled (Cunite) then Write_Info_Tab (25); if Is_Spec_Name (Uname) then Body_Fname := Get_File_Name (Get_Body_Name (Uname), Subunit => False); else Body_Fname := Get_File_Name (Uname, Subunit => False); end if; -- A package is considered to have a body if it requires -- a body or if a body is present in Ada 83 mode. if Body_Required (Cunit) or else (Ada_83 and then Full_Source_Name (Body_Fname) /= No_File) then Write_Info_Name (Body_Fname); Write_Info_Tab (49); Write_Info_Name (Lib_File_Name (Body_Fname)); else Write_Info_Name (Fname); Write_Info_Tab (49); Write_Info_Name (Lib_File_Name (Fname)); end if; if Elab_Flags (Unum) then Write_Info_Str (" E"); end if; if Elab_All_Flags (Unum) then Write_Info_Str (" EA"); end if; if Elab_Des_Flags (Unum) then Write_Info_Str (" ED"); end if; end if; Write_Info_EOL; end loop; end Write_With_Lines; -- Start of processing for Writ_ALI begin -- Build sorted source dependency table. We do this right away, -- because it is referenced by Up_To_Date_ALI_File_Exists. for Unum in Units.First .. Last_Unit loop Num_Sdep := Num_Sdep + 1; Sdep_Table (Num_Sdep) := Unum; end loop; -- Sort the table so that the D lines are in order Lib.Sort (Sdep_Table (1 .. Num_Sdep)); -- If we are not generating code, and there is an up to date -- ali file accessible, read it, and acquire the compilation -- arguments from this file. if Operating_Mode /= Generate_Code then if Up_To_Date_ALI_File_Exists then Update_Tables_From_ALI_File; return; end if; end if; -- Otherwise acquire compilation arguments and prepare to write -- out a new ali file. Create_Output_Library_Info; -- Output version line Write_Info_Initiate ('V'); Write_Info_Str (" """); Write_Info_Str (Library_Version); Write_Info_Char ('"'); Write_Info_EOL; -- Output main program line if this is acceptable main program declare U : Node_Id := Unit (Units.Table (Main_Unit).Cunit); S : Node_Id; procedure M_Parameters; -- Output parameters for main program line procedure M_Parameters is begin if Main_Priority (Main_Unit) /= Default_Main_Priority then Write_Info_Char (' '); Write_Info_Nat (Main_Priority (Main_Unit)); end if; if Opt.Time_Slice_Set then Write_Info_Str (" T="); Write_Info_Nat (Opt.Time_Slice_Value); end if; Write_Info_Str (" W="); Write_Info_Char (WC_Encoding_Letters (Wide_Character_Encoding_Method)); Write_Info_EOL; end M_Parameters; begin if Nkind (U) = N_Subprogram_Body or else (Nkind (U) = N_Package_Body and then (Nkind (Original_Node (U)) = N_Function_Instantiation or else Nkind (Original_Node (U)) = N_Procedure_Instantiation)) then -- If the unit is a subprogram instance, the entity for the -- subprogram is the alias of the visible entity, which is the -- related instance of the wrapper package. We retrieve the -- subprogram declaration of the desired entity. if Nkind (U) = N_Package_Body then U := Parent (Parent ( Alias (Related_Instance (Defining_Unit_Name (Specification (Unit (Library_Unit (Parent (U))))))))); end if; S := Specification (U); if not Present (Parameter_Specifications (S)) then if Nkind (S) = N_Procedure_Specification then Write_Info_Initiate ('M'); Write_Info_Str (" P"); M_Parameters; else declare Nam : Node_Id := Defining_Unit_Name (S); begin -- If it is a child unit, get its simple name. if Nkind (Nam) = N_Defining_Program_Unit_Name then Nam := Defining_Identifier (Nam); end if; if Is_Integer_Type (Etype (Nam)) then Write_Info_Initiate ('M'); Write_Info_Str (" F"); M_Parameters; end if; end; end if; end if; end if; end; -- Write command argmument ('A') lines for A in 1 .. Compilation_Switches.Last loop Write_Info_Initiate ('A'); Write_Info_Char (' '); Write_Info_Str (Compilation_Switches.Table (A).all); Write_Info_Terminate; end loop; -- Output parameters ('P') line Write_Info_Initiate ('P'); if Compilation_Errors then Write_Info_Str (" CE"); end if; if Opt.Float_Format /= ' ' then Write_Info_Str (" F"); if Opt.Float_Format = 'I' then Write_Info_Char ('I'); elsif Opt.Float_Format_Long = 'D' then Write_Info_Char ('D'); else Write_Info_Char ('G'); end if; end if; if Tasking_Used and then not Is_Predefined_File_Name (Unit_File_Name (Main_Unit)) then if Locking_Policy /= ' ' then Write_Info_Str (" L"); Write_Info_Char (Locking_Policy); end if; if Queuing_Policy /= ' ' then Write_Info_Str (" Q"); Write_Info_Char (Queuing_Policy); end if; if Task_Dispatching_Policy /= ' ' then Write_Info_Str (" T"); Write_Info_Char (Task_Dispatching_Policy); Write_Info_Char (' '); end if; end if; if not Object then Write_Info_Str (" NO"); end if; if No_Run_Time then Write_Info_Str (" NR"); end if; if Normalize_Scalars then Write_Info_Str (" NS"); end if; if Unreserve_All_Interrupts then Write_Info_Str (" UA"); end if; if ZCX_By_Default_On_Target then if Unit_Exception_Table_Present then Write_Info_Str (" UX"); end if; Write_Info_Str (" ZX"); end if; Write_Info_EOL; -- Output restrictions line Write_Info_Initiate ('R'); Write_Info_Char (' '); for J in Partition_Restrictions loop if Main_Restrictions (J) then Write_Info_Char ('r'); elsif Violations (J) then Write_Info_Char ('v'); else Write_Info_Char ('n'); end if; end loop; Write_Info_EOL; -- Loop through file table to output information for all units for which -- we have generated code, as marked by the Generate_Code flag. for Unit in Units.First .. Last_Unit loop if Units.Table (Unit).Generate_Code or else Unit = Main_Unit then Write_Info_EOL; -- blank line Write_Unit_Information (Unit); end if; end loop; Write_Info_EOL; -- blank line -- Output linker option lines for J in 1 .. Linker_Option_Lines.Last loop declare S : constant String_Id := Linker_Option_Lines.Table (J); C : Character; begin Write_Info_Initiate ('L'); Write_Info_Str (" """); for J in 1 .. String_Length (S) loop C := Get_Character (Get_String_Char (S, J)); if C in Character'Val (16#20#) .. Character'Val (16#7E#) and then C /= '{' then Write_Info_Char (C); if C = '"' then Write_Info_Char (C); end if; else declare Hex : array (0 .. 15) of Character := "0123456789ABCDEF"; begin Write_Info_Char ('{'); Write_Info_Char (Hex (Character'Pos (C) / 16)); Write_Info_Char (Hex (Character'Pos (C) mod 16)); Write_Info_Char ('}'); end; end if; end loop; Write_Info_Char ('"'); Write_Info_EOL; end; end loop; -- Output external version reference lines for J in 1 .. Version_Ref.Last loop Write_Info_Initiate ('E'); Write_Info_Char (' '); for K in 1 .. String_Length (Version_Ref.Table (J)) loop Write_Info_Char_Code (Get_String_Char (Version_Ref.Table (J), K)); end loop; Write_Info_EOL; end loop; -- Prepare to output the source dependency lines declare Unum : Unit_Number_Type; -- Number of unit being output Sind : Source_File_Index; -- Index of corresponding source file begin for J in 1 .. Num_Sdep loop Unum := Sdep_Table (J); Units.Table (Unum).Dependency_Num := J; Sind := Units.Table (Unum).Source_Index; Write_Info_Initiate ('D'); Write_Info_Char (' '); -- Normal case of a dependent unit entry with a source index if Sind /= No_Source_File and then Units.Table (Unum).Dependent_Unit then Write_Info_Name (File_Name (Sind)); Write_Info_Tab (25); Write_Info_Str (String (Time_Stamp (Sind))); Write_Info_Char (' '); Write_Info_Str (Get_Hex_String (Source_Checksum (Sind))); -- If subunit, add unit name, omitting the %b at the end if Present (Cunit (Unum)) and then Nkind (Unit (Cunit (Unum))) = N_Subunit then Get_Decoded_Name_String (Unit_Name (Unum)); Write_Info_Char (' '); Write_Info_Str (Name_Buffer (1 .. Name_Len - 2)); end if; -- If Source_Reference pragma used output information if Num_SRef_Pragmas (Sind) > 0 then Write_Info_Char (' '); if Num_SRef_Pragmas (Sind) = 1 then Write_Info_Nat (Int (First_Mapped_Line (Sind))); else Write_Info_Nat (0); end if; Write_Info_Char (':'); Write_Info_Name (Reference_Name (Sind)); end if; -- Case where there is no source index (happens for missing files) -- Also come here for non-dependent units. else Write_Info_Name (Unit_File_Name (Unum)); Write_Info_Tab (25); Write_Info_Str (String (Dummy_Time_Stamp)); Write_Info_Char (' '); Write_Info_Str (Get_Hex_String (0)); end if; Write_Info_EOL; end loop; end; Output_References; Write_Info_Terminate; Close_Output_Library_Info; end Write_ALI; end Lib.Writ;
with Entities; use Entities; package Links is type LinkTypes is (LTRope, LTSpring); type LinkTypesFactorsArr is array (LinkTypes) of Float; type Link is record A, B : EntityClassAcc; LinkType : LinkTypes; Factor, RestLen : Float; end record; pragma Pack(Link); type LinkAcc is access all Link; LinkTypesFactors : LinkTypesFactorsArr := (LTRope => 0.5, LTSpring => 500.0); function CreateLink(A, B : EntityClassAcc; LinkType : LinkTypes; Factor : Float := 0.0) return LinkAcc; procedure FreeLink(This : in out LinkAcc); end Links;
package body Parser_OO is function Evaluate (Root : in Node_Ptr) return Integer is Result : Integer := 0; begin if Root /= null then if Root.all'Class in Literal then return Literal (Root.all).Value; elsif Root.all'Class in Operator then case Operator (Root.all).Which is when '+' => return Evaluate (Operator (Root.all).Left) + Evaluate (Operator (Root.all).Right); when '-' => return Evaluate (Operator (Root.all).Left) - Evaluate (Operator (Root.all).Right); when '*' => return Evaluate (Operator (Root.all).Left) * Evaluate (Operator (Root.all).Right); when '/' => return Evaluate (Operator (Root.all).Left) / Evaluate (Operator (Root.all).Right); end case; end if; end if; return 0; end Evaluate; end Parser_OO;
-- Authors: Catherine Jiawen Song 965600, Ziqi Jia 693241 -- Our implementation proves following security properties: -- The Get, Put, Remove and Lock operations can only ever be performed -- when the password manager is in the unlocked state. -- We implemented procedures called Execute_xxx (i.e. Execute_Lock) -- for each operation and only calls the operation if preconditions are true. -- We specified the precondition IsLocked(Manager_Information) = False for all -- four operations to ensure that they are only executed if the password manager -- is unlocked. This ensures the confidentiality and integrity of the system as -- only users who has knowledge of the master pin can access and carry out changes -- to the database and master pin. We added the precondition PasswordDatabase.Has_Password_For -- for Get and Remove operations to ensure that the operations are not carried out if -- the database has no entry for the url in question. This ensures the safety of the system -- and prevents from the system from crashing if Put or Remove operations are executed -- for an entry that does not exist within the PasswordDatabase. For Put Command we -- specified the precondition StoredDatabaseLength(Manager_Information) < PasswordDatabase.Max_Entries -- in addition to IsLocked precondition to ensure that the number of database entries stored -- currently do not the maximum entries specified. Likewise, this also ensures the safety -- of the system and prevents the database from overflowing and causing the system to crash. -- -- The Unlock operation can only ever be performed when the password manager is in the locked state. -- We have an Execute_Unlock procedure which only calls the procedure Unlock_Manager if the -- IsLocked(Manager_Information) and supplied input pin equals to the stored master pin preconditions -- are true. We specified the post condition that if Unlock_Manager is executed then the Pin_Input -- needs to be equal to the current master pin and that IsLocked(Manager_Information) = False. This -- ensures the authentication of the system as only users who knows master pin can unlock the password manager. -- -- The Lock operation, when it is performed, should update the master PIN with -- the new PIN that is supplied. -- We have Execute_Lock procedure which only calls the procedure Lock_Manager if the -- IsLocked(Manager_Information) precondition is false. We specified post conditions -- that if Lock_Manager is executed then the Master Pin needs to be updated to Pin_Input -- and IsLocked(Manager_Information) is true. This ensures the authentication of the -- system as only users who have unlocked the password manager can update -- changes to the master pin and lock the system. -- -- The password manager can be in one of two states, either locked or unlocked. -- We implemented a private record type called information that records the database, -- master pin and lock status of the system. Our implementation ensures encapsulation -- and allows information hiding as this information cannot be accessed outside -- of the PasswordManager package. Is_Locked represents the two states -- of the Password Manager and can be only accessed through the Lock_Status function. pragma SPARK_Mode (On); with PasswordDatabase; with MyCommandLine; with MyString; with MyStringTokeniser; with PIN; with Ada.Text_IO; use Ada.Text_IO; with Ada.Integer_Text_IO; use Ada.Integer_Text_IO; with Ada.Characters.Handling; use Ada.Characters.Handling; with PasswordManager; with Utility; procedure Main is package Lines is new MyString(Max_MyString_Length => 2048); S : Lines.MyString; PM_Information : PasswordManager.Information; GETDB : constant String := "get"; REMDB : constant String := "rem"; PUTDB : constant String := "put"; UNLOCK : constant String := "unlock"; LOCK : constant String := "lock"; TokensList : MyStringTokeniser.TokenArray(1..5):= (others => (Start => 1, Length => 0)); NumTokens : Natural; begin -- Program must initiate with 1 Pin input if (MyCommandLine.Argument_Count = 1) then declare Temp_Pin : String := MyCommandLine.Argument(1); begin -- Pin must meet specified Pin requirements prior to Password Manager -- initiation if (MyCommandLine.Argument(1)'Length = 4 and (for all I in Temp_Pin'Range => Temp_Pin(I) >= '0' and Temp_Pin(I) <= '9')) then PasswordManager.Init(MyCommandLine.Argument(1), PM_Information); else Put_Line("Invalid input, program will exit!"); return; end if; end; else Put_Line("Invalid input, program will exit!"); return; end if; -- While loop for the system while True loop -- Checks status of Password Manager if (PasswordManager.Lock_Status(PM_Information)) then Put("locked> ");Lines.Get_Line(S); else Put("unlocked> ");Lines.Get_Line(S); end if; -- Tokenises input MyStringTokeniser.Tokenise(Lines.To_String(S),TokensList,NumTokens); -- Checks input command validity and termiantes program if input -- does not follow requirements if (NumTokens < 1 or NumTokens > 3 or Lines.To_String(S)'Length < 1 or Lines.To_String(S)'Length > Utility.Max_Line_Length) then Put_Line("Invalid input, program will exit!"); return; else declare -- Converts command token into string Command : String := To_Lower(Lines.To_String(Lines.Substring(S,TokensList(1).Start, TokensList(1).Start+TokensList(1).Length-1))); begin -- Get Command if (Command = GETDB and NumTokens = Utility.Get_Rem_Pin_Length) then -- If validity check is met get command is executed declare -- Converts Url Token into String TokUrl : String := Lines.To_String (Lines.Substring(S,TokensList(2).Start, TokensList(2).Start+TokensList(2).Length-1)); begin -- If Url is within required length then get -- execution is called if (TokUrl'Length <= PasswordDatabase.Max_URL_Length) then PasswordManager.Execute_Get_Command (PM_Information,PasswordDatabase.From_String(TokUrl)); -- Else the program terminates with error message else Put_Line("Invalid input, program will exit!"); return; end if; end; -- Put Command elsif (Command = PUTDB and NumTokens = Utility.Put_Length) then declare -- Converts Url Token into String TokUrl : String := Lines.To_String (Lines.Substring(S,TokensList(2).Start, TokensList(2).Start+TokensList(2).Length-1)); -- Converts Pwd Token into String TokPwd : String := Lines.To_String (Lines.Substring(S,TokensList(3).Start, TokensList(3).Start+TokensList(3).Length-1)); begin -- If url and password are within required length then -- put execution is called if (TokUrl'Length <= PasswordDatabase.Max_URL_Length and TokPwd'Length <= PasswordDatabase.Max_Password_Length) then PasswordManager.Execute_Put_Command (PM_Information,PasswordDatabase.From_String(TokUrl), PasswordDatabase.From_String(TokPwd)); -- Else the program terminates with error message else Put_Line("Invalid input, program will exit!"); return; end if; end; -- Rem Command elsif (Command = REMDB and NumTokens = Utility.Get_Rem_Pin_Length) then declare -- Converts Url Token into String TokUrl : String := Lines.To_String (Lines.Substring(S,TokensList(2).Start, TokensList(2).Start+TokensList(2).Length-1)); begin -- If Url is within required length then command is executed if (TokUrl'Length <= PasswordDatabase.Max_URL_Length) then PasswordManager.Execute_Rem_Command (PM_Information,PasswordDatabase.From_String(TokUrl)); -- Else the program terminates with error message else Put_Line("Invalid input, program will exit!"); return; end if; end; -- Unlock Command elsif (Command = UNLOCK and NumTokens = Utility.Get_Rem_Pin_Length) then declare -- Converts Pin Token into String TokPin : String := Lines.To_String (Lines.Substring(S,TokensList(2).Start, TokensList(2).Start+TokensList(2).Length - 1)); begin -- If Pin validity is met then Password Manager will -- be unlocked if (TokPin'Length = 4 and (for all I in TokPin'Range => TokPin(I) >= '0' and TokPin(I) <= '9')) then PasswordManager.Execute_Unlock (PM_Information, PIN.From_String(TokPin)); -- Else the program terminates with error message else Put_Line("Invalid input, program will exit!"); return; end if; end; -- Lock Command elsif(Command = LOCK and NumTokens = Utility.Get_Rem_Pin_Length) then declare TokPin : String := Lines.To_String (Lines.Substring(S,TokensList(2).Start, TokensList(2).Start+TokensList(2).Length-1)); begin -- If validity check is met Lock command is executed if (TokPin'Length = 4 and (for all I in TokPin'Range => TokPin(I) >= '0' and TokPin(I) <= '9')) then PasswordManager.Execute_Lock(PM_Information, PIN.From_String(TokPin)); -- Else the program terminates with error message else Put_Line("Invalid input, program will exit!"); return; end if; end; -- Other irregular commands will cause program to print out -- error message and terminate else Put_Line("Invalid input, program will exit!"); return; end if; end; end if; end loop; end Main;
package body OpenGL.Error is function Get_Error return Error_t is Error_Value : constant Thin.Enumeration_t := OpenGL.Thin.Get_Error; begin case Error_Value is when Thin.GL_NO_ERROR => return No_Error; when Thin.GL_INVALID_ENUM => return Invalid_Enum; when Thin.GL_INVALID_VALUE => return Invalid_Value; when Thin.GL_INVALID_OPERATION => return Invalid_Operation; when Thin.GL_STACK_OVERFLOW => return Stack_Overflow; when Thin.GL_STACK_UNDERFLOW => return Stack_Underflow; when Thin.GL_INVALID_FRAMEBUFFER_OPERATION => return Invalid_Framebuffer_Operation; when Thin.GL_OUT_OF_MEMORY => return Out_Of_Memory; when Thin.GL_TABLE_TOO_LARGE => return Table_Too_Large; when others => raise Constraint_Error; end case; end Get_Error; end OpenGL.Error;
------------------------------------------------------------------------------ -- -- -- Matreshka Project -- -- -- -- Localization, Internationalization, Globalization for Ada -- -- -- -- Runtime Library Component -- -- -- ------------------------------------------------------------------------------ -- -- -- Copyright © 2010, Vadim Godunko <vgodunko@gmail.com> -- -- All rights reserved. -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions -- -- are met: -- -- -- -- * Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- -- -- * Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in the -- -- documentation and/or other materials provided with the distribution. -- -- -- -- * Neither the name of the Vadim Godunko, IE nor the names of its -- -- contributors may be used to endorse or promote products derived from -- -- this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED -- -- TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR -- -- PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF -- -- LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING -- -- NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS -- -- SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ -- $Revision$ $Date$ ------------------------------------------------------------------------------ private package Matreshka.Internals.Text_Codecs.SHIFTJIS.Tables is pragma Preelaborate; Meta_Class : constant array (Ada.Streams.Stream_Element) of SHIFTJIS_Meta_Class := (1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 4, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 4, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 2, 5, 5, 5); Decode_Single : constant array (Ada.Streams.Stream_Element) of Matreshka.Internals.Unicode.Code_Point := (16#0000#, 16#0001#, 16#0002#, 16#0003#, 16#0004#, 16#0005#, 16#0006#, 16#0007#, 16#0008#, 16#0009#, 16#000A#, 16#000B#, 16#000C#, 16#000D#, 16#000E#, 16#000F#, 16#0010#, 16#0011#, 16#0012#, 16#0013#, 16#0014#, 16#0015#, 16#0016#, 16#0017#, 16#0018#, 16#0019#, 16#001A#, 16#001B#, 16#001C#, 16#001D#, 16#001E#, 16#001F#, 16#0020#, 16#0021#, 16#0022#, 16#0023#, 16#0024#, 16#0025#, 16#0026#, 16#0027#, 16#0028#, 16#0029#, 16#002A#, 16#002B#, 16#002C#, 16#002D#, 16#002E#, 16#002F#, 16#0030#, 16#0031#, 16#0032#, 16#0033#, 16#0034#, 16#0035#, 16#0036#, 16#0037#, 16#0038#, 16#0039#, 16#003A#, 16#003B#, 16#003C#, 16#003D#, 16#003E#, 16#003F#, 16#0040#, 16#0041#, 16#0042#, 16#0043#, 16#0044#, 16#0045#, 16#0046#, 16#0047#, 16#0048#, 16#0049#, 16#004A#, 16#004B#, 16#004C#, 16#004D#, 16#004E#, 16#004F#, 16#0050#, 16#0051#, 16#0052#, 16#0053#, 16#0054#, 16#0055#, 16#0056#, 16#0057#, 16#0058#, 16#0059#, 16#005A#, 16#005B#, 16#00A5#, 16#005D#, 16#005E#, 16#005F#, 16#0060#, 16#0061#, 16#0062#, 16#0063#, 16#0064#, 16#0065#, 16#0066#, 16#0067#, 16#0068#, 16#0069#, 16#006A#, 16#006B#, 16#006C#, 16#006D#, 16#006E#, 16#006F#, 16#0070#, 16#0071#, 16#0072#, 16#0073#, 16#0074#, 16#0075#, 16#0076#, 16#0077#, 16#0078#, 16#0079#, 16#007A#, 16#007B#, 16#007C#, 16#007D#, 16#203E#, 16#007F#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#FF61#, 16#FF62#, 16#FF63#, 16#FF64#, 16#FF65#, 16#FF66#, 16#FF67#, 16#FF68#, 16#FF69#, 16#FF6A#, 16#FF6B#, 16#FF6C#, 16#FF6D#, 16#FF6E#, 16#FF6F#, 16#FF70#, 16#FF71#, 16#FF72#, 16#FF73#, 16#FF74#, 16#FF75#, 16#FF76#, 16#FF77#, 16#FF78#, 16#FF79#, 16#FF7A#, 16#FF7B#, 16#FF7C#, 16#FF7D#, 16#FF7E#, 16#FF7F#, 16#FF80#, 16#FF81#, 16#FF82#, 16#FF83#, 16#FF84#, 16#FF85#, 16#FF86#, 16#FF87#, 16#FF88#, 16#FF89#, 16#FF8A#, 16#FF8B#, 16#FF8C#, 16#FF8D#, 16#FF8E#, 16#FF8F#, 16#FF90#, 16#FF91#, 16#FF92#, 16#FF93#, 16#FF94#, 16#FF95#, 16#FF96#, 16#FF97#, 16#FF98#, 16#FF99#, 16#FF9A#, 16#FF9B#, 16#FF9C#, 16#FF9D#, 16#FF9E#, 16#FF9F#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_Invalid : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_81 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#3000#, 16#3001#, 16#3002#, 16#FF0C#, 16#FF0E#, 16#30FB#, 16#FF1A#, 16#FF1B#, 16#FF1F#, 16#FF01#, 16#309B#, 16#309C#, 16#00B4#, 16#FF40#, 16#00A8#, 16#FF3E#, 16#FFE3#, 16#FF3F#, 16#30FD#, 16#30FE#, 16#309D#, 16#309E#, 16#3003#, 16#4EDD#, 16#3005#, 16#3006#, 16#3007#, 16#30FC#, 16#2014#, 16#2010#, 16#FF0F#, 16#005C#, 16#301C#, 16#2016#, 16#FF5C#, 16#2026#, 16#2025#, 16#2018#, 16#2019#, 16#201C#, 16#201D#, 16#FF08#, 16#FF09#, 16#3014#, 16#3015#, 16#FF3B#, 16#FF3D#, 16#FF5B#, 16#FF5D#, 16#3008#, 16#3009#, 16#300A#, 16#300B#, 16#300C#, 16#300D#, 16#300E#, 16#300F#, 16#3010#, 16#3011#, 16#FF0B#, 16#2212#, 16#00B1#, 16#00D7#, 16#0000#, 16#00F7#, 16#FF1D#, 16#2260#, 16#FF1C#, 16#FF1E#, 16#2266#, 16#2267#, 16#221E#, 16#2234#, 16#2642#, 16#2640#, 16#00B0#, 16#2032#, 16#2033#, 16#2103#, 16#FFE5#, 16#FF04#, 16#00A2#, 16#00A3#, 16#FF05#, 16#FF03#, 16#FF06#, 16#FF0A#, 16#FF20#, 16#00A7#, 16#2606#, 16#2605#, 16#25CB#, 16#25CF#, 16#25CE#, 16#25C7#, 16#25C6#, 16#25A1#, 16#25A0#, 16#25B3#, 16#25B2#, 16#25BD#, 16#25BC#, 16#203B#, 16#3012#, 16#2192#, 16#2190#, 16#2191#, 16#2193#, 16#3013#, 16#FF07#, 16#FF02#, 16#FF0D#, 16#007E#, 16#3033#, 16#3034#, 16#3035#, 16#303B#, 16#303C#, 16#30FF#, 16#309F#, 16#2208#, 16#220B#, 16#2286#, 16#2287#, 16#2282#, 16#2283#, 16#222A#, 16#2229#, 16#2284#, 16#2285#, 16#228A#, 16#228B#, 16#2209#, 16#2205#, 16#2305#, 16#2306#, 16#2227#, 16#2228#, 16#00AC#, 16#21D2#, 16#21D4#, 16#2200#, 16#2203#, 16#2295#, 16#2296#, 16#2297#, 16#2225#, 16#2226#, 16#FF5F#, 16#FF60#, 16#3018#, 16#3019#, 16#3016#, 16#3017#, 16#2220#, 16#22A5#, 16#2312#, 16#2202#, 16#2207#, 16#2261#, 16#2252#, 16#226A#, 16#226B#, 16#221A#, 16#223D#, 16#221D#, 16#2235#, 16#222B#, 16#222C#, 16#2262#, 16#2243#, 16#2245#, 16#2248#, 16#2276#, 16#2277#, 16#2194#, 16#212B#, 16#2030#, 16#266F#, 16#266D#, 16#266A#, 16#2020#, 16#2021#, 16#00B6#, 16#266E#, 16#266B#, 16#266C#, 16#2669#, 16#25EF#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_82 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#25B7#, 16#25B6#, 16#25C1#, 16#25C0#, 16#2197#, 16#2198#, 16#2196#, 16#2199#, 16#21C4#, 16#21E8#, 16#21E6#, 16#21E7#, 16#21E9#, 16#2934#, 16#2935#, 16#FF10#, 16#FF11#, 16#FF12#, 16#FF13#, 16#FF14#, 16#FF15#, 16#FF16#, 16#FF17#, 16#FF18#, 16#FF19#, 16#29BF#, 16#25C9#, 16#303D#, 16#FE46#, 16#FE45#, 16#25E6#, 16#2022#, 16#FF21#, 16#FF22#, 16#FF23#, 16#FF24#, 16#FF25#, 16#FF26#, 16#FF27#, 16#FF28#, 16#FF29#, 16#FF2A#, 16#FF2B#, 16#FF2C#, 16#FF2D#, 16#FF2E#, 16#FF2F#, 16#FF30#, 16#FF31#, 16#FF32#, 16#FF33#, 16#FF34#, 16#FF35#, 16#FF36#, 16#FF37#, 16#FF38#, 16#FF39#, 16#FF3A#, 16#2213#, 16#2135#, 16#210F#, 16#33CB#, 16#2113#, 16#0000#, 16#2127#, 16#FF41#, 16#FF42#, 16#FF43#, 16#FF44#, 16#FF45#, 16#FF46#, 16#FF47#, 16#FF48#, 16#FF49#, 16#FF4A#, 16#FF4B#, 16#FF4C#, 16#FF4D#, 16#FF4E#, 16#FF4F#, 16#FF50#, 16#FF51#, 16#FF52#, 16#FF53#, 16#FF54#, 16#FF55#, 16#FF56#, 16#FF57#, 16#FF58#, 16#FF59#, 16#FF5A#, 16#30A0#, 16#2013#, 16#29FA#, 16#29FB#, 16#3041#, 16#3042#, 16#3043#, 16#3044#, 16#3045#, 16#3046#, 16#3047#, 16#3048#, 16#3049#, 16#304A#, 16#304B#, 16#304C#, 16#304D#, 16#304E#, 16#304F#, 16#3050#, 16#3051#, 16#3052#, 16#3053#, 16#3054#, 16#3055#, 16#3056#, 16#3057#, 16#3058#, 16#3059#, 16#305A#, 16#305B#, 16#305C#, 16#305D#, 16#305E#, 16#305F#, 16#3060#, 16#3061#, 16#3062#, 16#3063#, 16#3064#, 16#3065#, 16#3066#, 16#3067#, 16#3068#, 16#3069#, 16#306A#, 16#306B#, 16#306C#, 16#306D#, 16#306E#, 16#306F#, 16#3070#, 16#3071#, 16#3072#, 16#3073#, 16#3074#, 16#3075#, 16#3076#, 16#3077#, 16#3078#, 16#3079#, 16#307A#, 16#307B#, 16#307C#, 16#307D#, 16#307E#, 16#307F#, 16#3080#, 16#3081#, 16#3082#, 16#3083#, 16#3084#, 16#3085#, 16#3086#, 16#3087#, 16#3088#, 16#3089#, 16#308A#, 16#308B#, 16#308C#, 16#308D#, 16#308E#, 16#308F#, 16#3090#, 16#3091#, 16#3092#, 16#3093#, 16#3094#, 16#3095#, 16#3096#, 16#0001#, 16#0002#, 16#0003#, 16#0004#, 16#0005#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_83 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#30A1#, 16#30A2#, 16#30A3#, 16#30A4#, 16#30A5#, 16#30A6#, 16#30A7#, 16#30A8#, 16#30A9#, 16#30AA#, 16#30AB#, 16#30AC#, 16#30AD#, 16#30AE#, 16#30AF#, 16#30B0#, 16#30B1#, 16#30B2#, 16#30B3#, 16#30B4#, 16#30B5#, 16#30B6#, 16#30B7#, 16#30B8#, 16#30B9#, 16#30BA#, 16#30BB#, 16#30BC#, 16#30BD#, 16#30BE#, 16#30BF#, 16#30C0#, 16#30C1#, 16#30C2#, 16#30C3#, 16#30C4#, 16#30C5#, 16#30C6#, 16#30C7#, 16#30C8#, 16#30C9#, 16#30CA#, 16#30CB#, 16#30CC#, 16#30CD#, 16#30CE#, 16#30CF#, 16#30D0#, 16#30D1#, 16#30D2#, 16#30D3#, 16#30D4#, 16#30D5#, 16#30D6#, 16#30D7#, 16#30D8#, 16#30D9#, 16#30DA#, 16#30DB#, 16#30DC#, 16#30DD#, 16#30DE#, 16#30DF#, 16#0000#, 16#30E0#, 16#30E1#, 16#30E2#, 16#30E3#, 16#30E4#, 16#30E5#, 16#30E6#, 16#30E7#, 16#30E8#, 16#30E9#, 16#30EA#, 16#30EB#, 16#30EC#, 16#30ED#, 16#30EE#, 16#30EF#, 16#30F0#, 16#30F1#, 16#30F2#, 16#30F3#, 16#30F4#, 16#30F5#, 16#30F6#, 16#0006#, 16#0007#, 16#0008#, 16#0009#, 16#000A#, 16#000B#, 16#000C#, 16#000D#, 16#0391#, 16#0392#, 16#0393#, 16#0394#, 16#0395#, 16#0396#, 16#0397#, 16#0398#, 16#0399#, 16#039A#, 16#039B#, 16#039C#, 16#039D#, 16#039E#, 16#039F#, 16#03A0#, 16#03A1#, 16#03A3#, 16#03A4#, 16#03A5#, 16#03A6#, 16#03A7#, 16#03A8#, 16#03A9#, 16#2664#, 16#2660#, 16#2662#, 16#2666#, 16#2661#, 16#2665#, 16#2667#, 16#2663#, 16#03B1#, 16#03B2#, 16#03B3#, 16#03B4#, 16#03B5#, 16#03B6#, 16#03B7#, 16#03B8#, 16#03B9#, 16#03BA#, 16#03BB#, 16#03BC#, 16#03BD#, 16#03BE#, 16#03BF#, 16#03C0#, 16#03C1#, 16#03C3#, 16#03C4#, 16#03C5#, 16#03C6#, 16#03C7#, 16#03C8#, 16#03C9#, 16#03C2#, 16#24F5#, 16#24F6#, 16#24F7#, 16#24F8#, 16#24F9#, 16#24FA#, 16#24FB#, 16#24FC#, 16#24FD#, 16#24FE#, 16#2616#, 16#2617#, 16#3020#, 16#260E#, 16#2600#, 16#2601#, 16#2602#, 16#2603#, 16#2668#, 16#25B1#, 16#31F0#, 16#31F1#, 16#31F2#, 16#31F3#, 16#31F4#, 16#31F5#, 16#31F6#, 16#31F7#, 16#31F8#, 16#31F9#, 16#000E#, 16#31FA#, 16#31FB#, 16#31FC#, 16#31FD#, 16#31FE#, 16#31FF#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_84 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0410#, 16#0411#, 16#0412#, 16#0413#, 16#0414#, 16#0415#, 16#0401#, 16#0416#, 16#0417#, 16#0418#, 16#0419#, 16#041A#, 16#041B#, 16#041C#, 16#041D#, 16#041E#, 16#041F#, 16#0420#, 16#0421#, 16#0422#, 16#0423#, 16#0424#, 16#0425#, 16#0426#, 16#0427#, 16#0428#, 16#0429#, 16#042A#, 16#042B#, 16#042C#, 16#042D#, 16#042E#, 16#042F#, 16#23BE#, 16#23BF#, 16#23C0#, 16#23C1#, 16#23C2#, 16#23C3#, 16#23C4#, 16#23C5#, 16#23C6#, 16#23C7#, 16#23C8#, 16#23C9#, 16#23CA#, 16#23CB#, 16#23CC#, 16#0430#, 16#0431#, 16#0432#, 16#0433#, 16#0434#, 16#0435#, 16#0451#, 16#0436#, 16#0437#, 16#0438#, 16#0439#, 16#043A#, 16#043B#, 16#043C#, 16#043D#, 16#0000#, 16#043E#, 16#043F#, 16#0440#, 16#0441#, 16#0442#, 16#0443#, 16#0444#, 16#0445#, 16#0446#, 16#0447#, 16#0448#, 16#0449#, 16#044A#, 16#044B#, 16#044C#, 16#044D#, 16#044E#, 16#044F#, 16#30F7#, 16#30F8#, 16#30F9#, 16#30FA#, 16#22DA#, 16#22DB#, 16#2153#, 16#2154#, 16#2155#, 16#2713#, 16#2318#, 16#2423#, 16#23CE#, 16#2500#, 16#2502#, 16#250C#, 16#2510#, 16#2518#, 16#2514#, 16#251C#, 16#252C#, 16#2524#, 16#2534#, 16#253C#, 16#2501#, 16#2503#, 16#250F#, 16#2513#, 16#251B#, 16#2517#, 16#2523#, 16#2533#, 16#252B#, 16#253B#, 16#254B#, 16#2520#, 16#252F#, 16#2528#, 16#2537#, 16#253F#, 16#251D#, 16#2530#, 16#2525#, 16#2538#, 16#2542#, 16#3251#, 16#3252#, 16#3253#, 16#3254#, 16#3255#, 16#3256#, 16#3257#, 16#3258#, 16#3259#, 16#325A#, 16#325B#, 16#325C#, 16#325D#, 16#325E#, 16#325F#, 16#32B1#, 16#32B2#, 16#32B3#, 16#32B4#, 16#32B5#, 16#32B6#, 16#32B7#, 16#32B8#, 16#32B9#, 16#32BA#, 16#32BB#, 16#32BC#, 16#32BD#, 16#32BE#, 16#32BF#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#25D0#, 16#25D1#, 16#25D2#, 16#25D3#, 16#203C#, 16#2047#, 16#2048#, 16#2049#, 16#01CD#, 16#01CE#, 16#01D0#, 16#1E3E#, 16#1E3F#, 16#01F8#, 16#01F9#, 16#01D1#, 16#01D2#, 16#01D4#, 16#01D6#, 16#01D8#, 16#01DA#, 16#01DC#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_85 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#20AC#, 16#00A0#, 16#00A1#, 16#00A4#, 16#00A6#, 16#00A9#, 16#00AA#, 16#00AB#, 16#00AD#, 16#00AE#, 16#00AF#, 16#00B2#, 16#00B3#, 16#00B7#, 16#00B8#, 16#00B9#, 16#00BA#, 16#00BB#, 16#00BC#, 16#00BD#, 16#00BE#, 16#00BF#, 16#00C0#, 16#00C1#, 16#00C2#, 16#00C3#, 16#00C4#, 16#00C5#, 16#00C6#, 16#00C7#, 16#00C8#, 16#00C9#, 16#00CA#, 16#00CB#, 16#00CC#, 16#00CD#, 16#00CE#, 16#00CF#, 16#00D0#, 16#00D1#, 16#00D2#, 16#00D3#, 16#00D4#, 16#00D5#, 16#00D6#, 16#00D8#, 16#00D9#, 16#00DA#, 16#00DB#, 16#00DC#, 16#00DD#, 16#00DE#, 16#00DF#, 16#00E0#, 16#00E1#, 16#00E2#, 16#00E3#, 16#00E4#, 16#00E5#, 16#00E6#, 16#00E7#, 16#00E8#, 16#00E9#, 16#0000#, 16#00EA#, 16#00EB#, 16#00EC#, 16#00ED#, 16#00EE#, 16#00EF#, 16#00F0#, 16#00F1#, 16#00F2#, 16#00F3#, 16#00F4#, 16#00F5#, 16#00F6#, 16#00F8#, 16#00F9#, 16#00FA#, 16#00FB#, 16#00FC#, 16#00FD#, 16#00FE#, 16#00FF#, 16#0100#, 16#012A#, 16#016A#, 16#0112#, 16#014C#, 16#0101#, 16#012B#, 16#016B#, 16#0113#, 16#014D#, 16#0104#, 16#02D8#, 16#0141#, 16#013D#, 16#015A#, 16#0160#, 16#015E#, 16#0164#, 16#0179#, 16#017D#, 16#017B#, 16#0105#, 16#02DB#, 16#0142#, 16#013E#, 16#015B#, 16#02C7#, 16#0161#, 16#015F#, 16#0165#, 16#017A#, 16#02DD#, 16#017E#, 16#017C#, 16#0154#, 16#0102#, 16#0139#, 16#0106#, 16#010C#, 16#0118#, 16#011A#, 16#010E#, 16#0143#, 16#0147#, 16#0150#, 16#0158#, 16#016E#, 16#0170#, 16#0162#, 16#0155#, 16#0103#, 16#013A#, 16#0107#, 16#010D#, 16#0119#, 16#011B#, 16#010F#, 16#0111#, 16#0144#, 16#0148#, 16#0151#, 16#0159#, 16#016F#, 16#0171#, 16#0163#, 16#02D9#, 16#0108#, 16#011C#, 16#0124#, 16#0134#, 16#015C#, 16#016C#, 16#0109#, 16#011D#, 16#0125#, 16#0135#, 16#015D#, 16#016D#, 16#0271#, 16#028B#, 16#027E#, 16#0283#, 16#0292#, 16#026C#, 16#026E#, 16#0279#, 16#0288#, 16#0256#, 16#0273#, 16#027D#, 16#0282#, 16#0290#, 16#027B#, 16#026D#, 16#025F#, 16#0272#, 16#029D#, 16#028E#, 16#0261#, 16#014B#, 16#0270#, 16#0281#, 16#0127#, 16#0295#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_86 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0294#, 16#0266#, 16#0298#, 16#01C2#, 16#0253#, 16#0257#, 16#0284#, 16#0260#, 16#0193#, 16#0153#, 16#0152#, 16#0268#, 16#0289#, 16#0258#, 16#0275#, 16#0259#, 16#025C#, 16#025E#, 16#0250#, 16#026F#, 16#028A#, 16#0264#, 16#028C#, 16#0254#, 16#0251#, 16#0252#, 16#028D#, 16#0265#, 16#02A2#, 16#02A1#, 16#0255#, 16#0291#, 16#027A#, 16#0267#, 16#025A#, 16#000F#, 16#01FD#, 16#1F70#, 16#1F71#, 16#0010#, 16#0011#, 16#0012#, 16#0013#, 16#0014#, 16#0015#, 16#0016#, 16#0017#, 16#1F72#, 16#1F73#, 16#0361#, 16#02C8#, 16#02CC#, 16#02D0#, 16#02D1#, 16#0306#, 16#203F#, 16#030B#, 16#0301#, 16#0304#, 16#0300#, 16#030F#, 16#030C#, 16#0302#, 16#0000#, 16#02E5#, 16#02E6#, 16#02E7#, 16#02E8#, 16#02E9#, 16#0018#, 16#0019#, 16#0325#, 16#032C#, 16#0339#, 16#031C#, 16#031F#, 16#0320#, 16#0308#, 16#033D#, 16#0329#, 16#032F#, 16#02DE#, 16#0324#, 16#0330#, 16#033C#, 16#0334#, 16#031D#, 16#031E#, 16#0318#, 16#0319#, 16#032A#, 16#033A#, 16#033B#, 16#0303#, 16#031A#, 16#2776#, 16#2777#, 16#2778#, 16#2779#, 16#277A#, 16#277B#, 16#277C#, 16#277D#, 16#277E#, 16#277F#, 16#24EB#, 16#24EC#, 16#24ED#, 16#24EE#, 16#24EF#, 16#24F0#, 16#24F1#, 16#24F2#, 16#24F3#, 16#24F4#, 16#2170#, 16#2171#, 16#2172#, 16#2173#, 16#2174#, 16#2175#, 16#2176#, 16#2177#, 16#2178#, 16#2179#, 16#217A#, 16#217B#, 16#24D0#, 16#24D1#, 16#24D2#, 16#24D3#, 16#24D4#, 16#24D5#, 16#24D6#, 16#24D7#, 16#24D8#, 16#24D9#, 16#24DA#, 16#24DB#, 16#24DC#, 16#24DD#, 16#24DE#, 16#24DF#, 16#24E0#, 16#24E1#, 16#24E2#, 16#24E3#, 16#24E4#, 16#24E5#, 16#24E6#, 16#24E7#, 16#24E8#, 16#24E9#, 16#32D0#, 16#32D1#, 16#32D2#, 16#32D3#, 16#32D4#, 16#32D5#, 16#32D6#, 16#32D7#, 16#32D8#, 16#32D9#, 16#32DA#, 16#32DB#, 16#32DC#, 16#32DD#, 16#32DE#, 16#32DF#, 16#32E0#, 16#32E1#, 16#32E2#, 16#32E3#, 16#32FA#, 16#32E9#, 16#32E5#, 16#32ED#, 16#32EC#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#2051#, 16#2042#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_87 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#2460#, 16#2461#, 16#2462#, 16#2463#, 16#2464#, 16#2465#, 16#2466#, 16#2467#, 16#2468#, 16#2469#, 16#246A#, 16#246B#, 16#246C#, 16#246D#, 16#246E#, 16#246F#, 16#2470#, 16#2471#, 16#2472#, 16#2473#, 16#2160#, 16#2161#, 16#2162#, 16#2163#, 16#2164#, 16#2165#, 16#2166#, 16#2167#, 16#2168#, 16#2169#, 16#216A#, 16#3349#, 16#3314#, 16#3322#, 16#334D#, 16#3318#, 16#3327#, 16#3303#, 16#3336#, 16#3351#, 16#3357#, 16#330D#, 16#3326#, 16#3323#, 16#332B#, 16#334A#, 16#333B#, 16#339C#, 16#339D#, 16#339E#, 16#338E#, 16#338F#, 16#33C4#, 16#33A1#, 16#216B#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#337B#, 16#0000#, 16#301D#, 16#301F#, 16#2116#, 16#33CD#, 16#2121#, 16#32A4#, 16#32A5#, 16#32A6#, 16#32A7#, 16#32A8#, 16#3231#, 16#3232#, 16#3239#, 16#337E#, 16#337D#, 16#337C#, 16#0000#, 16#0000#, 16#0000#, 16#222E#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#221F#, 16#22BF#, 16#0000#, 16#0000#, 16#0000#, 16#2756#, 16#261E#, 16#4FF1#, 16#02_000B#, 16#3402#, 16#4E28#, 16#4E2F#, 16#4E30#, 16#4E8D#, 16#4EE1#, 16#4EFD#, 16#4EFF#, 16#4F03#, 16#4F0B#, 16#4F60#, 16#4F48#, 16#4F49#, 16#4F56#, 16#4F5F#, 16#4F6A#, 16#4F6C#, 16#4F7E#, 16#4F8A#, 16#4F94#, 16#4F97#, 16#FA30#, 16#4FC9#, 16#4FE0#, 16#5001#, 16#5002#, 16#500E#, 16#5018#, 16#5027#, 16#502E#, 16#5040#, 16#503B#, 16#5041#, 16#5094#, 16#50CC#, 16#50F2#, 16#50D0#, 16#50E6#, 16#FA31#, 16#5106#, 16#5103#, 16#510B#, 16#511E#, 16#5135#, 16#514A#, 16#FA32#, 16#5155#, 16#5157#, 16#34B5#, 16#519D#, 16#51C3#, 16#51CA#, 16#51DE#, 16#51E2#, 16#51EE#, 16#5201#, 16#34DB#, 16#5213#, 16#5215#, 16#5249#, 16#5257#, 16#5261#, 16#5293#, 16#52C8#, 16#FA33#, 16#52CC#, 16#52D0#, 16#52D6#, 16#52DB#, 16#FA34#, 16#52F0#, 16#52FB#, 16#5300#, 16#5307#, 16#531C#, 16#FA35#, 16#5361#, 16#5363#, 16#537D#, 16#5393#, 16#539D#, 16#53B2#, 16#5412#, 16#5427#, 16#544D#, 16#549C#, 16#546B#, 16#5474#, 16#547F#, 16#5488#, 16#5496#, 16#54A1#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_88 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#54A9#, 16#54C6#, 16#54FF#, 16#550E#, 16#552B#, 16#5535#, 16#5550#, 16#555E#, 16#5581#, 16#5586#, 16#558E#, 16#FA36#, 16#55AD#, 16#55CE#, 16#FA37#, 16#5608#, 16#560E#, 16#563B#, 16#5649#, 16#5676#, 16#5666#, 16#FA38#, 16#566F#, 16#5671#, 16#5672#, 16#5699#, 16#569E#, 16#56A9#, 16#56AC#, 16#56B3#, 16#56C9#, 16#56CA#, 16#570A#, 16#02_123D#, 16#5721#, 16#572F#, 16#5733#, 16#5734#, 16#5770#, 16#5777#, 16#577C#, 16#579C#, 16#FA0F#, 16#02_131B#, 16#57B8#, 16#57C7#, 16#57C8#, 16#57CF#, 16#57E4#, 16#57ED#, 16#57F5#, 16#57F6#, 16#57FF#, 16#5809#, 16#FA10#, 16#5861#, 16#5864#, 16#FA39#, 16#587C#, 16#5889#, 16#589E#, 16#FA3A#, 16#58A9#, 16#0000#, 16#02_146E#, 16#58D2#, 16#58CE#, 16#58D4#, 16#58DA#, 16#58E0#, 16#58E9#, 16#590C#, 16#8641#, 16#595D#, 16#596D#, 16#598B#, 16#5992#, 16#59A4#, 16#59C3#, 16#59D2#, 16#59DD#, 16#5A13#, 16#5A23#, 16#5A67#, 16#5A6D#, 16#5A77#, 16#5A7E#, 16#5A84#, 16#5A9E#, 16#5AA7#, 16#5AC4#, 16#02_18BD#, 16#5B19#, 16#5B25#, 16#525D#, 16#4E9C#, 16#5516#, 16#5A03#, 16#963F#, 16#54C0#, 16#611B#, 16#6328#, 16#59F6#, 16#9022#, 16#8475#, 16#831C#, 16#7A50#, 16#60AA#, 16#63E1#, 16#6E25#, 16#65ED#, 16#8466#, 16#82A6#, 16#9BF5#, 16#6893#, 16#5727#, 16#65A1#, 16#6271#, 16#5B9B#, 16#59D0#, 16#867B#, 16#98F4#, 16#7D62#, 16#7DBE#, 16#9B8E#, 16#6216#, 16#7C9F#, 16#88B7#, 16#5B89#, 16#5EB5#, 16#6309#, 16#6697#, 16#6848#, 16#95C7#, 16#978D#, 16#674F#, 16#4EE5#, 16#4F0A#, 16#4F4D#, 16#4F9D#, 16#5049#, 16#56F2#, 16#5937#, 16#59D4#, 16#5A01#, 16#5C09#, 16#60DF#, 16#610F#, 16#6170#, 16#6613#, 16#6905#, 16#70BA#, 16#754F#, 16#7570#, 16#79FB#, 16#7DAD#, 16#7DEF#, 16#80C3#, 16#840E#, 16#8863#, 16#8B02#, 16#9055#, 16#907A#, 16#533B#, 16#4E95#, 16#4EA5#, 16#57DF#, 16#80B2#, 16#90C1#, 16#78EF#, 16#4E00#, 16#58F1#, 16#6EA2#, 16#9038#, 16#7A32#, 16#8328#, 16#828B#, 16#9C2F#, 16#5141#, 16#5370#, 16#54BD#, 16#54E1#, 16#56E0#, 16#59FB#, 16#5F15#, 16#98F2#, 16#6DEB#, 16#80E4#, 16#852D#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_89 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#9662#, 16#9670#, 16#96A0#, 16#97FB#, 16#540B#, 16#53F3#, 16#5B87#, 16#70CF#, 16#7FBD#, 16#8FC2#, 16#96E8#, 16#536F#, 16#9D5C#, 16#7ABA#, 16#4E11#, 16#7893#, 16#81FC#, 16#6E26#, 16#5618#, 16#5504#, 16#6B1D#, 16#851A#, 16#9C3B#, 16#59E5#, 16#53A9#, 16#6D66#, 16#74DC#, 16#958F#, 16#5642#, 16#4E91#, 16#904B#, 16#96F2#, 16#834F#, 16#990C#, 16#53E1#, 16#55B6#, 16#5B30#, 16#5F71#, 16#6620#, 16#66F3#, 16#6804#, 16#6C38#, 16#6CF3#, 16#6D29#, 16#745B#, 16#76C8#, 16#7A4E#, 16#9834#, 16#82F1#, 16#885B#, 16#8A60#, 16#92ED#, 16#6DB2#, 16#75AB#, 16#76CA#, 16#99C5#, 16#60A6#, 16#8B01#, 16#8D8A#, 16#95B2#, 16#698E#, 16#53AD#, 16#5186#, 16#0000#, 16#5712#, 16#5830#, 16#5944#, 16#5BB4#, 16#5EF6#, 16#6028#, 16#63A9#, 16#63F4#, 16#6CBF#, 16#6F14#, 16#708E#, 16#7114#, 16#7159#, 16#71D5#, 16#733F#, 16#7E01#, 16#8276#, 16#82D1#, 16#8597#, 16#9060#, 16#925B#, 16#9D1B#, 16#5869#, 16#65BC#, 16#6C5A#, 16#7525#, 16#51F9#, 16#592E#, 16#5965#, 16#5F80#, 16#5FDC#, 16#62BC#, 16#65FA#, 16#6A2A#, 16#6B27#, 16#6BB4#, 16#738B#, 16#7FC1#, 16#8956#, 16#9D2C#, 16#9D0E#, 16#9EC4#, 16#5CA1#, 16#6C96#, 16#837B#, 16#5104#, 16#5C4B#, 16#61B6#, 16#81C6#, 16#6876#, 16#7261#, 16#4E59#, 16#4FFA#, 16#5378#, 16#6069#, 16#6E29#, 16#7A4F#, 16#97F3#, 16#4E0B#, 16#5316#, 16#4EEE#, 16#4F55#, 16#4F3D#, 16#4FA1#, 16#4F73#, 16#52A0#, 16#53EF#, 16#5609#, 16#590F#, 16#5AC1#, 16#5BB6#, 16#5BE1#, 16#79D1#, 16#6687#, 16#679C#, 16#67B6#, 16#6B4C#, 16#6CB3#, 16#706B#, 16#73C2#, 16#798D#, 16#79BE#, 16#7A3C#, 16#7B87#, 16#82B1#, 16#82DB#, 16#8304#, 16#8377#, 16#83EF#, 16#83D3#, 16#8766#, 16#8AB2#, 16#5629#, 16#8CA8#, 16#8FE6#, 16#904E#, 16#971E#, 16#868A#, 16#4FC4#, 16#5CE8#, 16#6211#, 16#7259#, 16#753B#, 16#81E5#, 16#82BD#, 16#86FE#, 16#8CC0#, 16#96C5#, 16#9913#, 16#99D5#, 16#4ECB#, 16#4F1A#, 16#89E3#, 16#56DE#, 16#584A#, 16#58CA#, 16#5EFB#, 16#5FEB#, 16#602A#, 16#6094#, 16#6062#, 16#61D0#, 16#6212#, 16#62D0#, 16#6539#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_8A : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#9B41#, 16#6666#, 16#68B0#, 16#6D77#, 16#7070#, 16#754C#, 16#7686#, 16#7D75#, 16#82A5#, 16#87F9#, 16#958B#, 16#968E#, 16#8C9D#, 16#51F1#, 16#52BE#, 16#5916#, 16#54B3#, 16#5BB3#, 16#5D16#, 16#6168#, 16#6982#, 16#6DAF#, 16#788D#, 16#84CB#, 16#8857#, 16#8A72#, 16#93A7#, 16#9AB8#, 16#6D6C#, 16#99A8#, 16#86D9#, 16#57A3#, 16#67FF#, 16#86CE#, 16#920E#, 16#5283#, 16#5687#, 16#5404#, 16#5ED3#, 16#62E1#, 16#64B9#, 16#683C#, 16#6838#, 16#6BBB#, 16#7372#, 16#78BA#, 16#7A6B#, 16#899A#, 16#89D2#, 16#8D6B#, 16#8F03#, 16#90ED#, 16#95A3#, 16#9694#, 16#9769#, 16#5B66#, 16#5CB3#, 16#697D#, 16#984D#, 16#984E#, 16#639B#, 16#7B20#, 16#6A2B#, 16#0000#, 16#6A7F#, 16#68B6#, 16#9C0D#, 16#6F5F#, 16#5272#, 16#559D#, 16#6070#, 16#62EC#, 16#6D3B#, 16#6E07#, 16#6ED1#, 16#845B#, 16#8910#, 16#8F44#, 16#4E14#, 16#9C39#, 16#53F6#, 16#691B#, 16#6A3A#, 16#9784#, 16#682A#, 16#515C#, 16#7AC3#, 16#84B2#, 16#91DC#, 16#938C#, 16#565B#, 16#9D28#, 16#6822#, 16#8305#, 16#8431#, 16#7CA5#, 16#5208#, 16#82C5#, 16#74E6#, 16#4E7E#, 16#4F83#, 16#51A0#, 16#5BD2#, 16#520A#, 16#52D8#, 16#52E7#, 16#5DFB#, 16#559A#, 16#582A#, 16#59E6#, 16#5B8C#, 16#5B98#, 16#5BDB#, 16#5E72#, 16#5E79#, 16#60A3#, 16#611F#, 16#6163#, 16#61BE#, 16#63DB#, 16#6562#, 16#67D1#, 16#6853#, 16#68FA#, 16#6B3E#, 16#6B53#, 16#6C57#, 16#6F22#, 16#6F97#, 16#6F45#, 16#74B0#, 16#7518#, 16#76E3#, 16#770B#, 16#7AFF#, 16#7BA1#, 16#7C21#, 16#7DE9#, 16#7F36#, 16#7FF0#, 16#809D#, 16#8266#, 16#839E#, 16#89B3#, 16#8ACC#, 16#8CAB#, 16#9084#, 16#9451#, 16#9593#, 16#9591#, 16#95A2#, 16#9665#, 16#97D3#, 16#9928#, 16#8218#, 16#4E38#, 16#542B#, 16#5CB8#, 16#5DCC#, 16#73A9#, 16#764C#, 16#773C#, 16#5CA9#, 16#7FEB#, 16#8D0B#, 16#96C1#, 16#9811#, 16#9854#, 16#9858#, 16#4F01#, 16#4F0E#, 16#5371#, 16#559C#, 16#5668#, 16#57FA#, 16#5947#, 16#5B09#, 16#5BC4#, 16#5C90#, 16#5E0C#, 16#5E7E#, 16#5FCC#, 16#63EE#, 16#673A#, 16#65D7#, 16#65E2#, 16#671F#, 16#68CB#, 16#68C4#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_8B : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#6A5F#, 16#5E30#, 16#6BC5#, 16#6C17#, 16#6C7D#, 16#757F#, 16#7948#, 16#5B63#, 16#7A00#, 16#7D00#, 16#5FBD#, 16#898F#, 16#8A18#, 16#8CB4#, 16#8D77#, 16#8ECC#, 16#8F1D#, 16#98E2#, 16#9A0E#, 16#9B3C#, 16#4E80#, 16#507D#, 16#5100#, 16#5993#, 16#5B9C#, 16#622F#, 16#6280#, 16#64EC#, 16#6B3A#, 16#72A0#, 16#7591#, 16#7947#, 16#7FA9#, 16#87FB#, 16#8ABC#, 16#8B70#, 16#63AC#, 16#83CA#, 16#97A0#, 16#5409#, 16#5403#, 16#55AB#, 16#6854#, 16#6A58#, 16#8A70#, 16#7827#, 16#6775#, 16#9ECD#, 16#5374#, 16#5BA2#, 16#811A#, 16#8650#, 16#9006#, 16#4E18#, 16#4E45#, 16#4EC7#, 16#4F11#, 16#53CA#, 16#5438#, 16#5BAE#, 16#5F13#, 16#6025#, 16#6551#, 16#0000#, 16#673D#, 16#6C42#, 16#6C72#, 16#6CE3#, 16#7078#, 16#7403#, 16#7A76#, 16#7AAE#, 16#7B08#, 16#7D1A#, 16#7CFE#, 16#7D66#, 16#65E7#, 16#725B#, 16#53BB#, 16#5C45#, 16#5DE8#, 16#62D2#, 16#62E0#, 16#6319#, 16#6E20#, 16#865A#, 16#8A31#, 16#8DDD#, 16#92F8#, 16#6F01#, 16#79A6#, 16#9B5A#, 16#4EA8#, 16#4EAB#, 16#4EAC#, 16#4F9B#, 16#4FA0#, 16#50D1#, 16#5147#, 16#7AF6#, 16#5171#, 16#51F6#, 16#5354#, 16#5321#, 16#537F#, 16#53EB#, 16#55AC#, 16#5883#, 16#5CE1#, 16#5F37#, 16#5F4A#, 16#602F#, 16#6050#, 16#606D#, 16#631F#, 16#6559#, 16#6A4B#, 16#6CC1#, 16#72C2#, 16#72ED#, 16#77EF#, 16#80F8#, 16#8105#, 16#8208#, 16#854E#, 16#90F7#, 16#93E1#, 16#97FF#, 16#9957#, 16#9A5A#, 16#4EF0#, 16#51DD#, 16#5C2D#, 16#6681#, 16#696D#, 16#5C40#, 16#66F2#, 16#6975#, 16#7389#, 16#6850#, 16#7C81#, 16#50C5#, 16#52E4#, 16#5747#, 16#5DFE#, 16#9326#, 16#65A4#, 16#6B23#, 16#6B3D#, 16#7434#, 16#7981#, 16#79BD#, 16#7B4B#, 16#7DCA#, 16#82B9#, 16#83CC#, 16#887F#, 16#895F#, 16#8B39#, 16#8FD1#, 16#91D1#, 16#541F#, 16#9280#, 16#4E5D#, 16#5036#, 16#53E5#, 16#533A#, 16#72D7#, 16#7396#, 16#77E9#, 16#82E6#, 16#8EAF#, 16#99C6#, 16#99C8#, 16#99D2#, 16#5177#, 16#611A#, 16#865E#, 16#55B0#, 16#7A7A#, 16#5076#, 16#5BD3#, 16#9047#, 16#9685#, 16#4E32#, 16#6ADB#, 16#91E7#, 16#5C51#, 16#5C48#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_8C : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#6398#, 16#7A9F#, 16#6C93#, 16#9774#, 16#8F61#, 16#7AAA#, 16#718A#, 16#9688#, 16#7C82#, 16#6817#, 16#7E70#, 16#6851#, 16#936C#, 16#52F2#, 16#541B#, 16#85AB#, 16#8A13#, 16#7FA4#, 16#8ECD#, 16#90E1#, 16#5366#, 16#8888#, 16#7941#, 16#4FC2#, 16#50BE#, 16#5211#, 16#5144#, 16#5553#, 16#572D#, 16#73EA#, 16#578B#, 16#5951#, 16#5F62#, 16#5F84#, 16#6075#, 16#6176#, 16#6167#, 16#61A9#, 16#63B2#, 16#643A#, 16#656C#, 16#666F#, 16#6842#, 16#6E13#, 16#7566#, 16#7A3D#, 16#7CFB#, 16#7D4C#, 16#7D99#, 16#7E4B#, 16#7F6B#, 16#830E#, 16#834A#, 16#86CD#, 16#8A08#, 16#8A63#, 16#8B66#, 16#8EFD#, 16#981A#, 16#9D8F#, 16#82B8#, 16#8FCE#, 16#9BE8#, 16#0000#, 16#5287#, 16#621F#, 16#6483#, 16#6FC0#, 16#9699#, 16#6841#, 16#5091#, 16#6B20#, 16#6C7A#, 16#6F54#, 16#7A74#, 16#7D50#, 16#8840#, 16#8A23#, 16#6708#, 16#4EF6#, 16#5039#, 16#5026#, 16#5065#, 16#517C#, 16#5238#, 16#5263#, 16#55A7#, 16#570F#, 16#5805#, 16#5ACC#, 16#5EFA#, 16#61B2#, 16#61F8#, 16#62F3#, 16#6372#, 16#691C#, 16#6A29#, 16#727D#, 16#72AC#, 16#732E#, 16#7814#, 16#786F#, 16#7D79#, 16#770C#, 16#80A9#, 16#898B#, 16#8B19#, 16#8CE2#, 16#8ED2#, 16#9063#, 16#9375#, 16#967A#, 16#9855#, 16#9A13#, 16#9E78#, 16#5143#, 16#539F#, 16#53B3#, 16#5E7B#, 16#5F26#, 16#6E1B#, 16#6E90#, 16#7384#, 16#73FE#, 16#7D43#, 16#8237#, 16#8A00#, 16#8AFA#, 16#9650#, 16#4E4E#, 16#500B#, 16#53E4#, 16#547C#, 16#56FA#, 16#59D1#, 16#5B64#, 16#5DF1#, 16#5EAB#, 16#5F27#, 16#6238#, 16#6545#, 16#67AF#, 16#6E56#, 16#72D0#, 16#7CCA#, 16#88B4#, 16#80A1#, 16#80E1#, 16#83F0#, 16#864E#, 16#8A87#, 16#8DE8#, 16#9237#, 16#96C7#, 16#9867#, 16#9F13#, 16#4E94#, 16#4E92#, 16#4F0D#, 16#5348#, 16#5449#, 16#543E#, 16#5A2F#, 16#5F8C#, 16#5FA1#, 16#609F#, 16#68A7#, 16#6A8E#, 16#745A#, 16#7881#, 16#8A9E#, 16#8AA4#, 16#8B77#, 16#9190#, 16#4E5E#, 16#9BC9#, 16#4EA4#, 16#4F7C#, 16#4FAF#, 16#5019#, 16#5016#, 16#5149#, 16#516C#, 16#529F#, 16#52B9#, 16#52FE#, 16#539A#, 16#53E3#, 16#5411#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_8D : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#540E#, 16#5589#, 16#5751#, 16#57A2#, 16#597D#, 16#5B54#, 16#5B5D#, 16#5B8F#, 16#5DE5#, 16#5DE7#, 16#5DF7#, 16#5E78#, 16#5E83#, 16#5E9A#, 16#5EB7#, 16#5F18#, 16#6052#, 16#614C#, 16#6297#, 16#62D8#, 16#63A7#, 16#653B#, 16#6602#, 16#6643#, 16#66F4#, 16#676D#, 16#6821#, 16#6897#, 16#69CB#, 16#6C5F#, 16#6D2A#, 16#6D69#, 16#6E2F#, 16#6E9D#, 16#7532#, 16#7687#, 16#786C#, 16#7A3F#, 16#7CE0#, 16#7D05#, 16#7D18#, 16#7D5E#, 16#7DB1#, 16#8015#, 16#8003#, 16#80AF#, 16#80B1#, 16#8154#, 16#818F#, 16#822A#, 16#8352#, 16#884C#, 16#8861#, 16#8B1B#, 16#8CA2#, 16#8CFC#, 16#90CA#, 16#9175#, 16#9271#, 16#783F#, 16#92FC#, 16#95A4#, 16#964D#, 16#0000#, 16#9805#, 16#9999#, 16#9AD8#, 16#9D3B#, 16#525B#, 16#52AB#, 16#53F7#, 16#5408#, 16#58D5#, 16#62F7#, 16#6FE0#, 16#8C6A#, 16#8F5F#, 16#9EB9#, 16#514B#, 16#523B#, 16#544A#, 16#56FD#, 16#7A40#, 16#9177#, 16#9D60#, 16#9ED2#, 16#7344#, 16#6F09#, 16#8170#, 16#7511#, 16#5FFD#, 16#60DA#, 16#9AA8#, 16#72DB#, 16#8FBC#, 16#6B64#, 16#9803#, 16#4ECA#, 16#56F0#, 16#5764#, 16#58BE#, 16#5A5A#, 16#6068#, 16#61C7#, 16#660F#, 16#6606#, 16#6839#, 16#68B1#, 16#6DF7#, 16#75D5#, 16#7D3A#, 16#826E#, 16#9B42#, 16#4E9B#, 16#4F50#, 16#53C9#, 16#5506#, 16#5D6F#, 16#5DE6#, 16#5DEE#, 16#67FB#, 16#6C99#, 16#7473#, 16#7802#, 16#8A50#, 16#9396#, 16#88DF#, 16#5750#, 16#5EA7#, 16#632B#, 16#50B5#, 16#50AC#, 16#518D#, 16#6700#, 16#54C9#, 16#585E#, 16#59BB#, 16#5BB0#, 16#5F69#, 16#624D#, 16#63A1#, 16#683D#, 16#6B73#, 16#6E08#, 16#707D#, 16#91C7#, 16#7280#, 16#7815#, 16#7826#, 16#796D#, 16#658E#, 16#7D30#, 16#83DC#, 16#88C1#, 16#8F09#, 16#969B#, 16#5264#, 16#5728#, 16#6750#, 16#7F6A#, 16#8CA1#, 16#51B4#, 16#5742#, 16#962A#, 16#583A#, 16#698A#, 16#80B4#, 16#54B2#, 16#5D0E#, 16#57FC#, 16#7895#, 16#9DFA#, 16#4F5C#, 16#524A#, 16#548B#, 16#643E#, 16#6628#, 16#6714#, 16#67F5#, 16#7A84#, 16#7B56#, 16#7D22#, 16#932F#, 16#685C#, 16#9BAD#, 16#7B39#, 16#5319#, 16#518A#, 16#5237#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_8E : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#5BDF#, 16#62F6#, 16#64AE#, 16#64E6#, 16#672D#, 16#6BBA#, 16#85A9#, 16#96D1#, 16#7690#, 16#9BD6#, 16#634C#, 16#9306#, 16#9BAB#, 16#76BF#, 16#6652#, 16#4E09#, 16#5098#, 16#53C2#, 16#5C71#, 16#60E8#, 16#6492#, 16#6563#, 16#685F#, 16#71E6#, 16#73CA#, 16#7523#, 16#7B97#, 16#7E82#, 16#8695#, 16#8B83#, 16#8CDB#, 16#9178#, 16#9910#, 16#65AC#, 16#66AB#, 16#6B8B#, 16#4ED5#, 16#4ED4#, 16#4F3A#, 16#4F7F#, 16#523A#, 16#53F8#, 16#53F2#, 16#55E3#, 16#56DB#, 16#58EB#, 16#59CB#, 16#59C9#, 16#59FF#, 16#5B50#, 16#5C4D#, 16#5E02#, 16#5E2B#, 16#5FD7#, 16#601D#, 16#6307#, 16#652F#, 16#5B5C#, 16#65AF#, 16#65BD#, 16#65E8#, 16#679D#, 16#6B62#, 16#0000#, 16#6B7B#, 16#6C0F#, 16#7345#, 16#7949#, 16#79C1#, 16#7CF8#, 16#7D19#, 16#7D2B#, 16#80A2#, 16#8102#, 16#81F3#, 16#8996#, 16#8A5E#, 16#8A69#, 16#8A66#, 16#8A8C#, 16#8AEE#, 16#8CC7#, 16#8CDC#, 16#96CC#, 16#98FC#, 16#6B6F#, 16#4E8B#, 16#4F3C#, 16#4F8D#, 16#5150#, 16#5B57#, 16#5BFA#, 16#6148#, 16#6301#, 16#6642#, 16#6B21#, 16#6ECB#, 16#6CBB#, 16#723E#, 16#74BD#, 16#75D4#, 16#78C1#, 16#793A#, 16#800C#, 16#8033#, 16#81EA#, 16#8494#, 16#8F9E#, 16#6C50#, 16#9E7F#, 16#5F0F#, 16#8B58#, 16#9D2B#, 16#7AFA#, 16#8EF8#, 16#5B8D#, 16#96EB#, 16#4E03#, 16#53F1#, 16#57F7#, 16#5931#, 16#5AC9#, 16#5BA4#, 16#6089#, 16#6E7F#, 16#6F06#, 16#75BE#, 16#8CEA#, 16#5B9F#, 16#8500#, 16#7BE0#, 16#5072#, 16#67F4#, 16#829D#, 16#5C61#, 16#854A#, 16#7E1E#, 16#820E#, 16#5199#, 16#5C04#, 16#6368#, 16#8D66#, 16#659C#, 16#716E#, 16#793E#, 16#7D17#, 16#8005#, 16#8B1D#, 16#8ECA#, 16#906E#, 16#86C7#, 16#90AA#, 16#501F#, 16#52FA#, 16#5C3A#, 16#6753#, 16#707C#, 16#7235#, 16#914C#, 16#91C8#, 16#932B#, 16#82E5#, 16#5BC2#, 16#5F31#, 16#60F9#, 16#4E3B#, 16#53D6#, 16#5B88#, 16#624B#, 16#6731#, 16#6B8A#, 16#72E9#, 16#73E0#, 16#7A2E#, 16#816B#, 16#8DA3#, 16#9152#, 16#9996#, 16#5112#, 16#53D7#, 16#546A#, 16#5BFF#, 16#6388#, 16#6A39#, 16#7DAC#, 16#9700#, 16#56DA#, 16#53CE#, 16#5468#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_8F : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#5B97#, 16#5C31#, 16#5DDE#, 16#4FEE#, 16#6101#, 16#62FE#, 16#6D32#, 16#79C0#, 16#79CB#, 16#7D42#, 16#7E4D#, 16#7FD2#, 16#81ED#, 16#821F#, 16#8490#, 16#8846#, 16#8972#, 16#8B90#, 16#8E74#, 16#8F2F#, 16#9031#, 16#914B#, 16#916C#, 16#96C6#, 16#919C#, 16#4EC0#, 16#4F4F#, 16#5145#, 16#5341#, 16#5F93#, 16#620E#, 16#67D4#, 16#6C41#, 16#6E0B#, 16#7363#, 16#7E26#, 16#91CD#, 16#9283#, 16#53D4#, 16#5919#, 16#5BBF#, 16#6DD1#, 16#795D#, 16#7E2E#, 16#7C9B#, 16#587E#, 16#719F#, 16#51FA#, 16#8853#, 16#8FF0#, 16#4FCA#, 16#5CFB#, 16#6625#, 16#77AC#, 16#7AE3#, 16#821C#, 16#99FF#, 16#51C6#, 16#5FAA#, 16#65EC#, 16#696F#, 16#6B89#, 16#6DF3#, 16#0000#, 16#6E96#, 16#6F64#, 16#76FE#, 16#7D14#, 16#5DE1#, 16#9075#, 16#9187#, 16#9806#, 16#51E6#, 16#521D#, 16#6240#, 16#6691#, 16#66D9#, 16#6E1A#, 16#5EB6#, 16#7DD2#, 16#7F72#, 16#66F8#, 16#85AF#, 16#85F7#, 16#8AF8#, 16#52A9#, 16#53D9#, 16#5973#, 16#5E8F#, 16#5F90#, 16#6055#, 16#92E4#, 16#9664#, 16#50B7#, 16#511F#, 16#52DD#, 16#5320#, 16#5347#, 16#53EC#, 16#54E8#, 16#5546#, 16#5531#, 16#5617#, 16#5968#, 16#59BE#, 16#5A3C#, 16#5BB5#, 16#5C06#, 16#5C0F#, 16#5C11#, 16#5C1A#, 16#5E84#, 16#5E8A#, 16#5EE0#, 16#5F70#, 16#627F#, 16#6284#, 16#62DB#, 16#638C#, 16#6377#, 16#6607#, 16#660C#, 16#662D#, 16#6676#, 16#677E#, 16#68A2#, 16#6A1F#, 16#6A35#, 16#6CBC#, 16#6D88#, 16#6E09#, 16#6E58#, 16#713C#, 16#7126#, 16#7167#, 16#75C7#, 16#7701#, 16#785D#, 16#7901#, 16#7965#, 16#79F0#, 16#7AE0#, 16#7B11#, 16#7CA7#, 16#7D39#, 16#8096#, 16#83D6#, 16#848B#, 16#8549#, 16#885D#, 16#88F3#, 16#8A1F#, 16#8A3C#, 16#8A54#, 16#8A73#, 16#8C61#, 16#8CDE#, 16#91A4#, 16#9266#, 16#937E#, 16#9418#, 16#969C#, 16#9798#, 16#4E0A#, 16#4E08#, 16#4E1E#, 16#4E57#, 16#5197#, 16#5270#, 16#57CE#, 16#5834#, 16#58CC#, 16#5B22#, 16#5E38#, 16#60C5#, 16#64FE#, 16#6761#, 16#6756#, 16#6D44#, 16#72B6#, 16#7573#, 16#7A63#, 16#84B8#, 16#8B72#, 16#91B8#, 16#9320#, 16#5631#, 16#57F4#, 16#98FE#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_90 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#62ED#, 16#690D#, 16#6B96#, 16#71ED#, 16#7E54#, 16#8077#, 16#8272#, 16#89E6#, 16#98DF#, 16#8755#, 16#8FB1#, 16#5C3B#, 16#4F38#, 16#4FE1#, 16#4FB5#, 16#5507#, 16#5A20#, 16#5BDD#, 16#5BE9#, 16#5FC3#, 16#614E#, 16#632F#, 16#65B0#, 16#664B#, 16#68EE#, 16#699B#, 16#6D78#, 16#6DF1#, 16#7533#, 16#75B9#, 16#771F#, 16#795E#, 16#79E6#, 16#7D33#, 16#81E3#, 16#82AF#, 16#85AA#, 16#89AA#, 16#8A3A#, 16#8EAB#, 16#8F9B#, 16#9032#, 16#91DD#, 16#9707#, 16#4EBA#, 16#4EC1#, 16#5203#, 16#5875#, 16#58EC#, 16#5C0B#, 16#751A#, 16#5C3D#, 16#814E#, 16#8A0A#, 16#8FC5#, 16#9663#, 16#976D#, 16#7B25#, 16#8ACF#, 16#9808#, 16#9162#, 16#56F3#, 16#53A8#, 16#0000#, 16#9017#, 16#5439#, 16#5782#, 16#5E25#, 16#63A8#, 16#6C34#, 16#708A#, 16#7761#, 16#7C8B#, 16#7FE0#, 16#8870#, 16#9042#, 16#9154#, 16#9310#, 16#9318#, 16#968F#, 16#745E#, 16#9AC4#, 16#5D07#, 16#5D69#, 16#6570#, 16#67A2#, 16#8DA8#, 16#96DB#, 16#636E#, 16#6749#, 16#6919#, 16#83C5#, 16#9817#, 16#96C0#, 16#88FE#, 16#6F84#, 16#647A#, 16#5BF8#, 16#4E16#, 16#702C#, 16#755D#, 16#662F#, 16#51C4#, 16#5236#, 16#52E2#, 16#59D3#, 16#5F81#, 16#6027#, 16#6210#, 16#653F#, 16#6574#, 16#661F#, 16#6674#, 16#68F2#, 16#6816#, 16#6B63#, 16#6E05#, 16#7272#, 16#751F#, 16#76DB#, 16#7CBE#, 16#8056#, 16#58F0#, 16#88FD#, 16#897F#, 16#8AA0#, 16#8A93#, 16#8ACB#, 16#901D#, 16#9192#, 16#9752#, 16#9759#, 16#6589#, 16#7A0E#, 16#8106#, 16#96BB#, 16#5E2D#, 16#60DC#, 16#621A#, 16#65A5#, 16#6614#, 16#6790#, 16#77F3#, 16#7A4D#, 16#7C4D#, 16#7E3E#, 16#810A#, 16#8CAC#, 16#8D64#, 16#8DE1#, 16#8E5F#, 16#78A9#, 16#5207#, 16#62D9#, 16#63A5#, 16#6442#, 16#6298#, 16#8A2D#, 16#7A83#, 16#7BC0#, 16#8AAC#, 16#96EA#, 16#7D76#, 16#820C#, 16#8749#, 16#4ED9#, 16#5148#, 16#5343#, 16#5360#, 16#5BA3#, 16#5C02#, 16#5C16#, 16#5DDD#, 16#6226#, 16#6247#, 16#64B0#, 16#6813#, 16#6834#, 16#6CC9#, 16#6D45#, 16#6D17#, 16#67D3#, 16#6F5C#, 16#714E#, 16#717D#, 16#65CB#, 16#7A7F#, 16#7BAD#, 16#7DDA#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_91 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#7E4A#, 16#7FA8#, 16#817A#, 16#821B#, 16#8239#, 16#85A6#, 16#8A6E#, 16#8CCE#, 16#8DF5#, 16#9078#, 16#9077#, 16#92AD#, 16#9291#, 16#9583#, 16#9BAE#, 16#524D#, 16#5584#, 16#6F38#, 16#7136#, 16#5168#, 16#7985#, 16#7E55#, 16#81B3#, 16#7CCE#, 16#564C#, 16#5851#, 16#5CA8#, 16#63AA#, 16#66FE#, 16#66FD#, 16#695A#, 16#72D9#, 16#758F#, 16#758E#, 16#790E#, 16#7956#, 16#79DF#, 16#7C97#, 16#7D20#, 16#7D44#, 16#8607#, 16#8A34#, 16#963B#, 16#9061#, 16#9F20#, 16#50E7#, 16#5275#, 16#53CC#, 16#53E2#, 16#5009#, 16#55AA#, 16#58EE#, 16#594F#, 16#723D#, 16#5B8B#, 16#5C64#, 16#531D#, 16#60E3#, 16#60F3#, 16#635C#, 16#6383#, 16#633F#, 16#63BB#, 16#0000#, 16#64CD#, 16#65E9#, 16#66F9#, 16#5DE3#, 16#69CD#, 16#69FD#, 16#6F15#, 16#71E5#, 16#4E89#, 16#75E9#, 16#76F8#, 16#7A93#, 16#7CDF#, 16#7DCF#, 16#7D9C#, 16#8061#, 16#8349#, 16#8358#, 16#846C#, 16#84BC#, 16#85FB#, 16#88C5#, 16#8D70#, 16#9001#, 16#906D#, 16#9397#, 16#971C#, 16#9A12#, 16#50CF#, 16#5897#, 16#618E#, 16#81D3#, 16#8535#, 16#8D08#, 16#9020#, 16#4FC3#, 16#5074#, 16#5247#, 16#5373#, 16#606F#, 16#6349#, 16#675F#, 16#6E2C#, 16#8DB3#, 16#901F#, 16#4FD7#, 16#5C5E#, 16#8CCA#, 16#65CF#, 16#7D9A#, 16#5352#, 16#8896#, 16#5176#, 16#63C3#, 16#5B58#, 16#5B6B#, 16#5C0A#, 16#640D#, 16#6751#, 16#905C#, 16#4ED6#, 16#591A#, 16#592A#, 16#6C70#, 16#8A51#, 16#553E#, 16#5815#, 16#59A5#, 16#60F0#, 16#6253#, 16#67C1#, 16#8235#, 16#6955#, 16#9640#, 16#99C4#, 16#9A28#, 16#4F53#, 16#5806#, 16#5BFE#, 16#8010#, 16#5CB1#, 16#5E2F#, 16#5F85#, 16#6020#, 16#614B#, 16#6234#, 16#66FF#, 16#6CF0#, 16#6EDE#, 16#80CE#, 16#817F#, 16#82D4#, 16#888B#, 16#8CB8#, 16#9000#, 16#902E#, 16#968A#, 16#9EDB#, 16#9BDB#, 16#4EE3#, 16#53F0#, 16#5927#, 16#7B2C#, 16#918D#, 16#984C#, 16#9DF9#, 16#6EDD#, 16#7027#, 16#5353#, 16#5544#, 16#5B85#, 16#6258#, 16#629E#, 16#62D3#, 16#6CA2#, 16#6FEF#, 16#7422#, 16#8A17#, 16#9438#, 16#6FC1#, 16#8AFE#, 16#8338#, 16#51E7#, 16#86F8#, 16#53EA#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_92 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#53E9#, 16#4F46#, 16#9054#, 16#8FB0#, 16#596A#, 16#8131#, 16#5DFD#, 16#7AEA#, 16#8FBF#, 16#68DA#, 16#8C37#, 16#72F8#, 16#9C48#, 16#6A3D#, 16#8AB0#, 16#4E39#, 16#5358#, 16#5606#, 16#5766#, 16#62C5#, 16#63A2#, 16#65E6#, 16#6B4E#, 16#6DE1#, 16#6E5B#, 16#70AD#, 16#77ED#, 16#7AEF#, 16#7BAA#, 16#7DBB#, 16#803D#, 16#80C6#, 16#86CB#, 16#8A95#, 16#935B#, 16#56E3#, 16#58C7#, 16#5F3E#, 16#65AD#, 16#6696#, 16#6A80#, 16#6BB5#, 16#7537#, 16#8AC7#, 16#5024#, 16#77E5#, 16#5730#, 16#5F1B#, 16#6065#, 16#667A#, 16#6C60#, 16#75F4#, 16#7A1A#, 16#7F6E#, 16#81F4#, 16#8718#, 16#9045#, 16#99B3#, 16#7BC9#, 16#755C#, 16#7AF9#, 16#7B51#, 16#84C4#, 16#0000#, 16#9010#, 16#79E9#, 16#7A92#, 16#8336#, 16#5AE1#, 16#7740#, 16#4E2D#, 16#4EF2#, 16#5B99#, 16#5FE0#, 16#62BD#, 16#663C#, 16#67F1#, 16#6CE8#, 16#866B#, 16#8877#, 16#8A3B#, 16#914E#, 16#92F3#, 16#99D0#, 16#6A17#, 16#7026#, 16#732A#, 16#82E7#, 16#8457#, 16#8CAF#, 16#4E01#, 16#5146#, 16#51CB#, 16#558B#, 16#5BF5#, 16#5E16#, 16#5E33#, 16#5E81#, 16#5F14#, 16#5F35#, 16#5F6B#, 16#5FB4#, 16#61F2#, 16#6311#, 16#66A2#, 16#671D#, 16#6F6E#, 16#7252#, 16#753A#, 16#773A#, 16#8074#, 16#8139#, 16#8178#, 16#8776#, 16#8ABF#, 16#8ADC#, 16#8D85#, 16#8DF3#, 16#929A#, 16#9577#, 16#9802#, 16#9CE5#, 16#52C5#, 16#6357#, 16#76F4#, 16#6715#, 16#6C88#, 16#73CD#, 16#8CC3#, 16#93AE#, 16#9673#, 16#6D25#, 16#589C#, 16#690E#, 16#69CC#, 16#8FFD#, 16#939A#, 16#75DB#, 16#901A#, 16#585A#, 16#6802#, 16#63B4#, 16#69FB#, 16#4F43#, 16#6F2C#, 16#67D8#, 16#8FBB#, 16#8526#, 16#7DB4#, 16#9354#, 16#693F#, 16#6F70#, 16#576A#, 16#58F7#, 16#5B2C#, 16#7D2C#, 16#722A#, 16#540A#, 16#91E3#, 16#9DB4#, 16#4EAD#, 16#4F4E#, 16#505C#, 16#5075#, 16#5243#, 16#8C9E#, 16#5448#, 16#5824#, 16#5B9A#, 16#5E1D#, 16#5E95#, 16#5EAD#, 16#5EF7#, 16#5F1F#, 16#608C#, 16#62B5#, 16#633A#, 16#63D0#, 16#68AF#, 16#6C40#, 16#7887#, 16#798E#, 16#7A0B#, 16#7DE0#, 16#8247#, 16#8A02#, 16#8AE6#, 16#8E44#, 16#9013#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_93 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#90B8#, 16#912D#, 16#91D8#, 16#9F0E#, 16#6CE5#, 16#6458#, 16#64E2#, 16#6575#, 16#6EF4#, 16#7684#, 16#7B1B#, 16#9069#, 16#93D1#, 16#6EBA#, 16#54F2#, 16#5FB9#, 16#64A4#, 16#8F4D#, 16#8FED#, 16#9244#, 16#5178#, 16#586B#, 16#5929#, 16#5C55#, 16#5E97#, 16#6DFB#, 16#7E8F#, 16#751C#, 16#8CBC#, 16#8EE2#, 16#985B#, 16#70B9#, 16#4F1D#, 16#6BBF#, 16#6FB1#, 16#7530#, 16#96FB#, 16#514E#, 16#5410#, 16#5835#, 16#5857#, 16#59AC#, 16#5C60#, 16#5F92#, 16#6597#, 16#675C#, 16#6E21#, 16#767B#, 16#83DF#, 16#8CED#, 16#9014#, 16#90FD#, 16#934D#, 16#7825#, 16#783A#, 16#52AA#, 16#5EA6#, 16#571F#, 16#5974#, 16#6012#, 16#5012#, 16#515A#, 16#51AC#, 16#0000#, 16#51CD#, 16#5200#, 16#5510#, 16#5854#, 16#5858#, 16#5957#, 16#5B95#, 16#5CF6#, 16#5D8B#, 16#60BC#, 16#6295#, 16#642D#, 16#6771#, 16#6843#, 16#68BC#, 16#68DF#, 16#76D7#, 16#6DD8#, 16#6E6F#, 16#6D9B#, 16#706F#, 16#71C8#, 16#5F53#, 16#75D8#, 16#7977#, 16#7B49#, 16#7B54#, 16#7B52#, 16#7CD6#, 16#7D71#, 16#5230#, 16#8463#, 16#8569#, 16#85E4#, 16#8A0E#, 16#8B04#, 16#8C46#, 16#8E0F#, 16#9003#, 16#900F#, 16#9419#, 16#9676#, 16#982D#, 16#9A30#, 16#95D8#, 16#50CD#, 16#52D5#, 16#540C#, 16#5802#, 16#5C0E#, 16#61A7#, 16#649E#, 16#6D1E#, 16#77B3#, 16#7AE5#, 16#80F4#, 16#8404#, 16#9053#, 16#9285#, 16#5CE0#, 16#9D07#, 16#533F#, 16#5F97#, 16#5FB3#, 16#6D9C#, 16#7279#, 16#7763#, 16#79BF#, 16#7BE4#, 16#6BD2#, 16#72EC#, 16#8AAD#, 16#6803#, 16#6A61#, 16#51F8#, 16#7A81#, 16#6934#, 16#5C4A#, 16#9CF6#, 16#82EB#, 16#5BC5#, 16#9149#, 16#701E#, 16#5678#, 16#5C6F#, 16#60C7#, 16#6566#, 16#6C8C#, 16#8C5A#, 16#9041#, 16#9813#, 16#5451#, 16#66C7#, 16#920D#, 16#5948#, 16#90A3#, 16#5185#, 16#4E4D#, 16#51EA#, 16#8599#, 16#8B0E#, 16#7058#, 16#637A#, 16#934B#, 16#6962#, 16#99B4#, 16#7E04#, 16#7577#, 16#5357#, 16#6960#, 16#8EDF#, 16#96E3#, 16#6C5D#, 16#4E8C#, 16#5C3C#, 16#5F10#, 16#8FE9#, 16#5302#, 16#8CD1#, 16#8089#, 16#8679#, 16#5EFF#, 16#65E5#, 16#4E73#, 16#5165#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_94 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#5982#, 16#5C3F#, 16#97EE#, 16#4EFB#, 16#598A#, 16#5FCD#, 16#8A8D#, 16#6FE1#, 16#79B0#, 16#7962#, 16#5BE7#, 16#8471#, 16#732B#, 16#71B1#, 16#5E74#, 16#5FF5#, 16#637B#, 16#649A#, 16#71C3#, 16#7C98#, 16#4E43#, 16#5EFC#, 16#4E4B#, 16#57DC#, 16#56A2#, 16#60A9#, 16#6FC3#, 16#7D0D#, 16#80FD#, 16#8133#, 16#81BF#, 16#8FB2#, 16#8997#, 16#86A4#, 16#5DF4#, 16#628A#, 16#64AD#, 16#8987#, 16#6777#, 16#6CE2#, 16#6D3E#, 16#7436#, 16#7834#, 16#5A46#, 16#7F75#, 16#82AD#, 16#99AC#, 16#4FF3#, 16#5EC3#, 16#62DD#, 16#6392#, 16#6557#, 16#676F#, 16#76C3#, 16#724C#, 16#80CC#, 16#80BA#, 16#8F29#, 16#914D#, 16#500D#, 16#57F9#, 16#5A92#, 16#6885#, 16#0000#, 16#6973#, 16#7164#, 16#72FD#, 16#8CB7#, 16#58F2#, 16#8CE0#, 16#966A#, 16#9019#, 16#877F#, 16#79E4#, 16#77E7#, 16#8429#, 16#4F2F#, 16#5265#, 16#535A#, 16#62CD#, 16#67CF#, 16#6CCA#, 16#767D#, 16#7B94#, 16#7C95#, 16#8236#, 16#8584#, 16#8FEB#, 16#66DD#, 16#6F20#, 16#7206#, 16#7E1B#, 16#83AB#, 16#99C1#, 16#9EA6#, 16#51FD#, 16#7BB1#, 16#7872#, 16#7BB8#, 16#8087#, 16#7B48#, 16#6AE8#, 16#5E61#, 16#808C#, 16#7551#, 16#7560#, 16#516B#, 16#9262#, 16#6E8C#, 16#767A#, 16#9197#, 16#9AEA#, 16#4F10#, 16#7F70#, 16#629C#, 16#7B4F#, 16#95A5#, 16#9CE9#, 16#567A#, 16#5859#, 16#86E4#, 16#96BC#, 16#4F34#, 16#5224#, 16#534A#, 16#53CD#, 16#53DB#, 16#5E06#, 16#642C#, 16#6591#, 16#677F#, 16#6C3E#, 16#6C4E#, 16#7248#, 16#72AF#, 16#73ED#, 16#7554#, 16#7E41#, 16#822C#, 16#85E9#, 16#8CA9#, 16#7BC4#, 16#91C6#, 16#7169#, 16#9812#, 16#98EF#, 16#633D#, 16#6669#, 16#756A#, 16#76E4#, 16#78D0#, 16#8543#, 16#86EE#, 16#532A#, 16#5351#, 16#5426#, 16#5983#, 16#5E87#, 16#5F7C#, 16#60B2#, 16#6249#, 16#6279#, 16#62AB#, 16#6590#, 16#6BD4#, 16#6CCC#, 16#75B2#, 16#76AE#, 16#7891#, 16#79D8#, 16#7DCB#, 16#7F77#, 16#80A5#, 16#88AB#, 16#8AB9#, 16#8CBB#, 16#907F#, 16#975E#, 16#98DB#, 16#6A0B#, 16#7C38#, 16#5099#, 16#5C3E#, 16#5FAE#, 16#6787#, 16#6BD8#, 16#7435#, 16#7709#, 16#7F8E#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_95 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#9F3B#, 16#67CA#, 16#7A17#, 16#5339#, 16#758B#, 16#9AED#, 16#5F66#, 16#819D#, 16#83F1#, 16#8098#, 16#5F3C#, 16#5FC5#, 16#7562#, 16#7B46#, 16#903C#, 16#6867#, 16#59EB#, 16#5A9B#, 16#7D10#, 16#767E#, 16#8B2C#, 16#4FF5#, 16#5F6A#, 16#6A19#, 16#6C37#, 16#6F02#, 16#74E2#, 16#7968#, 16#8868#, 16#8A55#, 16#8C79#, 16#5EDF#, 16#63CF#, 16#75C5#, 16#79D2#, 16#82D7#, 16#9328#, 16#92F2#, 16#849C#, 16#86ED#, 16#9C2D#, 16#54C1#, 16#5F6C#, 16#658C#, 16#6D5C#, 16#7015#, 16#8CA7#, 16#8CD3#, 16#983B#, 16#654F#, 16#74F6#, 16#4E0D#, 16#4ED8#, 16#57E0#, 16#592B#, 16#5A66#, 16#5BCC#, 16#51A8#, 16#5E03#, 16#5E9C#, 16#6016#, 16#6276#, 16#6577#, 16#0000#, 16#65A7#, 16#666E#, 16#6D6E#, 16#7236#, 16#7B26#, 16#8150#, 16#819A#, 16#8299#, 16#8B5C#, 16#8CA0#, 16#8CE6#, 16#8D74#, 16#961C#, 16#9644#, 16#4FAE#, 16#64AB#, 16#6B66#, 16#821E#, 16#8461#, 16#856A#, 16#90E8#, 16#5C01#, 16#6953#, 16#98A8#, 16#847A#, 16#8557#, 16#4F0F#, 16#526F#, 16#5FA9#, 16#5E45#, 16#670D#, 16#798F#, 16#8179#, 16#8907#, 16#8986#, 16#6DF5#, 16#5F17#, 16#6255#, 16#6CB8#, 16#4ECF#, 16#7269#, 16#9B92#, 16#5206#, 16#543B#, 16#5674#, 16#58B3#, 16#61A4#, 16#626E#, 16#711A#, 16#596E#, 16#7C89#, 16#7CDE#, 16#7D1B#, 16#96F0#, 16#6587#, 16#805E#, 16#4E19#, 16#4F75#, 16#5175#, 16#5840#, 16#5E63#, 16#5E73#, 16#5F0A#, 16#67C4#, 16#4E26#, 16#853D#, 16#9589#, 16#965B#, 16#7C73#, 16#9801#, 16#50FB#, 16#58C1#, 16#7656#, 16#78A7#, 16#5225#, 16#77A5#, 16#8511#, 16#7B86#, 16#504F#, 16#5909#, 16#7247#, 16#7BC7#, 16#7DE8#, 16#8FBA#, 16#8FD4#, 16#904D#, 16#4FBF#, 16#52C9#, 16#5A29#, 16#5F01#, 16#97AD#, 16#4FDD#, 16#8217#, 16#92EA#, 16#5703#, 16#6355#, 16#6B69#, 16#752B#, 16#88DC#, 16#8F14#, 16#7A42#, 16#52DF#, 16#5893#, 16#6155#, 16#620A#, 16#66AE#, 16#6BCD#, 16#7C3F#, 16#83E9#, 16#5023#, 16#4FF8#, 16#5305#, 16#5446#, 16#5831#, 16#5949#, 16#5B9D#, 16#5CF0#, 16#5CEF#, 16#5D29#, 16#5E96#, 16#62B1#, 16#6367#, 16#653E#, 16#65B9#, 16#670B#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_96 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#6CD5#, 16#6CE1#, 16#70F9#, 16#7832#, 16#7E2B#, 16#80DE#, 16#82B3#, 16#840C#, 16#84EC#, 16#8702#, 16#8912#, 16#8A2A#, 16#8C4A#, 16#90A6#, 16#92D2#, 16#98FD#, 16#9CF3#, 16#9D6C#, 16#4E4F#, 16#4EA1#, 16#508D#, 16#5256#, 16#574A#, 16#59A8#, 16#5E3D#, 16#5FD8#, 16#5FD9#, 16#623F#, 16#66B4#, 16#671B#, 16#67D0#, 16#68D2#, 16#5192#, 16#7D21#, 16#80AA#, 16#81A8#, 16#8B00#, 16#8C8C#, 16#8CBF#, 16#927E#, 16#9632#, 16#5420#, 16#982C#, 16#5317#, 16#50D5#, 16#535C#, 16#58A8#, 16#64B2#, 16#6734#, 16#7267#, 16#7766#, 16#7A46#, 16#91E6#, 16#52C3#, 16#6CA1#, 16#6B86#, 16#5800#, 16#5E4C#, 16#5954#, 16#672C#, 16#7FFB#, 16#51E1#, 16#76C6#, 16#0000#, 16#6469#, 16#78E8#, 16#9B54#, 16#9EBB#, 16#57CB#, 16#59B9#, 16#6627#, 16#679A#, 16#6BCE#, 16#54E9#, 16#69D9#, 16#5E55#, 16#819C#, 16#6795#, 16#9BAA#, 16#67FE#, 16#9C52#, 16#685D#, 16#4EA6#, 16#4FE3#, 16#53C8#, 16#62B9#, 16#672B#, 16#6CAB#, 16#8FC4#, 16#4FAD#, 16#7E6D#, 16#9EBF#, 16#4E07#, 16#6162#, 16#6E80#, 16#6F2B#, 16#8513#, 16#5473#, 16#672A#, 16#9B45#, 16#5DF3#, 16#7B95#, 16#5CAC#, 16#5BC6#, 16#871C#, 16#6E4A#, 16#84D1#, 16#7A14#, 16#8108#, 16#5999#, 16#7C8D#, 16#6C11#, 16#7720#, 16#52D9#, 16#5922#, 16#7121#, 16#725F#, 16#77DB#, 16#9727#, 16#9D61#, 16#690B#, 16#5A7F#, 16#5A18#, 16#51A5#, 16#540D#, 16#547D#, 16#660E#, 16#76DF#, 16#8FF7#, 16#9298#, 16#9CF4#, 16#59EA#, 16#725D#, 16#6EC5#, 16#514D#, 16#68C9#, 16#7DBF#, 16#7DEC#, 16#9762#, 16#9EBA#, 16#6478#, 16#6A21#, 16#8302#, 16#5984#, 16#5B5F#, 16#6BDB#, 16#731B#, 16#76F2#, 16#7DB2#, 16#8017#, 16#8499#, 16#5132#, 16#6728#, 16#9ED9#, 16#76EE#, 16#6762#, 16#52FF#, 16#9905#, 16#5C24#, 16#623B#, 16#7C7E#, 16#8CB0#, 16#554F#, 16#60B6#, 16#7D0B#, 16#9580#, 16#5301#, 16#4E5F#, 16#51B6#, 16#591C#, 16#723A#, 16#8036#, 16#91CE#, 16#5F25#, 16#77E2#, 16#5384#, 16#5F79#, 16#7D04#, 16#85AC#, 16#8A33#, 16#8E8D#, 16#9756#, 16#67F3#, 16#85AE#, 16#9453#, 16#6109#, 16#6108#, 16#6CB9#, 16#7652#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_97 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#8AED#, 16#8F38#, 16#552F#, 16#4F51#, 16#512A#, 16#52C7#, 16#53CB#, 16#5BA5#, 16#5E7D#, 16#60A0#, 16#6182#, 16#63D6#, 16#6709#, 16#67DA#, 16#6E67#, 16#6D8C#, 16#7336#, 16#7337#, 16#7531#, 16#7950#, 16#88D5#, 16#8A98#, 16#904A#, 16#9091#, 16#90F5#, 16#96C4#, 16#878D#, 16#5915#, 16#4E88#, 16#4F59#, 16#4E0E#, 16#8A89#, 16#8F3F#, 16#9810#, 16#50AD#, 16#5E7C#, 16#5996#, 16#5BB9#, 16#5EB8#, 16#63DA#, 16#63FA#, 16#64C1#, 16#66DC#, 16#694A#, 16#69D8#, 16#6D0B#, 16#6EB6#, 16#7194#, 16#7528#, 16#7AAF#, 16#7F8A#, 16#8000#, 16#8449#, 16#84C9#, 16#8981#, 16#8B21#, 16#8E0A#, 16#9065#, 16#967D#, 16#990A#, 16#617E#, 16#6291#, 16#6B32#, 16#0000#, 16#6C83#, 16#6D74#, 16#7FCC#, 16#7FFC#, 16#6DC0#, 16#7F85#, 16#87BA#, 16#88F8#, 16#6765#, 16#83B1#, 16#983C#, 16#96F7#, 16#6D1B#, 16#7D61#, 16#843D#, 16#916A#, 16#4E71#, 16#5375#, 16#5D50#, 16#6B04#, 16#6FEB#, 16#85CD#, 16#862D#, 16#89A7#, 16#5229#, 16#540F#, 16#5C65#, 16#674E#, 16#68A8#, 16#7406#, 16#7483#, 16#75E2#, 16#88CF#, 16#88E1#, 16#91CC#, 16#96E2#, 16#9678#, 16#5F8B#, 16#7387#, 16#7ACB#, 16#844E#, 16#63A0#, 16#7565#, 16#5289#, 16#6D41#, 16#6E9C#, 16#7409#, 16#7559#, 16#786B#, 16#7C92#, 16#9686#, 16#7ADC#, 16#9F8D#, 16#4FB6#, 16#616E#, 16#65C5#, 16#865C#, 16#4E86#, 16#4EAE#, 16#50DA#, 16#4E21#, 16#51CC#, 16#5BEE#, 16#6599#, 16#6881#, 16#6DBC#, 16#731F#, 16#7642#, 16#77AD#, 16#7A1C#, 16#7CE7#, 16#826F#, 16#8AD2#, 16#907C#, 16#91CF#, 16#9675#, 16#9818#, 16#529B#, 16#7DD1#, 16#502B#, 16#5398#, 16#6797#, 16#6DCB#, 16#71D0#, 16#7433#, 16#81E8#, 16#8F2A#, 16#96A3#, 16#9C57#, 16#9E9F#, 16#7460#, 16#5841#, 16#6D99#, 16#7D2F#, 16#985E#, 16#4EE4#, 16#4F36#, 16#4F8B#, 16#51B7#, 16#52B1#, 16#5DBA#, 16#601C#, 16#73B2#, 16#793C#, 16#82D3#, 16#9234#, 16#96B7#, 16#96F6#, 16#970A#, 16#9E97#, 16#9F62#, 16#66A6#, 16#6B74#, 16#5217#, 16#52A3#, 16#70C8#, 16#88C2#, 16#5EC9#, 16#604B#, 16#6190#, 16#6F23#, 16#7149#, 16#7C3E#, 16#7DF4#, 16#806F#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_98 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#84EE#, 16#9023#, 16#932C#, 16#5442#, 16#9B6F#, 16#6AD3#, 16#7089#, 16#8CC2#, 16#8DEF#, 16#9732#, 16#52B4#, 16#5A41#, 16#5ECA#, 16#5F04#, 16#6717#, 16#697C#, 16#6994#, 16#6D6A#, 16#6F0F#, 16#7262#, 16#72FC#, 16#7BED#, 16#8001#, 16#807E#, 16#874B#, 16#90CE#, 16#516D#, 16#9E93#, 16#7984#, 16#808B#, 16#9332#, 16#8AD6#, 16#502D#, 16#548C#, 16#8A71#, 16#6B6A#, 16#8CC4#, 16#8107#, 16#60D1#, 16#67A0#, 16#9DF2#, 16#4E99#, 16#4E98#, 16#9C10#, 16#8A6B#, 16#85C1#, 16#8568#, 16#6900#, 16#6E7E#, 16#7897#, 16#8155#, 16#02_0B9F#, 16#5B41#, 16#5B56#, 16#5B7D#, 16#5B93#, 16#5BD8#, 16#5BEC#, 16#5C12#, 16#5C1E#, 16#5C23#, 16#5C2B#, 16#378D#, 16#0000#, 16#5C62#, 16#FA3B#, 16#FA3C#, 16#02_16B4#, 16#5C7A#, 16#5C8F#, 16#5C9F#, 16#5CA3#, 16#5CAA#, 16#5CBA#, 16#5CCB#, 16#5CD0#, 16#5CD2#, 16#5CF4#, 16#02_1E34#, 16#37E2#, 16#5D0D#, 16#5D27#, 16#FA11#, 16#5D46#, 16#5D47#, 16#5D53#, 16#5D4A#, 16#5D6D#, 16#5D81#, 16#5DA0#, 16#5DA4#, 16#5DA7#, 16#5DB8#, 16#5DCB#, 16#541E#, 16#5F0C#, 16#4E10#, 16#4E15#, 16#4E2A#, 16#4E31#, 16#4E36#, 16#4E3C#, 16#4E3F#, 16#4E42#, 16#4E56#, 16#4E58#, 16#4E82#, 16#4E85#, 16#8C6B#, 16#4E8A#, 16#8212#, 16#5F0D#, 16#4E8E#, 16#4E9E#, 16#4E9F#, 16#4EA0#, 16#4EA2#, 16#4EB0#, 16#4EB3#, 16#4EB6#, 16#4ECE#, 16#4ECD#, 16#4EC4#, 16#4EC6#, 16#4EC2#, 16#4ED7#, 16#4EDE#, 16#4EED#, 16#4EDF#, 16#4EF7#, 16#4F09#, 16#4F5A#, 16#4F30#, 16#4F5B#, 16#4F5D#, 16#4F57#, 16#4F47#, 16#4F76#, 16#4F88#, 16#4F8F#, 16#4F98#, 16#4F7B#, 16#4F69#, 16#4F70#, 16#4F91#, 16#4F6F#, 16#4F86#, 16#4F96#, 16#5118#, 16#4FD4#, 16#4FDF#, 16#4FCE#, 16#4FD8#, 16#4FDB#, 16#4FD1#, 16#4FDA#, 16#4FD0#, 16#4FE4#, 16#4FE5#, 16#501A#, 16#5028#, 16#5014#, 16#502A#, 16#5025#, 16#5005#, 16#4F1C#, 16#4FF6#, 16#5021#, 16#5029#, 16#502C#, 16#4FFE#, 16#4FEF#, 16#5011#, 16#5006#, 16#5043#, 16#5047#, 16#6703#, 16#5055#, 16#5050#, 16#5048#, 16#505A#, 16#5056#, 16#506C#, 16#5078#, 16#5080#, 16#509A#, 16#5085#, 16#50B4#, 16#50B2#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_99 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#50C9#, 16#50CA#, 16#50B3#, 16#50C2#, 16#50D6#, 16#50DE#, 16#50E5#, 16#50ED#, 16#50E3#, 16#50EE#, 16#50F9#, 16#50F5#, 16#5109#, 16#5101#, 16#5102#, 16#5116#, 16#5115#, 16#5114#, 16#511A#, 16#5121#, 16#513A#, 16#5137#, 16#513C#, 16#513B#, 16#513F#, 16#5140#, 16#5152#, 16#514C#, 16#5154#, 16#5162#, 16#7AF8#, 16#5169#, 16#516A#, 16#516E#, 16#5180#, 16#5182#, 16#56D8#, 16#518C#, 16#5189#, 16#518F#, 16#5191#, 16#5193#, 16#5195#, 16#5196#, 16#51A4#, 16#51A6#, 16#51A2#, 16#51A9#, 16#51AA#, 16#51AB#, 16#51B3#, 16#51B1#, 16#51B2#, 16#51B0#, 16#51B5#, 16#51BD#, 16#51C5#, 16#51C9#, 16#51DB#, 16#51E0#, 16#8655#, 16#51E9#, 16#51ED#, 16#0000#, 16#51F0#, 16#51F5#, 16#51FE#, 16#5204#, 16#520B#, 16#5214#, 16#520E#, 16#5227#, 16#522A#, 16#522E#, 16#5233#, 16#5239#, 16#524F#, 16#5244#, 16#524B#, 16#524C#, 16#525E#, 16#5254#, 16#526A#, 16#5274#, 16#5269#, 16#5273#, 16#527F#, 16#527D#, 16#528D#, 16#5294#, 16#5292#, 16#5271#, 16#5288#, 16#5291#, 16#8FA8#, 16#8FA7#, 16#52AC#, 16#52AD#, 16#52BC#, 16#52B5#, 16#52C1#, 16#52CD#, 16#52D7#, 16#52DE#, 16#52E3#, 16#52E6#, 16#98ED#, 16#52E0#, 16#52F3#, 16#52F5#, 16#52F8#, 16#52F9#, 16#5306#, 16#5308#, 16#7538#, 16#530D#, 16#5310#, 16#530F#, 16#5315#, 16#531A#, 16#5323#, 16#532F#, 16#5331#, 16#5333#, 16#5338#, 16#5340#, 16#5346#, 16#5345#, 16#4E17#, 16#5349#, 16#534D#, 16#51D6#, 16#535E#, 16#5369#, 16#536E#, 16#5918#, 16#537B#, 16#5377#, 16#5382#, 16#5396#, 16#53A0#, 16#53A6#, 16#53A5#, 16#53AE#, 16#53B0#, 16#53B6#, 16#53C3#, 16#7C12#, 16#96D9#, 16#53DF#, 16#66FC#, 16#71EE#, 16#53EE#, 16#53E8#, 16#53ED#, 16#53FA#, 16#5401#, 16#543D#, 16#5440#, 16#542C#, 16#542D#, 16#543C#, 16#542E#, 16#5436#, 16#5429#, 16#541D#, 16#544E#, 16#548F#, 16#5475#, 16#548E#, 16#545F#, 16#5471#, 16#5477#, 16#5470#, 16#5492#, 16#547B#, 16#5480#, 16#5476#, 16#5484#, 16#5490#, 16#5486#, 16#54C7#, 16#54A2#, 16#54B8#, 16#54A5#, 16#54AC#, 16#54C4#, 16#54C8#, 16#54A8#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_9A : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#54AB#, 16#54C2#, 16#54A4#, 16#54BE#, 16#54BC#, 16#54D8#, 16#54E5#, 16#54E6#, 16#550F#, 16#5514#, 16#54FD#, 16#54EE#, 16#54ED#, 16#54FA#, 16#54E2#, 16#5539#, 16#5540#, 16#5563#, 16#554C#, 16#552E#, 16#555C#, 16#5545#, 16#5556#, 16#5557#, 16#5538#, 16#5533#, 16#555D#, 16#5599#, 16#5580#, 16#54AF#, 16#558A#, 16#559F#, 16#557B#, 16#557E#, 16#5598#, 16#559E#, 16#55AE#, 16#557C#, 16#5583#, 16#55A9#, 16#5587#, 16#55A8#, 16#55DA#, 16#55C5#, 16#55DF#, 16#55C4#, 16#55DC#, 16#55E4#, 16#55D4#, 16#5614#, 16#55F7#, 16#5616#, 16#55FE#, 16#55FD#, 16#561B#, 16#55F9#, 16#564E#, 16#5650#, 16#71DF#, 16#5634#, 16#5636#, 16#5632#, 16#5638#, 16#0000#, 16#566B#, 16#5664#, 16#562F#, 16#566C#, 16#566A#, 16#5686#, 16#5680#, 16#568A#, 16#56A0#, 16#5694#, 16#568F#, 16#56A5#, 16#56AE#, 16#56B6#, 16#56B4#, 16#56C2#, 16#56BC#, 16#56C1#, 16#56C3#, 16#56C0#, 16#56C8#, 16#56CE#, 16#56D1#, 16#56D3#, 16#56D7#, 16#56EE#, 16#56F9#, 16#5700#, 16#56FF#, 16#5704#, 16#5709#, 16#5708#, 16#570B#, 16#570D#, 16#5713#, 16#5718#, 16#5716#, 16#55C7#, 16#571C#, 16#5726#, 16#5737#, 16#5738#, 16#574E#, 16#573B#, 16#5740#, 16#574F#, 16#5769#, 16#57C0#, 16#5788#, 16#5761#, 16#577F#, 16#5789#, 16#5793#, 16#57A0#, 16#57B3#, 16#57A4#, 16#57AA#, 16#57B0#, 16#57C3#, 16#57C6#, 16#57D4#, 16#57D2#, 16#57D3#, 16#580A#, 16#57D6#, 16#57E3#, 16#580B#, 16#5819#, 16#581D#, 16#5872#, 16#5821#, 16#5862#, 16#584B#, 16#5870#, 16#6BC0#, 16#5852#, 16#583D#, 16#5879#, 16#5885#, 16#58B9#, 16#589F#, 16#58AB#, 16#58BA#, 16#58DE#, 16#58BB#, 16#58B8#, 16#58AE#, 16#58C5#, 16#58D3#, 16#58D1#, 16#58D7#, 16#58D9#, 16#58D8#, 16#58E5#, 16#58DC#, 16#58E4#, 16#58DF#, 16#58EF#, 16#58FA#, 16#58F9#, 16#58FB#, 16#58FC#, 16#58FD#, 16#5902#, 16#590A#, 16#5910#, 16#591B#, 16#68A6#, 16#5925#, 16#592C#, 16#592D#, 16#5932#, 16#5938#, 16#593E#, 16#7AD2#, 16#5955#, 16#5950#, 16#594E#, 16#595A#, 16#5958#, 16#5962#, 16#5960#, 16#5967#, 16#596C#, 16#5969#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_9B : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#5978#, 16#5981#, 16#599D#, 16#4F5E#, 16#4FAB#, 16#59A3#, 16#59B2#, 16#59C6#, 16#59E8#, 16#59DC#, 16#598D#, 16#59D9#, 16#59DA#, 16#5A25#, 16#5A1F#, 16#5A11#, 16#5A1C#, 16#5A09#, 16#5A1A#, 16#5A40#, 16#5A6C#, 16#5A49#, 16#5A35#, 16#5A36#, 16#5A62#, 16#5A6A#, 16#5A9A#, 16#5ABC#, 16#5ABE#, 16#5ACB#, 16#5AC2#, 16#5ABD#, 16#5AE3#, 16#5AD7#, 16#5AE6#, 16#5AE9#, 16#5AD6#, 16#5AFA#, 16#5AFB#, 16#5B0C#, 16#5B0B#, 16#5B16#, 16#5B32#, 16#5AD0#, 16#5B2A#, 16#5B36#, 16#5B3E#, 16#5B43#, 16#5B45#, 16#5B40#, 16#5B51#, 16#5B55#, 16#5B5A#, 16#5B5B#, 16#5B65#, 16#5B69#, 16#5B70#, 16#5B73#, 16#5B75#, 16#5B78#, 16#6588#, 16#5B7A#, 16#5B80#, 16#0000#, 16#5B83#, 16#5BA6#, 16#5BB8#, 16#5BC3#, 16#5BC7#, 16#5BC9#, 16#5BD4#, 16#5BD0#, 16#5BE4#, 16#5BE6#, 16#5BE2#, 16#5BDE#, 16#5BE5#, 16#5BEB#, 16#5BF0#, 16#5BF6#, 16#5BF3#, 16#5C05#, 16#5C07#, 16#5C08#, 16#5C0D#, 16#5C13#, 16#5C20#, 16#5C22#, 16#5C28#, 16#5C38#, 16#5C39#, 16#5C41#, 16#5C46#, 16#5C4E#, 16#5C53#, 16#5C50#, 16#5C4F#, 16#5B71#, 16#5C6C#, 16#5C6E#, 16#4E62#, 16#5C76#, 16#5C79#, 16#5C8C#, 16#5C91#, 16#5C94#, 16#599B#, 16#5CAB#, 16#5CBB#, 16#5CB6#, 16#5CBC#, 16#5CB7#, 16#5CC5#, 16#5CBE#, 16#5CC7#, 16#5CD9#, 16#5CE9#, 16#5CFD#, 16#5CFA#, 16#5CED#, 16#5D8C#, 16#5CEA#, 16#5D0B#, 16#5D15#, 16#5D17#, 16#5D5C#, 16#5D1F#, 16#5D1B#, 16#5D11#, 16#5D14#, 16#5D22#, 16#5D1A#, 16#5D19#, 16#5D18#, 16#5D4C#, 16#5D52#, 16#5D4E#, 16#5D4B#, 16#5D6C#, 16#5D73#, 16#5D76#, 16#5D87#, 16#5D84#, 16#5D82#, 16#5DA2#, 16#5D9D#, 16#5DAC#, 16#5DAE#, 16#5DBD#, 16#5D90#, 16#5DB7#, 16#5DBC#, 16#5DC9#, 16#5DCD#, 16#5DD3#, 16#5DD2#, 16#5DD6#, 16#5DDB#, 16#5DEB#, 16#5DF2#, 16#5DF5#, 16#5E0B#, 16#5E1A#, 16#5E19#, 16#5E11#, 16#5E1B#, 16#5E36#, 16#5E37#, 16#5E44#, 16#5E43#, 16#5E40#, 16#5E4E#, 16#5E57#, 16#5E54#, 16#5E5F#, 16#5E62#, 16#5E64#, 16#5E47#, 16#5E75#, 16#5E76#, 16#5E7A#, 16#9EBC#, 16#5E7F#, 16#5EA0#, 16#5EC1#, 16#5EC2#, 16#5EC8#, 16#5ED0#, 16#5ECF#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_9C : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#5ED6#, 16#5EE3#, 16#5EDD#, 16#5EDA#, 16#5EDB#, 16#5EE2#, 16#5EE1#, 16#5EE8#, 16#5EE9#, 16#5EEC#, 16#5EF1#, 16#5EF3#, 16#5EF0#, 16#5EF4#, 16#5EF8#, 16#5EFE#, 16#5F03#, 16#5F09#, 16#5F5D#, 16#5F5C#, 16#5F0B#, 16#5F11#, 16#5F16#, 16#5F29#, 16#5F2D#, 16#5F38#, 16#5F41#, 16#5F48#, 16#5F4C#, 16#5F4E#, 16#5F2F#, 16#5F51#, 16#5F56#, 16#5F57#, 16#5F59#, 16#5F61#, 16#5F6D#, 16#5F73#, 16#5F77#, 16#5F83#, 16#5F82#, 16#5F7F#, 16#5F8A#, 16#5F88#, 16#5F91#, 16#5F87#, 16#5F9E#, 16#5F99#, 16#5F98#, 16#5FA0#, 16#5FA8#, 16#5FAD#, 16#5FBC#, 16#5FD6#, 16#5FFB#, 16#5FE4#, 16#5FF8#, 16#5FF1#, 16#5FDD#, 16#60B3#, 16#5FFF#, 16#6021#, 16#6060#, 16#0000#, 16#6019#, 16#6010#, 16#6029#, 16#600E#, 16#6031#, 16#601B#, 16#6015#, 16#602B#, 16#6026#, 16#600F#, 16#603A#, 16#605A#, 16#6041#, 16#606A#, 16#6077#, 16#605F#, 16#604A#, 16#6046#, 16#604D#, 16#6063#, 16#6043#, 16#6064#, 16#6042#, 16#606C#, 16#606B#, 16#6059#, 16#6081#, 16#608D#, 16#60E7#, 16#6083#, 16#609A#, 16#6084#, 16#609B#, 16#6096#, 16#6097#, 16#6092#, 16#60A7#, 16#608B#, 16#60E1#, 16#60B8#, 16#60E0#, 16#60D3#, 16#60B4#, 16#5FF0#, 16#60BD#, 16#60C6#, 16#60B5#, 16#60D8#, 16#614D#, 16#6115#, 16#6106#, 16#60F6#, 16#60F7#, 16#6100#, 16#60F4#, 16#60FA#, 16#6103#, 16#6121#, 16#60FB#, 16#60F1#, 16#610D#, 16#610E#, 16#6147#, 16#613E#, 16#6128#, 16#6127#, 16#614A#, 16#613F#, 16#613C#, 16#612C#, 16#6134#, 16#613D#, 16#6142#, 16#6144#, 16#6173#, 16#6177#, 16#6158#, 16#6159#, 16#615A#, 16#616B#, 16#6174#, 16#616F#, 16#6165#, 16#6171#, 16#615F#, 16#615D#, 16#6153#, 16#6175#, 16#6199#, 16#6196#, 16#6187#, 16#61AC#, 16#6194#, 16#619A#, 16#618A#, 16#6191#, 16#61AB#, 16#61AE#, 16#61CC#, 16#61CA#, 16#61C9#, 16#61F7#, 16#61C8#, 16#61C3#, 16#61C6#, 16#61BA#, 16#61CB#, 16#7F79#, 16#61CD#, 16#61E6#, 16#61E3#, 16#61F6#, 16#61FA#, 16#61F4#, 16#61FF#, 16#61FD#, 16#61FC#, 16#61FE#, 16#6200#, 16#6208#, 16#6209#, 16#620D#, 16#620C#, 16#6214#, 16#621B#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_9D : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#621E#, 16#6221#, 16#622A#, 16#622E#, 16#6230#, 16#6232#, 16#6233#, 16#6241#, 16#624E#, 16#625E#, 16#6263#, 16#625B#, 16#6260#, 16#6268#, 16#627C#, 16#6282#, 16#6289#, 16#627E#, 16#6292#, 16#6293#, 16#6296#, 16#62D4#, 16#6283#, 16#6294#, 16#62D7#, 16#62D1#, 16#62BB#, 16#62CF#, 16#62FF#, 16#62C6#, 16#64D4#, 16#62C8#, 16#62DC#, 16#62CC#, 16#62CA#, 16#62C2#, 16#62C7#, 16#629B#, 16#62C9#, 16#630C#, 16#62EE#, 16#62F1#, 16#6327#, 16#6302#, 16#6308#, 16#62EF#, 16#62F5#, 16#6350#, 16#633E#, 16#634D#, 16#641C#, 16#634F#, 16#6396#, 16#638E#, 16#6380#, 16#63AB#, 16#6376#, 16#63A3#, 16#638F#, 16#6389#, 16#639F#, 16#63B5#, 16#636B#, 16#0000#, 16#6369#, 16#63BE#, 16#63E9#, 16#63C0#, 16#63C6#, 16#63E3#, 16#63C9#, 16#63D2#, 16#63F6#, 16#63C4#, 16#6416#, 16#6434#, 16#6406#, 16#6413#, 16#6426#, 16#6436#, 16#651D#, 16#6417#, 16#6428#, 16#640F#, 16#6467#, 16#646F#, 16#6476#, 16#644E#, 16#652A#, 16#6495#, 16#6493#, 16#64A5#, 16#64A9#, 16#6488#, 16#64BC#, 16#64DA#, 16#64D2#, 16#64C5#, 16#64C7#, 16#64BB#, 16#64D8#, 16#64C2#, 16#64F1#, 16#64E7#, 16#8209#, 16#64E0#, 16#64E1#, 16#62AC#, 16#64E3#, 16#64EF#, 16#652C#, 16#64F6#, 16#64F4#, 16#64F2#, 16#64FA#, 16#6500#, 16#64FD#, 16#6518#, 16#651C#, 16#6505#, 16#6524#, 16#6523#, 16#652B#, 16#6534#, 16#6535#, 16#6537#, 16#6536#, 16#6538#, 16#754B#, 16#6548#, 16#6556#, 16#6555#, 16#654D#, 16#6558#, 16#655E#, 16#655D#, 16#6572#, 16#6578#, 16#6582#, 16#6583#, 16#8B8A#, 16#659B#, 16#659F#, 16#65AB#, 16#65B7#, 16#65C3#, 16#65C6#, 16#65C1#, 16#65C4#, 16#65CC#, 16#65D2#, 16#65DB#, 16#65D9#, 16#65E0#, 16#65E1#, 16#65F1#, 16#6772#, 16#660A#, 16#6603#, 16#65FB#, 16#6773#, 16#6635#, 16#6636#, 16#6634#, 16#661C#, 16#664F#, 16#6644#, 16#6649#, 16#6641#, 16#665E#, 16#665D#, 16#6664#, 16#6667#, 16#6668#, 16#665F#, 16#6662#, 16#6670#, 16#6683#, 16#6688#, 16#668E#, 16#6689#, 16#6684#, 16#6698#, 16#669D#, 16#66C1#, 16#66B9#, 16#66C9#, 16#66BE#, 16#66BC#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_9E : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#66C4#, 16#66B8#, 16#66D6#, 16#66DA#, 16#66E0#, 16#663F#, 16#66E6#, 16#66E9#, 16#66F0#, 16#66F5#, 16#66F7#, 16#670F#, 16#6716#, 16#671E#, 16#6726#, 16#6727#, 16#9738#, 16#672E#, 16#673F#, 16#6736#, 16#6741#, 16#6738#, 16#6737#, 16#6746#, 16#675E#, 16#6760#, 16#6759#, 16#6763#, 16#6764#, 16#6789#, 16#6770#, 16#67A9#, 16#677C#, 16#676A#, 16#678C#, 16#678B#, 16#67A6#, 16#67A1#, 16#6785#, 16#67B7#, 16#67EF#, 16#67B4#, 16#67EC#, 16#67B3#, 16#67E9#, 16#67B8#, 16#67E4#, 16#67DE#, 16#67DD#, 16#67E2#, 16#67EE#, 16#67B9#, 16#67CE#, 16#67C6#, 16#67E7#, 16#6A9C#, 16#681E#, 16#6846#, 16#6829#, 16#6840#, 16#684D#, 16#6832#, 16#684E#, 16#0000#, 16#68B3#, 16#682B#, 16#6859#, 16#6863#, 16#6877#, 16#687F#, 16#689F#, 16#688F#, 16#68AD#, 16#6894#, 16#689D#, 16#689B#, 16#6883#, 16#6AAE#, 16#68B9#, 16#6874#, 16#68B5#, 16#68A0#, 16#68BA#, 16#690F#, 16#688D#, 16#687E#, 16#6901#, 16#68CA#, 16#6908#, 16#68D8#, 16#6922#, 16#6926#, 16#68E1#, 16#690C#, 16#68CD#, 16#68D4#, 16#68E7#, 16#68D5#, 16#6936#, 16#6912#, 16#6904#, 16#68D7#, 16#68E3#, 16#6925#, 16#68F9#, 16#68E0#, 16#68EF#, 16#6928#, 16#692A#, 16#691A#, 16#6923#, 16#6921#, 16#68C6#, 16#6979#, 16#6977#, 16#695C#, 16#6978#, 16#696B#, 16#6954#, 16#697E#, 16#696E#, 16#6939#, 16#6974#, 16#693D#, 16#6959#, 16#6930#, 16#6961#, 16#695E#, 16#695D#, 16#6981#, 16#696A#, 16#69B2#, 16#69AE#, 16#69D0#, 16#69BF#, 16#69C1#, 16#69D3#, 16#69BE#, 16#69CE#, 16#5BE8#, 16#69CA#, 16#69DD#, 16#69BB#, 16#69C3#, 16#69A7#, 16#6A2E#, 16#6991#, 16#69A0#, 16#699C#, 16#6995#, 16#69B4#, 16#69DE#, 16#69E8#, 16#6A02#, 16#6A1B#, 16#69FF#, 16#6B0A#, 16#69F9#, 16#69F2#, 16#69E7#, 16#6A05#, 16#69B1#, 16#6A1E#, 16#69ED#, 16#6A14#, 16#69EB#, 16#6A0A#, 16#6A12#, 16#6AC1#, 16#6A23#, 16#6A13#, 16#6A44#, 16#6A0C#, 16#6A72#, 16#6A36#, 16#6A78#, 16#6A47#, 16#6A62#, 16#6A59#, 16#6A66#, 16#6A48#, 16#6A38#, 16#6A22#, 16#6A90#, 16#6A8D#, 16#6AA0#, 16#6A84#, 16#6AA2#, 16#6AA3#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_9F : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#6A97#, 16#8617#, 16#6ABB#, 16#6AC3#, 16#6AC2#, 16#6AB8#, 16#6AB3#, 16#6AAC#, 16#6ADE#, 16#6AD1#, 16#6ADF#, 16#6AAA#, 16#6ADA#, 16#6AEA#, 16#6AFB#, 16#6B05#, 16#8616#, 16#6AFA#, 16#6B12#, 16#6B16#, 16#9B31#, 16#6B1F#, 16#6B38#, 16#6B37#, 16#76DC#, 16#6B39#, 16#98EE#, 16#6B47#, 16#6B43#, 16#6B49#, 16#6B50#, 16#6B59#, 16#6B54#, 16#6B5B#, 16#6B5F#, 16#6B61#, 16#6B78#, 16#6B79#, 16#6B7F#, 16#6B80#, 16#6B84#, 16#6B83#, 16#6B8D#, 16#6B98#, 16#6B95#, 16#6B9E#, 16#6BA4#, 16#6BAA#, 16#6BAB#, 16#6BAF#, 16#6BB2#, 16#6BB1#, 16#6BB3#, 16#6BB7#, 16#6BBC#, 16#6BC6#, 16#6BCB#, 16#6BD3#, 16#6BDF#, 16#6BEC#, 16#6BEB#, 16#6BF3#, 16#6BEF#, 16#0000#, 16#9EBE#, 16#6C08#, 16#6C13#, 16#6C14#, 16#6C1B#, 16#6C24#, 16#6C23#, 16#6C5E#, 16#6C55#, 16#6C62#, 16#6C6A#, 16#6C82#, 16#6C8D#, 16#6C9A#, 16#6C81#, 16#6C9B#, 16#6C7E#, 16#6C68#, 16#6C73#, 16#6C92#, 16#6C90#, 16#6CC4#, 16#6CF1#, 16#6CD3#, 16#6CBD#, 16#6CD7#, 16#6CC5#, 16#6CDD#, 16#6CAE#, 16#6CB1#, 16#6CBE#, 16#6CBA#, 16#6CDB#, 16#6CEF#, 16#6CD9#, 16#6CEA#, 16#6D1F#, 16#884D#, 16#6D36#, 16#6D2B#, 16#6D3D#, 16#6D38#, 16#6D19#, 16#6D35#, 16#6D33#, 16#6D12#, 16#6D0C#, 16#6D63#, 16#6D93#, 16#6D64#, 16#6D5A#, 16#6D79#, 16#6D59#, 16#6D8E#, 16#6D95#, 16#6FE4#, 16#6D85#, 16#6DF9#, 16#6E15#, 16#6E0A#, 16#6DB5#, 16#6DC7#, 16#6DE6#, 16#6DB8#, 16#6DC6#, 16#6DEC#, 16#6DDE#, 16#6DCC#, 16#6DE8#, 16#6DD2#, 16#6DC5#, 16#6DFA#, 16#6DD9#, 16#6DE4#, 16#6DD5#, 16#6DEA#, 16#6DEE#, 16#6E2D#, 16#6E6E#, 16#6E2E#, 16#6E19#, 16#6E72#, 16#6E5F#, 16#6E3E#, 16#6E23#, 16#6E6B#, 16#6E2B#, 16#6E76#, 16#6E4D#, 16#6E1F#, 16#6E43#, 16#6E3A#, 16#6E4E#, 16#6E24#, 16#6EFF#, 16#6E1D#, 16#6E38#, 16#6E82#, 16#6EAA#, 16#6E98#, 16#6EC9#, 16#6EB7#, 16#6ED3#, 16#6EBD#, 16#6EAF#, 16#6EC4#, 16#6EB2#, 16#6ED4#, 16#6ED5#, 16#6E8F#, 16#6EA5#, 16#6EC2#, 16#6E9F#, 16#6F41#, 16#6F11#, 16#704C#, 16#6EEC#, 16#6EF8#, 16#6EFE#, 16#6F3F#, 16#6EF2#, 16#6F31#, 16#6EEF#, 16#6F32#, 16#6ECC#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_E0 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#6F3E#, 16#6F13#, 16#6EF7#, 16#6F86#, 16#6F7A#, 16#6F78#, 16#6F81#, 16#6F80#, 16#6F6F#, 16#6F5B#, 16#6FF3#, 16#6F6D#, 16#6F82#, 16#6F7C#, 16#6F58#, 16#6F8E#, 16#6F91#, 16#6FC2#, 16#6F66#, 16#6FB3#, 16#6FA3#, 16#6FA1#, 16#6FA4#, 16#6FB9#, 16#6FC6#, 16#6FAA#, 16#6FDF#, 16#6FD5#, 16#6FEC#, 16#6FD4#, 16#6FD8#, 16#6FF1#, 16#6FEE#, 16#6FDB#, 16#7009#, 16#700B#, 16#6FFA#, 16#7011#, 16#7001#, 16#700F#, 16#6FFE#, 16#701B#, 16#701A#, 16#6F74#, 16#701D#, 16#7018#, 16#701F#, 16#7030#, 16#703E#, 16#7032#, 16#7051#, 16#7063#, 16#7099#, 16#7092#, 16#70AF#, 16#70F1#, 16#70AC#, 16#70B8#, 16#70B3#, 16#70AE#, 16#70DF#, 16#70CB#, 16#70DD#, 16#0000#, 16#70D9#, 16#7109#, 16#70FD#, 16#711C#, 16#7119#, 16#7165#, 16#7155#, 16#7188#, 16#7166#, 16#7162#, 16#714C#, 16#7156#, 16#716C#, 16#718F#, 16#71FB#, 16#7184#, 16#7195#, 16#71A8#, 16#71AC#, 16#71D7#, 16#71B9#, 16#71BE#, 16#71D2#, 16#71C9#, 16#71D4#, 16#71CE#, 16#71E0#, 16#71EC#, 16#71E7#, 16#71F5#, 16#71FC#, 16#71F9#, 16#71FF#, 16#720D#, 16#7210#, 16#721B#, 16#7228#, 16#722D#, 16#722C#, 16#7230#, 16#7232#, 16#723B#, 16#723C#, 16#723F#, 16#7240#, 16#7246#, 16#724B#, 16#7258#, 16#7274#, 16#727E#, 16#7282#, 16#7281#, 16#7287#, 16#7292#, 16#7296#, 16#72A2#, 16#72A7#, 16#72B9#, 16#72B2#, 16#72C3#, 16#72C6#, 16#72C4#, 16#72CE#, 16#72D2#, 16#72E2#, 16#72E0#, 16#72E1#, 16#72F9#, 16#72F7#, 16#500F#, 16#7317#, 16#730A#, 16#731C#, 16#7316#, 16#731D#, 16#7334#, 16#732F#, 16#7329#, 16#7325#, 16#733E#, 16#734E#, 16#734F#, 16#9ED8#, 16#7357#, 16#736A#, 16#7368#, 16#7370#, 16#7378#, 16#7375#, 16#737B#, 16#737A#, 16#73C8#, 16#73B3#, 16#73CE#, 16#73BB#, 16#73C0#, 16#73E5#, 16#73EE#, 16#73DE#, 16#74A2#, 16#7405#, 16#746F#, 16#7425#, 16#73F8#, 16#7432#, 16#743A#, 16#7455#, 16#743F#, 16#745F#, 16#7459#, 16#7441#, 16#745C#, 16#7469#, 16#7470#, 16#7463#, 16#746A#, 16#7476#, 16#747E#, 16#748B#, 16#749E#, 16#74A7#, 16#74CA#, 16#74CF#, 16#74D4#, 16#73F1#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_E1 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#74E0#, 16#74E3#, 16#74E7#, 16#74E9#, 16#74EE#, 16#74F2#, 16#74F0#, 16#74F1#, 16#74F8#, 16#74F7#, 16#7504#, 16#7503#, 16#7505#, 16#750C#, 16#750E#, 16#750D#, 16#7515#, 16#7513#, 16#751E#, 16#7526#, 16#752C#, 16#753C#, 16#7544#, 16#754D#, 16#754A#, 16#7549#, 16#755B#, 16#7546#, 16#755A#, 16#7569#, 16#7564#, 16#7567#, 16#756B#, 16#756D#, 16#7578#, 16#7576#, 16#7586#, 16#7587#, 16#7574#, 16#758A#, 16#7589#, 16#7582#, 16#7594#, 16#759A#, 16#759D#, 16#75A5#, 16#75A3#, 16#75C2#, 16#75B3#, 16#75C3#, 16#75B5#, 16#75BD#, 16#75B8#, 16#75BC#, 16#75B1#, 16#75CD#, 16#75CA#, 16#75D2#, 16#75D9#, 16#75E3#, 16#75DE#, 16#75FE#, 16#75FF#, 16#0000#, 16#75FC#, 16#7601#, 16#75F0#, 16#75FA#, 16#75F2#, 16#75F3#, 16#760B#, 16#760D#, 16#7609#, 16#761F#, 16#7627#, 16#7620#, 16#7621#, 16#7622#, 16#7624#, 16#7634#, 16#7630#, 16#763B#, 16#7647#, 16#7648#, 16#7646#, 16#765C#, 16#7658#, 16#7661#, 16#7662#, 16#7668#, 16#7669#, 16#766A#, 16#7667#, 16#766C#, 16#7670#, 16#7672#, 16#7676#, 16#7678#, 16#767C#, 16#7680#, 16#7683#, 16#7688#, 16#768B#, 16#768E#, 16#7696#, 16#7693#, 16#7699#, 16#769A#, 16#76B0#, 16#76B4#, 16#76B8#, 16#76B9#, 16#76BA#, 16#76C2#, 16#76CD#, 16#76D6#, 16#76D2#, 16#76DE#, 16#76E1#, 16#76E5#, 16#76E7#, 16#76EA#, 16#862F#, 16#76FB#, 16#7708#, 16#7707#, 16#7704#, 16#7729#, 16#7724#, 16#771E#, 16#7725#, 16#7726#, 16#771B#, 16#7737#, 16#7738#, 16#7747#, 16#775A#, 16#7768#, 16#776B#, 16#775B#, 16#7765#, 16#777F#, 16#777E#, 16#7779#, 16#778E#, 16#778B#, 16#7791#, 16#77A0#, 16#779E#, 16#77B0#, 16#77B6#, 16#77B9#, 16#77BF#, 16#77BC#, 16#77BD#, 16#77BB#, 16#77C7#, 16#77CD#, 16#77D7#, 16#77DA#, 16#77DC#, 16#77E3#, 16#77EE#, 16#77FC#, 16#780C#, 16#7812#, 16#7926#, 16#7820#, 16#792A#, 16#7845#, 16#788E#, 16#7874#, 16#7886#, 16#787C#, 16#789A#, 16#788C#, 16#78A3#, 16#78B5#, 16#78AA#, 16#78AF#, 16#78D1#, 16#78C6#, 16#78CB#, 16#78D4#, 16#78BE#, 16#78BC#, 16#78C5#, 16#78CA#, 16#78EC#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_E2 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#78E7#, 16#78DA#, 16#78FD#, 16#78F4#, 16#7907#, 16#7912#, 16#7911#, 16#7919#, 16#792C#, 16#792B#, 16#7940#, 16#7960#, 16#7957#, 16#795F#, 16#795A#, 16#7955#, 16#7953#, 16#797A#, 16#797F#, 16#798A#, 16#799D#, 16#79A7#, 16#9F4B#, 16#79AA#, 16#79AE#, 16#79B3#, 16#79B9#, 16#79BA#, 16#79C9#, 16#79D5#, 16#79E7#, 16#79EC#, 16#79E1#, 16#79E3#, 16#7A08#, 16#7A0D#, 16#7A18#, 16#7A19#, 16#7A20#, 16#7A1F#, 16#7980#, 16#7A31#, 16#7A3B#, 16#7A3E#, 16#7A37#, 16#7A43#, 16#7A57#, 16#7A49#, 16#7A61#, 16#7A62#, 16#7A69#, 16#9F9D#, 16#7A70#, 16#7A79#, 16#7A7D#, 16#7A88#, 16#7A97#, 16#7A95#, 16#7A98#, 16#7A96#, 16#7AA9#, 16#7AC8#, 16#7AB0#, 16#0000#, 16#7AB6#, 16#7AC5#, 16#7AC4#, 16#7ABF#, 16#9083#, 16#7AC7#, 16#7ACA#, 16#7ACD#, 16#7ACF#, 16#7AD5#, 16#7AD3#, 16#7AD9#, 16#7ADA#, 16#7ADD#, 16#7AE1#, 16#7AE2#, 16#7AE6#, 16#7AED#, 16#7AF0#, 16#7B02#, 16#7B0F#, 16#7B0A#, 16#7B06#, 16#7B33#, 16#7B18#, 16#7B19#, 16#7B1E#, 16#7B35#, 16#7B28#, 16#7B36#, 16#7B50#, 16#7B7A#, 16#7B04#, 16#7B4D#, 16#7B0B#, 16#7B4C#, 16#7B45#, 16#7B75#, 16#7B65#, 16#7B74#, 16#7B67#, 16#7B70#, 16#7B71#, 16#7B6C#, 16#7B6E#, 16#7B9D#, 16#7B98#, 16#7B9F#, 16#7B8D#, 16#7B9C#, 16#7B9A#, 16#7B8B#, 16#7B92#, 16#7B8F#, 16#7B5D#, 16#7B99#, 16#7BCB#, 16#7BC1#, 16#7BCC#, 16#7BCF#, 16#7BB4#, 16#7BC6#, 16#7BDD#, 16#7BE9#, 16#7C11#, 16#7C14#, 16#7BE6#, 16#7BE5#, 16#7C60#, 16#7C00#, 16#7C07#, 16#7C13#, 16#7BF3#, 16#7BF7#, 16#7C17#, 16#7C0D#, 16#7BF6#, 16#7C23#, 16#7C27#, 16#7C2A#, 16#7C1F#, 16#7C37#, 16#7C2B#, 16#7C3D#, 16#7C4C#, 16#7C43#, 16#7C54#, 16#7C4F#, 16#7C40#, 16#7C50#, 16#7C58#, 16#7C5F#, 16#7C64#, 16#7C56#, 16#7C65#, 16#7C6C#, 16#7C75#, 16#7C83#, 16#7C90#, 16#7CA4#, 16#7CAD#, 16#7CA2#, 16#7CAB#, 16#7CA1#, 16#7CA8#, 16#7CB3#, 16#7CB2#, 16#7CB1#, 16#7CAE#, 16#7CB9#, 16#7CBD#, 16#7CC0#, 16#7CC5#, 16#7CC2#, 16#7CD8#, 16#7CD2#, 16#7CDC#, 16#7CE2#, 16#9B3B#, 16#7CEF#, 16#7CF2#, 16#7CF4#, 16#7CF6#, 16#7CFA#, 16#7D06#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_E3 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#7D02#, 16#7D1C#, 16#7D15#, 16#7D0A#, 16#7D45#, 16#7D4B#, 16#7D2E#, 16#7D32#, 16#7D3F#, 16#7D35#, 16#7D46#, 16#7D73#, 16#7D56#, 16#7D4E#, 16#7D72#, 16#7D68#, 16#7D6E#, 16#7D4F#, 16#7D63#, 16#7D93#, 16#7D89#, 16#7D5B#, 16#7D8F#, 16#7D7D#, 16#7D9B#, 16#7DBA#, 16#7DAE#, 16#7DA3#, 16#7DB5#, 16#7DC7#, 16#7DBD#, 16#7DAB#, 16#7E3D#, 16#7DA2#, 16#7DAF#, 16#7DDC#, 16#7DB8#, 16#7D9F#, 16#7DB0#, 16#7DD8#, 16#7DDD#, 16#7DE4#, 16#7DDE#, 16#7DFB#, 16#7DF2#, 16#7DE1#, 16#7E05#, 16#7E0A#, 16#7E23#, 16#7E21#, 16#7E12#, 16#7E31#, 16#7E1F#, 16#7E09#, 16#7E0B#, 16#7E22#, 16#7E46#, 16#7E66#, 16#7E3B#, 16#7E35#, 16#7E39#, 16#7E43#, 16#7E37#, 16#0000#, 16#7E32#, 16#7E3A#, 16#7E67#, 16#7E5D#, 16#7E56#, 16#7E5E#, 16#7E59#, 16#7E5A#, 16#7E79#, 16#7E6A#, 16#7E69#, 16#7E7C#, 16#7E7B#, 16#7E83#, 16#7DD5#, 16#7E7D#, 16#8FAE#, 16#7E7F#, 16#7E88#, 16#7E89#, 16#7E8C#, 16#7E92#, 16#7E90#, 16#7E93#, 16#7E94#, 16#7E96#, 16#7E8E#, 16#7E9B#, 16#7E9C#, 16#7F38#, 16#7F3A#, 16#7F45#, 16#7F4C#, 16#7F4D#, 16#7F4E#, 16#7F50#, 16#7F51#, 16#7F55#, 16#7F54#, 16#7F58#, 16#7F5F#, 16#7F60#, 16#7F68#, 16#7F69#, 16#7F67#, 16#7F78#, 16#7F82#, 16#7F86#, 16#7F83#, 16#7F88#, 16#7F87#, 16#7F8C#, 16#7F94#, 16#7F9E#, 16#7F9D#, 16#7F9A#, 16#7FA3#, 16#7FAF#, 16#7FB2#, 16#7FB9#, 16#7FAE#, 16#7FB6#, 16#7FB8#, 16#8B71#, 16#7FC5#, 16#7FC6#, 16#7FCA#, 16#7FD5#, 16#7FD4#, 16#7FE1#, 16#7FE6#, 16#7FE9#, 16#7FF3#, 16#7FF9#, 16#98DC#, 16#8006#, 16#8004#, 16#800B#, 16#8012#, 16#8018#, 16#8019#, 16#801C#, 16#8021#, 16#8028#, 16#803F#, 16#803B#, 16#804A#, 16#8046#, 16#8052#, 16#8058#, 16#805A#, 16#805F#, 16#8062#, 16#8068#, 16#8073#, 16#8072#, 16#8070#, 16#8076#, 16#8079#, 16#807D#, 16#807F#, 16#8084#, 16#8086#, 16#8085#, 16#809B#, 16#8093#, 16#809A#, 16#80AD#, 16#5190#, 16#80AC#, 16#80DB#, 16#80E5#, 16#80D9#, 16#80DD#, 16#80C4#, 16#80DA#, 16#80D6#, 16#8109#, 16#80EF#, 16#80F1#, 16#811B#, 16#8129#, 16#8123#, 16#812F#, 16#814B#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_E4 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#968B#, 16#8146#, 16#813E#, 16#8153#, 16#8151#, 16#80FC#, 16#8171#, 16#816E#, 16#8165#, 16#8166#, 16#8174#, 16#8183#, 16#8188#, 16#818A#, 16#8180#, 16#8182#, 16#81A0#, 16#8195#, 16#81A4#, 16#81A3#, 16#815F#, 16#8193#, 16#81A9#, 16#81B0#, 16#81B5#, 16#81BE#, 16#81B8#, 16#81BD#, 16#81C0#, 16#81C2#, 16#81BA#, 16#81C9#, 16#81CD#, 16#81D1#, 16#81D9#, 16#81D8#, 16#81C8#, 16#81DA#, 16#81DF#, 16#81E0#, 16#81E7#, 16#81FA#, 16#81FB#, 16#81FE#, 16#8201#, 16#8202#, 16#8205#, 16#8207#, 16#820A#, 16#820D#, 16#8210#, 16#8216#, 16#8229#, 16#822B#, 16#8238#, 16#8233#, 16#8240#, 16#8259#, 16#8258#, 16#825D#, 16#825A#, 16#825F#, 16#8264#, 16#0000#, 16#8262#, 16#8268#, 16#826A#, 16#826B#, 16#822E#, 16#8271#, 16#8277#, 16#8278#, 16#827E#, 16#828D#, 16#8292#, 16#82AB#, 16#829F#, 16#82BB#, 16#82AC#, 16#82E1#, 16#82E3#, 16#82DF#, 16#82D2#, 16#82F4#, 16#82F3#, 16#82FA#, 16#8393#, 16#8303#, 16#82FB#, 16#82F9#, 16#82DE#, 16#8306#, 16#82DC#, 16#8309#, 16#82D9#, 16#8335#, 16#8334#, 16#8316#, 16#8332#, 16#8331#, 16#8340#, 16#8339#, 16#8350#, 16#8345#, 16#832F#, 16#832B#, 16#8317#, 16#8318#, 16#8385#, 16#839A#, 16#83AA#, 16#839F#, 16#83A2#, 16#8396#, 16#8323#, 16#838E#, 16#8387#, 16#838A#, 16#837C#, 16#83B5#, 16#8373#, 16#8375#, 16#83A0#, 16#8389#, 16#83A8#, 16#83F4#, 16#8413#, 16#83EB#, 16#83CE#, 16#83FD#, 16#8403#, 16#83D8#, 16#840B#, 16#83C1#, 16#83F7#, 16#8407#, 16#83E0#, 16#83F2#, 16#840D#, 16#8422#, 16#8420#, 16#83BD#, 16#8438#, 16#8506#, 16#83FB#, 16#846D#, 16#842A#, 16#843C#, 16#855A#, 16#8484#, 16#8477#, 16#846B#, 16#84AD#, 16#846E#, 16#8482#, 16#8469#, 16#8446#, 16#842C#, 16#846F#, 16#8479#, 16#8435#, 16#84CA#, 16#8462#, 16#84B9#, 16#84BF#, 16#849F#, 16#84D9#, 16#84CD#, 16#84BB#, 16#84DA#, 16#84D0#, 16#84C1#, 16#84C6#, 16#84D6#, 16#84A1#, 16#8521#, 16#84FF#, 16#84F4#, 16#8517#, 16#8518#, 16#852C#, 16#851F#, 16#8515#, 16#8514#, 16#84FC#, 16#8540#, 16#8563#, 16#8558#, 16#8548#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_E5 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#8541#, 16#8602#, 16#854B#, 16#8555#, 16#8580#, 16#85A4#, 16#8588#, 16#8591#, 16#858A#, 16#85A8#, 16#856D#, 16#8594#, 16#859B#, 16#85EA#, 16#8587#, 16#859C#, 16#8577#, 16#857E#, 16#8590#, 16#85C9#, 16#85BA#, 16#85CF#, 16#85B9#, 16#85D0#, 16#85D5#, 16#85DD#, 16#85E5#, 16#85DC#, 16#85F9#, 16#860A#, 16#8613#, 16#860B#, 16#85FE#, 16#85FA#, 16#8606#, 16#8622#, 16#861A#, 16#8630#, 16#863F#, 16#864D#, 16#4E55#, 16#8654#, 16#865F#, 16#8667#, 16#8671#, 16#8693#, 16#86A3#, 16#86A9#, 16#86AA#, 16#868B#, 16#868C#, 16#86B6#, 16#86AF#, 16#86C4#, 16#86C6#, 16#86B0#, 16#86C9#, 16#8823#, 16#86AB#, 16#86D4#, 16#86DE#, 16#86E9#, 16#86EC#, 16#0000#, 16#86DF#, 16#86DB#, 16#86EF#, 16#8712#, 16#8706#, 16#8708#, 16#8700#, 16#8703#, 16#86FB#, 16#8711#, 16#8709#, 16#870D#, 16#86F9#, 16#870A#, 16#8734#, 16#873F#, 16#8737#, 16#873B#, 16#8725#, 16#8729#, 16#871A#, 16#8760#, 16#875F#, 16#8778#, 16#874C#, 16#874E#, 16#8774#, 16#8757#, 16#8768#, 16#876E#, 16#8759#, 16#8753#, 16#8763#, 16#876A#, 16#8805#, 16#87A2#, 16#879F#, 16#8782#, 16#87AF#, 16#87CB#, 16#87BD#, 16#87C0#, 16#87D0#, 16#96D6#, 16#87AB#, 16#87C4#, 16#87B3#, 16#87C7#, 16#87C6#, 16#87BB#, 16#87EF#, 16#87F2#, 16#87E0#, 16#880F#, 16#880D#, 16#87FE#, 16#87F6#, 16#87F7#, 16#880E#, 16#87D2#, 16#8811#, 16#8816#, 16#8815#, 16#8822#, 16#8821#, 16#8831#, 16#8836#, 16#8839#, 16#8827#, 16#883B#, 16#8844#, 16#8842#, 16#8852#, 16#8859#, 16#885E#, 16#8862#, 16#886B#, 16#8881#, 16#887E#, 16#889E#, 16#8875#, 16#887D#, 16#88B5#, 16#8872#, 16#8882#, 16#8897#, 16#8892#, 16#88AE#, 16#8899#, 16#88A2#, 16#888D#, 16#88A4#, 16#88B0#, 16#88BF#, 16#88B1#, 16#88C3#, 16#88C4#, 16#88D4#, 16#88D8#, 16#88D9#, 16#88DD#, 16#88F9#, 16#8902#, 16#88FC#, 16#88F4#, 16#88E8#, 16#88F2#, 16#8904#, 16#890C#, 16#890A#, 16#8913#, 16#8943#, 16#891E#, 16#8925#, 16#892A#, 16#892B#, 16#8941#, 16#8944#, 16#893B#, 16#8936#, 16#8938#, 16#894C#, 16#891D#, 16#8960#, 16#895E#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_E6 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#8966#, 16#8964#, 16#896D#, 16#896A#, 16#896F#, 16#8974#, 16#8977#, 16#897E#, 16#8983#, 16#8988#, 16#898A#, 16#8993#, 16#8998#, 16#89A1#, 16#89A9#, 16#89A6#, 16#89AC#, 16#89AF#, 16#89B2#, 16#89BA#, 16#89BD#, 16#89BF#, 16#89C0#, 16#89DA#, 16#89DC#, 16#89DD#, 16#89E7#, 16#89F4#, 16#89F8#, 16#8A03#, 16#8A16#, 16#8A10#, 16#8A0C#, 16#8A1B#, 16#8A1D#, 16#8A25#, 16#8A36#, 16#8A41#, 16#8A5B#, 16#8A52#, 16#8A46#, 16#8A48#, 16#8A7C#, 16#8A6D#, 16#8A6C#, 16#8A62#, 16#8A85#, 16#8A82#, 16#8A84#, 16#8AA8#, 16#8AA1#, 16#8A91#, 16#8AA5#, 16#8AA6#, 16#8A9A#, 16#8AA3#, 16#8AC4#, 16#8ACD#, 16#8AC2#, 16#8ADA#, 16#8AEB#, 16#8AF3#, 16#8AE7#, 16#0000#, 16#8AE4#, 16#8AF1#, 16#8B14#, 16#8AE0#, 16#8AE2#, 16#8AF7#, 16#8ADE#, 16#8ADB#, 16#8B0C#, 16#8B07#, 16#8B1A#, 16#8AE1#, 16#8B16#, 16#8B10#, 16#8B17#, 16#8B20#, 16#8B33#, 16#97AB#, 16#8B26#, 16#8B2B#, 16#8B3E#, 16#8B28#, 16#8B41#, 16#8B4C#, 16#8B4F#, 16#8B4E#, 16#8B49#, 16#8B56#, 16#8B5B#, 16#8B5A#, 16#8B6B#, 16#8B5F#, 16#8B6C#, 16#8B6F#, 16#8B74#, 16#8B7D#, 16#8B80#, 16#8B8C#, 16#8B8E#, 16#8B92#, 16#8B93#, 16#8B96#, 16#8B99#, 16#8B9A#, 16#8C3A#, 16#8C41#, 16#8C3F#, 16#8C48#, 16#8C4C#, 16#8C4E#, 16#8C50#, 16#8C55#, 16#8C62#, 16#8C6C#, 16#8C78#, 16#8C7A#, 16#8C82#, 16#8C89#, 16#8C85#, 16#8C8A#, 16#8C8D#, 16#8C8E#, 16#8C94#, 16#8C7C#, 16#8C98#, 16#621D#, 16#8CAD#, 16#8CAA#, 16#8CBD#, 16#8CB2#, 16#8CB3#, 16#8CAE#, 16#8CB6#, 16#8CC8#, 16#8CC1#, 16#8CE4#, 16#8CE3#, 16#8CDA#, 16#8CFD#, 16#8CFA#, 16#8CFB#, 16#8D04#, 16#8D05#, 16#8D0A#, 16#8D07#, 16#8D0F#, 16#8D0D#, 16#8D10#, 16#9F4E#, 16#8D13#, 16#8CCD#, 16#8D14#, 16#8D16#, 16#8D67#, 16#8D6D#, 16#8D71#, 16#8D73#, 16#8D81#, 16#8D99#, 16#8DC2#, 16#8DBE#, 16#8DBA#, 16#8DCF#, 16#8DDA#, 16#8DD6#, 16#8DCC#, 16#8DDB#, 16#8DCB#, 16#8DEA#, 16#8DEB#, 16#8DDF#, 16#8DE3#, 16#8DFC#, 16#8E08#, 16#8E09#, 16#8DFF#, 16#8E1D#, 16#8E1E#, 16#8E10#, 16#8E1F#, 16#8E42#, 16#8E35#, 16#8E30#, 16#8E34#, 16#8E4A#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_E7 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#8E47#, 16#8E49#, 16#8E4C#, 16#8E50#, 16#8E48#, 16#8E59#, 16#8E64#, 16#8E60#, 16#8E2A#, 16#8E63#, 16#8E55#, 16#8E76#, 16#8E72#, 16#8E7C#, 16#8E81#, 16#8E87#, 16#8E85#, 16#8E84#, 16#8E8B#, 16#8E8A#, 16#8E93#, 16#8E91#, 16#8E94#, 16#8E99#, 16#8EAA#, 16#8EA1#, 16#8EAC#, 16#8EB0#, 16#8EC6#, 16#8EB1#, 16#8EBE#, 16#8EC5#, 16#8EC8#, 16#8ECB#, 16#8EDB#, 16#8EE3#, 16#8EFC#, 16#8EFB#, 16#8EEB#, 16#8EFE#, 16#8F0A#, 16#8F05#, 16#8F15#, 16#8F12#, 16#8F19#, 16#8F13#, 16#8F1C#, 16#8F1F#, 16#8F1B#, 16#8F0C#, 16#8F26#, 16#8F33#, 16#8F3B#, 16#8F39#, 16#8F45#, 16#8F42#, 16#8F3E#, 16#8F4C#, 16#8F49#, 16#8F46#, 16#8F4E#, 16#8F57#, 16#8F5C#, 16#0000#, 16#8F62#, 16#8F63#, 16#8F64#, 16#8F9C#, 16#8F9F#, 16#8FA3#, 16#8FAD#, 16#8FAF#, 16#8FB7#, 16#8FDA#, 16#8FE5#, 16#8FE2#, 16#8FEA#, 16#8FEF#, 16#9087#, 16#8FF4#, 16#9005#, 16#8FF9#, 16#8FFA#, 16#9011#, 16#9015#, 16#9021#, 16#900D#, 16#901E#, 16#9016#, 16#900B#, 16#9027#, 16#9036#, 16#9035#, 16#9039#, 16#8FF8#, 16#904F#, 16#9050#, 16#9051#, 16#9052#, 16#900E#, 16#9049#, 16#903E#, 16#9056#, 16#9058#, 16#905E#, 16#9068#, 16#906F#, 16#9076#, 16#96A8#, 16#9072#, 16#9082#, 16#907D#, 16#9081#, 16#9080#, 16#908A#, 16#9089#, 16#908F#, 16#90A8#, 16#90AF#, 16#90B1#, 16#90B5#, 16#90E2#, 16#90E4#, 16#6248#, 16#90DB#, 16#9102#, 16#9112#, 16#9119#, 16#9132#, 16#9130#, 16#914A#, 16#9156#, 16#9158#, 16#9163#, 16#9165#, 16#9169#, 16#9173#, 16#9172#, 16#918B#, 16#9189#, 16#9182#, 16#91A2#, 16#91AB#, 16#91AF#, 16#91AA#, 16#91B5#, 16#91B4#, 16#91BA#, 16#91C0#, 16#91C1#, 16#91C9#, 16#91CB#, 16#91D0#, 16#91D6#, 16#91DF#, 16#91E1#, 16#91DB#, 16#91FC#, 16#91F5#, 16#91F6#, 16#921E#, 16#91FF#, 16#9214#, 16#922C#, 16#9215#, 16#9211#, 16#925E#, 16#9257#, 16#9245#, 16#9249#, 16#9264#, 16#9248#, 16#9295#, 16#923F#, 16#924B#, 16#9250#, 16#929C#, 16#9296#, 16#9293#, 16#929B#, 16#925A#, 16#92CF#, 16#92B9#, 16#92B7#, 16#92E9#, 16#930F#, 16#92FA#, 16#9344#, 16#932E#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_E8 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#9319#, 16#9322#, 16#931A#, 16#9323#, 16#933A#, 16#9335#, 16#933B#, 16#935C#, 16#9360#, 16#937C#, 16#936E#, 16#9356#, 16#93B0#, 16#93AC#, 16#93AD#, 16#9394#, 16#93B9#, 16#93D6#, 16#93D7#, 16#93E8#, 16#93E5#, 16#93D8#, 16#93C3#, 16#93DD#, 16#93D0#, 16#93C8#, 16#93E4#, 16#941A#, 16#9414#, 16#9413#, 16#9403#, 16#9407#, 16#9410#, 16#9436#, 16#942B#, 16#9435#, 16#9421#, 16#943A#, 16#9441#, 16#9452#, 16#9444#, 16#945B#, 16#9460#, 16#9462#, 16#945E#, 16#946A#, 16#9229#, 16#9470#, 16#9475#, 16#9477#, 16#947D#, 16#945A#, 16#947C#, 16#947E#, 16#9481#, 16#947F#, 16#9582#, 16#9587#, 16#958A#, 16#9594#, 16#9596#, 16#9598#, 16#9599#, 16#0000#, 16#95A0#, 16#95A8#, 16#95A7#, 16#95AD#, 16#95BC#, 16#95BB#, 16#95B9#, 16#95BE#, 16#95CA#, 16#6FF6#, 16#95C3#, 16#95CD#, 16#95CC#, 16#95D5#, 16#95D4#, 16#95D6#, 16#95DC#, 16#95E1#, 16#95E5#, 16#95E2#, 16#9621#, 16#9628#, 16#962E#, 16#962F#, 16#9642#, 16#964C#, 16#964F#, 16#964B#, 16#9677#, 16#965C#, 16#965E#, 16#965D#, 16#965F#, 16#9666#, 16#9672#, 16#966C#, 16#968D#, 16#9698#, 16#9695#, 16#9697#, 16#96AA#, 16#96A7#, 16#96B1#, 16#96B2#, 16#96B0#, 16#96B4#, 16#96B6#, 16#96B8#, 16#96B9#, 16#96CE#, 16#96CB#, 16#96C9#, 16#96CD#, 16#894D#, 16#96DC#, 16#970D#, 16#96D5#, 16#96F9#, 16#9704#, 16#9706#, 16#9708#, 16#9713#, 16#970E#, 16#9711#, 16#970F#, 16#9716#, 16#9719#, 16#9724#, 16#972A#, 16#9730#, 16#9739#, 16#973D#, 16#973E#, 16#9744#, 16#9746#, 16#9748#, 16#9742#, 16#9749#, 16#975C#, 16#9760#, 16#9764#, 16#9766#, 16#9768#, 16#52D2#, 16#976B#, 16#9771#, 16#9779#, 16#9785#, 16#977C#, 16#9781#, 16#977A#, 16#9786#, 16#978B#, 16#978F#, 16#9790#, 16#979C#, 16#97A8#, 16#97A6#, 16#97A3#, 16#97B3#, 16#97B4#, 16#97C3#, 16#97C6#, 16#97C8#, 16#97CB#, 16#97DC#, 16#97ED#, 16#9F4F#, 16#97F2#, 16#7ADF#, 16#97F6#, 16#97F5#, 16#980F#, 16#980C#, 16#9838#, 16#9824#, 16#9821#, 16#9837#, 16#983D#, 16#9846#, 16#984F#, 16#984B#, 16#986B#, 16#986F#, 16#9870#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_E9 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#9871#, 16#9874#, 16#9873#, 16#98AA#, 16#98AF#, 16#98B1#, 16#98B6#, 16#98C4#, 16#98C3#, 16#98C6#, 16#98E9#, 16#98EB#, 16#9903#, 16#9909#, 16#9912#, 16#9914#, 16#9918#, 16#9921#, 16#991D#, 16#991E#, 16#9924#, 16#9920#, 16#992C#, 16#992E#, 16#993D#, 16#993E#, 16#9942#, 16#9949#, 16#9945#, 16#9950#, 16#994B#, 16#9951#, 16#9952#, 16#994C#, 16#9955#, 16#9997#, 16#9998#, 16#99A5#, 16#99AD#, 16#99AE#, 16#99BC#, 16#99DF#, 16#99DB#, 16#99DD#, 16#99D8#, 16#99D1#, 16#99ED#, 16#99EE#, 16#99F1#, 16#99F2#, 16#99FB#, 16#99F8#, 16#9A01#, 16#9A0F#, 16#9A05#, 16#99E2#, 16#9A19#, 16#9A2B#, 16#9A37#, 16#9A45#, 16#9A42#, 16#9A40#, 16#9A43#, 16#0000#, 16#9A3E#, 16#9A55#, 16#9A4D#, 16#9A5B#, 16#9A57#, 16#9A5F#, 16#9A62#, 16#9A65#, 16#9A64#, 16#9A69#, 16#9A6B#, 16#9A6A#, 16#9AAD#, 16#9AB0#, 16#9ABC#, 16#9AC0#, 16#9ACF#, 16#9AD1#, 16#9AD3#, 16#9AD4#, 16#9ADE#, 16#9ADF#, 16#9AE2#, 16#9AE3#, 16#9AE6#, 16#9AEF#, 16#9AEB#, 16#9AEE#, 16#9AF4#, 16#9AF1#, 16#9AF7#, 16#9AFB#, 16#9B06#, 16#9B18#, 16#9B1A#, 16#9B1F#, 16#9B22#, 16#9B23#, 16#9B25#, 16#9B27#, 16#9B28#, 16#9B29#, 16#9B2A#, 16#9B2E#, 16#9B2F#, 16#9B32#, 16#9B44#, 16#9B43#, 16#9B4F#, 16#9B4D#, 16#9B4E#, 16#9B51#, 16#9B58#, 16#9B74#, 16#9B93#, 16#9B83#, 16#9B91#, 16#9B96#, 16#9B97#, 16#9B9F#, 16#9BA0#, 16#9BA8#, 16#9BB4#, 16#9BC0#, 16#9BCA#, 16#9BB9#, 16#9BC6#, 16#9BCF#, 16#9BD1#, 16#9BD2#, 16#9BE3#, 16#9BE2#, 16#9BE4#, 16#9BD4#, 16#9BE1#, 16#9C3A#, 16#9BF2#, 16#9BF1#, 16#9BF0#, 16#9C15#, 16#9C14#, 16#9C09#, 16#9C13#, 16#9C0C#, 16#9C06#, 16#9C08#, 16#9C12#, 16#9C0A#, 16#9C04#, 16#9C2E#, 16#9C1B#, 16#9C25#, 16#9C24#, 16#9C21#, 16#9C30#, 16#9C47#, 16#9C32#, 16#9C46#, 16#9C3E#, 16#9C5A#, 16#9C60#, 16#9C67#, 16#9C76#, 16#9C78#, 16#9CE7#, 16#9CEC#, 16#9CF0#, 16#9D09#, 16#9D08#, 16#9CEB#, 16#9D03#, 16#9D06#, 16#9D2A#, 16#9D26#, 16#9DAF#, 16#9D23#, 16#9D1F#, 16#9D44#, 16#9D15#, 16#9D12#, 16#9D41#, 16#9D3F#, 16#9D3E#, 16#9D46#, 16#9D48#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_EA : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#9D5D#, 16#9D5E#, 16#9D64#, 16#9D51#, 16#9D50#, 16#9D59#, 16#9D72#, 16#9D89#, 16#9D87#, 16#9DAB#, 16#9D6F#, 16#9D7A#, 16#9D9A#, 16#9DA4#, 16#9DA9#, 16#9DB2#, 16#9DC4#, 16#9DC1#, 16#9DBB#, 16#9DB8#, 16#9DBA#, 16#9DC6#, 16#9DCF#, 16#9DC2#, 16#9DD9#, 16#9DD3#, 16#9DF8#, 16#9DE6#, 16#9DED#, 16#9DEF#, 16#9DFD#, 16#9E1A#, 16#9E1B#, 16#9E1E#, 16#9E75#, 16#9E79#, 16#9E7D#, 16#9E81#, 16#9E88#, 16#9E8B#, 16#9E8C#, 16#9E92#, 16#9E95#, 16#9E91#, 16#9E9D#, 16#9EA5#, 16#9EA9#, 16#9EB8#, 16#9EAA#, 16#9EAD#, 16#9761#, 16#9ECC#, 16#9ECE#, 16#9ECF#, 16#9ED0#, 16#9ED4#, 16#9EDC#, 16#9EDE#, 16#9EDD#, 16#9EE0#, 16#9EE5#, 16#9EE8#, 16#9EEF#, 16#0000#, 16#9EF4#, 16#9EF6#, 16#9EF7#, 16#9EF9#, 16#9EFB#, 16#9EFC#, 16#9EFD#, 16#9F07#, 16#9F08#, 16#76B7#, 16#9F15#, 16#9F21#, 16#9F2C#, 16#9F3E#, 16#9F4A#, 16#9F52#, 16#9F54#, 16#9F63#, 16#9F5F#, 16#9F60#, 16#9F61#, 16#9F66#, 16#9F67#, 16#9F6C#, 16#9F6A#, 16#9F77#, 16#9F72#, 16#9F76#, 16#9F95#, 16#9F9C#, 16#9FA0#, 16#582F#, 16#69C7#, 16#9059#, 16#7464#, 16#51DC#, 16#7199#, 16#5653#, 16#5DE2#, 16#5E14#, 16#5E18#, 16#5E58#, 16#5E5E#, 16#5EBE#, 16#F928#, 16#5ECB#, 16#5EF9#, 16#5F00#, 16#5F02#, 16#5F07#, 16#5F1D#, 16#5F23#, 16#5F34#, 16#5F36#, 16#5F3D#, 16#5F40#, 16#5F45#, 16#5F54#, 16#5F58#, 16#5F64#, 16#5F67#, 16#5F7D#, 16#5F89#, 16#5F9C#, 16#5FA7#, 16#5FAF#, 16#5FB5#, 16#5FB7#, 16#5FC9#, 16#5FDE#, 16#5FE1#, 16#5FE9#, 16#600D#, 16#6014#, 16#6018#, 16#6033#, 16#6035#, 16#6047#, 16#FA3D#, 16#609D#, 16#609E#, 16#60CB#, 16#60D4#, 16#60D5#, 16#60DD#, 16#60F8#, 16#611C#, 16#612B#, 16#6130#, 16#6137#, 16#FA3E#, 16#618D#, 16#FA3F#, 16#61BC#, 16#61B9#, 16#FA40#, 16#6222#, 16#623E#, 16#6243#, 16#6256#, 16#625A#, 16#626F#, 16#6285#, 16#62C4#, 16#62D6#, 16#62FC#, 16#630A#, 16#6318#, 16#6339#, 16#6343#, 16#6365#, 16#637C#, 16#63E5#, 16#63ED#, 16#63F5#, 16#6410#, 16#6414#, 16#6422#, 16#6479#, 16#6451#, 16#6460#, 16#646D#, 16#64CE#, 16#64BE#, 16#64BF#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_EB : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#64C4#, 16#64CA#, 16#64D0#, 16#64F7#, 16#64FB#, 16#6522#, 16#6529#, 16#FA41#, 16#6567#, 16#659D#, 16#FA42#, 16#6600#, 16#6609#, 16#6615#, 16#661E#, 16#663A#, 16#6622#, 16#6624#, 16#662B#, 16#6630#, 16#6631#, 16#6633#, 16#66FB#, 16#6648#, 16#664C#, 16#02_31C4#, 16#6659#, 16#665A#, 16#6661#, 16#6665#, 16#6673#, 16#6677#, 16#6678#, 16#668D#, 16#FA43#, 16#66A0#, 16#66B2#, 16#66BB#, 16#66C6#, 16#66C8#, 16#3B22#, 16#66DB#, 16#66E8#, 16#66FA#, 16#6713#, 16#F929#, 16#6733#, 16#6766#, 16#6747#, 16#6748#, 16#677B#, 16#6781#, 16#6793#, 16#6798#, 16#679B#, 16#67BB#, 16#67F9#, 16#67C0#, 16#67D7#, 16#67FC#, 16#6801#, 16#6852#, 16#681D#, 16#0000#, 16#682C#, 16#6831#, 16#685B#, 16#6872#, 16#6875#, 16#FA44#, 16#68A3#, 16#68A5#, 16#68B2#, 16#68C8#, 16#68D0#, 16#68E8#, 16#68ED#, 16#68F0#, 16#68F1#, 16#68FC#, 16#690A#, 16#6949#, 16#02_35C4#, 16#6935#, 16#6942#, 16#6957#, 16#6963#, 16#6964#, 16#6968#, 16#6980#, 16#FA14#, 16#69A5#, 16#69AD#, 16#69CF#, 16#3BB6#, 16#3BC3#, 16#69E2#, 16#69E9#, 16#69EA#, 16#69F5#, 16#69F6#, 16#6A0F#, 16#6A15#, 16#02_373F#, 16#6A3B#, 16#6A3E#, 16#6A45#, 16#6A50#, 16#6A56#, 16#6A5B#, 16#6A6B#, 16#6A73#, 16#02_3763#, 16#6A89#, 16#6A94#, 16#6A9D#, 16#6A9E#, 16#6AA5#, 16#6AE4#, 16#6AE7#, 16#3C0F#, 16#F91D#, 16#6B1B#, 16#6B1E#, 16#6B2C#, 16#6B35#, 16#6B46#, 16#6B56#, 16#6B60#, 16#6B65#, 16#6B67#, 16#6B77#, 16#6B82#, 16#6BA9#, 16#6BAD#, 16#F970#, 16#6BCF#, 16#6BD6#, 16#6BD7#, 16#6BFF#, 16#6C05#, 16#6C10#, 16#6C33#, 16#6C59#, 16#6C5C#, 16#6CAA#, 16#6C74#, 16#6C76#, 16#6C85#, 16#6C86#, 16#6C98#, 16#6C9C#, 16#6CFB#, 16#6CC6#, 16#6CD4#, 16#6CE0#, 16#6CEB#, 16#6CEE#, 16#02_3CFE#, 16#6D04#, 16#6D0E#, 16#6D2E#, 16#6D31#, 16#6D39#, 16#6D3F#, 16#6D58#, 16#6D65#, 16#FA45#, 16#6D82#, 16#6D87#, 16#6D89#, 16#6D94#, 16#6DAA#, 16#6DAC#, 16#6DBF#, 16#6DC4#, 16#6DD6#, 16#6DDA#, 16#6DDB#, 16#6DDD#, 16#6DFC#, 16#FA46#, 16#6E34#, 16#6E44#, 16#6E5C#, 16#6E5E#, 16#6EAB#, 16#6EB1#, 16#6EC1#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_EC : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#6EC7#, 16#6ECE#, 16#6F10#, 16#6F1A#, 16#FA47#, 16#6F2A#, 16#6F2F#, 16#6F33#, 16#6F51#, 16#6F59#, 16#6F5E#, 16#6F61#, 16#6F62#, 16#6F7E#, 16#6F88#, 16#6F8C#, 16#6F8D#, 16#6F94#, 16#6FA0#, 16#6FA7#, 16#6FB6#, 16#6FBC#, 16#6FC7#, 16#6FCA#, 16#6FF9#, 16#6FF0#, 16#6FF5#, 16#7005#, 16#7006#, 16#7028#, 16#704A#, 16#705D#, 16#705E#, 16#704E#, 16#7064#, 16#7075#, 16#7085#, 16#70A4#, 16#70AB#, 16#70B7#, 16#70D4#, 16#70D8#, 16#70E4#, 16#710F#, 16#712B#, 16#711E#, 16#7120#, 16#712E#, 16#7130#, 16#7146#, 16#7147#, 16#7151#, 16#FA48#, 16#7152#, 16#715C#, 16#7160#, 16#7168#, 16#FA15#, 16#7185#, 16#7187#, 16#7192#, 16#71C1#, 16#71BA#, 16#0000#, 16#71C4#, 16#71FE#, 16#7200#, 16#7215#, 16#7255#, 16#7256#, 16#3E3F#, 16#728D#, 16#729B#, 16#72BE#, 16#72C0#, 16#72FB#, 16#02_47F1#, 16#7327#, 16#7328#, 16#FA16#, 16#7350#, 16#7366#, 16#737C#, 16#7395#, 16#739F#, 16#73A0#, 16#73A2#, 16#73A6#, 16#73AB#, 16#73C9#, 16#73CF#, 16#73D6#, 16#73D9#, 16#73E3#, 16#73E9#, 16#7407#, 16#740A#, 16#741A#, 16#741B#, 16#FA4A#, 16#7426#, 16#7428#, 16#742A#, 16#742B#, 16#742C#, 16#742E#, 16#742F#, 16#7430#, 16#7444#, 16#7446#, 16#7447#, 16#744B#, 16#7457#, 16#7462#, 16#746B#, 16#746D#, 16#7486#, 16#7487#, 16#7489#, 16#7498#, 16#749C#, 16#749F#, 16#74A3#, 16#7490#, 16#74A6#, 16#74A8#, 16#74A9#, 16#74B5#, 16#74BF#, 16#74C8#, 16#74C9#, 16#74DA#, 16#74FF#, 16#7501#, 16#7517#, 16#752F#, 16#756F#, 16#7579#, 16#7592#, 16#3F72#, 16#75CE#, 16#75E4#, 16#7600#, 16#7602#, 16#7608#, 16#7615#, 16#7616#, 16#7619#, 16#761E#, 16#762D#, 16#7635#, 16#7643#, 16#764B#, 16#7664#, 16#7665#, 16#766D#, 16#766F#, 16#7671#, 16#7681#, 16#769B#, 16#769D#, 16#769E#, 16#76A6#, 16#76AA#, 16#76B6#, 16#76C5#, 16#76CC#, 16#76CE#, 16#76D4#, 16#76E6#, 16#76F1#, 16#76FC#, 16#770A#, 16#7719#, 16#7734#, 16#7736#, 16#7746#, 16#774D#, 16#774E#, 16#775C#, 16#775F#, 16#7762#, 16#777A#, 16#7780#, 16#7794#, 16#77AA#, 16#77E0#, 16#782D#, 16#02_548E#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_ED : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#7843#, 16#784E#, 16#784F#, 16#7851#, 16#7868#, 16#786E#, 16#FA4B#, 16#78B0#, 16#02_550E#, 16#78AD#, 16#78E4#, 16#78F2#, 16#7900#, 16#78F7#, 16#791C#, 16#792E#, 16#7931#, 16#7934#, 16#FA4C#, 16#FA4D#, 16#7945#, 16#7946#, 16#FA4E#, 16#FA4F#, 16#FA50#, 16#795C#, 16#FA51#, 16#FA19#, 16#FA1A#, 16#7979#, 16#FA52#, 16#FA53#, 16#FA1B#, 16#7998#, 16#79B1#, 16#79B8#, 16#79C8#, 16#79CA#, 16#02_5771#, 16#79D4#, 16#79DE#, 16#79EB#, 16#79ED#, 16#7A03#, 16#FA54#, 16#7A39#, 16#7A5D#, 16#7A6D#, 16#FA55#, 16#7A85#, 16#7AA0#, 16#02_59C4#, 16#7AB3#, 16#7ABB#, 16#7ACE#, 16#7AEB#, 16#7AFD#, 16#7B12#, 16#7B2D#, 16#7B3B#, 16#7B47#, 16#7B4E#, 16#7B60#, 16#0000#, 16#7B6D#, 16#7B6F#, 16#7B72#, 16#7B9E#, 16#FA56#, 16#7BD7#, 16#7BD9#, 16#7C01#, 16#7C31#, 16#7C1E#, 16#7C20#, 16#7C33#, 16#7C36#, 16#4264#, 16#02_5DA1#, 16#7C59#, 16#7C6D#, 16#7C79#, 16#7C8F#, 16#7C94#, 16#7CA0#, 16#7CBC#, 16#7CD5#, 16#7CD9#, 16#7CDD#, 16#7D07#, 16#7D08#, 16#7D13#, 16#7D1D#, 16#7D23#, 16#7D31#, 16#7D41#, 16#7D48#, 16#7D53#, 16#7D5C#, 16#7D7A#, 16#7D83#, 16#7D8B#, 16#7DA0#, 16#7DA6#, 16#7DC2#, 16#7DCC#, 16#7DD6#, 16#7DE3#, 16#FA57#, 16#7E28#, 16#7E08#, 16#7E11#, 16#7E15#, 16#FA59#, 16#7E47#, 16#7E52#, 16#7E61#, 16#7E8A#, 16#7E8D#, 16#7F47#, 16#FA5A#, 16#7F91#, 16#7F97#, 16#7FBF#, 16#7FCE#, 16#7FDB#, 16#7FDF#, 16#7FEC#, 16#7FEE#, 16#7FFA#, 16#FA5B#, 16#8014#, 16#8026#, 16#8035#, 16#8037#, 16#803C#, 16#80CA#, 16#80D7#, 16#80E0#, 16#80F3#, 16#8118#, 16#814A#, 16#8160#, 16#8167#, 16#8168#, 16#816D#, 16#81BB#, 16#81CA#, 16#81CF#, 16#81D7#, 16#FA5C#, 16#4453#, 16#445B#, 16#8260#, 16#8274#, 16#02_6AFF#, 16#828E#, 16#82A1#, 16#82A3#, 16#82A4#, 16#82A9#, 16#82AE#, 16#82B7#, 16#82BE#, 16#82BF#, 16#82C6#, 16#82D5#, 16#82FD#, 16#82FE#, 16#8300#, 16#8301#, 16#8362#, 16#8322#, 16#832D#, 16#833A#, 16#8343#, 16#8347#, 16#8351#, 16#8355#, 16#837D#, 16#8386#, 16#8392#, 16#8398#, 16#83A7#, 16#83A9#, 16#83BF#, 16#83C0#, 16#83C7#, 16#83CF#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_EE : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#83D1#, 16#83E1#, 16#83EA#, 16#8401#, 16#8406#, 16#840A#, 16#FA5F#, 16#8448#, 16#845F#, 16#8470#, 16#8473#, 16#8485#, 16#849E#, 16#84AF#, 16#84B4#, 16#84BA#, 16#84C0#, 16#84C2#, 16#02_6E40#, 16#8532#, 16#851E#, 16#8523#, 16#852F#, 16#8559#, 16#8564#, 16#FA1F#, 16#85AD#, 16#857A#, 16#858C#, 16#858F#, 16#85A2#, 16#85B0#, 16#85CB#, 16#85CE#, 16#85ED#, 16#8612#, 16#85FF#, 16#8604#, 16#8605#, 16#8610#, 16#02_70F4#, 16#8618#, 16#8629#, 16#8638#, 16#8657#, 16#865B#, 16#F936#, 16#8662#, 16#459D#, 16#866C#, 16#8675#, 16#8698#, 16#86B8#, 16#86FA#, 16#86FC#, 16#86FD#, 16#870B#, 16#8771#, 16#8787#, 16#8788#, 16#87AC#, 16#87AD#, 16#87B5#, 16#0000#, 16#45EA#, 16#87D6#, 16#87EC#, 16#8806#, 16#880A#, 16#8810#, 16#8814#, 16#881F#, 16#8898#, 16#88AA#, 16#88CA#, 16#88CE#, 16#02_7684#, 16#88F5#, 16#891C#, 16#FA60#, 16#8918#, 16#8919#, 16#891A#, 16#8927#, 16#8930#, 16#8932#, 16#8939#, 16#8940#, 16#8994#, 16#FA61#, 16#89D4#, 16#89E5#, 16#89F6#, 16#8A12#, 16#8A15#, 16#8A22#, 16#8A37#, 16#8A47#, 16#8A4E#, 16#8A5D#, 16#8A61#, 16#8A75#, 16#8A79#, 16#8AA7#, 16#8AD0#, 16#8ADF#, 16#8AF4#, 16#8AF6#, 16#FA22#, 16#FA62#, 16#FA63#, 16#8B46#, 16#8B54#, 16#8B59#, 16#8B69#, 16#8B9D#, 16#8C49#, 16#8C68#, 16#FA64#, 16#8CE1#, 16#8CF4#, 16#8CF8#, 16#8CFE#, 16#FA65#, 16#8D12#, 16#8D1B#, 16#8DAF#, 16#8DCE#, 16#8DD1#, 16#8DD7#, 16#8E20#, 16#8E23#, 16#8E3D#, 16#8E70#, 16#8E7B#, 16#02_8277#, 16#8EC0#, 16#4844#, 16#8EFA#, 16#8F1E#, 16#8F2D#, 16#8F36#, 16#8F54#, 16#02_83CD#, 16#8FA6#, 16#8FB5#, 16#8FE4#, 16#8FE8#, 16#8FEE#, 16#9008#, 16#902D#, 16#FA67#, 16#9088#, 16#9095#, 16#9097#, 16#9099#, 16#909B#, 16#90A2#, 16#90B3#, 16#90BE#, 16#90C4#, 16#90C5#, 16#90C7#, 16#90D7#, 16#90DD#, 16#90DE#, 16#90EF#, 16#90F4#, 16#FA26#, 16#9114#, 16#9115#, 16#9116#, 16#9122#, 16#9123#, 16#9127#, 16#912F#, 16#9131#, 16#9134#, 16#913D#, 16#9148#, 16#915B#, 16#9183#, 16#919E#, 16#91AC#, 16#91B1#, 16#91BC#, 16#91D7#, 16#91FB#, 16#91E4#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_EF : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#91E5#, 16#91ED#, 16#91F1#, 16#9207#, 16#9210#, 16#9238#, 16#9239#, 16#923A#, 16#923C#, 16#9240#, 16#9243#, 16#924F#, 16#9278#, 16#9288#, 16#92C2#, 16#92CB#, 16#92CC#, 16#92D3#, 16#92E0#, 16#92FF#, 16#9304#, 16#931F#, 16#9321#, 16#9325#, 16#9348#, 16#9349#, 16#934A#, 16#9364#, 16#9365#, 16#936A#, 16#9370#, 16#939B#, 16#93A3#, 16#93BA#, 16#93C6#, 16#93DE#, 16#93DF#, 16#9404#, 16#93FD#, 16#9433#, 16#944A#, 16#9463#, 16#946B#, 16#9471#, 16#9472#, 16#958E#, 16#959F#, 16#95A6#, 16#95A9#, 16#95AC#, 16#95B6#, 16#95BD#, 16#95CB#, 16#95D0#, 16#95D3#, 16#49B0#, 16#95DA#, 16#95DE#, 16#9658#, 16#9684#, 16#F9DC#, 16#969D#, 16#96A4#, 16#0000#, 16#96A5#, 16#96D2#, 16#96DE#, 16#FA68#, 16#96E9#, 16#96EF#, 16#9733#, 16#973B#, 16#974D#, 16#974E#, 16#974F#, 16#975A#, 16#976E#, 16#9773#, 16#9795#, 16#97AE#, 16#97BA#, 16#97C1#, 16#97C9#, 16#97DE#, 16#97DB#, 16#97F4#, 16#FA69#, 16#980A#, 16#981E#, 16#982B#, 16#9830#, 16#FA6A#, 16#9852#, 16#9853#, 16#9856#, 16#9857#, 16#9859#, 16#985A#, 16#F9D0#, 16#9865#, 16#986C#, 16#98BA#, 16#98C8#, 16#98E7#, 16#9958#, 16#999E#, 16#9A02#, 16#9A03#, 16#9A24#, 16#9A2D#, 16#9A2E#, 16#9A38#, 16#9A4A#, 16#9A4E#, 16#9A52#, 16#9AB6#, 16#9AC1#, 16#9AC3#, 16#9ACE#, 16#9AD6#, 16#9AF9#, 16#9B02#, 16#9B08#, 16#9B20#, 16#4C17#, 16#9B2D#, 16#9B5E#, 16#9B79#, 16#9B66#, 16#9B72#, 16#9B75#, 16#9B84#, 16#9B8A#, 16#9B8F#, 16#9B9E#, 16#9BA7#, 16#9BC1#, 16#9BCE#, 16#9BE5#, 16#9BF8#, 16#9BFD#, 16#9C00#, 16#9C23#, 16#9C41#, 16#9C4F#, 16#9C50#, 16#9C53#, 16#9C63#, 16#9C65#, 16#9C77#, 16#9D1D#, 16#9D1E#, 16#9D43#, 16#9D47#, 16#9D52#, 16#9D63#, 16#9D70#, 16#9D7C#, 16#9D8A#, 16#9D96#, 16#9DC0#, 16#9DAC#, 16#9DBC#, 16#9DD7#, 16#02_A190#, 16#9DE7#, 16#9E07#, 16#9E15#, 16#9E7C#, 16#9E9E#, 16#9EA4#, 16#9EAC#, 16#9EAF#, 16#9EB4#, 16#9EB5#, 16#9EC3#, 16#9ED1#, 16#9F10#, 16#9F39#, 16#9F57#, 16#9F90#, 16#9F94#, 16#9F97#, 16#9FA2#, 16#59F8#, 16#5C5B#, 16#5E77#, 16#7626#, 16#7E6B#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_F0 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#02_0089#, 16#4E02#, 16#4E0F#, 16#4E12#, 16#4E29#, 16#4E2B#, 16#4E2E#, 16#4E40#, 16#4E47#, 16#4E48#, 16#02_00A2#, 16#4E51#, 16#3406#, 16#02_00A4#, 16#4E5A#, 16#4E69#, 16#4E9D#, 16#342C#, 16#342E#, 16#4EB9#, 16#4EBB#, 16#02_01A2#, 16#4EBC#, 16#4EC3#, 16#4EC8#, 16#4ED0#, 16#4EEB#, 16#4EDA#, 16#4EF1#, 16#4EF5#, 16#4F00#, 16#4F16#, 16#4F64#, 16#4F37#, 16#4F3E#, 16#4F54#, 16#4F58#, 16#02_0213#, 16#4F77#, 16#4F78#, 16#4F7A#, 16#4F7D#, 16#4F82#, 16#4F85#, 16#4F92#, 16#4F9A#, 16#4FE6#, 16#4FB2#, 16#4FBE#, 16#4FC5#, 16#4FCB#, 16#4FCF#, 16#4FD2#, 16#346A#, 16#4FF2#, 16#5000#, 16#5010#, 16#5013#, 16#501C#, 16#501E#, 16#5022#, 16#3468#, 16#5042#, 16#0000#, 16#5046#, 16#504E#, 16#5053#, 16#5057#, 16#5063#, 16#5066#, 16#506A#, 16#5070#, 16#50A3#, 16#5088#, 16#5092#, 16#5093#, 16#5095#, 16#5096#, 16#509C#, 16#50AA#, 16#02_032B#, 16#50B1#, 16#50BA#, 16#50BB#, 16#50C4#, 16#50C7#, 16#50F3#, 16#02_0381#, 16#50CE#, 16#02_0371#, 16#50D4#, 16#50D9#, 16#50E1#, 16#50E9#, 16#3492#, 16#5B96#, 16#5BAC#, 16#3761#, 16#5BC0#, 16#3762#, 16#5BCE#, 16#5BD6#, 16#376C#, 16#376B#, 16#5BF1#, 16#5BFD#, 16#3775#, 16#5C03#, 16#5C29#, 16#5C30#, 16#02_1C56#, 16#5C5F#, 16#5C63#, 16#5C67#, 16#5C68#, 16#5C69#, 16#5C70#, 16#02_1D2D#, 16#02_1D45#, 16#5C7C#, 16#02_1D78#, 16#02_1D62#, 16#5C88#, 16#5C8A#, 16#37C1#, 16#02_1DA1#, 16#02_1D9C#, 16#5CA0#, 16#5CA2#, 16#5CA6#, 16#5CA7#, 16#02_1D92#, 16#5CAD#, 16#5CB5#, 16#02_1DB7#, 16#5CC9#, 16#02_1DE0#, 16#02_1E33#, 16#5D06#, 16#5D10#, 16#5D2B#, 16#5D1D#, 16#5D20#, 16#5D24#, 16#5D26#, 16#5D31#, 16#5D39#, 16#5D42#, 16#37E8#, 16#5D61#, 16#5D6A#, 16#37F4#, 16#5D70#, 16#02_1F1E#, 16#37FD#, 16#5D88#, 16#3800#, 16#5D92#, 16#5D94#, 16#5D97#, 16#5D99#, 16#5DB0#, 16#5DB2#, 16#5DB4#, 16#02_1F76#, 16#5DB9#, 16#5DD1#, 16#5DD7#, 16#5DD8#, 16#5DE0#, 16#02_1FFA#, 16#5DE4#, 16#5DE9#, 16#382F#, 16#5E00#, 16#3836#, 16#5E12#, 16#5E15#, 16#3840#, 16#5E1F#, 16#5E2E#, 16#5E3E#, 16#5E49#, 16#385C#, 16#5E56#, 16#3861#, 16#5E6B#, 16#5E6C#, 16#5E6D#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_F1 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#5108#, 16#02_03F9#, 16#5117#, 16#511B#, 16#02_044A#, 16#5160#, 16#02_0509#, 16#5173#, 16#5183#, 16#518B#, 16#34BC#, 16#5198#, 16#51A3#, 16#51AD#, 16#34C7#, 16#51BC#, 16#02_05D6#, 16#02_0628#, 16#51F3#, 16#51F4#, 16#5202#, 16#5212#, 16#5216#, 16#02_074F#, 16#5255#, 16#525C#, 16#526C#, 16#5277#, 16#5284#, 16#5282#, 16#02_0807#, 16#5298#, 16#02_083A#, 16#52A4#, 16#52A6#, 16#52AF#, 16#52BA#, 16#52BB#, 16#52CA#, 16#351F#, 16#52D1#, 16#02_08B9#, 16#52F7#, 16#530A#, 16#530B#, 16#5324#, 16#5335#, 16#533E#, 16#5342#, 16#02_097C#, 16#02_099D#, 16#5367#, 16#536C#, 16#537A#, 16#53A4#, 16#53B4#, 16#02_0AD3#, 16#53B7#, 16#53C0#, 16#02_0B1D#, 16#355D#, 16#355E#, 16#53D5#, 16#0000#, 16#53DA#, 16#3563#, 16#53F4#, 16#53F5#, 16#5455#, 16#5424#, 16#5428#, 16#356E#, 16#5443#, 16#5462#, 16#5466#, 16#546C#, 16#548A#, 16#548D#, 16#5495#, 16#54A0#, 16#54A6#, 16#54AD#, 16#54AE#, 16#54B7#, 16#54BA#, 16#54BF#, 16#54C3#, 16#02_0D45#, 16#54EC#, 16#54EF#, 16#54F1#, 16#54F3#, 16#5500#, 16#5501#, 16#5509#, 16#553C#, 16#5541#, 16#35A6#, 16#5547#, 16#554A#, 16#35A8#, 16#5560#, 16#5561#, 16#5564#, 16#02_0DE1#, 16#557D#, 16#5582#, 16#5588#, 16#5591#, 16#35C5#, 16#55D2#, 16#02_0E95#, 16#02_0E6D#, 16#55BF#, 16#55C9#, 16#55CC#, 16#55D1#, 16#55DD#, 16#35DA#, 16#55E2#, 16#02_0E64#, 16#55E9#, 16#5628#, 16#02_0F5F#, 16#5607#, 16#5610#, 16#5630#, 16#5637#, 16#35F4#, 16#563D#, 16#563F#, 16#5640#, 16#5647#, 16#565E#, 16#5660#, 16#566D#, 16#3605#, 16#5688#, 16#568C#, 16#5695#, 16#569A#, 16#569D#, 16#56A8#, 16#56AD#, 16#56B2#, 16#56C5#, 16#56CD#, 16#56DF#, 16#56E8#, 16#56F6#, 16#56F7#, 16#02_1201#, 16#5715#, 16#5723#, 16#02_1255#, 16#5729#, 16#02_127B#, 16#5745#, 16#5746#, 16#574C#, 16#574D#, 16#02_1274#, 16#5768#, 16#576F#, 16#5773#, 16#5774#, 16#5775#, 16#577B#, 16#02_12E4#, 16#02_12D7#, 16#57AC#, 16#579A#, 16#579D#, 16#579E#, 16#57A8#, 16#57D7#, 16#02_12FD#, 16#57CC#, 16#02_1336#, 16#02_1344#, 16#57DE#, 16#57E6#, 16#57F0#, 16#364A#, 16#57F8#, 16#57FB#, 16#57FD#, 16#5804#, 16#581E#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_F2 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#5820#, 16#5827#, 16#5832#, 16#5839#, 16#02_13C4#, 16#5849#, 16#584C#, 16#5867#, 16#588A#, 16#588B#, 16#588D#, 16#588F#, 16#5890#, 16#5894#, 16#589D#, 16#58AA#, 16#58B1#, 16#02_146D#, 16#58C3#, 16#58CD#, 16#58E2#, 16#58F3#, 16#58F4#, 16#5905#, 16#5906#, 16#590B#, 16#590D#, 16#5914#, 16#5924#, 16#02_15D7#, 16#3691#, 16#593D#, 16#3699#, 16#5946#, 16#3696#, 16#02_6C29#, 16#595B#, 16#595F#, 16#02_1647#, 16#5975#, 16#5976#, 16#597C#, 16#599F#, 16#59AE#, 16#59BC#, 16#59C8#, 16#59CD#, 16#59DE#, 16#59E3#, 16#59E4#, 16#59E7#, 16#59EE#, 16#02_1706#, 16#02_1742#, 16#36CF#, 16#5A0C#, 16#5A0D#, 16#5A17#, 16#5A27#, 16#5A2D#, 16#5A55#, 16#5A65#, 16#5A7A#, 16#0000#, 16#5A8B#, 16#5A9C#, 16#5A9F#, 16#5AA0#, 16#5AA2#, 16#5AB1#, 16#5AB3#, 16#5AB5#, 16#5ABA#, 16#5ABF#, 16#5ADA#, 16#5ADC#, 16#5AE0#, 16#5AE5#, 16#5AF0#, 16#5AEE#, 16#5AF5#, 16#5B00#, 16#5B08#, 16#5B17#, 16#5B34#, 16#5B2D#, 16#5B4C#, 16#5B52#, 16#5B68#, 16#5B6F#, 16#5B7C#, 16#5B7F#, 16#5B81#, 16#5B84#, 16#02_19C3#, 16#5E6E#, 16#02_217B#, 16#5EA5#, 16#5EAA#, 16#5EAC#, 16#5EB9#, 16#5EBF#, 16#5EC6#, 16#5ED2#, 16#5ED9#, 16#02_231E#, 16#5EFD#, 16#5F08#, 16#5F0E#, 16#5F1C#, 16#02_23AD#, 16#5F1E#, 16#5F47#, 16#5F63#, 16#5F72#, 16#5F7E#, 16#5F8F#, 16#5FA2#, 16#5FA4#, 16#5FB8#, 16#5FC4#, 16#38FA#, 16#5FC7#, 16#5FCB#, 16#5FD2#, 16#5FD3#, 16#5FD4#, 16#5FE2#, 16#5FEE#, 16#5FEF#, 16#5FF3#, 16#5FFC#, 16#3917#, 16#6017#, 16#6022#, 16#6024#, 16#391A#, 16#604C#, 16#607F#, 16#608A#, 16#6095#, 16#60A8#, 16#02_26F3#, 16#60B0#, 16#60B1#, 16#60BE#, 16#60C8#, 16#60D9#, 16#60DB#, 16#60EE#, 16#60F2#, 16#60F5#, 16#6110#, 16#6112#, 16#6113#, 16#6119#, 16#611E#, 16#613A#, 16#396F#, 16#6141#, 16#6146#, 16#6160#, 16#617C#, 16#02_285B#, 16#6192#, 16#6193#, 16#6197#, 16#6198#, 16#61A5#, 16#61A8#, 16#61AD#, 16#02_28AB#, 16#61D5#, 16#61DD#, 16#61DF#, 16#61F5#, 16#02_298F#, 16#6215#, 16#6223#, 16#6229#, 16#6246#, 16#624C#, 16#6251#, 16#6252#, 16#6261#, 16#6264#, 16#627B#, 16#626D#, 16#6273#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_F3 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#6299#, 16#62A6#, 16#62D5#, 16#02_2AB8#, 16#62FD#, 16#6303#, 16#630D#, 16#6310#, 16#02_2B4F#, 16#02_2B50#, 16#6332#, 16#6335#, 16#633B#, 16#633C#, 16#6341#, 16#6344#, 16#634E#, 16#02_2B46#, 16#6359#, 16#02_2C1D#, 16#02_2BA6#, 16#636C#, 16#6384#, 16#6399#, 16#02_2C24#, 16#6394#, 16#63BD#, 16#63F7#, 16#63D4#, 16#63D5#, 16#63DC#, 16#63E0#, 16#63EB#, 16#63EC#, 16#63F2#, 16#6409#, 16#641E#, 16#6425#, 16#6429#, 16#642F#, 16#645A#, 16#645B#, 16#645D#, 16#6473#, 16#647D#, 16#6487#, 16#6491#, 16#649D#, 16#649F#, 16#64CB#, 16#64CC#, 16#64D5#, 16#64D7#, 16#02_2DE1#, 16#64E4#, 16#64E5#, 16#64FF#, 16#6504#, 16#3A6E#, 16#650F#, 16#6514#, 16#6516#, 16#3A73#, 16#0000#, 16#651E#, 16#6532#, 16#6544#, 16#6554#, 16#656B#, 16#657A#, 16#6581#, 16#6584#, 16#6585#, 16#658A#, 16#65B2#, 16#65B5#, 16#65B8#, 16#65BF#, 16#65C2#, 16#65C9#, 16#65D4#, 16#3AD6#, 16#65F2#, 16#65F9#, 16#65FC#, 16#6604#, 16#6608#, 16#6621#, 16#662A#, 16#6645#, 16#6651#, 16#664E#, 16#3AEA#, 16#02_31C3#, 16#6657#, 16#665B#, 16#6663#, 16#02_31F5#, 16#02_31B6#, 16#666A#, 16#666B#, 16#666C#, 16#666D#, 16#667B#, 16#6680#, 16#6690#, 16#6692#, 16#6699#, 16#3B0E#, 16#66AD#, 16#66B1#, 16#66B5#, 16#3B1A#, 16#66BF#, 16#3B1C#, 16#66EC#, 16#3AD7#, 16#6701#, 16#6705#, 16#6712#, 16#02_3372#, 16#6719#, 16#02_33D3#, 16#02_33D2#, 16#674C#, 16#674D#, 16#6754#, 16#675D#, 16#02_33D0#, 16#02_33E4#, 16#02_33D5#, 16#6774#, 16#6776#, 16#02_33DA#, 16#6792#, 16#02_33DF#, 16#8363#, 16#6810#, 16#67B0#, 16#67B2#, 16#67C3#, 16#67C8#, 16#67D2#, 16#67D9#, 16#67DB#, 16#67F0#, 16#67F7#, 16#02_344A#, 16#02_3451#, 16#02_344B#, 16#6818#, 16#681F#, 16#682D#, 16#02_3465#, 16#6833#, 16#683B#, 16#683E#, 16#6844#, 16#6845#, 16#6849#, 16#684C#, 16#6855#, 16#6857#, 16#3B77#, 16#686B#, 16#686E#, 16#687A#, 16#687C#, 16#6882#, 16#6890#, 16#6896#, 16#3B6D#, 16#6898#, 16#6899#, 16#689A#, 16#689C#, 16#68AA#, 16#68AB#, 16#68B4#, 16#68BB#, 16#68FB#, 16#02_34E4#, 16#02_355A#, 16#FA13#, 16#68C3#, 16#68C5#, 16#68CC#, 16#68CF#, 16#68D6#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_F4 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#68D9#, 16#68E4#, 16#68E5#, 16#68EC#, 16#68F7#, 16#6903#, 16#6907#, 16#3B87#, 16#3B88#, 16#02_3594#, 16#693B#, 16#3B8D#, 16#6946#, 16#6969#, 16#696C#, 16#6972#, 16#697A#, 16#697F#, 16#6992#, 16#3BA4#, 16#6996#, 16#6998#, 16#69A6#, 16#69B0#, 16#69B7#, 16#69BA#, 16#69BC#, 16#69C0#, 16#69D1#, 16#69D6#, 16#02_3639#, 16#02_3647#, 16#6A30#, 16#02_3638#, 16#02_363A#, 16#69E3#, 16#69EE#, 16#69EF#, 16#69F3#, 16#3BCD#, 16#69F4#, 16#69FE#, 16#6A11#, 16#6A1A#, 16#6A1D#, 16#02_371C#, 16#6A32#, 16#6A33#, 16#6A34#, 16#6A3F#, 16#6A46#, 16#6A49#, 16#6A7A#, 16#6A4E#, 16#6A52#, 16#6A64#, 16#02_370C#, 16#6A7E#, 16#6A83#, 16#6A8B#, 16#3BF0#, 16#6A91#, 16#6A9F#, 16#0000#, 16#6AA1#, 16#02_3764#, 16#6AAB#, 16#6ABD#, 16#6AC6#, 16#6AD4#, 16#6AD0#, 16#6ADC#, 16#6ADD#, 16#02_37FF#, 16#02_37E7#, 16#6AEC#, 16#6AF1#, 16#6AF2#, 16#6AF3#, 16#6AFD#, 16#02_3824#, 16#6B0B#, 16#6B0F#, 16#6B10#, 16#6B11#, 16#02_383D#, 16#6B17#, 16#3C26#, 16#6B2F#, 16#6B4A#, 16#6B58#, 16#6B6C#, 16#6B75#, 16#6B7A#, 16#6B81#, 16#6B9B#, 16#6BAE#, 16#02_3A98#, 16#6BBD#, 16#6BBE#, 16#6BC7#, 16#6BC8#, 16#6BC9#, 16#6BDA#, 16#6BE6#, 16#6BE7#, 16#6BEE#, 16#6BF1#, 16#6C02#, 16#6C0A#, 16#6C0E#, 16#6C35#, 16#6C36#, 16#6C3A#, 16#02_3C7F#, 16#6C3F#, 16#6C4D#, 16#6C5B#, 16#6C6D#, 16#6C84#, 16#6C89#, 16#3CC3#, 16#6C94#, 16#6C95#, 16#6C97#, 16#6CAD#, 16#6CC2#, 16#6CD0#, 16#3CD2#, 16#6CD6#, 16#6CDA#, 16#6CDC#, 16#6CE9#, 16#6CEC#, 16#6CED#, 16#02_3D00#, 16#6D00#, 16#6D0A#, 16#6D24#, 16#6D26#, 16#6D27#, 16#6C67#, 16#6D2F#, 16#6D3C#, 16#6D5B#, 16#6D5E#, 16#6D60#, 16#6D70#, 16#6D80#, 16#6D81#, 16#6D8A#, 16#6D8D#, 16#6D91#, 16#6D98#, 16#02_3D40#, 16#6E17#, 16#02_3DFA#, 16#02_3DF9#, 16#02_3DD3#, 16#6DAB#, 16#6DAE#, 16#6DB4#, 16#6DC2#, 16#6D34#, 16#6DC8#, 16#6DCE#, 16#6DCF#, 16#6DD0#, 16#6DDF#, 16#6DE9#, 16#6DF6#, 16#6E36#, 16#6E1E#, 16#6E22#, 16#6E27#, 16#3D11#, 16#6E32#, 16#6E3C#, 16#6E48#, 16#6E49#, 16#6E4B#, 16#6E4C#, 16#6E4F#, 16#6E51#, 16#6E53#, 16#6E54#, 16#6E57#, 16#6E63#, 16#3D1E#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_F5 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#6E93#, 16#6EA7#, 16#6EB4#, 16#6EBF#, 16#6EC3#, 16#6ECA#, 16#6ED9#, 16#6F35#, 16#6EEB#, 16#6EF9#, 16#6EFB#, 16#6F0A#, 16#6F0C#, 16#6F18#, 16#6F25#, 16#6F36#, 16#6F3C#, 16#02_3F7E#, 16#6F52#, 16#6F57#, 16#6F5A#, 16#6F60#, 16#6F68#, 16#6F98#, 16#6F7D#, 16#6F90#, 16#6F96#, 16#6FBE#, 16#6F9F#, 16#6FA5#, 16#6FAF#, 16#3D64#, 16#6FB5#, 16#6FC8#, 16#6FC9#, 16#6FDA#, 16#6FDE#, 16#6FE9#, 16#02_4096#, 16#6FFC#, 16#7000#, 16#7007#, 16#700A#, 16#7023#, 16#02_4103#, 16#7039#, 16#703A#, 16#703C#, 16#7043#, 16#7047#, 16#704B#, 16#3D9A#, 16#7054#, 16#7065#, 16#7069#, 16#706C#, 16#706E#, 16#7076#, 16#707E#, 16#7081#, 16#7086#, 16#7095#, 16#7097#, 16#0000#, 16#70BB#, 16#02_41C6#, 16#709F#, 16#70B1#, 16#02_41FE#, 16#70EC#, 16#70CA#, 16#70D1#, 16#70D3#, 16#70DC#, 16#7103#, 16#7104#, 16#7106#, 16#7107#, 16#7108#, 16#710C#, 16#3DC0#, 16#712F#, 16#7131#, 16#7150#, 16#714A#, 16#7153#, 16#715E#, 16#3DD4#, 16#7196#, 16#7180#, 16#719B#, 16#71A0#, 16#71A2#, 16#71AE#, 16#71AF#, 16#71B3#, 16#02_43BC#, 16#71CB#, 16#71D3#, 16#71D9#, 16#71DC#, 16#7207#, 16#3E05#, 16#FA49#, 16#722B#, 16#7234#, 16#7238#, 16#7239#, 16#4E2C#, 16#7242#, 16#7253#, 16#7257#, 16#7263#, 16#02_4629#, 16#726E#, 16#726F#, 16#7278#, 16#727F#, 16#728E#, 16#02_46A5#, 16#72AD#, 16#72AE#, 16#72B0#, 16#72B1#, 16#72C1#, 16#3E60#, 16#72CC#, 16#3E66#, 16#3E68#, 16#72F3#, 16#72FA#, 16#7307#, 16#7312#, 16#7318#, 16#7319#, 16#3E83#, 16#7339#, 16#732C#, 16#7331#, 16#7333#, 16#733D#, 16#7352#, 16#3E94#, 16#736B#, 16#736C#, 16#02_4896#, 16#736E#, 16#736F#, 16#7371#, 16#7377#, 16#7381#, 16#7385#, 16#738A#, 16#7394#, 16#7398#, 16#739C#, 16#739E#, 16#73A5#, 16#73A8#, 16#73B5#, 16#73B7#, 16#73B9#, 16#73BC#, 16#73BF#, 16#73C5#, 16#73CB#, 16#73E1#, 16#73E7#, 16#73F9#, 16#7413#, 16#73FA#, 16#7401#, 16#7424#, 16#7431#, 16#7439#, 16#7453#, 16#7440#, 16#7443#, 16#744D#, 16#7452#, 16#745D#, 16#7471#, 16#7481#, 16#7485#, 16#7488#, 16#02_4A4D#, 16#7492#, 16#7497#, 16#7499#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_F6 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#74A0#, 16#74A1#, 16#74A5#, 16#74AA#, 16#74AB#, 16#74B9#, 16#74BB#, 16#74BA#, 16#74D6#, 16#74D8#, 16#74DE#, 16#74EF#, 16#74EB#, 16#02_4B56#, 16#74FA#, 16#02_4B6F#, 16#7520#, 16#7524#, 16#752A#, 16#3F57#, 16#02_4C16#, 16#753D#, 16#753E#, 16#7540#, 16#7548#, 16#754E#, 16#7550#, 16#7552#, 16#756C#, 16#7572#, 16#7571#, 16#757A#, 16#757D#, 16#757E#, 16#7581#, 16#02_4D14#, 16#758C#, 16#3F75#, 16#75A2#, 16#3F77#, 16#75B0#, 16#75B7#, 16#75BF#, 16#75C0#, 16#75C6#, 16#75CF#, 16#75D3#, 16#75DD#, 16#75DF#, 16#75E0#, 16#75E7#, 16#75EC#, 16#75EE#, 16#75F1#, 16#75F9#, 16#7603#, 16#7618#, 16#7607#, 16#760F#, 16#3FAE#, 16#02_4E0E#, 16#7613#, 16#761B#, 16#0000#, 16#761C#, 16#02_4E37#, 16#7625#, 16#7628#, 16#763C#, 16#7633#, 16#02_4E6A#, 16#3FC9#, 16#7641#, 16#02_4E8B#, 16#7649#, 16#7655#, 16#3FD7#, 16#766E#, 16#7695#, 16#769C#, 16#76A1#, 16#76A0#, 16#76A7#, 16#76A8#, 16#76AF#, 16#02_504A#, 16#76C9#, 16#02_5055#, 16#76E8#, 16#76EC#, 16#02_5122#, 16#7717#, 16#771A#, 16#772D#, 16#7735#, 16#02_51A9#, 16#4039#, 16#02_51E5#, 16#02_51CD#, 16#7758#, 16#7760#, 16#776A#, 16#02_521E#, 16#7772#, 16#777C#, 16#777D#, 16#02_524C#, 16#4058#, 16#779A#, 16#779F#, 16#77A2#, 16#77A4#, 16#77A9#, 16#77DE#, 16#77DF#, 16#77E4#, 16#77E6#, 16#77EA#, 16#77EC#, 16#4093#, 16#77F0#, 16#77F4#, 16#77FB#, 16#02_542E#, 16#7805#, 16#7806#, 16#7809#, 16#780D#, 16#7819#, 16#7821#, 16#782C#, 16#7847#, 16#7864#, 16#786A#, 16#02_54D9#, 16#788A#, 16#7894#, 16#78A4#, 16#789D#, 16#789E#, 16#789F#, 16#78BB#, 16#78C8#, 16#78CC#, 16#78CE#, 16#78D5#, 16#78E0#, 16#78E1#, 16#78E6#, 16#78F9#, 16#78FA#, 16#78FB#, 16#78FE#, 16#02_55A7#, 16#7910#, 16#791B#, 16#7930#, 16#7925#, 16#793B#, 16#794A#, 16#7958#, 16#795B#, 16#4105#, 16#7967#, 16#7972#, 16#7994#, 16#7995#, 16#7996#, 16#799B#, 16#79A1#, 16#79A9#, 16#79B4#, 16#79BB#, 16#79C2#, 16#79C7#, 16#79CC#, 16#79CD#, 16#79D6#, 16#4148#, 16#02_57A9#, 16#02_57B4#, 16#414F#, 16#7A0A#, 16#7A11#, 16#7A15#, 16#7A1B#, 16#7A1E#, 16#4163#, 16#7A2D#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_F7 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#7A38#, 16#7A47#, 16#7A4C#, 16#7A56#, 16#7A59#, 16#7A5C#, 16#7A5F#, 16#7A60#, 16#7A67#, 16#7A6A#, 16#7A75#, 16#7A78#, 16#7A82#, 16#7A8A#, 16#7A90#, 16#7AA3#, 16#7AAC#, 16#02_59D4#, 16#41B4#, 16#7AB9#, 16#7ABC#, 16#7ABE#, 16#41BF#, 16#7ACC#, 16#7AD1#, 16#7AE7#, 16#7AE8#, 16#7AF4#, 16#02_5AE4#, 16#02_5AE3#, 16#7B07#, 16#02_5AF1#, 16#7B3D#, 16#7B27#, 16#7B2A#, 16#7B2E#, 16#7B2F#, 16#7B31#, 16#41E6#, 16#41F3#, 16#7B7F#, 16#7B41#, 16#41EE#, 16#7B55#, 16#7B79#, 16#7B64#, 16#7B66#, 16#7B69#, 16#7B73#, 16#02_5BB2#, 16#4207#, 16#7B90#, 16#7B91#, 16#7B9B#, 16#420E#, 16#7BAF#, 16#7BB5#, 16#7BBC#, 16#7BC5#, 16#7BCA#, 16#02_5C4B#, 16#02_5C64#, 16#7BD4#, 16#0000#, 16#7BD6#, 16#7BDA#, 16#7BEA#, 16#7BF0#, 16#7C03#, 16#7C0B#, 16#7C0E#, 16#7C0F#, 16#7C26#, 16#7C45#, 16#7C4A#, 16#7C51#, 16#7C57#, 16#7C5E#, 16#7C61#, 16#7C69#, 16#7C6E#, 16#7C6F#, 16#7C70#, 16#02_5E2E#, 16#02_5E56#, 16#02_5E65#, 16#7CA6#, 16#02_5E62#, 16#7CB6#, 16#7CB7#, 16#7CBF#, 16#02_5ED8#, 16#7CC4#, 16#02_5EC2#, 16#7CC8#, 16#7CCD#, 16#02_5EE8#, 16#7CD7#, 16#02_5F23#, 16#7CE6#, 16#7CEB#, 16#02_5F5C#, 16#7CF5#, 16#7D03#, 16#7D09#, 16#42C6#, 16#7D12#, 16#7D1E#, 16#02_5FE0#, 16#02_5FD4#, 16#7D3D#, 16#7D3E#, 16#7D40#, 16#7D47#, 16#02_600C#, 16#02_5FFB#, 16#42D6#, 16#7D59#, 16#7D5A#, 16#7D6A#, 16#7D70#, 16#42DD#, 16#7D7F#, 16#02_6017#, 16#7D86#, 16#7D88#, 16#7D8C#, 16#7D97#, 16#02_6060#, 16#7D9D#, 16#7DA7#, 16#7DAA#, 16#7DB6#, 16#7DB7#, 16#7DC0#, 16#7DD7#, 16#7DD9#, 16#7DE6#, 16#7DF1#, 16#7DF9#, 16#4302#, 16#02_60ED#, 16#FA58#, 16#7E10#, 16#7E17#, 16#7E1D#, 16#7E20#, 16#7E27#, 16#7E2C#, 16#7E45#, 16#7E73#, 16#7E75#, 16#7E7E#, 16#7E86#, 16#7E87#, 16#432B#, 16#7E91#, 16#7E98#, 16#7E9A#, 16#4343#, 16#7F3C#, 16#7F3B#, 16#7F3E#, 16#7F43#, 16#7F44#, 16#7F4F#, 16#34C1#, 16#02_6270#, 16#7F52#, 16#02_6286#, 16#7F61#, 16#7F63#, 16#7F64#, 16#7F6D#, 16#7F7D#, 16#7F7E#, 16#02_634C#, 16#7F90#, 16#517B#, 16#02_3D0E#, 16#7F96#, 16#7F9C#, 16#7FAD#, 16#02_6402#, 16#7FC3#, 16#7FCF#, 16#7FE3#, 16#7FE5#, 16#7FEF#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_F8 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#7FF2#, 16#8002#, 16#800A#, 16#8008#, 16#800E#, 16#8011#, 16#8016#, 16#8024#, 16#802C#, 16#8030#, 16#8043#, 16#8066#, 16#8071#, 16#8075#, 16#807B#, 16#8099#, 16#809C#, 16#80A4#, 16#80A7#, 16#80B8#, 16#02_667E#, 16#80C5#, 16#80D5#, 16#80D8#, 16#80E6#, 16#02_66B0#, 16#810D#, 16#80F5#, 16#80FB#, 16#43EE#, 16#8135#, 16#8116#, 16#811E#, 16#43F0#, 16#8124#, 16#8127#, 16#812C#, 16#02_671D#, 16#813D#, 16#4408#, 16#8169#, 16#4417#, 16#8181#, 16#441C#, 16#8184#, 16#8185#, 16#4422#, 16#8198#, 16#81B2#, 16#81C1#, 16#81C3#, 16#81D6#, 16#81DB#, 16#02_68DD#, 16#81E4#, 16#02_68EA#, 16#81EC#, 16#02_6951#, 16#81FD#, 16#81FF#, 16#02_696F#, 16#8204#, 16#02_69DD#, 16#0000#, 16#8219#, 16#8221#, 16#8222#, 16#02_6A1E#, 16#8232#, 16#8234#, 16#823C#, 16#8246#, 16#8249#, 16#8245#, 16#02_6A58#, 16#824B#, 16#4476#, 16#824F#, 16#447A#, 16#8257#, 16#02_6A8C#, 16#825C#, 16#8263#, 16#02_6AB7#, 16#FA5D#, 16#FA5E#, 16#8279#, 16#4491#, 16#827D#, 16#827F#, 16#8283#, 16#828A#, 16#8293#, 16#82A7#, 16#82A8#, 16#82B2#, 16#82B4#, 16#82BA#, 16#82BC#, 16#82E2#, 16#82E8#, 16#82F7#, 16#8307#, 16#8308#, 16#830C#, 16#8354#, 16#831B#, 16#831D#, 16#8330#, 16#833C#, 16#8344#, 16#8357#, 16#44BE#, 16#837F#, 16#44D4#, 16#44B3#, 16#838D#, 16#8394#, 16#8395#, 16#839B#, 16#839D#, 16#83C9#, 16#83D0#, 16#83D4#, 16#83DD#, 16#83E5#, 16#83F9#, 16#840F#, 16#8411#, 16#8415#, 16#02_6C73#, 16#8417#, 16#8439#, 16#844A#, 16#844F#, 16#8451#, 16#8452#, 16#8459#, 16#845A#, 16#845C#, 16#02_6CDD#, 16#8465#, 16#8476#, 16#8478#, 16#847C#, 16#8481#, 16#450D#, 16#84DC#, 16#8497#, 16#84A6#, 16#84BE#, 16#4508#, 16#84CE#, 16#84CF#, 16#84D3#, 16#02_6E65#, 16#84E7#, 16#84EA#, 16#84EF#, 16#84F0#, 16#84F1#, 16#84FA#, 16#84FD#, 16#850C#, 16#851B#, 16#8524#, 16#8525#, 16#852B#, 16#8534#, 16#854F#, 16#856F#, 16#4525#, 16#4543#, 16#853E#, 16#8551#, 16#8553#, 16#855E#, 16#8561#, 16#8562#, 16#02_6F94#, 16#857B#, 16#857D#, 16#857F#, 16#8581#, 16#8586#, 16#8593#, 16#859D#, 16#859F#, 16#02_6FF8#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_F9 : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#02_6FF6#, 16#02_6FF7#, 16#85B7#, 16#85BC#, 16#85C7#, 16#85CA#, 16#85D8#, 16#85D9#, 16#85DF#, 16#85E1#, 16#85E6#, 16#85F6#, 16#8600#, 16#8611#, 16#861E#, 16#8621#, 16#8624#, 16#8627#, 16#02_710D#, 16#8639#, 16#863C#, 16#02_7139#, 16#8640#, 16#FA20#, 16#8653#, 16#8656#, 16#866F#, 16#8677#, 16#867A#, 16#8687#, 16#8689#, 16#868D#, 16#8691#, 16#869C#, 16#869D#, 16#86A8#, 16#FA21#, 16#86B1#, 16#86B3#, 16#86C1#, 16#86C3#, 16#86D1#, 16#86D5#, 16#86D7#, 16#86E3#, 16#86E6#, 16#45B8#, 16#8705#, 16#8707#, 16#870E#, 16#8710#, 16#8713#, 16#8719#, 16#871F#, 16#8721#, 16#8723#, 16#8731#, 16#873A#, 16#873E#, 16#8740#, 16#8743#, 16#8751#, 16#8758#, 16#0000#, 16#8764#, 16#8765#, 16#8772#, 16#877C#, 16#02_73DB#, 16#02_73DA#, 16#87A7#, 16#8789#, 16#878B#, 16#8793#, 16#87A0#, 16#02_73FE#, 16#45E5#, 16#87BE#, 16#02_7410#, 16#87C1#, 16#87CE#, 16#87F5#, 16#87DF#, 16#02_7449#, 16#87E3#, 16#87E5#, 16#87E6#, 16#87EA#, 16#87EB#, 16#87ED#, 16#8801#, 16#8803#, 16#880B#, 16#8813#, 16#8828#, 16#882E#, 16#8832#, 16#883C#, 16#460F#, 16#884A#, 16#8858#, 16#885F#, 16#8864#, 16#02_7615#, 16#02_7614#, 16#8869#, 16#02_7631#, 16#886F#, 16#88A0#, 16#88BC#, 16#88BD#, 16#88BE#, 16#88C0#, 16#88D2#, 16#02_7693#, 16#88D1#, 16#88D3#, 16#88DB#, 16#88F0#, 16#88F1#, 16#4641#, 16#8901#, 16#02_770E#, 16#8937#, 16#02_7723#, 16#8942#, 16#8945#, 16#8949#, 16#02_7752#, 16#4665#, 16#8962#, 16#8980#, 16#8989#, 16#8990#, 16#899F#, 16#89B0#, 16#89B7#, 16#89D6#, 16#89D8#, 16#89EB#, 16#46A1#, 16#89F1#, 16#89F3#, 16#89FD#, 16#89FF#, 16#46AF#, 16#8A11#, 16#8A14#, 16#02_7985#, 16#8A21#, 16#8A35#, 16#8A3E#, 16#8A45#, 16#8A4D#, 16#8A58#, 16#8AAE#, 16#8A90#, 16#8AB7#, 16#8ABE#, 16#8AD7#, 16#8AFC#, 16#02_7A84#, 16#8B0A#, 16#8B05#, 16#8B0D#, 16#8B1C#, 16#8B1F#, 16#8B2D#, 16#8B43#, 16#470C#, 16#8B51#, 16#8B5E#, 16#8B76#, 16#8B7F#, 16#8B81#, 16#8B8B#, 16#8B94#, 16#8B95#, 16#8B9C#, 16#8B9E#, 16#8C39#, 16#02_7BB3#, 16#8C3D#, 16#02_7BBE#, 16#02_7BC7#, 16#8C45#, 16#8C47#, 16#8C4F#, 16#8C54#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_FA : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#8C57#, 16#8C69#, 16#8C6D#, 16#8C73#, 16#02_7CB8#, 16#8C93#, 16#8C92#, 16#8C99#, 16#4764#, 16#8C9B#, 16#8CA4#, 16#8CD6#, 16#8CD5#, 16#8CD9#, 16#02_7DA0#, 16#8CF0#, 16#8CF1#, 16#02_7E10#, 16#8D09#, 16#8D0E#, 16#8D6C#, 16#8D84#, 16#8D95#, 16#8DA6#, 16#02_7FB7#, 16#8DC6#, 16#8DC8#, 16#8DD9#, 16#8DEC#, 16#8E0C#, 16#47FD#, 16#8DFD#, 16#8E06#, 16#02_808A#, 16#8E14#, 16#8E16#, 16#8E21#, 16#8E22#, 16#8E27#, 16#02_80BB#, 16#4816#, 16#8E36#, 16#8E39#, 16#8E4B#, 16#8E54#, 16#8E62#, 16#8E6C#, 16#8E6D#, 16#8E6F#, 16#8E98#, 16#8E9E#, 16#8EAE#, 16#8EB3#, 16#8EB5#, 16#8EB6#, 16#8EBB#, 16#02_8282#, 16#8ED1#, 16#8ED4#, 16#484E#, 16#8EF9#, 16#02_82F3#, 16#8F00#, 16#0000#, 16#8F08#, 16#8F17#, 16#8F2B#, 16#8F40#, 16#8F4A#, 16#8F58#, 16#02_840C#, 16#8FA4#, 16#8FB4#, 16#FA66#, 16#8FB6#, 16#02_8455#, 16#8FC1#, 16#8FC6#, 16#FA24#, 16#8FCA#, 16#8FCD#, 16#8FD3#, 16#8FD5#, 16#8FE0#, 16#8FF1#, 16#8FF5#, 16#8FFB#, 16#9002#, 16#900C#, 16#9037#, 16#02_856B#, 16#9043#, 16#9044#, 16#905D#, 16#02_85C8#, 16#02_85C9#, 16#9085#, 16#908C#, 16#9090#, 16#961D#, 16#90A1#, 16#48B5#, 16#90B0#, 16#90B6#, 16#90C3#, 16#90C8#, 16#02_86D7#, 16#90DC#, 16#90DF#, 16#02_86FA#, 16#90F6#, 16#90F2#, 16#9100#, 16#90EB#, 16#90FE#, 16#90FF#, 16#9104#, 16#9106#, 16#9118#, 16#911C#, 16#911E#, 16#9137#, 16#9139#, 16#913A#, 16#9146#, 16#9147#, 16#9157#, 16#9159#, 16#9161#, 16#9164#, 16#9174#, 16#9179#, 16#9185#, 16#918E#, 16#91A8#, 16#91AE#, 16#91B3#, 16#91B6#, 16#91C3#, 16#91C4#, 16#91DA#, 16#02_8949#, 16#02_8946#, 16#91EC#, 16#91EE#, 16#9201#, 16#920A#, 16#9216#, 16#9217#, 16#02_896B#, 16#9233#, 16#9242#, 16#9247#, 16#924A#, 16#924E#, 16#9251#, 16#9256#, 16#9259#, 16#9260#, 16#9261#, 16#9265#, 16#9267#, 16#9268#, 16#02_8987#, 16#02_8988#, 16#927C#, 16#927D#, 16#927F#, 16#9289#, 16#928D#, 16#9297#, 16#9299#, 16#929F#, 16#92A7#, 16#92AB#, 16#02_89BA#, 16#02_89BB#, 16#92B2#, 16#92BF#, 16#92C0#, 16#92C6#, 16#92CE#, 16#92D0#, 16#92D7#, 16#92D9#, 16#92E5#, 16#92E7#, 16#9311#, 16#02_8A1E#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_FB : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#02_8A29#, 16#92F7#, 16#92F9#, 16#92FB#, 16#9302#, 16#930D#, 16#9315#, 16#931D#, 16#931E#, 16#9327#, 16#9329#, 16#02_8A71#, 16#02_8A43#, 16#9347#, 16#9351#, 16#9357#, 16#935A#, 16#936B#, 16#9371#, 16#9373#, 16#93A1#, 16#02_8A99#, 16#02_8ACD#, 16#9388#, 16#938B#, 16#938F#, 16#939E#, 16#93F5#, 16#02_8AE4#, 16#02_8ADD#, 16#93F1#, 16#93C1#, 16#93C7#, 16#93DC#, 16#93E2#, 16#93E7#, 16#9409#, 16#940F#, 16#9416#, 16#9417#, 16#93FB#, 16#9432#, 16#9434#, 16#943B#, 16#9445#, 16#02_8BC1#, 16#02_8BEF#, 16#946D#, 16#946F#, 16#9578#, 16#9579#, 16#9586#, 16#958C#, 16#958D#, 16#02_8D10#, 16#95AB#, 16#95B4#, 16#02_8D71#, 16#95C8#, 16#02_8DFB#, 16#02_8E1F#, 16#962C#, 16#9633#, 16#0000#, 16#9634#, 16#02_8E36#, 16#963C#, 16#9641#, 16#9661#, 16#02_8E89#, 16#9682#, 16#02_8EEB#, 16#969A#, 16#02_8F32#, 16#49E7#, 16#96A9#, 16#96AF#, 16#96B3#, 16#96BA#, 16#96BD#, 16#49FA#, 16#02_8FF8#, 16#96D8#, 16#96DA#, 16#96DD#, 16#4A04#, 16#9714#, 16#9723#, 16#4A29#, 16#9736#, 16#9741#, 16#9747#, 16#9755#, 16#9757#, 16#975B#, 16#976A#, 16#02_92A0#, 16#02_92B1#, 16#9796#, 16#979A#, 16#979E#, 16#97A2#, 16#97B1#, 16#97B2#, 16#97BE#, 16#97CC#, 16#97D1#, 16#97D4#, 16#97D8#, 16#97D9#, 16#97E1#, 16#97F1#, 16#9804#, 16#980D#, 16#980E#, 16#9814#, 16#9816#, 16#4ABC#, 16#02_9490#, 16#9823#, 16#9832#, 16#9833#, 16#9825#, 16#9847#, 16#9866#, 16#98AB#, 16#98AD#, 16#98B0#, 16#02_95CF#, 16#98B7#, 16#98B8#, 16#98BB#, 16#98BC#, 16#98BF#, 16#98C2#, 16#98C7#, 16#98CB#, 16#98E0#, 16#02_967F#, 16#98E1#, 16#98E3#, 16#98E5#, 16#98EA#, 16#98F0#, 16#98F1#, 16#98F3#, 16#9908#, 16#4B3B#, 16#02_96F0#, 16#9916#, 16#9917#, 16#02_9719#, 16#991A#, 16#991B#, 16#991C#, 16#02_9750#, 16#9931#, 16#9932#, 16#9933#, 16#993A#, 16#993B#, 16#993C#, 16#9940#, 16#9941#, 16#9946#, 16#994D#, 16#994E#, 16#995C#, 16#995F#, 16#9960#, 16#99A3#, 16#99A6#, 16#99B9#, 16#99BD#, 16#99BF#, 16#99C3#, 16#99C9#, 16#99D4#, 16#99D9#, 16#99DE#, 16#02_98C6#, 16#99F0#, 16#99F9#, 16#99FC#, 16#9A0A#, 16#9A11#, 16#9A16#, 16#9A1A#, 16#9A20#, 16#0000#, 16#0000#, 16#0000#); Decode_Double_FC : aliased constant SHIFTJIS_Code_Point_Array := (16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#9A31#, 16#9A36#, 16#9A44#, 16#9A4C#, 16#9A58#, 16#4BC2#, 16#9AAF#, 16#4BCA#, 16#9AB7#, 16#4BD2#, 16#9AB9#, 16#02_9A72#, 16#9AC6#, 16#9AD0#, 16#9AD2#, 16#9AD5#, 16#4BE8#, 16#9ADC#, 16#9AE0#, 16#9AE5#, 16#9AE9#, 16#9B03#, 16#9B0C#, 16#9B10#, 16#9B12#, 16#9B16#, 16#9B1C#, 16#9B2B#, 16#9B33#, 16#9B3D#, 16#4C20#, 16#9B4B#, 16#9B63#, 16#9B65#, 16#9B6B#, 16#9B6C#, 16#9B73#, 16#9B76#, 16#9B77#, 16#9BA6#, 16#9BAC#, 16#9BB1#, 16#02_9DDB#, 16#02_9E3D#, 16#9BB2#, 16#9BB8#, 16#9BBE#, 16#9BC7#, 16#9BF3#, 16#9BD8#, 16#9BDD#, 16#9BE7#, 16#9BEA#, 16#9BEB#, 16#9BEF#, 16#9BEE#, 16#02_9E15#, 16#9BFA#, 16#02_9E8A#, 16#9BF7#, 16#02_9E49#, 16#9C16#, 16#9C18#, 16#0000#, 16#9C19#, 16#9C1A#, 16#9C1D#, 16#9C22#, 16#9C27#, 16#9C29#, 16#9C2A#, 16#02_9EC4#, 16#9C31#, 16#9C36#, 16#9C37#, 16#9C45#, 16#9C5C#, 16#02_9EE9#, 16#9C49#, 16#9C4A#, 16#02_9EDB#, 16#9C54#, 16#9C58#, 16#9C5B#, 16#9C5D#, 16#9C5F#, 16#9C69#, 16#9C6A#, 16#9C6B#, 16#9C6D#, 16#9C6E#, 16#9C70#, 16#9C72#, 16#9C75#, 16#9C7A#, 16#9CE6#, 16#9CF2#, 16#9D0B#, 16#9D02#, 16#02_9FCE#, 16#9D11#, 16#9D17#, 16#9D18#, 16#02_A02F#, 16#4CC4#, 16#02_A01A#, 16#9D32#, 16#4CD1#, 16#9D42#, 16#9D4A#, 16#9D5F#, 16#9D62#, 16#02_A0F9#, 16#9D69#, 16#9D6B#, 16#02_A082#, 16#9D73#, 16#9D76#, 16#9D77#, 16#9D7E#, 16#9D84#, 16#9D8D#, 16#9D99#, 16#9DA1#, 16#9DBF#, 16#9DB5#, 16#9DB9#, 16#9DBD#, 16#9DC3#, 16#9DC7#, 16#9DC9#, 16#9DD6#, 16#9DDA#, 16#9DDF#, 16#9DE0#, 16#9DE3#, 16#9DF4#, 16#4D07#, 16#9E0A#, 16#9E02#, 16#9E0D#, 16#9E19#, 16#9E1C#, 16#9E1D#, 16#9E7B#, 16#02_2218#, 16#9E80#, 16#9E85#, 16#9E9B#, 16#9EA8#, 16#02_A38C#, 16#9EBD#, 16#02_A437#, 16#9EDF#, 16#9EE7#, 16#9EEE#, 16#9EFF#, 16#9F02#, 16#4D77#, 16#9F03#, 16#9F17#, 16#9F19#, 16#9F2F#, 16#9F37#, 16#9F3A#, 16#9F3D#, 16#9F41#, 16#9F45#, 16#9F46#, 16#9F53#, 16#9F55#, 16#9F58#, 16#02_A5F1#, 16#9F5D#, 16#02_A602#, 16#9F69#, 16#02_A61A#, 16#9F6D#, 16#9F70#, 16#9F75#, 16#02_A6B2#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#, 16#0000#); Decode_Double : constant array (Ada.Streams.Stream_Element) of not null SHIFTJIS_Code_Point_Array_Access := (Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_81'Access, Decode_Double_82'Access, Decode_Double_83'Access, Decode_Double_84'Access, Decode_Double_85'Access, Decode_Double_86'Access, Decode_Double_87'Access, Decode_Double_88'Access, Decode_Double_89'Access, Decode_Double_8A'Access, Decode_Double_8B'Access, Decode_Double_8C'Access, Decode_Double_8D'Access, Decode_Double_8E'Access, Decode_Double_8F'Access, Decode_Double_90'Access, Decode_Double_91'Access, Decode_Double_92'Access, Decode_Double_93'Access, Decode_Double_94'Access, Decode_Double_95'Access, Decode_Double_96'Access, Decode_Double_97'Access, Decode_Double_98'Access, Decode_Double_99'Access, Decode_Double_9A'Access, Decode_Double_9B'Access, Decode_Double_9C'Access, Decode_Double_9D'Access, Decode_Double_9E'Access, Decode_Double_9F'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_E0'Access, Decode_Double_E1'Access, Decode_Double_E2'Access, Decode_Double_E3'Access, Decode_Double_E4'Access, Decode_Double_E5'Access, Decode_Double_E6'Access, Decode_Double_E7'Access, Decode_Double_E8'Access, Decode_Double_E9'Access, Decode_Double_EA'Access, Decode_Double_EB'Access, Decode_Double_EC'Access, Decode_Double_ED'Access, Decode_Double_EE'Access, Decode_Double_EF'Access, Decode_Double_F0'Access, Decode_Double_F1'Access, Decode_Double_F2'Access, Decode_Double_F3'Access, Decode_Double_F4'Access, Decode_Double_F5'Access, Decode_Double_F6'Access, Decode_Double_F7'Access, Decode_Double_F8'Access, Decode_Double_F9'Access, Decode_Double_FA'Access, Decode_Double_FB'Access, Decode_Double_FC'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access, Decode_Double_Invalid'Access); Expansion : constant array (Matreshka.Internals.Unicode.Code_Unit_32 range 1 .. 25) of SHIFTJIS_Expansion_Pair := ((16#304B#, 16#309A#), (16#304D#, 16#309A#), (16#304F#, 16#309A#), (16#3051#, 16#309A#), (16#3053#, 16#309A#), (16#30AB#, 16#309A#), (16#30AD#, 16#309A#), (16#30AF#, 16#309A#), (16#30B1#, 16#309A#), (16#30B3#, 16#309A#), (16#30BB#, 16#309A#), (16#30C4#, 16#309A#), (16#30C8#, 16#309A#), (16#31F7#, 16#309A#), (16#00E6#, 16#0300#), (16#0254#, 16#0300#), (16#0254#, 16#0301#), (16#028C#, 16#0300#), (16#028C#, 16#0301#), (16#0259#, 16#0300#), (16#0259#, 16#0301#), (16#025A#, 16#0300#), (16#025A#, 16#0301#), (16#02E9#, 16#02E5#), (16#02E5#, 16#02E9#)); end Matreshka.Internals.Text_Codecs.SHIFTJIS.Tables;
-- This spec has been automatically generated from STM32F0xx.svd pragma Restrictions (No_Elaboration_Code); pragma Ada_2012; pragma Style_Checks (Off); with System; package STM32_SVD.CEC is pragma Preelaborate; --------------- -- Registers -- --------------- subtype CR_CECEN_Field is STM32_SVD.Bit; subtype CR_TXSOM_Field is STM32_SVD.Bit; subtype CR_TXEOM_Field is STM32_SVD.Bit; -- control register type CR_Register is record -- CEC Enable CECEN : CR_CECEN_Field := 16#0#; -- Tx start of message TXSOM : CR_TXSOM_Field := 16#0#; -- Tx End Of Message TXEOM : CR_TXEOM_Field := 16#0#; -- unspecified Reserved_3_31 : STM32_SVD.UInt29 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for CR_Register use record CECEN at 0 range 0 .. 0; TXSOM at 0 range 1 .. 1; TXEOM at 0 range 2 .. 2; Reserved_3_31 at 0 range 3 .. 31; end record; subtype CFGR_OAR_Field is STM32_SVD.UInt4; subtype CFGR_LSTN_Field is STM32_SVD.Bit; subtype CFGR_SFT_Field is STM32_SVD.UInt3; subtype CFGR_RXTOL_Field is STM32_SVD.Bit; subtype CFGR_BRESTP_Field is STM32_SVD.Bit; subtype CFGR_BREGEN_Field is STM32_SVD.Bit; subtype CFGR_LBPEGEN_Field is STM32_SVD.Bit; -- configuration register type CFGR_Register is record -- Own Address OAR : CFGR_OAR_Field := 16#0#; -- Listen mode LSTN : CFGR_LSTN_Field := 16#0#; -- Signal Free Time SFT : CFGR_SFT_Field := 16#0#; -- Rx-Tolerance RXTOL : CFGR_RXTOL_Field := 16#0#; -- Rx-stop on bit rising error BRESTP : CFGR_BRESTP_Field := 16#0#; -- Generate error-bit on bit rising error BREGEN : CFGR_BREGEN_Field := 16#0#; -- Generate Error-Bit on Long Bit Period Error LBPEGEN : CFGR_LBPEGEN_Field := 16#0#; -- unspecified Reserved_12_31 : STM32_SVD.UInt20 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for CFGR_Register use record OAR at 0 range 0 .. 3; LSTN at 0 range 4 .. 4; SFT at 0 range 5 .. 7; RXTOL at 0 range 8 .. 8; BRESTP at 0 range 9 .. 9; BREGEN at 0 range 10 .. 10; LBPEGEN at 0 range 11 .. 11; Reserved_12_31 at 0 range 12 .. 31; end record; subtype TXDR_TXD_Field is STM32_SVD.Byte; -- Tx data register type TXDR_Register is record -- Write-only. Tx Data register TXD : TXDR_TXD_Field := 16#0#; -- unspecified Reserved_8_31 : STM32_SVD.UInt24 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for TXDR_Register use record TXD at 0 range 0 .. 7; Reserved_8_31 at 0 range 8 .. 31; end record; subtype RXDR_RXDR_Field is STM32_SVD.Byte; -- Rx Data Register type RXDR_Register is record -- Read-only. CEC Rx Data Register RXDR : RXDR_RXDR_Field; -- unspecified Reserved_8_31 : STM32_SVD.UInt24; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for RXDR_Register use record RXDR at 0 range 0 .. 7; Reserved_8_31 at 0 range 8 .. 31; end record; subtype ISR_RXBR_Field is STM32_SVD.Bit; subtype ISR_RXEND_Field is STM32_SVD.Bit; subtype ISR_RXOVR_Field is STM32_SVD.Bit; subtype ISR_BRE_Field is STM32_SVD.Bit; subtype ISR_SBPE_Field is STM32_SVD.Bit; subtype ISR_LBPE_Field is STM32_SVD.Bit; subtype ISR_RXACKE_Field is STM32_SVD.Bit; subtype ISR_ARBLST_Field is STM32_SVD.Bit; subtype ISR_TXBR_Field is STM32_SVD.Bit; subtype ISR_TXEND_Field is STM32_SVD.Bit; subtype ISR_TXUDR_Field is STM32_SVD.Bit; subtype ISR_TXERR_Field is STM32_SVD.Bit; subtype ISR_TXACKE_Field is STM32_SVD.Bit; -- Interrupt and Status Register type ISR_Register is record -- Rx-Byte Received RXBR : ISR_RXBR_Field := 16#0#; -- End Of Reception RXEND : ISR_RXEND_Field := 16#0#; -- Rx-Overrun RXOVR : ISR_RXOVR_Field := 16#0#; -- Rx-Bit rising error BRE : ISR_BRE_Field := 16#0#; -- Rx-Short Bit period error SBPE : ISR_SBPE_Field := 16#0#; -- Rx-Long Bit Period Error LBPE : ISR_LBPE_Field := 16#0#; -- Rx-Missing Acknowledge RXACKE : ISR_RXACKE_Field := 16#0#; -- Arbitration Lost ARBLST : ISR_ARBLST_Field := 16#0#; -- Tx-Byte Request TXBR : ISR_TXBR_Field := 16#0#; -- End of Transmission TXEND : ISR_TXEND_Field := 16#0#; -- Tx-Buffer Underrun TXUDR : ISR_TXUDR_Field := 16#0#; -- Tx-Error TXERR : ISR_TXERR_Field := 16#0#; -- Tx-Missing acknowledge error TXACKE : ISR_TXACKE_Field := 16#0#; -- unspecified Reserved_13_31 : STM32_SVD.UInt19 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for ISR_Register use record RXBR at 0 range 0 .. 0; RXEND at 0 range 1 .. 1; RXOVR at 0 range 2 .. 2; BRE at 0 range 3 .. 3; SBPE at 0 range 4 .. 4; LBPE at 0 range 5 .. 5; RXACKE at 0 range 6 .. 6; ARBLST at 0 range 7 .. 7; TXBR at 0 range 8 .. 8; TXEND at 0 range 9 .. 9; TXUDR at 0 range 10 .. 10; TXERR at 0 range 11 .. 11; TXACKE at 0 range 12 .. 12; Reserved_13_31 at 0 range 13 .. 31; end record; subtype IER_RXBRIE_Field is STM32_SVD.Bit; subtype IER_RXENDIE_Field is STM32_SVD.Bit; subtype IER_RXOVRIE_Field is STM32_SVD.Bit; subtype IER_BREIE_Field is STM32_SVD.Bit; subtype IER_SBPEIE_Field is STM32_SVD.Bit; subtype IER_LBPEIE_Field is STM32_SVD.Bit; subtype IER_RXACKIE_Field is STM32_SVD.Bit; subtype IER_ARBLSTIE_Field is STM32_SVD.Bit; subtype IER_TXBRIE_Field is STM32_SVD.Bit; subtype IER_TXENDIE_Field is STM32_SVD.Bit; subtype IER_TXUDRIE_Field is STM32_SVD.Bit; subtype IER_TXERRIE_Field is STM32_SVD.Bit; subtype IER_TXACKIE_Field is STM32_SVD.Bit; -- interrupt enable register type IER_Register is record -- Rx-Byte Received Interrupt Enable RXBRIE : IER_RXBRIE_Field := 16#0#; -- End Of Reception Interrupt Enable RXENDIE : IER_RXENDIE_Field := 16#0#; -- Rx-Buffer Overrun Interrupt Enable RXOVRIE : IER_RXOVRIE_Field := 16#0#; -- Bit Rising Error Interrupt Enable BREIE : IER_BREIE_Field := 16#0#; -- Short Bit Period Error Interrupt Enable SBPEIE : IER_SBPEIE_Field := 16#0#; -- Long Bit Period Error Interrupt Enable LBPEIE : IER_LBPEIE_Field := 16#0#; -- Rx-Missing Acknowledge Error Interrupt Enable RXACKIE : IER_RXACKIE_Field := 16#0#; -- Arbitration Lost Interrupt Enable ARBLSTIE : IER_ARBLSTIE_Field := 16#0#; -- Tx-Byte Request Interrupt Enable TXBRIE : IER_TXBRIE_Field := 16#0#; -- Tx-End of message interrupt enable TXENDIE : IER_TXENDIE_Field := 16#0#; -- Tx-Underrun interrupt enable TXUDRIE : IER_TXUDRIE_Field := 16#0#; -- Tx-Error Interrupt Enable TXERRIE : IER_TXERRIE_Field := 16#0#; -- Tx-Missing Acknowledge Error Interrupt Enable TXACKIE : IER_TXACKIE_Field := 16#0#; -- unspecified Reserved_13_31 : STM32_SVD.UInt19 := 16#0#; end record with Volatile_Full_Access, Size => 32, Bit_Order => System.Low_Order_First; for IER_Register use record RXBRIE at 0 range 0 .. 0; RXENDIE at 0 range 1 .. 1; RXOVRIE at 0 range 2 .. 2; BREIE at 0 range 3 .. 3; SBPEIE at 0 range 4 .. 4; LBPEIE at 0 range 5 .. 5; RXACKIE at 0 range 6 .. 6; ARBLSTIE at 0 range 7 .. 7; TXBRIE at 0 range 8 .. 8; TXENDIE at 0 range 9 .. 9; TXUDRIE at 0 range 10 .. 10; TXERRIE at 0 range 11 .. 11; TXACKIE at 0 range 12 .. 12; Reserved_13_31 at 0 range 13 .. 31; end record; ----------------- -- Peripherals -- ----------------- -- HDMI-CEC controller type CEC_Peripheral is record -- control register CR : aliased CR_Register; -- configuration register CFGR : aliased CFGR_Register; -- Tx data register TXDR : aliased TXDR_Register; -- Rx Data Register RXDR : aliased RXDR_Register; -- Interrupt and Status Register ISR : aliased ISR_Register; -- interrupt enable register IER : aliased IER_Register; end record with Volatile; for CEC_Peripheral use record CR at 16#0# range 0 .. 31; CFGR at 16#4# range 0 .. 31; TXDR at 16#8# range 0 .. 31; RXDR at 16#C# range 0 .. 31; ISR at 16#10# range 0 .. 31; IER at 16#14# range 0 .. 31; end record; -- HDMI-CEC controller CEC_Periph : aliased CEC_Peripheral with Import, Address => System'To_Address (16#40007800#); end STM32_SVD.CEC;
------------------------------------------------------------------------------ -- -- -- Copyright (C) 2015, AdaCore -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions are -- -- met: -- -- 1. Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- 2. Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in -- -- the documentation and/or other materials provided with the -- -- distribution. -- -- 3. Neither the name of STMicroelectronics nor the names of its -- -- contributors may be used to endorse or promote products derived -- -- from this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -- -- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -- -- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -- -- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -- -- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -- -- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- -- -- -- This file is based on: -- -- -- -- @file stm32f4xx_hal_cortex.c -- -- @author MCD Application Team -- -- @version V1.1.0 -- -- @date 19-June-2014 -- -- @brief CORTEX HAL module driver. -- -- -- -- COPYRIGHT(c) 2014 STMicroelectronics -- ------------------------------------------------------------------------------ with Memory_Barriers; package body Cortex_M.NVIC is ----------------------- -- Priority_Grouping -- ----------------------- function Priority_Grouping return UInt32 is begin return Shift_Right (SCB.AIRCR and SCB_AIRCR_PRIGROUP_Mask, SCB_AIRCR_PRIGROUP_Pos); end Priority_Grouping; --------------------------- -- Set_Priority_Grouping -- --------------------------- procedure Set_Priority_Grouping (Priority_Group : UInt32) is Reg_Value : UInt32; PriorityGroupTmp : constant UInt32 := Priority_Group and 16#07#; Key : constant := 16#5FA#; begin Reg_Value := SCB.AIRCR; Reg_Value := Reg_Value and (not (SCB_AIRCR_VECTKEY_Mask or SCB_AIRCR_PRIGROUP_Mask)); Reg_Value := Reg_Value or Shift_Left (Key, SCB_AIRCR_VECTKEY_Pos) or Shift_Left (PriorityGroupTmp, 8); SCB.AIRCR := Reg_Value; end Set_Priority_Grouping; ------------------ -- Set_Priority -- ------------------ procedure Set_Priority (IRQn : Interrupt_ID; Priority : UInt32) is Index : constant Natural := Integer (IRQn); Value : constant UInt32 := Shift_Left (Priority, 8 - NVIC_PRIO_BITS) and 16#FF#; begin -- IRQ numbers are never less than 0 in the current definition, hence -- the code is different from that in the CMSIS. NVIC.IP (Index) := UInt8 (Value); end Set_Priority; ---------------------- -- Encoded_Priority -- ---------------------- function Encoded_Priority (Priority_Group : UInt32; Preempt_Priority : UInt32; Subpriority : UInt32) return UInt32 is PriorityGroupTmp : constant UInt32 := Priority_Group and 16#07#; PreemptPriorityBits : UInt32; SubPriorityBits : UInt32; Temp1 : UInt32; Temp2 : UInt32; Temp3 : UInt32; Temp4 : UInt32; Temp5 : UInt32; begin if (7 - PriorityGroupTmp) > NVIC_PRIO_BITS then PreemptPriorityBits := NVIC_PRIO_BITS; else PreemptPriorityBits := 7 - PriorityGroupTmp; end if; if (PriorityGroupTmp + NVIC_PRIO_BITS) < 7 then SubPriorityBits := 0; else SubPriorityBits := PriorityGroupTmp - 7 + NVIC_PRIO_BITS; end if; Temp1 := Shift_Left (1, Integer (PreemptPriorityBits)) - 1; Temp2 := Preempt_Priority and Temp1; Temp3 := Shift_Left (Temp2, Integer (SubPriorityBits)); Temp4 := Shift_Left (1, Integer (SubPriorityBits)) - 1; Temp5 := Subpriority and Temp4; return Temp3 or Temp5; end Encoded_Priority; ------------------ -- Set_Priority -- ------------------ procedure Set_Priority (IRQn : Interrupt_ID; Preempt_Priority : UInt32; Subpriority : UInt32) is Priority_Group : constant UInt32 := Priority_Grouping; begin Set_Priority (IRQn, Encoded_Priority (Priority_Group, Preempt_Priority, Subpriority)); end Set_Priority; ---------------------- -- Enable_Interrupt -- ---------------------- procedure Enable_Interrupt (IRQn : Interrupt_ID) is IRQn_As_Word : constant UInt32 := UInt32 (IRQn); Index : constant Natural := Integer (Shift_Right (IRQn_As_Word, 5)); begin NVIC.ISER (Index) := Shift_Left (IRQn_As_Word and 16#1F#, 1); end Enable_Interrupt; ----------------------- -- Disable_Interrupt -- ----------------------- procedure Disable_Interrupt (IRQn : Interrupt_ID) is IRQn_As_Word : constant UInt32 := UInt32 (IRQn); Index : constant Natural := Integer (Shift_Right (IRQn_As_Word, 5)); begin -- NVIC->ICER[((uint32_t)(IRQn)>>5)] = (1 << ((uint32_t)(IRQn) & 0x1F)); NVIC.ICER (Index) := Shift_Left (1, Integer (IRQn_As_Word and 16#1F#)); end Disable_Interrupt; ------------ -- Active -- ------------ function Active (IRQn : Interrupt_ID) return Boolean is IRQn_As_Word : constant UInt32 := UInt32 (IRQn); Index : constant Natural := Integer (Shift_Right (IRQn_As_Word, 5)); Value : constant UInt32 := Shift_Left (1, Integer (IRQn_As_Word and 16#1F#)); begin return (NVIC.IABR (Index) and Value) /= 0; end Active; ------------- -- Pending -- ------------- function Pending (IRQn : Interrupt_ID) return Boolean is IRQn_As_Word : constant UInt32 := UInt32 (IRQn); Index : constant Natural := Integer (Shift_Right (IRQn_As_Word, 5)); Value : constant UInt32 := Shift_Left (1, Integer (IRQn_As_Word and 16#1F#)); begin return (NVIC.ISPR (Index) and Value) /= 0; end Pending; ----------------- -- Set_Pending -- ----------------- procedure Set_Pending (IRQn : Interrupt_ID) is IRQn_As_Word : constant UInt32 := UInt32 (IRQn); Index : constant Natural := Integer (Shift_Right (IRQn_As_Word, 5)); begin NVIC.ISPR (Index) := Shift_Left (1, Integer (IRQn_As_Word and 16#1F#)); end Set_Pending; ------------------- -- Clear_Pending -- ------------------- procedure Clear_Pending (IRQn : Interrupt_ID) is IRQn_As_Word : constant UInt32 := UInt32 (IRQn); Index : constant Natural := Integer (Shift_Right (IRQn_As_Word, 5)); begin NVIC.ICPR (Index) := Shift_Left (1, Integer (IRQn_As_Word and 16#1F#)); end Clear_Pending; ------------------ -- Reset_System -- ------------------ procedure Reset_System is Key : constant := 16#05FA#; -- required for write to be accepted use Memory_Barriers; begin -- Ensure all outstanding memory accesses including -- buffered writes are completed Data_Synchronization_Barrier; SCB.AIRCR := Shift_Left (Key, SCB_AIRCR_VECTKEY_Pos) or -- keep priority group unchanged (SCB.AIRCR and SCB_AIRCR_PRIGROUP_Mask) or SCB_AIRCR_SYSRESETREQ_Mask; -- TODO: why is all code from here onward in the CMSIS??? Data_Synchronization_Barrier; -- wait until reset pragma Warnings (Off); <<spin>> goto spin; pragma Warnings (On); end Reset_System; end Cortex_M.NVIC;
------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- G N A T . A L T I V E C . V E C T O R _ O P E R A T I O N S -- -- -- -- B o d y -- -- -- -- Copyright (C) 2004-2005, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 2, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -- -- for more details. You should have received a copy of the GNU General -- -- Public License distributed with GNAT; see file COPYING. If not, write -- -- to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, -- -- MA 02111-1307, USA. -- -- -- -- As a special exception, if other files instantiate generics from this -- -- unit, or you link this unit with other files to produce an executable, -- -- this unit does not by itself cause the resulting executable to be -- -- covered by the GNU General Public License. This exception does not -- -- however invalidate any other reasons why the executable file might be -- -- covered by the GNU Public License. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ with GNAT.Altivec.Low_Level_Vectors; use GNAT.Altivec.Low_Level_Vectors; package body GNAT.Altivec.Vector_Operations is -------------------------------------------------------- -- Bodies for generic and specific Altivec operations -- -------------------------------------------------------- -- vec_abs -- function vec_abs (A : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (abs_v16qi (A)); end vec_abs; function vec_abs (A : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (abs_v8hi (A)); end vec_abs; function vec_abs (A : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (abs_v4si (A)); end vec_abs; function vec_abs (A : vector_float) return vector_float is begin return To_LL_VF (abs_v4sf (A)); end vec_abs; -- vec_abss -- function vec_abss (A : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (abss_v16qi (A)); end vec_abss; function vec_abss (A : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (abss_v8hi (A)); end vec_abss; function vec_abss (A : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (abss_v4si (A)); end vec_abss; -- vec_add -- function vec_add (A : vector_bool_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vaddubm (To_LL_VSC (A), To_LL_VSC (B))); end vec_add; function vec_add (A : vector_signed_char; B : vector_bool_char) return vector_signed_char is begin return To_LL_VSC (vaddubm (To_LL_VSC (A), To_LL_VSC (B))); end vec_add; function vec_add (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vaddubm (To_LL_VSC (A), To_LL_VSC (B))); end vec_add; function vec_add (A : vector_bool_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vaddubm (To_LL_VSC (A), To_LL_VSC (B))); end vec_add; function vec_add (A : vector_unsigned_char; B : vector_bool_char) return vector_unsigned_char is begin return To_LL_VUC (vaddubm (To_LL_VSC (A), To_LL_VSC (B))); end vec_add; function vec_add (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vaddubm (To_LL_VSC (A), To_LL_VSC (B))); end vec_add; function vec_add (A : vector_bool_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vadduhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_add; function vec_add (A : vector_signed_short; B : vector_bool_short) return vector_signed_short is begin return To_LL_VSS (vadduhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_add; function vec_add (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vadduhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_add; function vec_add (A : vector_bool_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vadduhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_add; function vec_add (A : vector_unsigned_short; B : vector_bool_short) return vector_unsigned_short is begin return To_LL_VUS (vadduhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_add; function vec_add (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vadduhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_add; function vec_add (A : vector_bool_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vadduwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_add; function vec_add (A : vector_signed_int; B : vector_bool_int) return vector_signed_int is begin return To_LL_VSI (vadduwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_add; function vec_add (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vadduwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_add; function vec_add (A : vector_bool_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vadduwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_add; function vec_add (A : vector_unsigned_int; B : vector_bool_int) return vector_unsigned_int is begin return To_LL_VUI (vadduwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_add; function vec_add (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vadduwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_add; function vec_add (A : vector_float; B : vector_float) return vector_float is begin return To_LL_VF (vaddfp (To_LL_VF (A), To_LL_VF (B))); end vec_add; -- vec_vaddfp -- function vec_vaddfp (A : vector_float; B : vector_float) return vector_float is begin return To_LL_VF (vaddfp (To_LL_VF (A), To_LL_VF (B))); end vec_vaddfp; -- vec_vadduwm -- function vec_vadduwm (A : vector_bool_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vadduwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_vadduwm; function vec_vadduwm (A : vector_signed_int; B : vector_bool_int) return vector_signed_int is begin return To_LL_VSI (vadduwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_vadduwm; function vec_vadduwm (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vadduwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_vadduwm; function vec_vadduwm (A : vector_bool_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vadduwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_vadduwm; function vec_vadduwm (A : vector_unsigned_int; B : vector_bool_int) return vector_unsigned_int is begin return To_LL_VUI (vadduwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_vadduwm; function vec_vadduwm (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vadduwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_vadduwm; -- vec_vadduhm -- function vec_vadduhm (A : vector_bool_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vadduhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_vadduhm; function vec_vadduhm (A : vector_signed_short; B : vector_bool_short) return vector_signed_short is begin return To_LL_VSS (vadduhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_vadduhm; function vec_vadduhm (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vadduhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_vadduhm; function vec_vadduhm (A : vector_bool_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vadduhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_vadduhm; function vec_vadduhm (A : vector_unsigned_short; B : vector_bool_short) return vector_unsigned_short is begin return To_LL_VUS (vadduhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_vadduhm; function vec_vadduhm (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vadduhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_vadduhm; -- vec_vaddubm -- function vec_vaddubm (A : vector_bool_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vaddubm (To_LL_VSC (A), To_LL_VSC (B))); end vec_vaddubm; function vec_vaddubm (A : vector_signed_char; B : vector_bool_char) return vector_signed_char is begin return To_LL_VSC (vaddubm (To_LL_VSC (A), To_LL_VSC (B))); end vec_vaddubm; function vec_vaddubm (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vaddubm (To_LL_VSC (A), To_LL_VSC (B))); end vec_vaddubm; function vec_vaddubm (A : vector_bool_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vaddubm (To_LL_VSC (A), To_LL_VSC (B))); end vec_vaddubm; function vec_vaddubm (A : vector_unsigned_char; B : vector_bool_char) return vector_unsigned_char is begin return To_LL_VUC (vaddubm (To_LL_VSC (A), To_LL_VSC (B))); end vec_vaddubm; function vec_vaddubm (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vaddubm (To_LL_VSC (A), To_LL_VSC (B))); end vec_vaddubm; -- vec_addc -- function vec_addc (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vaddcuw (To_LL_VSI (A), To_LL_VSI (B))); end vec_addc; -- vec_adds -- function vec_adds (A : vector_bool_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vaddubs (To_LL_VSC (A), To_LL_VSC (B))); end vec_adds; function vec_adds (A : vector_unsigned_char; B : vector_bool_char) return vector_unsigned_char is begin return To_LL_VUC (vaddubs (To_LL_VSC (A), To_LL_VSC (B))); end vec_adds; function vec_adds (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vaddubs (To_LL_VSC (A), To_LL_VSC (B))); end vec_adds; function vec_adds (A : vector_bool_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vaddsbs (To_LL_VSC (A), To_LL_VSC (B))); end vec_adds; function vec_adds (A : vector_signed_char; B : vector_bool_char) return vector_signed_char is begin return To_LL_VSC (vaddsbs (To_LL_VSC (A), To_LL_VSC (B))); end vec_adds; function vec_adds (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vaddsbs (To_LL_VSC (A), To_LL_VSC (B))); end vec_adds; function vec_adds (A : vector_bool_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vadduhs (To_LL_VSS (A), To_LL_VSS (B))); end vec_adds; function vec_adds (A : vector_unsigned_short; B : vector_bool_short) return vector_unsigned_short is begin return To_LL_VUS (vadduhs (To_LL_VSS (A), To_LL_VSS (B))); end vec_adds; function vec_adds (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vadduhs (To_LL_VSS (A), To_LL_VSS (B))); end vec_adds; function vec_adds (A : vector_bool_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vaddshs (To_LL_VSS (A), To_LL_VSS (B))); end vec_adds; function vec_adds (A : vector_signed_short; B : vector_bool_short) return vector_signed_short is begin return To_LL_VSS (vaddshs (To_LL_VSS (A), To_LL_VSS (B))); end vec_adds; function vec_adds (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vaddshs (To_LL_VSS (A), To_LL_VSS (B))); end vec_adds; function vec_adds (A : vector_bool_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vadduws (To_LL_VSI (A), To_LL_VSI (B))); end vec_adds; function vec_adds (A : vector_unsigned_int; B : vector_bool_int) return vector_unsigned_int is begin return To_LL_VUI (vadduws (To_LL_VSI (A), To_LL_VSI (B))); end vec_adds; function vec_adds (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vadduws (To_LL_VSI (A), To_LL_VSI (B))); end vec_adds; function vec_adds (A : vector_bool_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vaddsws (To_LL_VSI (A), To_LL_VSI (B))); end vec_adds; function vec_adds (A : vector_signed_int; B : vector_bool_int) return vector_signed_int is begin return To_LL_VSI (vaddsws (To_LL_VSI (A), To_LL_VSI (B))); end vec_adds; function vec_adds (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vaddsws (To_LL_VSI (A), To_LL_VSI (B))); end vec_adds; -- vec_vaddsws -- function vec_vaddsws (A : vector_bool_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vaddsws (To_LL_VSI (A), To_LL_VSI (B))); end vec_vaddsws; function vec_vaddsws (A : vector_signed_int; B : vector_bool_int) return vector_signed_int is begin return To_LL_VSI (vaddsws (To_LL_VSI (A), To_LL_VSI (B))); end vec_vaddsws; function vec_vaddsws (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vaddsws (To_LL_VSI (A), To_LL_VSI (B))); end vec_vaddsws; -- vec_vadduws -- function vec_vadduws (A : vector_bool_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vadduws (To_LL_VSI (A), To_LL_VSI (B))); end vec_vadduws; function vec_vadduws (A : vector_unsigned_int; B : vector_bool_int) return vector_unsigned_int is begin return To_LL_VUI (vadduws (To_LL_VSI (A), To_LL_VSI (B))); end vec_vadduws; function vec_vadduws (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vadduws (To_LL_VSI (A), To_LL_VSI (B))); end vec_vadduws; -- vec_vaddshs -- function vec_vaddshs (A : vector_bool_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vaddshs (To_LL_VSS (A), To_LL_VSS (B))); end vec_vaddshs; function vec_vaddshs (A : vector_signed_short; B : vector_bool_short) return vector_signed_short is begin return To_LL_VSS (vaddshs (To_LL_VSS (A), To_LL_VSS (B))); end vec_vaddshs; function vec_vaddshs (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vaddshs (To_LL_VSS (A), To_LL_VSS (B))); end vec_vaddshs; -- vec_vadduhs -- function vec_vadduhs (A : vector_bool_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vadduhs (To_LL_VSS (A), To_LL_VSS (B))); end vec_vadduhs; function vec_vadduhs (A : vector_unsigned_short; B : vector_bool_short) return vector_unsigned_short is begin return To_LL_VUS (vadduhs (To_LL_VSS (A), To_LL_VSS (B))); end vec_vadduhs; function vec_vadduhs (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vadduhs (To_LL_VSS (A), To_LL_VSS (B))); end vec_vadduhs; -- vec_vaddsbs -- function vec_vaddsbs (A : vector_bool_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vaddsbs (To_LL_VSC (A), To_LL_VSC (B))); end vec_vaddsbs; function vec_vaddsbs (A : vector_signed_char; B : vector_bool_char) return vector_signed_char is begin return To_LL_VSC (vaddsbs (To_LL_VSC (A), To_LL_VSC (B))); end vec_vaddsbs; function vec_vaddsbs (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vaddsbs (To_LL_VSC (A), To_LL_VSC (B))); end vec_vaddsbs; -- vec_vaddubs -- function vec_vaddubs (A : vector_bool_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vaddubs (To_LL_VSC (A), To_LL_VSC (B))); end vec_vaddubs; function vec_vaddubs (A : vector_unsigned_char; B : vector_bool_char) return vector_unsigned_char is begin return To_LL_VUC (vaddubs (To_LL_VSC (A), To_LL_VSC (B))); end vec_vaddubs; function vec_vaddubs (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vaddubs (To_LL_VSC (A), To_LL_VSC (B))); end vec_vaddubs; -- vec_and -- function vec_and (A : vector_float; B : vector_float) return vector_float is begin return To_LL_VF (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_float; B : vector_bool_int) return vector_float is begin return To_LL_VF (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_bool_int; B : vector_float) return vector_float is begin return To_LL_VF (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_bool_int; B : vector_bool_int) return vector_bool_int is begin return To_LL_VBI (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_bool_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_signed_int; B : vector_bool_int) return vector_signed_int is begin return To_LL_VSI (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_bool_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_unsigned_int; B : vector_bool_int) return vector_unsigned_int is begin return To_LL_VUI (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_bool_short; B : vector_bool_short) return vector_bool_short is begin return To_LL_VBS (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_bool_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_signed_short; B : vector_bool_short) return vector_signed_short is begin return To_LL_VSS (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_bool_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_unsigned_short; B : vector_bool_short) return vector_unsigned_short is begin return To_LL_VUS (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_bool_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_bool_char; B : vector_bool_char) return vector_bool_char is begin return To_LL_VBC (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_signed_char; B : vector_bool_char) return vector_signed_char is begin return To_LL_VSC (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_bool_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_unsigned_char; B : vector_bool_char) return vector_unsigned_char is begin return To_LL_VUC (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; function vec_and (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vand (To_LL_VSI (A), To_LL_VSI (B))); end vec_and; -- vec_andc -- function vec_andc (A : vector_float; B : vector_float) return vector_float is begin return To_LL_VF (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_float; B : vector_bool_int) return vector_float is begin return To_LL_VF (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_bool_int; B : vector_float) return vector_float is begin return To_LL_VF (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_bool_int; B : vector_bool_int) return vector_bool_int is begin return To_LL_VBI (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_bool_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_signed_int; B : vector_bool_int) return vector_signed_int is begin return To_LL_VSI (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_bool_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_unsigned_int; B : vector_bool_int) return vector_unsigned_int is begin return To_LL_VUI (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_bool_short; B : vector_bool_short) return vector_bool_short is begin return To_LL_VBS (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_bool_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_signed_short; B : vector_bool_short) return vector_signed_short is begin return To_LL_VSS (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_bool_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_unsigned_short; B : vector_bool_short) return vector_unsigned_short is begin return To_LL_VUS (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_bool_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_bool_char; B : vector_bool_char) return vector_bool_char is begin return To_LL_VBC (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_signed_char; B : vector_bool_char) return vector_signed_char is begin return To_LL_VSC (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_bool_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_unsigned_char; B : vector_bool_char) return vector_unsigned_char is begin return To_LL_VUC (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; function vec_andc (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vandc (To_LL_VSI (A), To_LL_VSI (B))); end vec_andc; -- vec_avg -- function vec_avg (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vavgub (To_LL_VSC (A), To_LL_VSC (B))); end vec_avg; function vec_avg (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vavgsb (To_LL_VSC (A), To_LL_VSC (B))); end vec_avg; function vec_avg (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vavguh (To_LL_VSS (A), To_LL_VSS (B))); end vec_avg; function vec_avg (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vavgsh (To_LL_VSS (A), To_LL_VSS (B))); end vec_avg; function vec_avg (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vavguw (To_LL_VSI (A), To_LL_VSI (B))); end vec_avg; function vec_avg (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vavgsw (To_LL_VSI (A), To_LL_VSI (B))); end vec_avg; -- vec_vavgsw -- function vec_vavgsw (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vavgsw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vavgsw; -- vec_vavguw -- function vec_vavguw (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vavguw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vavguw; -- vec_vavgsh -- function vec_vavgsh (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vavgsh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vavgsh; -- vec_vavguh -- function vec_vavguh (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vavguh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vavguh; -- vec_vavgsb -- function vec_vavgsb (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vavgsb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vavgsb; -- vec_vavgub -- function vec_vavgub (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vavgub (To_LL_VSC (A), To_LL_VSC (B))); end vec_vavgub; -- vec_ceil -- function vec_ceil (A : vector_float) return vector_float is begin return To_LL_VF (vrfip (To_LL_VF (A))); end vec_ceil; -- vec_cmpb -- function vec_cmpb (A : vector_float; B : vector_float) return vector_signed_int is begin return To_LL_VSI (vcmpbfp (To_LL_VF (A), To_LL_VF (B))); end vec_cmpb; -- vec_cmpeq -- function vec_cmpeq (A : vector_signed_char; B : vector_signed_char) return vector_bool_char is begin return To_LL_VBC (vcmpequb (To_LL_VSC (A), To_LL_VSC (B))); end vec_cmpeq; function vec_cmpeq (A : vector_unsigned_char; B : vector_unsigned_char) return vector_bool_char is begin return To_LL_VBC (vcmpequb (To_LL_VSC (A), To_LL_VSC (B))); end vec_cmpeq; function vec_cmpeq (A : vector_signed_short; B : vector_signed_short) return vector_bool_short is begin return To_LL_VBS (vcmpequh (To_LL_VSS (A), To_LL_VSS (B))); end vec_cmpeq; function vec_cmpeq (A : vector_unsigned_short; B : vector_unsigned_short) return vector_bool_short is begin return To_LL_VBS (vcmpequh (To_LL_VSS (A), To_LL_VSS (B))); end vec_cmpeq; function vec_cmpeq (A : vector_signed_int; B : vector_signed_int) return vector_bool_int is begin return To_LL_VBI (vcmpequw (To_LL_VSI (A), To_LL_VSI (B))); end vec_cmpeq; function vec_cmpeq (A : vector_unsigned_int; B : vector_unsigned_int) return vector_bool_int is begin return To_LL_VBI (vcmpequw (To_LL_VSI (A), To_LL_VSI (B))); end vec_cmpeq; function vec_cmpeq (A : vector_float; B : vector_float) return vector_bool_int is begin return To_LL_VBI (vcmpeqfp (To_LL_VF (A), To_LL_VF (B))); end vec_cmpeq; -- vec_vcmpeqfp -- function vec_vcmpeqfp (A : vector_float; B : vector_float) return vector_bool_int is begin return To_LL_VBI (vcmpeqfp (To_LL_VF (A), To_LL_VF (B))); end vec_vcmpeqfp; -- vec_vcmpequw -- function vec_vcmpequw (A : vector_signed_int; B : vector_signed_int) return vector_bool_int is begin return To_LL_VBI (vcmpequw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vcmpequw; function vec_vcmpequw (A : vector_unsigned_int; B : vector_unsigned_int) return vector_bool_int is begin return To_LL_VBI (vcmpequw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vcmpequw; -- vec_vcmpequh -- function vec_vcmpequh (A : vector_signed_short; B : vector_signed_short) return vector_bool_short is begin return To_LL_VBS (vcmpequh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vcmpequh; function vec_vcmpequh (A : vector_unsigned_short; B : vector_unsigned_short) return vector_bool_short is begin return To_LL_VBS (vcmpequh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vcmpequh; -- vec_vcmpequb -- function vec_vcmpequb (A : vector_signed_char; B : vector_signed_char) return vector_bool_char is begin return To_LL_VBC (vcmpequb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vcmpequb; function vec_vcmpequb (A : vector_unsigned_char; B : vector_unsigned_char) return vector_bool_char is begin return To_LL_VBC (vcmpequb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vcmpequb; -- vec_cmpge -- function vec_cmpge (A : vector_float; B : vector_float) return vector_bool_int is begin return To_LL_VBI (vcmpgefp (To_LL_VF (A), To_LL_VF (B))); end vec_cmpge; -- vec_cmpgt -- function vec_cmpgt (A : vector_unsigned_char; B : vector_unsigned_char) return vector_bool_char is begin return To_LL_VBC (vcmpgtub (To_LL_VSC (A), To_LL_VSC (B))); end vec_cmpgt; function vec_cmpgt (A : vector_signed_char; B : vector_signed_char) return vector_bool_char is begin return To_LL_VBC (vcmpgtsb (To_LL_VSC (A), To_LL_VSC (B))); end vec_cmpgt; function vec_cmpgt (A : vector_unsigned_short; B : vector_unsigned_short) return vector_bool_short is begin return To_LL_VBS (vcmpgtuh (To_LL_VSS (A), To_LL_VSS (B))); end vec_cmpgt; function vec_cmpgt (A : vector_signed_short; B : vector_signed_short) return vector_bool_short is begin return To_LL_VBS (vcmpgtsh (To_LL_VSS (A), To_LL_VSS (B))); end vec_cmpgt; function vec_cmpgt (A : vector_unsigned_int; B : vector_unsigned_int) return vector_bool_int is begin return To_LL_VBI (vcmpgtuw (To_LL_VSI (A), To_LL_VSI (B))); end vec_cmpgt; function vec_cmpgt (A : vector_signed_int; B : vector_signed_int) return vector_bool_int is begin return To_LL_VBI (vcmpgtsw (To_LL_VSI (A), To_LL_VSI (B))); end vec_cmpgt; function vec_cmpgt (A : vector_float; B : vector_float) return vector_bool_int is begin return To_LL_VBI (vcmpgtfp (To_LL_VF (A), To_LL_VF (B))); end vec_cmpgt; -- vec_vcmpgtfp -- function vec_vcmpgtfp (A : vector_float; B : vector_float) return vector_bool_int is begin return To_LL_VBI (vcmpgtfp (To_LL_VF (A), To_LL_VF (B))); end vec_vcmpgtfp; -- vec_vcmpgtsw -- function vec_vcmpgtsw (A : vector_signed_int; B : vector_signed_int) return vector_bool_int is begin return To_LL_VBI (vcmpgtsw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vcmpgtsw; -- vec_vcmpgtuw -- function vec_vcmpgtuw (A : vector_unsigned_int; B : vector_unsigned_int) return vector_bool_int is begin return To_LL_VBI (vcmpgtuw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vcmpgtuw; -- vec_vcmpgtsh -- function vec_vcmpgtsh (A : vector_signed_short; B : vector_signed_short) return vector_bool_short is begin return To_LL_VBS (vcmpgtsh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vcmpgtsh; -- vec_vcmpgtuh -- function vec_vcmpgtuh (A : vector_unsigned_short; B : vector_unsigned_short) return vector_bool_short is begin return To_LL_VBS (vcmpgtuh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vcmpgtuh; -- vec_vcmpgtsb -- function vec_vcmpgtsb (A : vector_signed_char; B : vector_signed_char) return vector_bool_char is begin return To_LL_VBC (vcmpgtsb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vcmpgtsb; -- vec_vcmpgtub -- function vec_vcmpgtub (A : vector_unsigned_char; B : vector_unsigned_char) return vector_bool_char is begin return To_LL_VBC (vcmpgtub (To_LL_VSC (A), To_LL_VSC (B))); end vec_vcmpgtub; -- vec_cmple -- function vec_cmple (A : vector_float; B : vector_float) return vector_bool_int is begin return To_LL_VBI (vcmpgefp (To_LL_VF (B), To_LL_VF (A))); end vec_cmple; -- vec_cmplt -- function vec_cmplt (A : vector_unsigned_char; B : vector_unsigned_char) return vector_bool_char is begin return To_LL_VBC (vcmpgtub (To_LL_VSC (B), To_LL_VSC (A))); end vec_cmplt; function vec_cmplt (A : vector_signed_char; B : vector_signed_char) return vector_bool_char is begin return To_LL_VBC (vcmpgtsb (To_LL_VSC (B), To_LL_VSC (A))); end vec_cmplt; function vec_cmplt (A : vector_unsigned_short; B : vector_unsigned_short) return vector_bool_short is begin return To_LL_VBS (vcmpgtuh (To_LL_VSS (B), To_LL_VSS (A))); end vec_cmplt; function vec_cmplt (A : vector_signed_short; B : vector_signed_short) return vector_bool_short is begin return To_LL_VBS (vcmpgtsh (To_LL_VSS (B), To_LL_VSS (A))); end vec_cmplt; function vec_cmplt (A : vector_unsigned_int; B : vector_unsigned_int) return vector_bool_int is begin return To_LL_VBI (vcmpgtuw (To_LL_VSI (B), To_LL_VSI (A))); end vec_cmplt; function vec_cmplt (A : vector_signed_int; B : vector_signed_int) return vector_bool_int is begin return To_LL_VBI (vcmpgtsw (To_LL_VSI (B), To_LL_VSI (A))); end vec_cmplt; function vec_cmplt (A : vector_float; B : vector_float) return vector_bool_int is begin return To_LL_VBI (vcmpgtfp (To_LL_VF (B), To_LL_VF (A))); end vec_cmplt; -- vec_expte -- function vec_expte (A : vector_float) return vector_float is begin return To_LL_VF (vexptefp (To_LL_VF (A))); end vec_expte; -- vec_floor -- function vec_floor (A : vector_float) return vector_float is begin return To_LL_VF (vrfim (To_LL_VF (A))); end vec_floor; -- vec_ld -- function vec_ld (A : c_long; B : const_vector_float_ptr) return vector_float is begin return To_LL_VF (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_float_ptr) return vector_float is begin return To_LL_VF (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_vector_bool_int_ptr) return vector_bool_int is begin return To_LL_VBI (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_vector_signed_int_ptr) return vector_signed_int is begin return To_LL_VSI (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_int_ptr) return vector_signed_int is begin return To_LL_VSI (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_long_ptr) return vector_signed_int is begin return To_LL_VSI (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_vector_unsigned_int_ptr) return vector_unsigned_int is begin return To_LL_VUI (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_unsigned_int_ptr) return vector_unsigned_int is begin return To_LL_VUI (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_unsigned_long_ptr) return vector_unsigned_int is begin return To_LL_VUI (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_vector_bool_short_ptr) return vector_bool_short is begin return To_LL_VBS (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_vector_pixel_ptr) return vector_pixel is begin return To_LL_VP (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_vector_signed_short_ptr) return vector_signed_short is begin return To_LL_VSS (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_short_ptr) return vector_signed_short is begin return To_LL_VSS (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_vector_unsigned_short_ptr) return vector_unsigned_short is begin return To_LL_VUS (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_unsigned_short_ptr) return vector_unsigned_short is begin return To_LL_VUS (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_vector_bool_char_ptr) return vector_bool_char is begin return To_LL_VBC (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_vector_signed_char_ptr) return vector_signed_char is begin return To_LL_VSC (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_signed_char_ptr) return vector_signed_char is begin return To_LL_VSC (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_vector_unsigned_char_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvx (A, To_PTR (B))); end vec_ld; function vec_ld (A : c_long; B : const_unsigned_char_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvx (A, To_PTR (B))); end vec_ld; -- vec_lde -- function vec_lde (A : c_long; B : const_signed_char_ptr) return vector_signed_char is begin return To_LL_VSC (lvebx (A, To_PTR (B))); end vec_lde; function vec_lde (A : c_long; B : const_unsigned_char_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvebx (A, To_PTR (B))); end vec_lde; function vec_lde (A : c_long; B : const_short_ptr) return vector_signed_short is begin return To_LL_VSS (lvehx (A, To_PTR (B))); end vec_lde; function vec_lde (A : c_long; B : const_unsigned_short_ptr) return vector_unsigned_short is begin return To_LL_VUS (lvehx (A, To_PTR (B))); end vec_lde; function vec_lde (A : c_long; B : const_float_ptr) return vector_float is begin return To_LL_VF (lvewx (A, To_PTR (B))); end vec_lde; function vec_lde (A : c_long; B : const_int_ptr) return vector_signed_int is begin return To_LL_VSI (lvewx (A, To_PTR (B))); end vec_lde; function vec_lde (A : c_long; B : const_unsigned_int_ptr) return vector_unsigned_int is begin return To_LL_VUI (lvewx (A, To_PTR (B))); end vec_lde; function vec_lde (A : c_long; B : const_long_ptr) return vector_signed_int is begin return To_LL_VSI (lvewx (A, To_PTR (B))); end vec_lde; function vec_lde (A : c_long; B : const_unsigned_long_ptr) return vector_unsigned_int is begin return To_LL_VUI (lvewx (A, To_PTR (B))); end vec_lde; -- vec_lvewx -- function vec_lvewx (A : c_long; B : float_ptr) return vector_float is begin return To_LL_VF (lvewx (A, To_PTR (B))); end vec_lvewx; function vec_lvewx (A : c_long; B : int_ptr) return vector_signed_int is begin return To_LL_VSI (lvewx (A, To_PTR (B))); end vec_lvewx; function vec_lvewx (A : c_long; B : unsigned_int_ptr) return vector_unsigned_int is begin return To_LL_VUI (lvewx (A, To_PTR (B))); end vec_lvewx; function vec_lvewx (A : c_long; B : long_ptr) return vector_signed_int is begin return To_LL_VSI (lvewx (A, To_PTR (B))); end vec_lvewx; function vec_lvewx (A : c_long; B : unsigned_long_ptr) return vector_unsigned_int is begin return To_LL_VUI (lvewx (A, To_PTR (B))); end vec_lvewx; -- vec_lvehx -- function vec_lvehx (A : c_long; B : short_ptr) return vector_signed_short is begin return To_LL_VSS (lvehx (A, To_PTR (B))); end vec_lvehx; function vec_lvehx (A : c_long; B : unsigned_short_ptr) return vector_unsigned_short is begin return To_LL_VUS (lvehx (A, To_PTR (B))); end vec_lvehx; -- vec_lvebx -- function vec_lvebx (A : c_long; B : signed_char_ptr) return vector_signed_char is begin return To_LL_VSC (lvebx (A, To_PTR (B))); end vec_lvebx; function vec_lvebx (A : c_long; B : unsigned_char_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvebx (A, To_PTR (B))); end vec_lvebx; -- vec_ldl -- function vec_ldl (A : c_long; B : const_vector_float_ptr) return vector_float is begin return To_LL_VF (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_float_ptr) return vector_float is begin return To_LL_VF (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_vector_bool_int_ptr) return vector_bool_int is begin return To_LL_VBI (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_vector_signed_int_ptr) return vector_signed_int is begin return To_LL_VSI (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_int_ptr) return vector_signed_int is begin return To_LL_VSI (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_long_ptr) return vector_signed_int is begin return To_LL_VSI (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_vector_unsigned_int_ptr) return vector_unsigned_int is begin return To_LL_VUI (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_unsigned_int_ptr) return vector_unsigned_int is begin return To_LL_VUI (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_unsigned_long_ptr) return vector_unsigned_int is begin return To_LL_VUI (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_vector_bool_short_ptr) return vector_bool_short is begin return To_LL_VBS (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_vector_pixel_ptr) return vector_pixel is begin return To_LL_VP (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_vector_signed_short_ptr) return vector_signed_short is begin return To_LL_VSS (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_short_ptr) return vector_signed_short is begin return To_LL_VSS (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_vector_unsigned_short_ptr) return vector_unsigned_short is begin return To_LL_VUS (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_unsigned_short_ptr) return vector_unsigned_short is begin return To_LL_VUS (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_vector_bool_char_ptr) return vector_bool_char is begin return To_LL_VBC (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_vector_signed_char_ptr) return vector_signed_char is begin return To_LL_VSC (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_signed_char_ptr) return vector_signed_char is begin return To_LL_VSC (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_vector_unsigned_char_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvxl (A, To_PTR (B))); end vec_ldl; function vec_ldl (A : c_long; B : const_unsigned_char_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvxl (A, To_PTR (B))); end vec_ldl; -- vec_loge -- function vec_loge (A : vector_float) return vector_float is begin return To_LL_VF (vlogefp (To_LL_VF (A))); end vec_loge; -- vec_lvsl -- function vec_lvsl (A : c_long; B : constv_unsigned_char_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsl (A, To_PTR (B))); end vec_lvsl; function vec_lvsl (A : c_long; B : constv_signed_char_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsl (A, To_PTR (B))); end vec_lvsl; function vec_lvsl (A : c_long; B : constv_unsigned_short_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsl (A, To_PTR (B))); end vec_lvsl; function vec_lvsl (A : c_long; B : constv_short_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsl (A, To_PTR (B))); end vec_lvsl; function vec_lvsl (A : c_long; B : constv_unsigned_int_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsl (A, To_PTR (B))); end vec_lvsl; function vec_lvsl (A : c_long; B : constv_int_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsl (A, To_PTR (B))); end vec_lvsl; function vec_lvsl (A : c_long; B : constv_unsigned_long_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsl (A, To_PTR (B))); end vec_lvsl; function vec_lvsl (A : c_long; B : constv_long_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsl (A, To_PTR (B))); end vec_lvsl; function vec_lvsl (A : c_long; B : constv_float_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsl (A, To_PTR (B))); end vec_lvsl; -- vec_lvsr -- function vec_lvsr (A : c_long; B : constv_unsigned_char_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsr (A, To_PTR (B))); end vec_lvsr; function vec_lvsr (A : c_long; B : constv_signed_char_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsr (A, To_PTR (B))); end vec_lvsr; function vec_lvsr (A : c_long; B : constv_unsigned_short_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsr (A, To_PTR (B))); end vec_lvsr; function vec_lvsr (A : c_long; B : constv_short_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsr (A, To_PTR (B))); end vec_lvsr; function vec_lvsr (A : c_long; B : constv_unsigned_int_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsr (A, To_PTR (B))); end vec_lvsr; function vec_lvsr (A : c_long; B : constv_int_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsr (A, To_PTR (B))); end vec_lvsr; function vec_lvsr (A : c_long; B : constv_unsigned_long_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsr (A, To_PTR (B))); end vec_lvsr; function vec_lvsr (A : c_long; B : constv_long_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsr (A, To_PTR (B))); end vec_lvsr; function vec_lvsr (A : c_long; B : constv_float_ptr) return vector_unsigned_char is begin return To_LL_VUC (lvsr (A, To_PTR (B))); end vec_lvsr; -- vec_madd -- function vec_madd (A : vector_float; B : vector_float; C : vector_float) return vector_float is begin return vmaddfp (A, B, C); end vec_madd; -- vec_madds -- function vec_madds (A : vector_signed_short; B : vector_signed_short; C : vector_signed_short) return vector_signed_short is begin return vmhaddshs (A, B, C); end vec_madds; -- vec_max -- function vec_max (A : vector_bool_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vmaxub (To_LL_VSC (A), To_LL_VSC (B))); end vec_max; function vec_max (A : vector_unsigned_char; B : vector_bool_char) return vector_unsigned_char is begin return To_LL_VUC (vmaxub (To_LL_VSC (A), To_LL_VSC (B))); end vec_max; function vec_max (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vmaxub (To_LL_VSC (A), To_LL_VSC (B))); end vec_max; function vec_max (A : vector_bool_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vmaxsb (To_LL_VSC (A), To_LL_VSC (B))); end vec_max; function vec_max (A : vector_signed_char; B : vector_bool_char) return vector_signed_char is begin return To_LL_VSC (vmaxsb (To_LL_VSC (A), To_LL_VSC (B))); end vec_max; function vec_max (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vmaxsb (To_LL_VSC (A), To_LL_VSC (B))); end vec_max; function vec_max (A : vector_bool_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vmaxuh (To_LL_VSS (A), To_LL_VSS (B))); end vec_max; function vec_max (A : vector_unsigned_short; B : vector_bool_short) return vector_unsigned_short is begin return To_LL_VUS (vmaxuh (To_LL_VSS (A), To_LL_VSS (B))); end vec_max; function vec_max (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vmaxuh (To_LL_VSS (A), To_LL_VSS (B))); end vec_max; function vec_max (A : vector_bool_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vmaxsh (To_LL_VSS (A), To_LL_VSS (B))); end vec_max; function vec_max (A : vector_signed_short; B : vector_bool_short) return vector_signed_short is begin return To_LL_VSS (vmaxsh (To_LL_VSS (A), To_LL_VSS (B))); end vec_max; function vec_max (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vmaxsh (To_LL_VSS (A), To_LL_VSS (B))); end vec_max; function vec_max (A : vector_bool_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vmaxuw (To_LL_VSI (A), To_LL_VSI (B))); end vec_max; function vec_max (A : vector_unsigned_int; B : vector_bool_int) return vector_unsigned_int is begin return To_LL_VUI (vmaxuw (To_LL_VSI (A), To_LL_VSI (B))); end vec_max; function vec_max (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vmaxuw (To_LL_VSI (A), To_LL_VSI (B))); end vec_max; function vec_max (A : vector_bool_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vmaxsw (To_LL_VSI (A), To_LL_VSI (B))); end vec_max; function vec_max (A : vector_signed_int; B : vector_bool_int) return vector_signed_int is begin return To_LL_VSI (vmaxsw (To_LL_VSI (A), To_LL_VSI (B))); end vec_max; function vec_max (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vmaxsw (To_LL_VSI (A), To_LL_VSI (B))); end vec_max; function vec_max (A : vector_float; B : vector_float) return vector_float is begin return To_LL_VF (vmaxfp (To_LL_VF (A), To_LL_VF (B))); end vec_max; -- vec_vmaxfp -- function vec_vmaxfp (A : vector_float; B : vector_float) return vector_float is begin return To_LL_VF (vmaxfp (To_LL_VF (A), To_LL_VF (B))); end vec_vmaxfp; -- vec_vmaxsw -- function vec_vmaxsw (A : vector_bool_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vmaxsw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vmaxsw; function vec_vmaxsw (A : vector_signed_int; B : vector_bool_int) return vector_signed_int is begin return To_LL_VSI (vmaxsw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vmaxsw; function vec_vmaxsw (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vmaxsw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vmaxsw; -- vec_vmaxuw -- function vec_vmaxuw (A : vector_bool_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vmaxuw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vmaxuw; function vec_vmaxuw (A : vector_unsigned_int; B : vector_bool_int) return vector_unsigned_int is begin return To_LL_VUI (vmaxuw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vmaxuw; function vec_vmaxuw (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vmaxuw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vmaxuw; -- vec_vmaxsh -- function vec_vmaxsh (A : vector_bool_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vmaxsh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmaxsh; function vec_vmaxsh (A : vector_signed_short; B : vector_bool_short) return vector_signed_short is begin return To_LL_VSS (vmaxsh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmaxsh; function vec_vmaxsh (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vmaxsh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmaxsh; -- vec_vmaxuh -- function vec_vmaxuh (A : vector_bool_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vmaxuh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmaxuh; function vec_vmaxuh (A : vector_unsigned_short; B : vector_bool_short) return vector_unsigned_short is begin return To_LL_VUS (vmaxuh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmaxuh; function vec_vmaxuh (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vmaxuh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmaxuh; -- vec_vmaxsb -- function vec_vmaxsb (A : vector_bool_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vmaxsb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vmaxsb; function vec_vmaxsb (A : vector_signed_char; B : vector_bool_char) return vector_signed_char is begin return To_LL_VSC (vmaxsb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vmaxsb; function vec_vmaxsb (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vmaxsb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vmaxsb; -- vec_vmaxub -- function vec_vmaxub (A : vector_bool_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vmaxub (To_LL_VSC (A), To_LL_VSC (B))); end vec_vmaxub; function vec_vmaxub (A : vector_unsigned_char; B : vector_bool_char) return vector_unsigned_char is begin return To_LL_VUC (vmaxub (To_LL_VSC (A), To_LL_VSC (B))); end vec_vmaxub; function vec_vmaxub (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vmaxub (To_LL_VSC (A), To_LL_VSC (B))); end vec_vmaxub; -- vec_mergeh -- function vec_mergeh (A : vector_bool_char; B : vector_bool_char) return vector_bool_char is begin return To_LL_VBC (vmrghb (To_LL_VSC (A), To_LL_VSC (B))); end vec_mergeh; function vec_mergeh (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vmrghb (To_LL_VSC (A), To_LL_VSC (B))); end vec_mergeh; function vec_mergeh (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vmrghb (To_LL_VSC (A), To_LL_VSC (B))); end vec_mergeh; function vec_mergeh (A : vector_bool_short; B : vector_bool_short) return vector_bool_short is begin return To_LL_VBS (vmrghh (To_LL_VSS (A), To_LL_VSS (B))); end vec_mergeh; function vec_mergeh (A : vector_pixel; B : vector_pixel) return vector_pixel is begin return To_LL_VP (vmrghh (To_LL_VSS (A), To_LL_VSS (B))); end vec_mergeh; function vec_mergeh (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vmrghh (To_LL_VSS (A), To_LL_VSS (B))); end vec_mergeh; function vec_mergeh (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vmrghh (To_LL_VSS (A), To_LL_VSS (B))); end vec_mergeh; function vec_mergeh (A : vector_float; B : vector_float) return vector_float is begin return To_LL_VF (vmrghw (To_LL_VSI (A), To_LL_VSI (B))); end vec_mergeh; function vec_mergeh (A : vector_bool_int; B : vector_bool_int) return vector_bool_int is begin return To_LL_VBI (vmrghw (To_LL_VSI (A), To_LL_VSI (B))); end vec_mergeh; function vec_mergeh (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vmrghw (To_LL_VSI (A), To_LL_VSI (B))); end vec_mergeh; function vec_mergeh (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vmrghw (To_LL_VSI (A), To_LL_VSI (B))); end vec_mergeh; -- vec_vmrghw -- function vec_vmrghw (A : vector_float; B : vector_float) return vector_float is begin return To_LL_VF (vmrghw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vmrghw; function vec_vmrghw (A : vector_bool_int; B : vector_bool_int) return vector_bool_int is begin return To_LL_VBI (vmrghw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vmrghw; function vec_vmrghw (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vmrghw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vmrghw; function vec_vmrghw (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vmrghw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vmrghw; -- vec_vmrghh -- function vec_vmrghh (A : vector_bool_short; B : vector_bool_short) return vector_bool_short is begin return To_LL_VBS (vmrghh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmrghh; function vec_vmrghh (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vmrghh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmrghh; function vec_vmrghh (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vmrghh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmrghh; function vec_vmrghh (A : vector_pixel; B : vector_pixel) return vector_pixel is begin return To_LL_VP (vmrghh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmrghh; -- vec_vmrghb -- function vec_vmrghb (A : vector_bool_char; B : vector_bool_char) return vector_bool_char is begin return To_LL_VBC (vmrghb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vmrghb; function vec_vmrghb (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vmrghb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vmrghb; function vec_vmrghb (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vmrghb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vmrghb; -- vec_mergel -- function vec_mergel (A : vector_bool_char; B : vector_bool_char) return vector_bool_char is begin return To_LL_VBC (vmrglb (To_LL_VSC (A), To_LL_VSC (B))); end vec_mergel; function vec_mergel (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vmrglb (To_LL_VSC (A), To_LL_VSC (B))); end vec_mergel; function vec_mergel (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vmrglb (To_LL_VSC (A), To_LL_VSC (B))); end vec_mergel; function vec_mergel (A : vector_bool_short; B : vector_bool_short) return vector_bool_short is begin return To_LL_VBS (vmrglh (To_LL_VSS (A), To_LL_VSS (B))); end vec_mergel; function vec_mergel (A : vector_pixel; B : vector_pixel) return vector_pixel is begin return To_LL_VP (vmrglh (To_LL_VSS (A), To_LL_VSS (B))); end vec_mergel; function vec_mergel (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vmrglh (To_LL_VSS (A), To_LL_VSS (B))); end vec_mergel; function vec_mergel (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vmrglh (To_LL_VSS (A), To_LL_VSS (B))); end vec_mergel; function vec_mergel (A : vector_float; B : vector_float) return vector_float is begin return To_LL_VF (vmrglw (To_LL_VSI (A), To_LL_VSI (B))); end vec_mergel; function vec_mergel (A : vector_bool_int; B : vector_bool_int) return vector_bool_int is begin return To_LL_VBI (vmrglw (To_LL_VSI (A), To_LL_VSI (B))); end vec_mergel; function vec_mergel (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vmrglw (To_LL_VSI (A), To_LL_VSI (B))); end vec_mergel; function vec_mergel (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vmrglw (To_LL_VSI (A), To_LL_VSI (B))); end vec_mergel; -- vec_vmrglw -- function vec_vmrglw (A : vector_float; B : vector_float) return vector_float is begin return To_LL_VF (vmrglw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vmrglw; function vec_vmrglw (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vmrglw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vmrglw; function vec_vmrglw (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vmrglw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vmrglw; function vec_vmrglw (A : vector_bool_int; B : vector_bool_int) return vector_bool_int is begin return To_LL_VBI (vmrglw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vmrglw; -- vec_vmrglh -- function vec_vmrglh (A : vector_bool_short; B : vector_bool_short) return vector_bool_short is begin return To_LL_VBS (vmrglh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmrglh; function vec_vmrglh (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vmrglh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmrglh; function vec_vmrglh (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vmrglh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmrglh; function vec_vmrglh (A : vector_pixel; B : vector_pixel) return vector_pixel is begin return To_LL_VP (vmrglh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmrglh; -- vec_vmrglb -- function vec_vmrglb (A : vector_bool_char; B : vector_bool_char) return vector_bool_char is begin return To_LL_VBC (vmrglb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vmrglb; function vec_vmrglb (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vmrglb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vmrglb; function vec_vmrglb (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vmrglb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vmrglb; -- vec_mfvscr -- function vec_mfvscr return vector_unsigned_short is begin return To_LL_VUS (mfvscr); end vec_mfvscr; -- vec_min -- function vec_min (A : vector_bool_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vminub (To_LL_VSC (A), To_LL_VSC (B))); end vec_min; function vec_min (A : vector_unsigned_char; B : vector_bool_char) return vector_unsigned_char is begin return To_LL_VUC (vminub (To_LL_VSC (A), To_LL_VSC (B))); end vec_min; function vec_min (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vminub (To_LL_VSC (A), To_LL_VSC (B))); end vec_min; function vec_min (A : vector_bool_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vminsb (To_LL_VSC (A), To_LL_VSC (B))); end vec_min; function vec_min (A : vector_signed_char; B : vector_bool_char) return vector_signed_char is begin return To_LL_VSC (vminsb (To_LL_VSC (A), To_LL_VSC (B))); end vec_min; function vec_min (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vminsb (To_LL_VSC (A), To_LL_VSC (B))); end vec_min; function vec_min (A : vector_bool_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vminuh (To_LL_VSS (A), To_LL_VSS (B))); end vec_min; function vec_min (A : vector_unsigned_short; B : vector_bool_short) return vector_unsigned_short is begin return To_LL_VUS (vminuh (To_LL_VSS (A), To_LL_VSS (B))); end vec_min; function vec_min (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vminuh (To_LL_VSS (A), To_LL_VSS (B))); end vec_min; function vec_min (A : vector_bool_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vminsh (To_LL_VSS (A), To_LL_VSS (B))); end vec_min; function vec_min (A : vector_signed_short; B : vector_bool_short) return vector_signed_short is begin return To_LL_VSS (vminsh (To_LL_VSS (A), To_LL_VSS (B))); end vec_min; function vec_min (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vminsh (To_LL_VSS (A), To_LL_VSS (B))); end vec_min; function vec_min (A : vector_bool_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vminuw (To_LL_VSI (A), To_LL_VSI (B))); end vec_min; function vec_min (A : vector_unsigned_int; B : vector_bool_int) return vector_unsigned_int is begin return To_LL_VUI (vminuw (To_LL_VSI (A), To_LL_VSI (B))); end vec_min; function vec_min (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vminuw (To_LL_VSI (A), To_LL_VSI (B))); end vec_min; function vec_min (A : vector_bool_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vminsw (To_LL_VSI (A), To_LL_VSI (B))); end vec_min; function vec_min (A : vector_signed_int; B : vector_bool_int) return vector_signed_int is begin return To_LL_VSI (vminsw (To_LL_VSI (A), To_LL_VSI (B))); end vec_min; function vec_min (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vminsw (To_LL_VSI (A), To_LL_VSI (B))); end vec_min; function vec_min (A : vector_float; B : vector_float) return vector_float is begin return To_LL_VF (vminfp (To_LL_VF (A), To_LL_VF (B))); end vec_min; -- vec_vminfp -- function vec_vminfp (A : vector_float; B : vector_float) return vector_float is begin return To_LL_VF (vminfp (To_LL_VF (A), To_LL_VF (B))); end vec_vminfp; -- vec_vminsw -- function vec_vminsw (A : vector_bool_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vminsw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vminsw; function vec_vminsw (A : vector_signed_int; B : vector_bool_int) return vector_signed_int is begin return To_LL_VSI (vminsw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vminsw; function vec_vminsw (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vminsw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vminsw; -- vec_vminuw -- function vec_vminuw (A : vector_bool_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vminuw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vminuw; function vec_vminuw (A : vector_unsigned_int; B : vector_bool_int) return vector_unsigned_int is begin return To_LL_VUI (vminuw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vminuw; function vec_vminuw (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vminuw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vminuw; -- vec_vminsh -- function vec_vminsh (A : vector_bool_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vminsh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vminsh; function vec_vminsh (A : vector_signed_short; B : vector_bool_short) return vector_signed_short is begin return To_LL_VSS (vminsh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vminsh; function vec_vminsh (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vminsh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vminsh; -- vec_vminuh -- function vec_vminuh (A : vector_bool_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vminuh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vminuh; function vec_vminuh (A : vector_unsigned_short; B : vector_bool_short) return vector_unsigned_short is begin return To_LL_VUS (vminuh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vminuh; function vec_vminuh (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vminuh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vminuh; -- vec_vminsb -- function vec_vminsb (A : vector_bool_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vminsb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vminsb; function vec_vminsb (A : vector_signed_char; B : vector_bool_char) return vector_signed_char is begin return To_LL_VSC (vminsb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vminsb; function vec_vminsb (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vminsb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vminsb; -- vec_vminub -- function vec_vminub (A : vector_bool_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vminub (To_LL_VSC (A), To_LL_VSC (B))); end vec_vminub; function vec_vminub (A : vector_unsigned_char; B : vector_bool_char) return vector_unsigned_char is begin return To_LL_VUC (vminub (To_LL_VSC (A), To_LL_VSC (B))); end vec_vminub; function vec_vminub (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vminub (To_LL_VSC (A), To_LL_VSC (B))); end vec_vminub; -- vec_mladd -- function vec_mladd (A : vector_signed_short; B : vector_signed_short; C : vector_signed_short) return vector_signed_short is begin return vmladduhm (A, B, C); end vec_mladd; function vec_mladd (A : vector_signed_short; B : vector_unsigned_short; C : vector_unsigned_short) return vector_signed_short is begin return vmladduhm (A, To_LL_VSS (B), To_LL_VSS (C)); end vec_mladd; function vec_mladd (A : vector_unsigned_short; B : vector_signed_short; C : vector_signed_short) return vector_signed_short is begin return vmladduhm (To_LL_VSS (A), B, C); end vec_mladd; function vec_mladd (A : vector_unsigned_short; B : vector_unsigned_short; C : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vmladduhm (To_LL_VSS (A), To_LL_VSS (B), To_LL_VSS (C))); end vec_mladd; -- vec_mradds -- function vec_mradds (A : vector_signed_short; B : vector_signed_short; C : vector_signed_short) return vector_signed_short is begin return vmhraddshs (A, B, C); end vec_mradds; -- vec_msum -- function vec_msum (A : vector_unsigned_char; B : vector_unsigned_char; C : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vmsumubm (To_LL_VSC (A), To_LL_VSC (B), To_LL_VSI (C))); end vec_msum; function vec_msum (A : vector_signed_char; B : vector_unsigned_char; C : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vmsummbm (To_LL_VSC (A), To_LL_VSC (B), To_LL_VSI (C))); end vec_msum; function vec_msum (A : vector_unsigned_short; B : vector_unsigned_short; C : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vmsumuhm (To_LL_VSS (A), To_LL_VSS (B), To_LL_VSI (C))); end vec_msum; function vec_msum (A : vector_signed_short; B : vector_signed_short; C : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vmsumshm (To_LL_VSS (A), To_LL_VSS (B), To_LL_VSI (C))); end vec_msum; -- vec_vmsumshm -- function vec_vmsumshm (A : vector_signed_short; B : vector_signed_short; C : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vmsumshm (To_LL_VSS (A), To_LL_VSS (B), To_LL_VSI (C))); end vec_vmsumshm; -- vec_vmsumuhm -- function vec_vmsumuhm (A : vector_unsigned_short; B : vector_unsigned_short; C : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vmsumuhm (To_LL_VSS (A), To_LL_VSS (B), To_LL_VSI (C))); end vec_vmsumuhm; -- vec_vmsummbm -- function vec_vmsummbm (A : vector_signed_char; B : vector_unsigned_char; C : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vmsummbm (To_LL_VSC (A), To_LL_VSC (B), To_LL_VSI (C))); end vec_vmsummbm; -- vec_vmsumubm -- function vec_vmsumubm (A : vector_unsigned_char; B : vector_unsigned_char; C : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vmsumubm (To_LL_VSC (A), To_LL_VSC (B), To_LL_VSI (C))); end vec_vmsumubm; -- vec_msums -- function vec_msums (A : vector_unsigned_short; B : vector_unsigned_short; C : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vmsumuhs (To_LL_VSS (A), To_LL_VSS (B), To_LL_VSI (C))); end vec_msums; function vec_msums (A : vector_signed_short; B : vector_signed_short; C : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vmsumshs (To_LL_VSS (A), To_LL_VSS (B), To_LL_VSI (C))); end vec_msums; -- vec_vmsumshs -- function vec_vmsumshs (A : vector_signed_short; B : vector_signed_short; C : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vmsumshs (To_LL_VSS (A), To_LL_VSS (B), To_LL_VSI (C))); end vec_vmsumshs; -- vec_vmsumuhs -- function vec_vmsumuhs (A : vector_unsigned_short; B : vector_unsigned_short; C : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vmsumuhs (To_LL_VSS (A), To_LL_VSS (B), To_LL_VSI (C))); end vec_vmsumuhs; -- vec_mtvscr -- procedure vec_mtvscr (A : vector_signed_int) is begin mtvscr (To_LL_VSI (A)); end vec_mtvscr; procedure vec_mtvscr (A : vector_unsigned_int) is begin mtvscr (To_LL_VSI (A)); end vec_mtvscr; procedure vec_mtvscr (A : vector_bool_int) is begin mtvscr (To_LL_VSI (A)); end vec_mtvscr; procedure vec_mtvscr (A : vector_signed_short) is begin mtvscr (To_LL_VSI (A)); end vec_mtvscr; procedure vec_mtvscr (A : vector_unsigned_short) is begin mtvscr (To_LL_VSI (A)); end vec_mtvscr; procedure vec_mtvscr (A : vector_bool_short) is begin mtvscr (To_LL_VSI (A)); end vec_mtvscr; procedure vec_mtvscr (A : vector_pixel) is begin mtvscr (To_LL_VSI (A)); end vec_mtvscr; procedure vec_mtvscr (A : vector_signed_char) is begin mtvscr (To_LL_VSI (A)); end vec_mtvscr; procedure vec_mtvscr (A : vector_unsigned_char) is begin mtvscr (To_LL_VSI (A)); end vec_mtvscr; procedure vec_mtvscr (A : vector_bool_char) is begin mtvscr (To_LL_VSI (A)); end vec_mtvscr; -- vec_mule -- function vec_mule (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_short is begin return To_LL_VUS (vmuleub (To_LL_VSC (A), To_LL_VSC (B))); end vec_mule; function vec_mule (A : vector_signed_char; B : vector_signed_char) return vector_signed_short is begin return To_LL_VSS (vmulesb (To_LL_VSC (A), To_LL_VSC (B))); end vec_mule; function vec_mule (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_int is begin return To_LL_VUI (vmuleuh (To_LL_VSS (A), To_LL_VSS (B))); end vec_mule; function vec_mule (A : vector_signed_short; B : vector_signed_short) return vector_signed_int is begin return To_LL_VSI (vmulesh (To_LL_VSS (A), To_LL_VSS (B))); end vec_mule; -- vec_vmulesh -- function vec_vmulesh (A : vector_signed_short; B : vector_signed_short) return vector_signed_int is begin return To_LL_VSI (vmulesh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmulesh; -- vec_vmuleuh -- function vec_vmuleuh (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_int is begin return To_LL_VUI (vmuleuh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmuleuh; -- vec_vmulesb -- function vec_vmulesb (A : vector_signed_char; B : vector_signed_char) return vector_signed_short is begin return To_LL_VSS (vmuleub (To_LL_VSC (A), To_LL_VSC (B))); end vec_vmulesb; -- vec_vmuleub -- function vec_vmuleub (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_short is begin return To_LL_VUS (vmuleub (To_LL_VSC (A), To_LL_VSC (B))); end vec_vmuleub; -- vec_mulo -- function vec_mulo (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_short is begin return To_LL_VUS (vmuloub (To_LL_VSC (A), To_LL_VSC (B))); end vec_mulo; function vec_mulo (A : vector_signed_char; B : vector_signed_char) return vector_signed_short is begin return To_LL_VSS (vmulosb (To_LL_VSC (A), To_LL_VSC (B))); end vec_mulo; function vec_mulo (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_int is begin return To_LL_VUI (vmulouh (To_LL_VSS (A), To_LL_VSS (B))); end vec_mulo; function vec_mulo (A : vector_signed_short; B : vector_signed_short) return vector_signed_int is begin return To_LL_VSI (vmulosh (To_LL_VSS (A), To_LL_VSS (B))); end vec_mulo; -- vec_vmulosh -- function vec_vmulosh (A : vector_signed_short; B : vector_signed_short) return vector_signed_int is begin return To_LL_VSI (vmulosh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmulosh; -- vec_vmulouh -- function vec_vmulouh (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_int is begin return To_LL_VUI (vmulouh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vmulouh; -- vec_vmulosb -- function vec_vmulosb (A : vector_signed_char; B : vector_signed_char) return vector_signed_short is begin return To_LL_VSS (vmulosb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vmulosb; -- vec_vmuloub -- function vec_vmuloub (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_short is begin return To_LL_VUS (vmuloub (To_LL_VSC (A), To_LL_VSC (B))); end vec_vmuloub; -- vec_nmsub -- function vec_nmsub (A : vector_float; B : vector_float; C : vector_float) return vector_float is begin return To_LL_VF (vnmsubfp (To_LL_VF (A), To_LL_VF (B), To_LL_VF (C))); end vec_nmsub; -- vec_nor -- function vec_nor (A : vector_float; B : vector_float) return vector_float is begin return To_LL_VF (vnor (To_LL_VSI (A), To_LL_VSI (B))); end vec_nor; function vec_nor (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vnor (To_LL_VSI (A), To_LL_VSI (B))); end vec_nor; function vec_nor (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vnor (To_LL_VSI (A), To_LL_VSI (B))); end vec_nor; function vec_nor (A : vector_bool_int; B : vector_bool_int) return vector_bool_int is begin return To_LL_VBI (vnor (To_LL_VSI (A), To_LL_VSI (B))); end vec_nor; function vec_nor (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vnor (To_LL_VSI (A), To_LL_VSI (B))); end vec_nor; function vec_nor (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vnor (To_LL_VSI (A), To_LL_VSI (B))); end vec_nor; function vec_nor (A : vector_bool_short; B : vector_bool_short) return vector_bool_short is begin return To_LL_VBS (vnor (To_LL_VSI (A), To_LL_VSI (B))); end vec_nor; function vec_nor (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vnor (To_LL_VSI (A), To_LL_VSI (B))); end vec_nor; function vec_nor (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vnor (To_LL_VSI (A), To_LL_VSI (B))); end vec_nor; function vec_nor (A : vector_bool_char; B : vector_bool_char) return vector_bool_char is begin return To_LL_VBC (vnor (To_LL_VSI (A), To_LL_VSI (B))); end vec_nor; -- vec_or -- function vec_or (A : vector_float; B : vector_float) return vector_float is begin return To_LL_VF (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_float; B : vector_bool_int) return vector_float is begin return To_LL_VF (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_bool_int; B : vector_float) return vector_float is begin return To_LL_VF (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_bool_int; B : vector_bool_int) return vector_bool_int is begin return To_LL_VBI (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_bool_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_signed_int; B : vector_bool_int) return vector_signed_int is begin return To_LL_VSI (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_bool_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_unsigned_int; B : vector_bool_int) return vector_unsigned_int is begin return To_LL_VUI (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_bool_short; B : vector_bool_short) return vector_bool_short is begin return To_LL_VBS (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_bool_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_signed_short; B : vector_bool_short) return vector_signed_short is begin return To_LL_VSS (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_bool_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_unsigned_short; B : vector_bool_short) return vector_unsigned_short is begin return To_LL_VUS (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_bool_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_bool_char; B : vector_bool_char) return vector_bool_char is begin return To_LL_VBC (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_signed_char; B : vector_bool_char) return vector_signed_char is begin return To_LL_VSC (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_bool_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_unsigned_char; B : vector_bool_char) return vector_unsigned_char is begin return To_LL_VUC (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; function vec_or (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vor (To_LL_VSI (A), To_LL_VSI (B))); end vec_or; -- vec_pack -- function vec_pack (A : vector_signed_short; B : vector_signed_short) return vector_signed_char is begin return To_LL_VSC (vpkuhum (To_LL_VSS (A), To_LL_VSS (B))); end vec_pack; function vec_pack (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_char is begin return To_LL_VUC (vpkuhum (To_LL_VSS (A), To_LL_VSS (B))); end vec_pack; function vec_pack (A : vector_bool_short; B : vector_bool_short) return vector_bool_char is begin return To_LL_VBC (vpkuhum (To_LL_VSS (A), To_LL_VSS (B))); end vec_pack; function vec_pack (A : vector_signed_int; B : vector_signed_int) return vector_signed_short is begin return To_LL_VSS (vpkuwum (To_LL_VSI (A), To_LL_VSI (B))); end vec_pack; function vec_pack (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_short is begin return To_LL_VUS (vpkuwum (To_LL_VSI (A), To_LL_VSI (B))); end vec_pack; function vec_pack (A : vector_bool_int; B : vector_bool_int) return vector_bool_short is begin return To_LL_VBS (vpkuwum (To_LL_VSI (A), To_LL_VSI (B))); end vec_pack; -- vec_vpkuwum -- function vec_vpkuwum (A : vector_bool_int; B : vector_bool_int) return vector_bool_short is begin return To_LL_VBS (vpkuwum (To_LL_VSI (A), To_LL_VSI (B))); end vec_vpkuwum; function vec_vpkuwum (A : vector_signed_int; B : vector_signed_int) return vector_signed_short is begin return To_LL_VSS (vpkuwum (To_LL_VSI (A), To_LL_VSI (B))); end vec_vpkuwum; function vec_vpkuwum (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_short is begin return To_LL_VUS (vpkuwum (To_LL_VSI (A), To_LL_VSI (B))); end vec_vpkuwum; -- vec_vpkuhum -- function vec_vpkuhum (A : vector_bool_short; B : vector_bool_short) return vector_bool_char is begin return To_LL_VBC (vpkuhum (To_LL_VSS (A), To_LL_VSS (B))); end vec_vpkuhum; function vec_vpkuhum (A : vector_signed_short; B : vector_signed_short) return vector_signed_char is begin return To_LL_VSC (vpkuhum (To_LL_VSS (A), To_LL_VSS (B))); end vec_vpkuhum; function vec_vpkuhum (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_char is begin return To_LL_VUC (vpkuhum (To_LL_VSS (A), To_LL_VSS (B))); end vec_vpkuhum; -- vec_packpx -- function vec_packpx (A : vector_unsigned_int; B : vector_unsigned_int) return vector_pixel is begin return To_LL_VP (vpkpx (To_LL_VSI (A), To_LL_VSI (B))); end vec_packpx; -- vec_packs -- function vec_packs (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_char is begin return To_LL_VUC (vpkuhus (To_LL_VSS (A), To_LL_VSS (B))); end vec_packs; function vec_packs (A : vector_signed_short; B : vector_signed_short) return vector_signed_char is begin return To_LL_VSC (vpkshss (To_LL_VSS (A), To_LL_VSS (B))); end vec_packs; function vec_packs (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_short is begin return To_LL_VUS (vpkuwus (To_LL_VSI (A), To_LL_VSI (B))); end vec_packs; function vec_packs (A : vector_signed_int; B : vector_signed_int) return vector_signed_short is begin return To_LL_VSS (vpkswss (To_LL_VSI (A), To_LL_VSI (B))); end vec_packs; -- vec_vpkswss -- function vec_vpkswss (A : vector_signed_int; B : vector_signed_int) return vector_signed_short is begin return To_LL_VSS (vpkswss (To_LL_VSI (A), To_LL_VSI (B))); end vec_vpkswss; -- vec_vpkuwus -- function vec_vpkuwus (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_short is begin return To_LL_VUS (vpkuwus (To_LL_VSI (A), To_LL_VSI (B))); end vec_vpkuwus; -- vec_vpkshss -- function vec_vpkshss (A : vector_signed_short; B : vector_signed_short) return vector_signed_char is begin return To_LL_VSC (vpkshss (To_LL_VSS (A), To_LL_VSS (B))); end vec_vpkshss; -- vec_vpkuhus -- function vec_vpkuhus (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_char is begin return To_LL_VUC (vpkuhus (To_LL_VSS (A), To_LL_VSS (B))); end vec_vpkuhus; -- vec_packsu -- function vec_packsu (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_char is begin return To_LL_VUC (vpkuhus (To_LL_VSS (A), To_LL_VSS (B))); end vec_packsu; function vec_packsu (A : vector_signed_short; B : vector_signed_short) return vector_unsigned_char is begin return To_LL_VUC (vpkshus (To_LL_VSS (A), To_LL_VSS (B))); end vec_packsu; function vec_packsu (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_short is begin return To_LL_VUS (vpkuwus (To_LL_VSI (A), To_LL_VSI (B))); end vec_packsu; function vec_packsu (A : vector_signed_int; B : vector_signed_int) return vector_unsigned_short is begin return To_LL_VUS (vpkswus (To_LL_VSI (A), To_LL_VSI (B))); end vec_packsu; -- vec_vpkswus -- function vec_vpkswus (A : vector_signed_int; B : vector_signed_int) return vector_unsigned_short is begin return To_LL_VUS (vpkswus (To_LL_VSI (A), To_LL_VSI (B))); end vec_vpkswus; -- vec_vpkshus -- function vec_vpkshus (A : vector_signed_short; B : vector_signed_short) return vector_unsigned_char is begin return To_LL_VUC (vpkshus (To_LL_VSS (A), To_LL_VSS (B))); end vec_vpkshus; -- vec_perm -- function vec_perm (A : vector_float; B : vector_float; C : vector_unsigned_char) return vector_float is begin return To_LL_VF (vperm_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSC (C))); end vec_perm; function vec_perm (A : vector_signed_int; B : vector_signed_int; C : vector_unsigned_char) return vector_signed_int is begin return To_LL_VSI (vperm_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSC (C))); end vec_perm; function vec_perm (A : vector_unsigned_int; B : vector_unsigned_int; C : vector_unsigned_char) return vector_unsigned_int is begin return To_LL_VUI (vperm_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSC (C))); end vec_perm; function vec_perm (A : vector_bool_int; B : vector_bool_int; C : vector_unsigned_char) return vector_bool_int is begin return To_LL_VBI (vperm_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSC (C))); end vec_perm; function vec_perm (A : vector_signed_short; B : vector_signed_short; C : vector_unsigned_char) return vector_signed_short is begin return To_LL_VSS (vperm_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSC (C))); end vec_perm; function vec_perm (A : vector_unsigned_short; B : vector_unsigned_short; C : vector_unsigned_char) return vector_unsigned_short is begin return To_LL_VUS (vperm_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSC (C))); end vec_perm; function vec_perm (A : vector_bool_short; B : vector_bool_short; C : vector_unsigned_char) return vector_bool_short is begin return To_LL_VBS (vperm_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSC (C))); end vec_perm; function vec_perm (A : vector_pixel; B : vector_pixel; C : vector_unsigned_char) return vector_pixel is begin return To_LL_VP (vperm_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSC (C))); end vec_perm; function vec_perm (A : vector_signed_char; B : vector_signed_char; C : vector_unsigned_char) return vector_signed_char is begin return To_LL_VSC (vperm_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSC (C))); end vec_perm; function vec_perm (A : vector_unsigned_char; B : vector_unsigned_char; C : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vperm_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSC (C))); end vec_perm; function vec_perm (A : vector_bool_char; B : vector_bool_char; C : vector_unsigned_char) return vector_bool_char is begin return To_LL_VBC (vperm_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSC (C))); end vec_perm; -- vec_re -- function vec_re (A : vector_float) return vector_float is begin return To_LL_VF (vrefp (To_LL_VF (A))); end vec_re; -- vec_rl -- function vec_rl (A : vector_signed_char; B : vector_unsigned_char) return vector_signed_char is begin return To_LL_VSC (vrlb (To_LL_VSC (A), To_LL_VSC (B))); end vec_rl; function vec_rl (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vrlb (To_LL_VSC (A), To_LL_VSC (B))); end vec_rl; function vec_rl (A : vector_signed_short; B : vector_unsigned_short) return vector_signed_short is begin return To_LL_VSS (vrlh (To_LL_VSS (A), To_LL_VSS (B))); end vec_rl; function vec_rl (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vrlh (To_LL_VSS (A), To_LL_VSS (B))); end vec_rl; function vec_rl (A : vector_signed_int; B : vector_unsigned_int) return vector_signed_int is begin return To_LL_VSI (vrlw (To_LL_VSI (A), To_LL_VSI (B))); end vec_rl; function vec_rl (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vrlw (To_LL_VSI (A), To_LL_VSI (B))); end vec_rl; -- vec_vrlw -- function vec_vrlw (A : vector_signed_int; B : vector_unsigned_int) return vector_signed_int is begin return To_LL_VSI (vrlw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vrlw; function vec_vrlw (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vrlw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vrlw; -- vec_vrlh -- function vec_vrlh (A : vector_signed_short; B : vector_unsigned_short) return vector_signed_short is begin return To_LL_VSS (vrlh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vrlh; function vec_vrlh (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vrlh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vrlh; -- vec_vrlb -- function vec_vrlb (A : vector_signed_char; B : vector_unsigned_char) return vector_signed_char is begin return To_LL_VSC (vrlb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vrlb; function vec_vrlb (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vrlb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vrlb; -- vec_round -- function vec_round (A : vector_float) return vector_float is begin return To_LL_VF (vrfin (To_LL_VF (A))); end vec_round; -- vec_rsqrte -- function vec_rsqrte (A : vector_float) return vector_float is begin return To_LL_VF (vrsqrtefp (To_LL_VF (A))); end vec_rsqrte; -- vec_sel -- function vec_sel (A : vector_float; B : vector_float; C : vector_bool_int) return vector_float is begin return To_LL_VF (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_float; B : vector_float; C : vector_unsigned_int) return vector_float is begin return To_LL_VF (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_signed_int; B : vector_signed_int; C : vector_bool_int) return vector_signed_int is begin return To_LL_VSI (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_signed_int; B : vector_signed_int; C : vector_unsigned_int) return vector_signed_int is begin return To_LL_VSI (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_unsigned_int; B : vector_unsigned_int; C : vector_bool_int) return vector_unsigned_int is begin return To_LL_VUI (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_unsigned_int; B : vector_unsigned_int; C : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_bool_int; B : vector_bool_int; C : vector_bool_int) return vector_bool_int is begin return To_LL_VBI (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_bool_int; B : vector_bool_int; C : vector_unsigned_int) return vector_bool_int is begin return To_LL_VBI (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_signed_short; B : vector_signed_short; C : vector_bool_short) return vector_signed_short is begin return To_LL_VSS (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_signed_short; B : vector_signed_short; C : vector_unsigned_short) return vector_signed_short is begin return To_LL_VSS (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_unsigned_short; B : vector_unsigned_short; C : vector_bool_short) return vector_unsigned_short is begin return To_LL_VUS (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_unsigned_short; B : vector_unsigned_short; C : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_bool_short; B : vector_bool_short; C : vector_bool_short) return vector_bool_short is begin return To_LL_VBS (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_bool_short; B : vector_bool_short; C : vector_unsigned_short) return vector_bool_short is begin return To_LL_VBS (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_signed_char; B : vector_signed_char; C : vector_bool_char) return vector_signed_char is begin return To_LL_VSC (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_signed_char; B : vector_signed_char; C : vector_unsigned_char) return vector_signed_char is begin return To_LL_VSC (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_unsigned_char; B : vector_unsigned_char; C : vector_bool_char) return vector_unsigned_char is begin return To_LL_VUC (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_unsigned_char; B : vector_unsigned_char; C : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_bool_char; B : vector_bool_char; C : vector_bool_char) return vector_bool_char is begin return To_LL_VBC (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; function vec_sel (A : vector_bool_char; B : vector_bool_char; C : vector_unsigned_char) return vector_bool_char is begin return To_LL_VBC (vsel_4si (To_LL_VSI (A), To_LL_VSI (B), To_LL_VSI (C))); end vec_sel; -- vec_sl -- function vec_sl (A : vector_signed_char; B : vector_unsigned_char) return vector_signed_char is begin return To_LL_VSC (vslb (To_LL_VSC (A), To_LL_VSC (B))); end vec_sl; function vec_sl (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vslb (To_LL_VSC (A), To_LL_VSC (B))); end vec_sl; function vec_sl (A : vector_signed_short; B : vector_unsigned_short) return vector_signed_short is begin return To_LL_VSS (vslh (To_LL_VSS (A), To_LL_VSS (B))); end vec_sl; function vec_sl (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vslh (To_LL_VSS (A), To_LL_VSS (B))); end vec_sl; function vec_sl (A : vector_signed_int; B : vector_unsigned_int) return vector_signed_int is begin return To_LL_VSI (vslw (To_LL_VSI (A), To_LL_VSI (B))); end vec_sl; function vec_sl (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vslw (To_LL_VSI (A), To_LL_VSI (B))); end vec_sl; -- vec_vslw -- function vec_vslw (A : vector_signed_int; B : vector_unsigned_int) return vector_signed_int is begin return To_LL_VSI (vslw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vslw; function vec_vslw (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vslw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vslw; -- vec_vslh -- function vec_vslh (A : vector_signed_short; B : vector_unsigned_short) return vector_signed_short is begin return To_LL_VSS (vslh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vslh; function vec_vslh (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vslh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vslh; -- vec_vslb -- function vec_vslb (A : vector_signed_char; B : vector_unsigned_char) return vector_signed_char is begin return To_LL_VSC (vslb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vslb; function vec_vslb (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vslb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vslb; -- vec_sll -- function vec_sll (A : vector_signed_int; B : vector_unsigned_int) return vector_signed_int is begin return To_LL_VSI (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_signed_int; B : vector_unsigned_short) return vector_signed_int is begin return To_LL_VSI (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_signed_int; B : vector_unsigned_char) return vector_signed_int is begin return To_LL_VSI (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_unsigned_int; B : vector_unsigned_short) return vector_unsigned_int is begin return To_LL_VUI (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_unsigned_int; B : vector_unsigned_char) return vector_unsigned_int is begin return To_LL_VUI (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_bool_int; B : vector_unsigned_int) return vector_bool_int is begin return To_LL_VBI (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_bool_int; B : vector_unsigned_short) return vector_bool_int is begin return To_LL_VBI (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_bool_int; B : vector_unsigned_char) return vector_bool_int is begin return To_LL_VBI (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_signed_short; B : vector_unsigned_int) return vector_signed_short is begin return To_LL_VSS (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_signed_short; B : vector_unsigned_short) return vector_signed_short is begin return To_LL_VSS (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_signed_short; B : vector_unsigned_char) return vector_signed_short is begin return To_LL_VSS (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_unsigned_short; B : vector_unsigned_int) return vector_unsigned_short is begin return To_LL_VUS (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_unsigned_short; B : vector_unsigned_char) return vector_unsigned_short is begin return To_LL_VUS (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_bool_short; B : vector_unsigned_int) return vector_bool_short is begin return To_LL_VBS (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_bool_short; B : vector_unsigned_short) return vector_bool_short is begin return To_LL_VBS (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_bool_short; B : vector_unsigned_char) return vector_bool_short is begin return To_LL_VBS (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_pixel; B : vector_unsigned_int) return vector_pixel is begin return To_LL_VP (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_pixel; B : vector_unsigned_short) return vector_pixel is begin return To_LL_VP (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_pixel; B : vector_unsigned_char) return vector_pixel is begin return To_LL_VP (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_signed_char; B : vector_unsigned_int) return vector_signed_char is begin return To_LL_VSC (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_signed_char; B : vector_unsigned_short) return vector_signed_char is begin return To_LL_VSC (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_signed_char; B : vector_unsigned_char) return vector_signed_char is begin return To_LL_VSC (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_unsigned_char; B : vector_unsigned_int) return vector_unsigned_char is begin return To_LL_VUC (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_unsigned_char; B : vector_unsigned_short) return vector_unsigned_char is begin return To_LL_VUC (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_bool_char; B : vector_unsigned_int) return vector_bool_char is begin return To_LL_VBC (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_bool_char; B : vector_unsigned_short) return vector_bool_char is begin return To_LL_VBC (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; function vec_sll (A : vector_bool_char; B : vector_unsigned_char) return vector_bool_char is begin return To_LL_VBC (vsl (To_LL_VSI (A), To_LL_VSI (B))); end vec_sll; -- vec_slo -- function vec_slo (A : vector_float; B : vector_signed_char) return vector_float is begin return To_LL_VF (vslo (To_LL_VSI (A), To_LL_VSI (B))); end vec_slo; function vec_slo (A : vector_float; B : vector_unsigned_char) return vector_float is begin return To_LL_VF (vslo (To_LL_VSI (A), To_LL_VSI (B))); end vec_slo; function vec_slo (A : vector_signed_int; B : vector_signed_char) return vector_signed_int is begin return To_LL_VSI (vslo (To_LL_VSI (A), To_LL_VSI (B))); end vec_slo; function vec_slo (A : vector_signed_int; B : vector_unsigned_char) return vector_signed_int is begin return To_LL_VSI (vslo (To_LL_VSI (A), To_LL_VSI (B))); end vec_slo; function vec_slo (A : vector_unsigned_int; B : vector_signed_char) return vector_unsigned_int is begin return To_LL_VUI (vslo (To_LL_VSI (A), To_LL_VSI (B))); end vec_slo; function vec_slo (A : vector_unsigned_int; B : vector_unsigned_char) return vector_unsigned_int is begin return To_LL_VUI (vslo (To_LL_VSI (A), To_LL_VSI (B))); end vec_slo; function vec_slo (A : vector_signed_short; B : vector_signed_char) return vector_signed_short is begin return To_LL_VSS (vslo (To_LL_VSI (A), To_LL_VSI (B))); end vec_slo; function vec_slo (A : vector_signed_short; B : vector_unsigned_char) return vector_signed_short is begin return To_LL_VSS (vslo (To_LL_VSI (A), To_LL_VSI (B))); end vec_slo; function vec_slo (A : vector_unsigned_short; B : vector_signed_char) return vector_unsigned_short is begin return To_LL_VUS (vslo (To_LL_VSI (A), To_LL_VSI (B))); end vec_slo; function vec_slo (A : vector_unsigned_short; B : vector_unsigned_char) return vector_unsigned_short is begin return To_LL_VUS (vslo (To_LL_VSI (A), To_LL_VSI (B))); end vec_slo; function vec_slo (A : vector_pixel; B : vector_signed_char) return vector_pixel is begin return To_LL_VP (vslo (To_LL_VSI (A), To_LL_VSI (B))); end vec_slo; function vec_slo (A : vector_pixel; B : vector_unsigned_char) return vector_pixel is begin return To_LL_VP (vslo (To_LL_VSI (A), To_LL_VSI (B))); end vec_slo; function vec_slo (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vslo (To_LL_VSI (A), To_LL_VSI (B))); end vec_slo; function vec_slo (A : vector_signed_char; B : vector_unsigned_char) return vector_signed_char is begin return To_LL_VSC (vslo (To_LL_VSI (A), To_LL_VSI (B))); end vec_slo; function vec_slo (A : vector_unsigned_char; B : vector_signed_char) return vector_unsigned_char is begin return To_LL_VUC (vslo (To_LL_VSI (A), To_LL_VSI (B))); end vec_slo; function vec_slo (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vslo (To_LL_VSI (A), To_LL_VSI (B))); end vec_slo; -- vec_sr -- function vec_sr (A : vector_signed_char; B : vector_unsigned_char) return vector_signed_char is begin return To_LL_VSC (vsrb (To_LL_VSC (A), To_LL_VSC (B))); end vec_sr; function vec_sr (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vsrb (To_LL_VSC (A), To_LL_VSC (B))); end vec_sr; function vec_sr (A : vector_signed_short; B : vector_unsigned_short) return vector_signed_short is begin return To_LL_VSS (vsrh (To_LL_VSS (A), To_LL_VSS (B))); end vec_sr; function vec_sr (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vsrh (To_LL_VSS (A), To_LL_VSS (B))); end vec_sr; function vec_sr (A : vector_signed_int; B : vector_unsigned_int) return vector_signed_int is begin return To_LL_VSI (vsrw (To_LL_VSI (A), To_LL_VSI (B))); end vec_sr; function vec_sr (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsrw (To_LL_VSI (A), To_LL_VSI (B))); end vec_sr; -- vec_vsrw -- function vec_vsrw (A : vector_signed_int; B : vector_unsigned_int) return vector_signed_int is begin return To_LL_VSI (vsrw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vsrw; function vec_vsrw (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsrw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vsrw; -- vec_vsrh -- function vec_vsrh (A : vector_signed_short; B : vector_unsigned_short) return vector_signed_short is begin return To_LL_VSS (vsrh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vsrh; function vec_vsrh (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vsrh (To_LL_VSS (A), To_LL_VSS (B))); end vec_vsrh; -- vec_vsrb -- function vec_vsrb (A : vector_signed_char; B : vector_unsigned_char) return vector_signed_char is begin return To_LL_VSC (vsrb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vsrb; function vec_vsrb (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vsrb (To_LL_VSC (A), To_LL_VSC (B))); end vec_vsrb; -- vec_sra -- function vec_sra (A : vector_signed_char; B : vector_unsigned_char) return vector_signed_char is begin return To_LL_VSC (vsrab (To_LL_VSC (A), To_LL_VSC (B))); end vec_sra; function vec_sra (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vsrab (To_LL_VSC (A), To_LL_VSC (B))); end vec_sra; function vec_sra (A : vector_signed_short; B : vector_unsigned_short) return vector_signed_short is begin return To_LL_VSS (vsrah (To_LL_VSS (A), To_LL_VSS (B))); end vec_sra; function vec_sra (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vsrah (To_LL_VSS (A), To_LL_VSS (B))); end vec_sra; function vec_sra (A : vector_signed_int; B : vector_unsigned_int) return vector_signed_int is begin return To_LL_VSI (vsraw (To_LL_VSI (A), To_LL_VSI (B))); end vec_sra; function vec_sra (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsraw (To_LL_VSI (A), To_LL_VSI (B))); end vec_sra; -- vec_vsraw -- function vec_vsraw (A : vector_signed_int; B : vector_unsigned_int) return vector_signed_int is begin return To_LL_VSI (vsraw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vsraw; function vec_vsraw (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsraw (To_LL_VSI (A), To_LL_VSI (B))); end vec_vsraw; -- vec_vsrah -- function vec_vsrah (A : vector_signed_short; B : vector_unsigned_short) return vector_signed_short is begin return To_LL_VSS (vsrah (To_LL_VSS (A), To_LL_VSS (B))); end vec_vsrah; function vec_vsrah (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vsrah (To_LL_VSS (A), To_LL_VSS (B))); end vec_vsrah; -- vec_vsrab -- function vec_vsrab (A : vector_signed_char; B : vector_unsigned_char) return vector_signed_char is begin return To_LL_VSC (vsrab (To_LL_VSC (A), To_LL_VSC (B))); end vec_vsrab; function vec_vsrab (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vsrab (To_LL_VSC (A), To_LL_VSC (B))); end vec_vsrab; -- vec_srl -- function vec_srl (A : vector_signed_int; B : vector_unsigned_int) return vector_signed_int is begin return To_LL_VSI (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_signed_int; B : vector_unsigned_short) return vector_signed_int is begin return To_LL_VSI (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_signed_int; B : vector_unsigned_char) return vector_signed_int is begin return To_LL_VSI (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_unsigned_int; B : vector_unsigned_short) return vector_unsigned_int is begin return To_LL_VUI (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_unsigned_int; B : vector_unsigned_char) return vector_unsigned_int is begin return To_LL_VUI (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_bool_int; B : vector_unsigned_int) return vector_bool_int is begin return To_LL_VBI (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_bool_int; B : vector_unsigned_short) return vector_bool_int is begin return To_LL_VBI (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_bool_int; B : vector_unsigned_char) return vector_bool_int is begin return To_LL_VBI (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_signed_short; B : vector_unsigned_int) return vector_signed_short is begin return To_LL_VSS (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_signed_short; B : vector_unsigned_short) return vector_signed_short is begin return To_LL_VSS (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_signed_short; B : vector_unsigned_char) return vector_signed_short is begin return To_LL_VSS (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_unsigned_short; B : vector_unsigned_int) return vector_unsigned_short is begin return To_LL_VUS (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_unsigned_short; B : vector_unsigned_char) return vector_unsigned_short is begin return To_LL_VUS (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_bool_short; B : vector_unsigned_int) return vector_bool_short is begin return To_LL_VBS (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_bool_short; B : vector_unsigned_short) return vector_bool_short is begin return To_LL_VBS (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_bool_short; B : vector_unsigned_char) return vector_bool_short is begin return To_LL_VBS (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_pixel; B : vector_unsigned_int) return vector_pixel is begin return To_LL_VP (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_pixel; B : vector_unsigned_short) return vector_pixel is begin return To_LL_VP (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_pixel; B : vector_unsigned_char) return vector_pixel is begin return To_LL_VP (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_signed_char; B : vector_unsigned_int) return vector_signed_char is begin return To_LL_VSC (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_signed_char; B : vector_unsigned_short) return vector_signed_char is begin return To_LL_VSC (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_signed_char; B : vector_unsigned_char) return vector_signed_char is begin return To_LL_VSC (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_unsigned_char; B : vector_unsigned_int) return vector_unsigned_char is begin return To_LL_VUC (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_unsigned_char; B : vector_unsigned_short) return vector_unsigned_char is begin return To_LL_VUC (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_bool_char; B : vector_unsigned_int) return vector_bool_char is begin return To_LL_VBC (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_bool_char; B : vector_unsigned_short) return vector_bool_char is begin return To_LL_VBC (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; function vec_srl (A : vector_bool_char; B : vector_unsigned_char) return vector_bool_char is begin return To_LL_VBC (vsr (To_LL_VSI (A), To_LL_VSI (B))); end vec_srl; -- vec_sro -- function vec_sro (A : vector_float; B : vector_signed_char) return vector_float is begin return To_LL_VF (vsro (To_LL_VSI (A), To_LL_VSI (B))); end vec_sro; function vec_sro (A : vector_float; B : vector_unsigned_char) return vector_float is begin return To_LL_VF (vsro (To_LL_VSI (A), To_LL_VSI (B))); end vec_sro; function vec_sro (A : vector_signed_int; B : vector_signed_char) return vector_signed_int is begin return To_LL_VSI (vsro (To_LL_VSI (A), To_LL_VSI (B))); end vec_sro; function vec_sro (A : vector_signed_int; B : vector_unsigned_char) return vector_signed_int is begin return To_LL_VSI (vsro (To_LL_VSI (A), To_LL_VSI (B))); end vec_sro; function vec_sro (A : vector_unsigned_int; B : vector_signed_char) return vector_unsigned_int is begin return To_LL_VUI (vsro (To_LL_VSI (A), To_LL_VSI (B))); end vec_sro; function vec_sro (A : vector_unsigned_int; B : vector_unsigned_char) return vector_unsigned_int is begin return To_LL_VUI (vsro (To_LL_VSI (A), To_LL_VSI (B))); end vec_sro; function vec_sro (A : vector_signed_short; B : vector_signed_char) return vector_signed_short is begin return To_LL_VSS (vsro (To_LL_VSI (A), To_LL_VSI (B))); end vec_sro; function vec_sro (A : vector_signed_short; B : vector_unsigned_char) return vector_signed_short is begin return To_LL_VSS (vsro (To_LL_VSI (A), To_LL_VSI (B))); end vec_sro; function vec_sro (A : vector_unsigned_short; B : vector_signed_char) return vector_unsigned_short is begin return To_LL_VUS (vsro (To_LL_VSI (A), To_LL_VSI (B))); end vec_sro; function vec_sro (A : vector_unsigned_short; B : vector_unsigned_char) return vector_unsigned_short is begin return To_LL_VUS (vsro (To_LL_VSI (A), To_LL_VSI (B))); end vec_sro; function vec_sro (A : vector_pixel; B : vector_signed_char) return vector_pixel is begin return To_LL_VP (vsro (To_LL_VSI (A), To_LL_VSI (B))); end vec_sro; function vec_sro (A : vector_pixel; B : vector_unsigned_char) return vector_pixel is begin return To_LL_VP (vsro (To_LL_VSI (A), To_LL_VSI (B))); end vec_sro; function vec_sro (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vsro (To_LL_VSI (A), To_LL_VSI (B))); end vec_sro; function vec_sro (A : vector_signed_char; B : vector_unsigned_char) return vector_signed_char is begin return To_LL_VSC (vsro (To_LL_VSI (A), To_LL_VSI (B))); end vec_sro; function vec_sro (A : vector_unsigned_char; B : vector_signed_char) return vector_unsigned_char is begin return To_LL_VUC (vsro (To_LL_VSI (A), To_LL_VSI (B))); end vec_sro; function vec_sro (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vsro (To_LL_VSI (A), To_LL_VSI (B))); end vec_sro; -- vec_st -- procedure vec_st (A : vector_float; B : c_int; C : vector_float_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_float; B : c_int; C : float_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_signed_int; B : c_int; C : vector_signed_int_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_signed_int; B : c_int; C : int_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_unsigned_int; B : c_int; C : vector_unsigned_int_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_unsigned_int; B : c_int; C : unsigned_int_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_bool_int; B : c_int; C : vector_bool_int_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_bool_int; B : c_int; C : unsigned_int_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_bool_int; B : c_int; C : int_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_signed_short; B : c_int; C : vector_signed_short_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_signed_short; B : c_int; C : short_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_unsigned_short; B : c_int; C : vector_unsigned_short_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_unsigned_short; B : c_int; C : unsigned_short_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_bool_short; B : c_int; C : vector_bool_short_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_bool_short; B : c_int; C : unsigned_short_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_pixel; B : c_int; C : vector_pixel_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_pixel; B : c_int; C : unsigned_short_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_pixel; B : c_int; C : short_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_bool_short; B : c_int; C : short_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_signed_char; B : c_int; C : vector_signed_char_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_signed_char; B : c_int; C : signed_char_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_unsigned_char; B : c_int; C : vector_unsigned_char_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_unsigned_char; B : c_int; C : unsigned_char_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_bool_char; B : c_int; C : vector_bool_char_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_bool_char; B : c_int; C : unsigned_char_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; procedure vec_st (A : vector_bool_char; B : c_int; C : signed_char_ptr) is begin stvx (To_LL_VSI (A), B, To_PTR (C)); end vec_st; -- vec_ste -- procedure vec_ste (A : vector_signed_char; B : c_int; C : signed_char_ptr) is begin stvebx (To_LL_VSC (A), B, To_PTR (C)); end vec_ste; procedure vec_ste (A : vector_unsigned_char; B : c_int; C : unsigned_char_ptr) is begin stvebx (To_LL_VSC (A), B, To_PTR (C)); end vec_ste; procedure vec_ste (A : vector_bool_char; B : c_int; C : signed_char_ptr) is begin stvebx (To_LL_VSC (A), B, To_PTR (C)); end vec_ste; procedure vec_ste (A : vector_bool_char; B : c_int; C : unsigned_char_ptr) is begin stvebx (To_LL_VSC (A), B, To_PTR (C)); end vec_ste; procedure vec_ste (A : vector_signed_short; B : c_int; C : short_ptr) is begin stvehx (To_LL_VSS (A), B, To_PTR (C)); end vec_ste; procedure vec_ste (A : vector_unsigned_short; B : c_int; C : unsigned_short_ptr) is begin stvehx (To_LL_VSS (A), B, To_PTR (C)); end vec_ste; procedure vec_ste (A : vector_bool_short; B : c_int; C : short_ptr) is begin stvehx (To_LL_VSS (A), B, To_PTR (C)); end vec_ste; procedure vec_ste (A : vector_bool_short; B : c_int; C : unsigned_short_ptr) is begin stvehx (To_LL_VSS (A), B, To_PTR (C)); end vec_ste; procedure vec_ste (A : vector_pixel; B : c_int; C : short_ptr) is begin stvehx (To_LL_VSS (A), B, To_PTR (C)); end vec_ste; procedure vec_ste (A : vector_pixel; B : c_int; C : unsigned_short_ptr) is begin stvehx (To_LL_VSS (A), B, To_PTR (C)); end vec_ste; procedure vec_ste (A : vector_float; B : c_int; C : float_ptr) is begin stvewx (To_LL_VSI (A), B, To_PTR (C)); end vec_ste; procedure vec_ste (A : vector_signed_int; B : c_int; C : int_ptr) is begin stvewx (To_LL_VSI (A), B, To_PTR (C)); end vec_ste; procedure vec_ste (A : vector_unsigned_int; B : c_int; C : unsigned_int_ptr) is begin stvewx (To_LL_VSI (A), B, To_PTR (C)); end vec_ste; procedure vec_ste (A : vector_bool_int; B : c_int; C : int_ptr) is begin stvewx (To_LL_VSI (A), B, To_PTR (C)); end vec_ste; procedure vec_ste (A : vector_bool_int; B : c_int; C : unsigned_int_ptr) is begin stvewx (To_LL_VSI (A), B, To_PTR (C)); end vec_ste; -- vec_stvewx -- procedure vec_stvewx (A : vector_float; B : c_int; C : float_ptr) is begin stvewx (To_LL_VSI (A), B, To_PTR (C)); end vec_stvewx; procedure vec_stvewx (A : vector_signed_int; B : c_int; C : int_ptr) is begin stvewx (To_LL_VSI (A), B, To_PTR (C)); end vec_stvewx; procedure vec_stvewx (A : vector_unsigned_int; B : c_int; C : unsigned_int_ptr) is begin stvewx (To_LL_VSI (A), B, To_PTR (C)); end vec_stvewx; procedure vec_stvewx (A : vector_bool_int; B : c_int; C : int_ptr) is begin stvewx (To_LL_VSI (A), B, To_PTR (C)); end vec_stvewx; procedure vec_stvewx (A : vector_bool_int; B : c_int; C : unsigned_int_ptr) is begin stvewx (To_LL_VSI (A), B, To_PTR (C)); end vec_stvewx; -- vec_stvehx -- procedure vec_stvehx (A : vector_signed_short; B : c_int; C : short_ptr) is begin stvehx (To_LL_VSS (A), B, To_PTR (C)); end vec_stvehx; procedure vec_stvehx (A : vector_unsigned_short; B : c_int; C : unsigned_short_ptr) is begin stvehx (To_LL_VSS (A), B, To_PTR (C)); end vec_stvehx; procedure vec_stvehx (A : vector_bool_short; B : c_int; C : short_ptr) is begin stvehx (To_LL_VSS (A), B, To_PTR (C)); end vec_stvehx; procedure vec_stvehx (A : vector_bool_short; B : c_int; C : unsigned_short_ptr) is begin stvehx (To_LL_VSS (A), B, To_PTR (C)); end vec_stvehx; procedure vec_stvehx (A : vector_pixel; B : c_int; C : short_ptr) is begin stvehx (To_LL_VSS (A), B, To_PTR (C)); end vec_stvehx; procedure vec_stvehx (A : vector_pixel; B : c_int; C : unsigned_short_ptr) is begin stvehx (To_LL_VSS (A), B, To_PTR (C)); end vec_stvehx; -- vec_stvebx -- procedure vec_stvebx (A : vector_signed_char; B : c_int; C : signed_char_ptr) is begin stvebx (To_LL_VSC (A), B, To_PTR (C)); end vec_stvebx; procedure vec_stvebx (A : vector_unsigned_char; B : c_int; C : unsigned_char_ptr) is begin stvebx (To_LL_VSC (A), B, To_PTR (C)); end vec_stvebx; procedure vec_stvebx (A : vector_bool_char; B : c_int; C : signed_char_ptr) is begin stvebx (To_LL_VSC (A), B, To_PTR (C)); end vec_stvebx; procedure vec_stvebx (A : vector_bool_char; B : c_int; C : unsigned_char_ptr) is begin stvebx (To_LL_VSC (A), B, To_PTR (C)); end vec_stvebx; -- vec_stl -- procedure vec_stl (A : vector_float; B : c_int; C : vector_float_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_float; B : c_int; C : float_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_signed_int; B : c_int; C : vector_signed_int_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_signed_int; B : c_int; C : int_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_unsigned_int; B : c_int; C : vector_unsigned_int_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_unsigned_int; B : c_int; C : unsigned_int_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_bool_int; B : c_int; C : vector_bool_int_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_bool_int; B : c_int; C : unsigned_int_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_bool_int; B : c_int; C : int_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_signed_short; B : c_int; C : vector_signed_short_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_signed_short; B : c_int; C : short_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_unsigned_short; B : c_int; C : vector_unsigned_short_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_unsigned_short; B : c_int; C : unsigned_short_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_bool_short; B : c_int; C : vector_bool_short_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_bool_short; B : c_int; C : unsigned_short_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_bool_short; B : c_int; C : short_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_pixel; B : c_int; C : vector_pixel_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_pixel; B : c_int; C : unsigned_short_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_pixel; B : c_int; C : short_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_signed_char; B : c_int; C : vector_signed_char_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_signed_char; B : c_int; C : signed_char_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_unsigned_char; B : c_int; C : vector_unsigned_char_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_unsigned_char; B : c_int; C : unsigned_char_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_bool_char; B : c_int; C : vector_bool_char_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_bool_char; B : c_int; C : unsigned_char_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; procedure vec_stl (A : vector_bool_char; B : c_int; C : signed_char_ptr) is begin stvxl (To_LL_VSI (A), B, To_PTR (C)); end vec_stl; -- vec_sub -- function vec_sub (A : vector_bool_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vsububm (To_LL_VSC (A), To_LL_VSC (B))); end vec_sub; function vec_sub (A : vector_signed_char; B : vector_bool_char) return vector_signed_char is begin return To_LL_VSC (vsububm (To_LL_VSC (A), To_LL_VSC (B))); end vec_sub; function vec_sub (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vsububm (To_LL_VSC (A), To_LL_VSC (B))); end vec_sub; function vec_sub (A : vector_bool_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vsububm (To_LL_VSC (A), To_LL_VSC (B))); end vec_sub; function vec_sub (A : vector_unsigned_char; B : vector_bool_char) return vector_unsigned_char is begin return To_LL_VUC (vsububm (To_LL_VSC (A), To_LL_VSC (B))); end vec_sub; function vec_sub (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vsububm (To_LL_VSC (A), To_LL_VSC (B))); end vec_sub; function vec_sub (A : vector_bool_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vsubuhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_sub; function vec_sub (A : vector_signed_short; B : vector_bool_short) return vector_signed_short is begin return To_LL_VSS (vsubuhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_sub; function vec_sub (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vsubuhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_sub; function vec_sub (A : vector_bool_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vsubuhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_sub; function vec_sub (A : vector_unsigned_short; B : vector_bool_short) return vector_unsigned_short is begin return To_LL_VUS (vsubuhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_sub; function vec_sub (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vsubuhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_sub; function vec_sub (A : vector_bool_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vsubuwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_sub; function vec_sub (A : vector_signed_int; B : vector_bool_int) return vector_signed_int is begin return To_LL_VSI (vsubuwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_sub; function vec_sub (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vsubuwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_sub; function vec_sub (A : vector_bool_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsubuwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_sub; function vec_sub (A : vector_unsigned_int; B : vector_bool_int) return vector_unsigned_int is begin return To_LL_VUI (vsubuwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_sub; function vec_sub (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsubuwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_sub; function vec_sub (A : vector_float; B : vector_float) return vector_float is begin return To_LL_VF (vsubfp (To_LL_VF (A), To_LL_VF (B))); end vec_sub; -- vec_vsubfp -- function vec_vsubfp (A : vector_float; B : vector_float) return vector_float is begin return To_LL_VF (vsubfp (To_LL_VF (A), To_LL_VF (B))); end vec_vsubfp; -- vec_vsubuwm -- function vec_vsubuwm (A : vector_bool_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vsubuwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_vsubuwm; function vec_vsubuwm (A : vector_signed_int; B : vector_bool_int) return vector_signed_int is begin return To_LL_VSI (vsubuwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_vsubuwm; function vec_vsubuwm (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vsubuwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_vsubuwm; function vec_vsubuwm (A : vector_bool_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsubuwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_vsubuwm; function vec_vsubuwm (A : vector_unsigned_int; B : vector_bool_int) return vector_unsigned_int is begin return To_LL_VUI (vsubuwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_vsubuwm; function vec_vsubuwm (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsubuwm (To_LL_VSI (A), To_LL_VSI (B))); end vec_vsubuwm; -- vec_vsubuhm -- function vec_vsubuhm (A : vector_bool_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vsubuhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_vsubuhm; function vec_vsubuhm (A : vector_signed_short; B : vector_bool_short) return vector_signed_short is begin return To_LL_VSS (vsubuhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_vsubuhm; function vec_vsubuhm (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vsubuhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_vsubuhm; function vec_vsubuhm (A : vector_bool_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vsubuhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_vsubuhm; function vec_vsubuhm (A : vector_unsigned_short; B : vector_bool_short) return vector_unsigned_short is begin return To_LL_VUS (vsubuhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_vsubuhm; function vec_vsubuhm (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vsubuhm (To_LL_VSS (A), To_LL_VSS (B))); end vec_vsubuhm; -- vec_vsububm -- function vec_vsububm (A : vector_bool_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vsububm (To_LL_VSC (A), To_LL_VSC (B))); end vec_vsububm; function vec_vsububm (A : vector_signed_char; B : vector_bool_char) return vector_signed_char is begin return To_LL_VSC (vsububm (To_LL_VSC (A), To_LL_VSC (B))); end vec_vsububm; function vec_vsububm (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vsububm (To_LL_VSC (A), To_LL_VSC (B))); end vec_vsububm; function vec_vsububm (A : vector_bool_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vsububm (To_LL_VSC (A), To_LL_VSC (B))); end vec_vsububm; function vec_vsububm (A : vector_unsigned_char; B : vector_bool_char) return vector_unsigned_char is begin return To_LL_VUC (vsububm (To_LL_VSC (A), To_LL_VSC (B))); end vec_vsububm; function vec_vsububm (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vsububm (To_LL_VSC (A), To_LL_VSC (B))); end vec_vsububm; -- vec_subc -- function vec_subc (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsubcuw (To_LL_VSI (A), To_LL_VSI (B))); end vec_subc; -- vec_subs -- function vec_subs (A : vector_bool_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vsububs (To_LL_VSC (A), To_LL_VSC (B))); end vec_subs; function vec_subs (A : vector_unsigned_char; B : vector_bool_char) return vector_unsigned_char is begin return To_LL_VUC (vsububs (To_LL_VSC (A), To_LL_VSC (B))); end vec_subs; function vec_subs (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vsububs (To_LL_VSC (A), To_LL_VSC (B))); end vec_subs; function vec_subs (A : vector_bool_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vsubsbs (To_LL_VSC (A), To_LL_VSC (B))); end vec_subs; function vec_subs (A : vector_signed_char; B : vector_bool_char) return vector_signed_char is begin return To_LL_VSC (vsubsbs (To_LL_VSC (A), To_LL_VSC (B))); end vec_subs; function vec_subs (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vsubsbs (To_LL_VSC (A), To_LL_VSC (B))); end vec_subs; function vec_subs (A : vector_bool_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vsubuhs (To_LL_VSS (A), To_LL_VSS (B))); end vec_subs; function vec_subs (A : vector_unsigned_short; B : vector_bool_short) return vector_unsigned_short is begin return To_LL_VUS (vsubuhs (To_LL_VSS (A), To_LL_VSS (B))); end vec_subs; function vec_subs (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vsubuhs (To_LL_VSS (A), To_LL_VSS (B))); end vec_subs; function vec_subs (A : vector_bool_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vsubshs (To_LL_VSS (A), To_LL_VSS (B))); end vec_subs; function vec_subs (A : vector_signed_short; B : vector_bool_short) return vector_signed_short is begin return To_LL_VSS (vsubshs (To_LL_VSS (A), To_LL_VSS (B))); end vec_subs; function vec_subs (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vsubshs (To_LL_VSS (A), To_LL_VSS (B))); end vec_subs; function vec_subs (A : vector_bool_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsubuws (To_LL_VSI (A), To_LL_VSI (B))); end vec_subs; function vec_subs (A : vector_unsigned_int; B : vector_bool_int) return vector_unsigned_int is begin return To_LL_VUI (vsubuws (To_LL_VSI (A), To_LL_VSI (B))); end vec_subs; function vec_subs (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsubuws (To_LL_VSI (A), To_LL_VSI (B))); end vec_subs; function vec_subs (A : vector_bool_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vsubsws (To_LL_VSI (A), To_LL_VSI (B))); end vec_subs; function vec_subs (A : vector_signed_int; B : vector_bool_int) return vector_signed_int is begin return To_LL_VSI (vsubsws (To_LL_VSI (A), To_LL_VSI (B))); end vec_subs; function vec_subs (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vsubsws (To_LL_VSI (A), To_LL_VSI (B))); end vec_subs; -- vec_vsubsws -- function vec_vsubsws (A : vector_bool_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vsubsws (To_LL_VSI (A), To_LL_VSI (B))); end vec_vsubsws; function vec_vsubsws (A : vector_signed_int; B : vector_bool_int) return vector_signed_int is begin return To_LL_VSI (vsubsws (To_LL_VSI (A), To_LL_VSI (B))); end vec_vsubsws; function vec_vsubsws (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vsubsws (To_LL_VSI (A), To_LL_VSI (B))); end vec_vsubsws; -- vec_vsubuws -- function vec_vsubuws (A : vector_bool_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsubuws (To_LL_VSI (A), To_LL_VSI (B))); end vec_vsubuws; function vec_vsubuws (A : vector_unsigned_int; B : vector_bool_int) return vector_unsigned_int is begin return To_LL_VUI (vsubuws (To_LL_VSI (A), To_LL_VSI (B))); end vec_vsubuws; function vec_vsubuws (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsubuws (To_LL_VSI (A), To_LL_VSI (B))); end vec_vsubuws; -- vec_vsubshs -- function vec_vsubshs (A : vector_bool_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vsubshs (To_LL_VSS (A), To_LL_VSS (B))); end vec_vsubshs; function vec_vsubshs (A : vector_signed_short; B : vector_bool_short) return vector_signed_short is begin return To_LL_VSS (vsubshs (To_LL_VSS (A), To_LL_VSS (B))); end vec_vsubshs; function vec_vsubshs (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vsubshs (To_LL_VSS (A), To_LL_VSS (B))); end vec_vsubshs; -- vec_vsubuhs -- function vec_vsubuhs (A : vector_bool_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vsubuhs (To_LL_VSS (A), To_LL_VSS (B))); end vec_vsubuhs; function vec_vsubuhs (A : vector_unsigned_short; B : vector_bool_short) return vector_unsigned_short is begin return To_LL_VUS (vsubuhs (To_LL_VSS (A), To_LL_VSS (B))); end vec_vsubuhs; function vec_vsubuhs (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vsubuhs (To_LL_VSS (A), To_LL_VSS (B))); end vec_vsubuhs; -- vec_vsubsbs -- function vec_vsubsbs (A : vector_bool_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vsubsbs (To_LL_VSC (A), To_LL_VSC (B))); end vec_vsubsbs; function vec_vsubsbs (A : vector_signed_char; B : vector_bool_char) return vector_signed_char is begin return To_LL_VSC (vsubsbs (To_LL_VSC (A), To_LL_VSC (B))); end vec_vsubsbs; function vec_vsubsbs (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vsubsbs (To_LL_VSC (A), To_LL_VSC (B))); end vec_vsubsbs; -- vec_vsububs -- function vec_vsububs (A : vector_bool_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vsububs (To_LL_VSC (A), To_LL_VSC (B))); end vec_vsububs; function vec_vsububs (A : vector_unsigned_char; B : vector_bool_char) return vector_unsigned_char is begin return To_LL_VUC (vsububs (To_LL_VSC (A), To_LL_VSC (B))); end vec_vsububs; function vec_vsububs (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vsububs (To_LL_VSC (A), To_LL_VSC (B))); end vec_vsububs; -- vec_sum4s -- function vec_sum4s (A : vector_unsigned_char; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsum4ubs (To_LL_VSC (A), To_LL_VSI (B))); end vec_sum4s; function vec_sum4s (A : vector_signed_char; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vsum4sbs (To_LL_VSC (A), To_LL_VSI (B))); end vec_sum4s; function vec_sum4s (A : vector_signed_short; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vsum4shs (To_LL_VSS (A), To_LL_VSI (B))); end vec_sum4s; -- vec_vsum4shs -- function vec_vsum4shs (A : vector_signed_short; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vsum4shs (To_LL_VSS (A), To_LL_VSI (B))); end vec_vsum4shs; -- vec_vsum4sbs -- function vec_vsum4sbs (A : vector_signed_char; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vsum4sbs (To_LL_VSC (A), To_LL_VSI (B))); end vec_vsum4sbs; -- vec_vsum4ubs -- function vec_vsum4ubs (A : vector_unsigned_char; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vsum4ubs (To_LL_VSC (A), To_LL_VSI (B))); end vec_vsum4ubs; -- vec_sum2s -- function vec_sum2s (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vsum2sws (To_LL_VSI (A), To_LL_VSI (B))); end vec_sum2s; -- vec_sums -- function vec_sums (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vsumsws (To_LL_VSI (A), To_LL_VSI (B))); end vec_sums; -- vec_trunc -- function vec_trunc (A : vector_float) return vector_float is begin return To_LL_VF (vrfiz (To_LL_VF (A))); end vec_trunc; -- vec_unpackh -- function vec_unpackh (A : vector_signed_char) return vector_signed_short is begin return To_LL_VSS (vupkhsb (To_LL_VSC (A))); end vec_unpackh; function vec_unpackh (A : vector_bool_char) return vector_bool_short is begin return To_LL_VBS (vupkhsb (To_LL_VSC (A))); end vec_unpackh; function vec_unpackh (A : vector_signed_short) return vector_signed_int is begin return To_LL_VSI (vupkhsh (To_LL_VSS (A))); end vec_unpackh; function vec_unpackh (A : vector_bool_short) return vector_bool_int is begin return To_LL_VBI (vupkhsh (To_LL_VSS (A))); end vec_unpackh; function vec_unpackh (A : vector_pixel) return vector_unsigned_int is begin return To_LL_VUI (vupkhpx (To_LL_VSS (A))); end vec_unpackh; -- vec_vupkhsh -- function vec_vupkhsh (A : vector_bool_short) return vector_bool_int is begin return To_LL_VBI (vupkhsh (To_LL_VSS (A))); end vec_vupkhsh; function vec_vupkhsh (A : vector_signed_short) return vector_signed_int is begin return To_LL_VSI (vupkhsh (To_LL_VSS (A))); end vec_vupkhsh; -- vec_vupkhpx -- function vec_vupkhpx (A : vector_pixel) return vector_unsigned_int is begin return To_LL_VUI (vupkhpx (To_LL_VSS (A))); end vec_vupkhpx; -- vec_vupkhsb -- function vec_vupkhsb (A : vector_bool_char) return vector_bool_short is begin return To_LL_VBS (vupkhsb (To_LL_VSC (A))); end vec_vupkhsb; function vec_vupkhsb (A : vector_signed_char) return vector_signed_short is begin return To_LL_VSS (vupkhsb (To_LL_VSC (A))); end vec_vupkhsb; -- vec_unpackl -- function vec_unpackl (A : vector_signed_char) return vector_signed_short is begin return To_LL_VSS (vupklsb (To_LL_VSC (A))); end vec_unpackl; function vec_unpackl (A : vector_bool_char) return vector_bool_short is begin return To_LL_VBS (vupklsb (To_LL_VSC (A))); end vec_unpackl; function vec_unpackl (A : vector_pixel) return vector_unsigned_int is begin return To_LL_VUI (vupklpx (To_LL_VSS (A))); end vec_unpackl; function vec_unpackl (A : vector_signed_short) return vector_signed_int is begin return To_LL_VSI (vupklsh (To_LL_VSS (A))); end vec_unpackl; function vec_unpackl (A : vector_bool_short) return vector_bool_int is begin return To_LL_VBI (vupklsh (To_LL_VSS (A))); end vec_unpackl; -- vec_vupklpx -- function vec_vupklpx (A : vector_pixel) return vector_unsigned_int is begin return To_LL_VUI (vupklpx (To_LL_VSS (A))); end vec_vupklpx; -- vec_upklsh -- function vec_vupklsh (A : vector_bool_short) return vector_bool_int is begin return To_LL_VBI (vupklsh (To_LL_VSS (A))); end vec_vupklsh; function vec_vupklsh (A : vector_signed_short) return vector_signed_int is begin return To_LL_VSI (vupklsh (To_LL_VSS (A))); end vec_vupklsh; -- vec_vupklsb -- function vec_vupklsb (A : vector_bool_char) return vector_bool_short is begin return To_LL_VBS (vupklsb (To_LL_VSC (A))); end vec_vupklsb; function vec_vupklsb (A : vector_signed_char) return vector_signed_short is begin return To_LL_VSS (vupklsb (To_LL_VSC (A))); end vec_vupklsb; -- vec_xor -- function vec_xor (A : vector_float; B : vector_float) return vector_float is begin return To_LL_VF (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_float; B : vector_bool_int) return vector_float is begin return To_LL_VF (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_bool_int; B : vector_float) return vector_float is begin return To_LL_VF (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_bool_int; B : vector_bool_int) return vector_bool_int is begin return To_LL_VBI (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_bool_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_signed_int; B : vector_bool_int) return vector_signed_int is begin return To_LL_VSI (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_signed_int; B : vector_signed_int) return vector_signed_int is begin return To_LL_VSI (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_bool_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_unsigned_int; B : vector_bool_int) return vector_unsigned_int is begin return To_LL_VUI (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_unsigned_int; B : vector_unsigned_int) return vector_unsigned_int is begin return To_LL_VUI (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_bool_short; B : vector_bool_short) return vector_bool_short is begin return To_LL_VBS (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_bool_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_signed_short; B : vector_bool_short) return vector_signed_short is begin return To_LL_VSS (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_signed_short; B : vector_signed_short) return vector_signed_short is begin return To_LL_VSS (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_bool_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_unsigned_short; B : vector_bool_short) return vector_unsigned_short is begin return To_LL_VUS (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_unsigned_short; B : vector_unsigned_short) return vector_unsigned_short is begin return To_LL_VUS (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_bool_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_bool_char; B : vector_bool_char) return vector_bool_char is begin return To_LL_VBC (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_signed_char; B : vector_bool_char) return vector_signed_char is begin return To_LL_VSC (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_signed_char; B : vector_signed_char) return vector_signed_char is begin return To_LL_VSC (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_bool_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_unsigned_char; B : vector_bool_char) return vector_unsigned_char is begin return To_LL_VUC (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; function vec_xor (A : vector_unsigned_char; B : vector_unsigned_char) return vector_unsigned_char is begin return To_LL_VUC (vxor (To_LL_VSI (A), To_LL_VSI (B))); end vec_xor; ----------------------------------- -- Bodies for Altivec predicates -- ----------------------------------- -- vec_all_eq -- function vec_all_eq (A : vector_signed_char; B : vector_bool_char) return c_int is begin return vcmpequb_p (CR6_LT, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_eq; function vec_all_eq (A : vector_signed_char; B : vector_signed_char) return c_int is begin return vcmpequb_p (CR6_LT, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_eq; function vec_all_eq (A : vector_unsigned_char; B : vector_bool_char) return c_int is begin return vcmpequb_p (CR6_LT, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_eq; function vec_all_eq (A : vector_unsigned_char; B : vector_unsigned_char) return c_int is begin return vcmpequb_p (CR6_LT, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_eq; function vec_all_eq (A : vector_bool_char; B : vector_bool_char) return c_int is begin return vcmpequb_p (CR6_LT, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_eq; function vec_all_eq (A : vector_bool_char; B : vector_unsigned_char) return c_int is begin return vcmpequb_p (CR6_LT, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_eq; function vec_all_eq (A : vector_bool_char; B : vector_signed_char) return c_int is begin return vcmpequb_p (CR6_LT, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_eq; function vec_all_eq (A : vector_signed_short; B : vector_bool_short) return c_int is begin return vcmpequh_p (CR6_LT, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_eq; function vec_all_eq (A : vector_signed_short; B : vector_signed_short) return c_int is begin return vcmpequh_p (CR6_LT, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_eq; function vec_all_eq (A : vector_unsigned_short; B : vector_bool_short) return c_int is begin return vcmpequh_p (CR6_LT, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_eq; function vec_all_eq (A : vector_unsigned_short; B : vector_unsigned_short) return c_int is begin return vcmpequh_p (CR6_LT, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_eq; function vec_all_eq (A : vector_bool_short; B : vector_bool_short) return c_int is begin return vcmpequh_p (CR6_LT, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_eq; function vec_all_eq (A : vector_bool_short; B : vector_unsigned_short) return c_int is begin return vcmpequh_p (CR6_LT, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_eq; function vec_all_eq (A : vector_bool_short; B : vector_signed_short) return c_int is begin return vcmpequh_p (CR6_LT, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_eq; function vec_all_eq (A : vector_pixel; B : vector_pixel) return c_int is begin return vcmpequh_p (CR6_LT, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_eq; function vec_all_eq (A : vector_signed_int; B : vector_bool_int) return c_int is begin return vcmpequw_p (CR6_LT, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_eq; function vec_all_eq (A : vector_signed_int; B : vector_signed_int) return c_int is begin return vcmpequw_p (CR6_LT, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_eq; function vec_all_eq (A : vector_unsigned_int; B : vector_bool_int) return c_int is begin return vcmpequw_p (CR6_LT, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_eq; function vec_all_eq (A : vector_unsigned_int; B : vector_unsigned_int) return c_int is begin return vcmpequw_p (CR6_LT, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_eq; function vec_all_eq (A : vector_bool_int; B : vector_bool_int) return c_int is begin return vcmpequw_p (CR6_LT, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_eq; function vec_all_eq (A : vector_bool_int; B : vector_unsigned_int) return c_int is begin return vcmpequw_p (CR6_LT, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_eq; function vec_all_eq (A : vector_bool_int; B : vector_signed_int) return c_int is begin return vcmpequw_p (CR6_LT, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_eq; function vec_all_eq (A : vector_float; B : vector_float) return c_int is begin return vcmpeqfp_p (CR6_LT, To_LL_VF (A), To_LL_VF (B)); end vec_all_eq; -- vec_all_ge -- function vec_all_ge (A : vector_bool_char; B : vector_unsigned_char) return c_int is begin return vcmpgtub_p (CR6_EQ, To_LL_VSC (B), To_LL_VSC (A)); end vec_all_ge; function vec_all_ge (A : vector_unsigned_char; B : vector_bool_char) return c_int is begin return vcmpgtub_p (CR6_EQ, To_LL_VSC (B), To_LL_VSC (A)); end vec_all_ge; function vec_all_ge (A : vector_unsigned_char; B : vector_unsigned_char) return c_int is begin return vcmpgtub_p (CR6_EQ, To_LL_VSC (B), To_LL_VSC (A)); end vec_all_ge; function vec_all_ge (A : vector_bool_char; B : vector_signed_char) return c_int is begin return vcmpgtsb_p (CR6_EQ, To_LL_VSC (B), To_LL_VSC (A)); end vec_all_ge; function vec_all_ge (A : vector_signed_char; B : vector_bool_char) return c_int is begin return vcmpgtsb_p (CR6_EQ, To_LL_VSC (B), To_LL_VSC (A)); end vec_all_ge; function vec_all_ge (A : vector_signed_char; B : vector_signed_char) return c_int is begin return vcmpgtsb_p (CR6_EQ, To_LL_VSC (B), To_LL_VSC (A)); end vec_all_ge; function vec_all_ge (A : vector_bool_short; B : vector_unsigned_short) return c_int is begin return vcmpgtuh_p (CR6_EQ, To_LL_VSS (B), To_LL_VSS (A)); end vec_all_ge; function vec_all_ge (A : vector_unsigned_short; B : vector_bool_short) return c_int is begin return vcmpgtuh_p (CR6_EQ, To_LL_VSS (B), To_LL_VSS (A)); end vec_all_ge; function vec_all_ge (A : vector_unsigned_short; B : vector_unsigned_short) return c_int is begin return vcmpgtuh_p (CR6_EQ, To_LL_VSS (B), To_LL_VSS (A)); end vec_all_ge; function vec_all_ge (A : vector_signed_short; B : vector_signed_short) return c_int is begin return vcmpgtsh_p (CR6_EQ, To_LL_VSS (B), To_LL_VSS (A)); end vec_all_ge; function vec_all_ge (A : vector_bool_short; B : vector_signed_short) return c_int is begin return vcmpgtsh_p (CR6_EQ, To_LL_VSS (B), To_LL_VSS (A)); end vec_all_ge; function vec_all_ge (A : vector_signed_short; B : vector_bool_short) return c_int is begin return vcmpgtsh_p (CR6_EQ, To_LL_VSS (B), To_LL_VSS (A)); end vec_all_ge; function vec_all_ge (A : vector_bool_int; B : vector_unsigned_int) return c_int is begin return vcmpgtuw_p (CR6_EQ, To_LL_VSI (B), To_LL_VSI (A)); end vec_all_ge; function vec_all_ge (A : vector_unsigned_int; B : vector_bool_int) return c_int is begin return vcmpgtuw_p (CR6_EQ, To_LL_VSI (B), To_LL_VSI (A)); end vec_all_ge; function vec_all_ge (A : vector_unsigned_int; B : vector_unsigned_int) return c_int is begin return vcmpgtuw_p (CR6_EQ, To_LL_VSI (B), To_LL_VSI (A)); end vec_all_ge; function vec_all_ge (A : vector_bool_int; B : vector_signed_int) return c_int is begin return vcmpgtsw_p (CR6_EQ, To_LL_VSI (B), To_LL_VSI (A)); end vec_all_ge; function vec_all_ge (A : vector_signed_int; B : vector_bool_int) return c_int is begin return vcmpgtsw_p (CR6_EQ, To_LL_VSI (B), To_LL_VSI (A)); end vec_all_ge; function vec_all_ge (A : vector_signed_int; B : vector_signed_int) return c_int is begin return vcmpgtsw_p (CR6_EQ, To_LL_VSI (B), To_LL_VSI (A)); end vec_all_ge; function vec_all_ge (A : vector_float; B : vector_float) return c_int is begin return vcmpgefp_p (CR6_LT, To_LL_VF (A), To_LL_VF (B)); end vec_all_ge; -- vec_all_gt -- function vec_all_gt (A : vector_bool_char; B : vector_unsigned_char) return c_int is begin return vcmpgtub_p (CR6_LT, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_gt; function vec_all_gt (A : vector_unsigned_char; B : vector_bool_char) return c_int is begin return vcmpgtub_p (CR6_LT, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_gt; function vec_all_gt (A : vector_unsigned_char; B : vector_unsigned_char) return c_int is begin return vcmpgtub_p (CR6_LT, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_gt; function vec_all_gt (A : vector_bool_char; B : vector_signed_char) return c_int is begin return vcmpgtsb_p (CR6_LT, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_gt; function vec_all_gt (A : vector_signed_char; B : vector_bool_char) return c_int is begin return vcmpgtsb_p (CR6_LT, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_gt; function vec_all_gt (A : vector_signed_char; B : vector_signed_char) return c_int is begin return vcmpgtsb_p (CR6_LT, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_gt; function vec_all_gt (A : vector_bool_short; B : vector_unsigned_short) return c_int is begin return vcmpgtuh_p (CR6_LT, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_gt; function vec_all_gt (A : vector_unsigned_short; B : vector_bool_short) return c_int is begin return vcmpgtuh_p (CR6_LT, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_gt; function vec_all_gt (A : vector_unsigned_short; B : vector_unsigned_short) return c_int is begin return vcmpgtuh_p (CR6_LT, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_gt; function vec_all_gt (A : vector_bool_short; B : vector_signed_short) return c_int is begin return vcmpgtsh_p (CR6_LT, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_gt; function vec_all_gt (A : vector_signed_short; B : vector_bool_short) return c_int is begin return vcmpgtsh_p (CR6_LT, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_gt; function vec_all_gt (A : vector_signed_short; B : vector_signed_short) return c_int is begin return vcmpgtsh_p (CR6_LT, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_gt; function vec_all_gt (A : vector_bool_int; B : vector_unsigned_int) return c_int is begin return vcmpgtuw_p (CR6_LT, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_gt; function vec_all_gt (A : vector_unsigned_int; B : vector_bool_int) return c_int is begin return vcmpgtuw_p (CR6_LT, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_gt; function vec_all_gt (A : vector_unsigned_int; B : vector_unsigned_int) return c_int is begin return vcmpgtuw_p (CR6_LT, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_gt; function vec_all_gt (A : vector_bool_int; B : vector_signed_int) return c_int is begin return vcmpgtsw_p (CR6_LT, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_gt; function vec_all_gt (A : vector_signed_int; B : vector_bool_int) return c_int is begin return vcmpgtsw_p (CR6_LT, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_gt; function vec_all_gt (A : vector_signed_int; B : vector_signed_int) return c_int is begin return vcmpgtsw_p (CR6_LT, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_gt; function vec_all_gt (A : vector_float; B : vector_float) return c_int is begin return vcmpgtfp_p (CR6_LT, To_LL_VF (A), To_LL_VF (B)); end vec_all_gt; -- vec_all_in -- function vec_all_in (A : vector_float; B : vector_float) return c_int is begin return vcmpbfp_p (CR6_EQ, To_LL_VF (A), To_LL_VF (B)); end vec_all_in; -- vec_all_le -- function vec_all_le (A : vector_bool_char; B : vector_unsigned_char) return c_int is begin return vcmpgtub_p (CR6_EQ, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_le; function vec_all_le (A : vector_unsigned_char; B : vector_bool_char) return c_int is begin return vcmpgtub_p (CR6_EQ, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_le; function vec_all_le (A : vector_unsigned_char; B : vector_unsigned_char) return c_int is begin return vcmpgtub_p (CR6_EQ, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_le; function vec_all_le (A : vector_bool_char; B : vector_signed_char) return c_int is begin return vcmpgtsb_p (CR6_EQ, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_le; function vec_all_le (A : vector_signed_char; B : vector_bool_char) return c_int is begin return vcmpgtsb_p (CR6_EQ, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_le; function vec_all_le (A : vector_signed_char; B : vector_signed_char) return c_int is begin return vcmpgtsb_p (CR6_EQ, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_le; function vec_all_le (A : vector_bool_short; B : vector_unsigned_short) return c_int is begin return vcmpgtuh_p (CR6_EQ, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_le; function vec_all_le (A : vector_unsigned_short; B : vector_bool_short) return c_int is begin return vcmpgtuh_p (CR6_EQ, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_le; function vec_all_le (A : vector_unsigned_short; B : vector_unsigned_short) return c_int is begin return vcmpgtuh_p (CR6_EQ, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_le; function vec_all_le (A : vector_bool_short; B : vector_signed_short) return c_int is begin return vcmpgtsh_p (CR6_EQ, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_le; function vec_all_le (A : vector_signed_short; B : vector_bool_short) return c_int is begin return vcmpgtsh_p (CR6_EQ, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_le; function vec_all_le (A : vector_signed_short; B : vector_signed_short) return c_int is begin return vcmpgtsh_p (CR6_EQ, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_le; function vec_all_le (A : vector_bool_int; B : vector_unsigned_int) return c_int is begin return vcmpgtuw_p (CR6_EQ, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_le; function vec_all_le (A : vector_unsigned_int; B : vector_bool_int) return c_int is begin return vcmpgtuw_p (CR6_EQ, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_le; function vec_all_le (A : vector_unsigned_int; B : vector_unsigned_int) return c_int is begin return vcmpgtuw_p (CR6_EQ, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_le; function vec_all_le (A : vector_bool_int; B : vector_signed_int) return c_int is begin return vcmpgtsw_p (CR6_EQ, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_le; function vec_all_le (A : vector_signed_int; B : vector_bool_int) return c_int is begin return vcmpgtsw_p (CR6_EQ, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_le; function vec_all_le (A : vector_signed_int; B : vector_signed_int) return c_int is begin return vcmpgtsw_p (CR6_EQ, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_le; function vec_all_le (A : vector_float; B : vector_float) return c_int is begin return vcmpgefp_p (CR6_LT, To_LL_VF (B), To_LL_VF (A)); end vec_all_le; -- vec_all_lt -- function vec_all_lt (A : vector_bool_char; B : vector_unsigned_char) return c_int is begin return vcmpgtub_p (CR6_LT, To_LL_VSC (B), To_LL_VSC (A)); end vec_all_lt; function vec_all_lt (A : vector_unsigned_char; B : vector_bool_char) return c_int is begin return vcmpgtub_p (CR6_LT, To_LL_VSC (B), To_LL_VSC (A)); end vec_all_lt; function vec_all_lt (A : vector_unsigned_char; B : vector_unsigned_char) return c_int is begin return vcmpgtub_p (CR6_LT, To_LL_VSC (B), To_LL_VSC (A)); end vec_all_lt; function vec_all_lt (A : vector_bool_char; B : vector_signed_char) return c_int is begin return vcmpgtsb_p (CR6_LT, To_LL_VSC (B), To_LL_VSC (A)); end vec_all_lt; function vec_all_lt (A : vector_signed_char; B : vector_bool_char) return c_int is begin return vcmpgtsb_p (CR6_LT, To_LL_VSC (B), To_LL_VSC (A)); end vec_all_lt; function vec_all_lt (A : vector_signed_char; B : vector_signed_char) return c_int is begin return vcmpgtsb_p (CR6_LT, To_LL_VSC (B), To_LL_VSC (A)); end vec_all_lt; function vec_all_lt (A : vector_bool_short; B : vector_unsigned_short) return c_int is begin return vcmpgtuh_p (CR6_LT, To_LL_VSS (B), To_LL_VSS (A)); end vec_all_lt; function vec_all_lt (A : vector_unsigned_short; B : vector_bool_short) return c_int is begin return vcmpgtuh_p (CR6_LT, To_LL_VSS (B), To_LL_VSS (A)); end vec_all_lt; function vec_all_lt (A : vector_unsigned_short; B : vector_unsigned_short) return c_int is begin return vcmpgtuh_p (CR6_LT, To_LL_VSS (B), To_LL_VSS (A)); end vec_all_lt; function vec_all_lt (A : vector_bool_short; B : vector_signed_short) return c_int is begin return vcmpgtsh_p (CR6_LT, To_LL_VSS (B), To_LL_VSS (A)); end vec_all_lt; function vec_all_lt (A : vector_signed_short; B : vector_bool_short) return c_int is begin return vcmpgtsh_p (CR6_LT, To_LL_VSS (B), To_LL_VSS (A)); end vec_all_lt; function vec_all_lt (A : vector_signed_short; B : vector_signed_short) return c_int is begin return vcmpgtsh_p (CR6_LT, To_LL_VSS (B), To_LL_VSS (A)); end vec_all_lt; function vec_all_lt (A : vector_bool_int; B : vector_unsigned_int) return c_int is begin return vcmpgtuw_p (CR6_LT, To_LL_VSI (B), To_LL_VSI (A)); end vec_all_lt; function vec_all_lt (A : vector_unsigned_int; B : vector_bool_int) return c_int is begin return vcmpgtuw_p (CR6_LT, To_LL_VSI (B), To_LL_VSI (A)); end vec_all_lt; function vec_all_lt (A : vector_unsigned_int; B : vector_unsigned_int) return c_int is begin return vcmpgtuw_p (CR6_LT, To_LL_VSI (B), To_LL_VSI (A)); end vec_all_lt; function vec_all_lt (A : vector_bool_int; B : vector_signed_int) return c_int is begin return vcmpgtsw_p (CR6_LT, To_LL_VSI (B), To_LL_VSI (A)); end vec_all_lt; function vec_all_lt (A : vector_signed_int; B : vector_bool_int) return c_int is begin return vcmpgtsw_p (CR6_LT, To_LL_VSI (B), To_LL_VSI (A)); end vec_all_lt; function vec_all_lt (A : vector_signed_int; B : vector_signed_int) return c_int is begin return vcmpgtsw_p (CR6_LT, To_LL_VSI (B), To_LL_VSI (A)); end vec_all_lt; function vec_all_lt (A : vector_float; B : vector_float) return c_int is begin return vcmpgtfp_p (CR6_LT, To_LL_VF (B), To_LL_VF (A)); end vec_all_lt; -- vec_all_nan -- function vec_all_nan (A : vector_float) return c_int is begin return vcmpeqfp_p (CR6_EQ, To_LL_VF (A), To_LL_VF (A)); end vec_all_nan; -- vec_all_ne -- function vec_all_ne (A : vector_signed_char; B : vector_bool_char) return c_int is begin return vcmpequb_p (CR6_EQ, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_ne; function vec_all_ne (A : vector_signed_char; B : vector_signed_char) return c_int is begin return vcmpequb_p (CR6_EQ, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_ne; function vec_all_ne (A : vector_unsigned_char; B : vector_bool_char) return c_int is begin return vcmpequb_p (CR6_EQ, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_ne; function vec_all_ne (A : vector_unsigned_char; B : vector_unsigned_char) return c_int is begin return vcmpequb_p (CR6_EQ, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_ne; function vec_all_ne (A : vector_bool_char; B : vector_bool_char) return c_int is begin return vcmpequb_p (CR6_EQ, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_ne; function vec_all_ne (A : vector_bool_char; B : vector_unsigned_char) return c_int is begin return vcmpequb_p (CR6_EQ, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_ne; function vec_all_ne (A : vector_bool_char; B : vector_signed_char) return c_int is begin return vcmpequb_p (CR6_EQ, To_LL_VSC (A), To_LL_VSC (B)); end vec_all_ne; function vec_all_ne (A : vector_signed_short; B : vector_bool_short) return c_int is begin return vcmpequh_p (CR6_EQ, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_ne; function vec_all_ne (A : vector_signed_short; B : vector_signed_short) return c_int is begin return vcmpequh_p (CR6_EQ, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_ne; function vec_all_ne (A : vector_unsigned_short; B : vector_bool_short) return c_int is begin return vcmpequh_p (CR6_EQ, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_ne; function vec_all_ne (A : vector_unsigned_short; B : vector_unsigned_short) return c_int is begin return vcmpequh_p (CR6_EQ, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_ne; function vec_all_ne (A : vector_bool_short; B : vector_bool_short) return c_int is begin return vcmpequh_p (CR6_EQ, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_ne; function vec_all_ne (A : vector_bool_short; B : vector_unsigned_short) return c_int is begin return vcmpequh_p (CR6_EQ, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_ne; function vec_all_ne (A : vector_bool_short; B : vector_signed_short) return c_int is begin return vcmpequh_p (CR6_EQ, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_ne; function vec_all_ne (A : vector_pixel; B : vector_pixel) return c_int is begin return vcmpequh_p (CR6_EQ, To_LL_VSS (A), To_LL_VSS (B)); end vec_all_ne; function vec_all_ne (A : vector_signed_int; B : vector_bool_int) return c_int is begin return vcmpequw_p (CR6_EQ, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_ne; function vec_all_ne (A : vector_signed_int; B : vector_signed_int) return c_int is begin return vcmpequw_p (CR6_EQ, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_ne; function vec_all_ne (A : vector_unsigned_int; B : vector_bool_int) return c_int is begin return vcmpequw_p (CR6_EQ, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_ne; function vec_all_ne (A : vector_unsigned_int; B : vector_unsigned_int) return c_int is begin return vcmpequw_p (CR6_EQ, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_ne; function vec_all_ne (A : vector_bool_int; B : vector_bool_int) return c_int is begin return vcmpequw_p (CR6_EQ, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_ne; function vec_all_ne (A : vector_bool_int; B : vector_unsigned_int) return c_int is begin return vcmpequw_p (CR6_EQ, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_ne; function vec_all_ne (A : vector_bool_int; B : vector_signed_int) return c_int is begin return vcmpequw_p (CR6_EQ, To_LL_VSI (A), To_LL_VSI (B)); end vec_all_ne; function vec_all_ne (A : vector_float; B : vector_float) return c_int is begin return vcmpeqfp_p (CR6_EQ, To_LL_VF (A), To_LL_VF (B)); end vec_all_ne; -- vec_all_nge -- function vec_all_nge (A : vector_float; B : vector_float) return c_int is begin return vcmpgefp_p (CR6_EQ, To_LL_VF (A), To_LL_VF (B)); end vec_all_nge; -- vec_all_ngt -- function vec_all_ngt (A : vector_float; B : vector_float) return c_int is begin return vcmpgtfp_p (CR6_EQ, To_LL_VF (A), To_LL_VF (B)); end vec_all_ngt; -- vec_all_nle -- function vec_all_nle (A : vector_float; B : vector_float) return c_int is begin return vcmpgefp_p (CR6_EQ, To_LL_VF (B), To_LL_VF (A)); end vec_all_nle; -- vec_all_nlt -- function vec_all_nlt (A : vector_float; B : vector_float) return c_int is begin return vcmpgtfp_p (CR6_EQ, To_LL_VF (B), To_LL_VF (A)); end vec_all_nlt; -- vec_all_numeric -- function vec_all_numeric (A : vector_float) return c_int is begin return vcmpeqfp_p (CR6_LT, To_LL_VF (A), To_LL_VF (A)); end vec_all_numeric; -- vec_any_eq -- function vec_any_eq (A : vector_signed_char; B : vector_bool_char) return c_int is begin return vcmpequb_p (CR6_EQ_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_eq; function vec_any_eq (A : vector_signed_char; B : vector_signed_char) return c_int is begin return vcmpequb_p (CR6_EQ_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_eq; function vec_any_eq (A : vector_unsigned_char; B : vector_bool_char) return c_int is begin return vcmpequb_p (CR6_EQ_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_eq; function vec_any_eq (A : vector_unsigned_char; B : vector_unsigned_char) return c_int is begin return vcmpequb_p (CR6_EQ_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_eq; function vec_any_eq (A : vector_bool_char; B : vector_bool_char) return c_int is begin return vcmpequb_p (CR6_EQ_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_eq; function vec_any_eq (A : vector_bool_char; B : vector_unsigned_char) return c_int is begin return vcmpequb_p (CR6_EQ_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_eq; function vec_any_eq (A : vector_bool_char; B : vector_signed_char) return c_int is begin return vcmpequb_p (CR6_EQ_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_eq; function vec_any_eq (A : vector_signed_short; B : vector_bool_short) return c_int is begin return vcmpequh_p (CR6_EQ_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_eq; function vec_any_eq (A : vector_signed_short; B : vector_signed_short) return c_int is begin return vcmpequh_p (CR6_EQ_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_eq; function vec_any_eq (A : vector_unsigned_short; B : vector_bool_short) return c_int is begin return vcmpequh_p (CR6_EQ_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_eq; function vec_any_eq (A : vector_unsigned_short; B : vector_unsigned_short) return c_int is begin return vcmpequh_p (CR6_EQ_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_eq; function vec_any_eq (A : vector_bool_short; B : vector_bool_short) return c_int is begin return vcmpequh_p (CR6_EQ_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_eq; function vec_any_eq (A : vector_bool_short; B : vector_unsigned_short) return c_int is begin return vcmpequh_p (CR6_EQ_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_eq; function vec_any_eq (A : vector_bool_short; B : vector_signed_short) return c_int is begin return vcmpequh_p (CR6_EQ_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_eq; function vec_any_eq (A : vector_pixel; B : vector_pixel) return c_int is begin return vcmpequh_p (CR6_EQ_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_eq; function vec_any_eq (A : vector_signed_int; B : vector_bool_int) return c_int is begin return vcmpequw_p (CR6_EQ_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_eq; function vec_any_eq (A : vector_signed_int; B : vector_signed_int) return c_int is begin return vcmpequw_p (CR6_EQ_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_eq; function vec_any_eq (A : vector_unsigned_int; B : vector_bool_int) return c_int is begin return vcmpequw_p (CR6_EQ_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_eq; function vec_any_eq (A : vector_unsigned_int; B : vector_unsigned_int) return c_int is begin return vcmpequw_p (CR6_EQ_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_eq; function vec_any_eq (A : vector_bool_int; B : vector_bool_int) return c_int is begin return vcmpequw_p (CR6_EQ_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_eq; function vec_any_eq (A : vector_bool_int; B : vector_unsigned_int) return c_int is begin return vcmpequw_p (CR6_EQ_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_eq; function vec_any_eq (A : vector_bool_int; B : vector_signed_int) return c_int is begin return vcmpequw_p (CR6_EQ_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_eq; function vec_any_eq (A : vector_float; B : vector_float) return c_int is begin return vcmpeqfp_p (CR6_EQ_REV, To_LL_VF (A), To_LL_VF (B)); end vec_any_eq; -- vec_any_ge -- function vec_any_ge (A : vector_signed_char; B : vector_bool_char) return c_int is begin return vcmpgtub_p (CR6_LT_REV, To_LL_VSC (B), To_LL_VSC (A)); end vec_any_ge; function vec_any_ge (A : vector_unsigned_char; B : vector_bool_char) return c_int is begin return vcmpgtub_p (CR6_LT_REV, To_LL_VSC (B), To_LL_VSC (A)); end vec_any_ge; function vec_any_ge (A : vector_unsigned_char; B : vector_unsigned_char) return c_int is begin return vcmpgtub_p (CR6_LT_REV, To_LL_VSC (B), To_LL_VSC (A)); end vec_any_ge; function vec_any_ge (A : vector_signed_char; B : vector_signed_char) return c_int is begin return vcmpgtsb_p (CR6_LT_REV, To_LL_VSC (B), To_LL_VSC (A)); end vec_any_ge; function vec_any_ge (A : vector_bool_char; B : vector_unsigned_char) return c_int is begin return vcmpgtub_p (CR6_LT_REV, To_LL_VSC (B), To_LL_VSC (A)); end vec_any_ge; function vec_any_ge (A : vector_bool_char; B : vector_signed_char) return c_int is begin return vcmpgtub_p (CR6_LT_REV, To_LL_VSC (B), To_LL_VSC (A)); end vec_any_ge; function vec_any_ge (A : vector_unsigned_short; B : vector_bool_short) return c_int is begin return vcmpgtuh_p (CR6_LT_REV, To_LL_VSS (B), To_LL_VSS (A)); end vec_any_ge; function vec_any_ge (A : vector_unsigned_short; B : vector_unsigned_short) return c_int is begin return vcmpgtuh_p (CR6_LT_REV, To_LL_VSS (B), To_LL_VSS (A)); end vec_any_ge; function vec_any_ge (A : vector_signed_short; B : vector_signed_short) return c_int is begin return vcmpgtsh_p (CR6_LT_REV, To_LL_VSS (B), To_LL_VSS (A)); end vec_any_ge; function vec_any_ge (A : vector_signed_short; B : vector_bool_short) return c_int is begin return vcmpgtsh_p (CR6_LT_REV, To_LL_VSS (B), To_LL_VSS (A)); end vec_any_ge; function vec_any_ge (A : vector_bool_short; B : vector_unsigned_short) return c_int is begin return vcmpgtuh_p (CR6_LT_REV, To_LL_VSS (B), To_LL_VSS (A)); end vec_any_ge; function vec_any_ge (A : vector_bool_short; B : vector_signed_short) return c_int is begin return vcmpgtuh_p (CR6_LT_REV, To_LL_VSS (B), To_LL_VSS (A)); end vec_any_ge; function vec_any_ge (A : vector_signed_int; B : vector_bool_int) return c_int is begin return vcmpgtuw_p (CR6_LT_REV, To_LL_VSI (B), To_LL_VSI (A)); end vec_any_ge; function vec_any_ge (A : vector_unsigned_int; B : vector_bool_int) return c_int is begin return vcmpgtuw_p (CR6_LT_REV, To_LL_VSI (B), To_LL_VSI (A)); end vec_any_ge; function vec_any_ge (A : vector_unsigned_int; B : vector_unsigned_int) return c_int is begin return vcmpgtuw_p (CR6_LT_REV, To_LL_VSI (B), To_LL_VSI (A)); end vec_any_ge; function vec_any_ge (A : vector_signed_int; B : vector_signed_int) return c_int is begin return vcmpgtsw_p (CR6_LT_REV, To_LL_VSI (B), To_LL_VSI (A)); end vec_any_ge; function vec_any_ge (A : vector_bool_int; B : vector_unsigned_int) return c_int is begin return vcmpgtuw_p (CR6_LT_REV, To_LL_VSI (B), To_LL_VSI (A)); end vec_any_ge; function vec_any_ge (A : vector_bool_int; B : vector_signed_int) return c_int is begin return vcmpgtuw_p (CR6_LT_REV, To_LL_VSI (B), To_LL_VSI (A)); end vec_any_ge; function vec_any_ge (A : vector_float; B : vector_float) return c_int is begin return vcmpgefp_p (CR6_EQ_REV, To_LL_VF (A), To_LL_VF (B)); end vec_any_ge; -- vec_any_gt -- function vec_any_gt (A : vector_bool_char; B : vector_unsigned_char) return c_int is begin return vcmpgtub_p (CR6_EQ_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_gt; function vec_any_gt (A : vector_unsigned_char; B : vector_bool_char) return c_int is begin return vcmpgtub_p (CR6_EQ_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_gt; function vec_any_gt (A : vector_unsigned_char; B : vector_unsigned_char) return c_int is begin return vcmpgtub_p (CR6_EQ_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_gt; function vec_any_gt (A : vector_bool_char; B : vector_signed_char) return c_int is begin return vcmpgtsb_p (CR6_EQ_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_gt; function vec_any_gt (A : vector_signed_char; B : vector_bool_char) return c_int is begin return vcmpgtsb_p (CR6_EQ_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_gt; function vec_any_gt (A : vector_signed_char; B : vector_signed_char) return c_int is begin return vcmpgtsb_p (CR6_EQ_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_gt; function vec_any_gt (A : vector_bool_short; B : vector_unsigned_short) return c_int is begin return vcmpgtuh_p (CR6_EQ_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_gt; function vec_any_gt (A : vector_unsigned_short; B : vector_bool_short) return c_int is begin return vcmpgtuh_p (CR6_EQ_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_gt; function vec_any_gt (A : vector_unsigned_short; B : vector_unsigned_short) return c_int is begin return vcmpgtuh_p (CR6_EQ_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_gt; function vec_any_gt (A : vector_bool_short; B : vector_signed_short) return c_int is begin return vcmpgtsh_p (CR6_EQ_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_gt; function vec_any_gt (A : vector_signed_short; B : vector_bool_short) return c_int is begin return vcmpgtsh_p (CR6_EQ_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_gt; function vec_any_gt (A : vector_signed_short; B : vector_signed_short) return c_int is begin return vcmpgtsh_p (CR6_EQ_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_gt; function vec_any_gt (A : vector_bool_int; B : vector_unsigned_int) return c_int is begin return vcmpgtuw_p (CR6_EQ_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_gt; function vec_any_gt (A : vector_unsigned_int; B : vector_bool_int) return c_int is begin return vcmpgtuw_p (CR6_EQ_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_gt; function vec_any_gt (A : vector_unsigned_int; B : vector_unsigned_int) return c_int is begin return vcmpgtuw_p (CR6_EQ_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_gt; function vec_any_gt (A : vector_bool_int; B : vector_signed_int) return c_int is begin return vcmpgtsw_p (CR6_EQ_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_gt; function vec_any_gt (A : vector_signed_int; B : vector_bool_int) return c_int is begin return vcmpgtsw_p (CR6_EQ_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_gt; function vec_any_gt (A : vector_signed_int; B : vector_signed_int) return c_int is begin return vcmpgtsw_p (CR6_EQ_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_gt; function vec_any_gt (A : vector_float; B : vector_float) return c_int is begin return vcmpgtfp_p (CR6_EQ_REV, To_LL_VF (A), To_LL_VF (B)); end vec_any_gt; -- vec_any_le -- function vec_any_le (A : vector_bool_char; B : vector_unsigned_char) return c_int is begin return vcmpgtub_p (CR6_LT_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_le; function vec_any_le (A : vector_unsigned_char; B : vector_bool_char) return c_int is begin return vcmpgtub_p (CR6_LT_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_le; function vec_any_le (A : vector_unsigned_char; B : vector_unsigned_char) return c_int is begin return vcmpgtub_p (CR6_LT_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_le; function vec_any_le (A : vector_bool_char; B : vector_signed_char) return c_int is begin return vcmpgtsb_p (CR6_LT_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_le; function vec_any_le (A : vector_signed_char; B : vector_bool_char) return c_int is begin return vcmpgtsb_p (CR6_LT_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_le; function vec_any_le (A : vector_signed_char; B : vector_signed_char) return c_int is begin return vcmpgtsb_p (CR6_LT_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_le; function vec_any_le (A : vector_bool_short; B : vector_unsigned_short) return c_int is begin return vcmpgtuh_p (CR6_LT_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_le; function vec_any_le (A : vector_unsigned_short; B : vector_bool_short) return c_int is begin return vcmpgtuh_p (CR6_LT_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_le; function vec_any_le (A : vector_unsigned_short; B : vector_unsigned_short) return c_int is begin return vcmpgtuh_p (CR6_LT_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_le; function vec_any_le (A : vector_bool_short; B : vector_signed_short) return c_int is begin return vcmpgtsh_p (CR6_LT_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_le; function vec_any_le (A : vector_signed_short; B : vector_bool_short) return c_int is begin return vcmpgtsh_p (CR6_LT_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_le; function vec_any_le (A : vector_signed_short; B : vector_signed_short) return c_int is begin return vcmpgtsh_p (CR6_LT_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_le; function vec_any_le (A : vector_bool_int; B : vector_unsigned_int) return c_int is begin return vcmpgtuw_p (CR6_LT_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_le; function vec_any_le (A : vector_unsigned_int; B : vector_bool_int) return c_int is begin return vcmpgtuw_p (CR6_LT_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_le; function vec_any_le (A : vector_unsigned_int; B : vector_unsigned_int) return c_int is begin return vcmpgtuw_p (CR6_LT_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_le; function vec_any_le (A : vector_bool_int; B : vector_signed_int) return c_int is begin return vcmpgtsw_p (CR6_LT_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_le; function vec_any_le (A : vector_signed_int; B : vector_bool_int) return c_int is begin return vcmpgtsw_p (CR6_LT_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_le; function vec_any_le (A : vector_signed_int; B : vector_signed_int) return c_int is begin return vcmpgtsw_p (CR6_LT_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_le; function vec_any_le (A : vector_float; B : vector_float) return c_int is begin return vcmpgefp_p (CR6_EQ_REV, To_LL_VF (B), To_LL_VF (A)); end vec_any_le; -- vec_any_lt -- function vec_any_lt (A : vector_bool_char; B : vector_unsigned_char) return c_int is begin return vcmpgtub_p (CR6_EQ_REV, To_LL_VSC (B), To_LL_VSC (A)); end vec_any_lt; function vec_any_lt (A : vector_unsigned_char; B : vector_bool_char) return c_int is begin return vcmpgtub_p (CR6_EQ_REV, To_LL_VSC (B), To_LL_VSC (A)); end vec_any_lt; function vec_any_lt (A : vector_unsigned_char; B : vector_unsigned_char) return c_int is begin return vcmpgtub_p (CR6_EQ_REV, To_LL_VSC (B), To_LL_VSC (A)); end vec_any_lt; function vec_any_lt (A : vector_bool_char; B : vector_signed_char) return c_int is begin return vcmpgtsb_p (CR6_EQ_REV, To_LL_VSC (B), To_LL_VSC (A)); end vec_any_lt; function vec_any_lt (A : vector_signed_char; B : vector_bool_char) return c_int is begin return vcmpgtsb_p (CR6_EQ_REV, To_LL_VSC (B), To_LL_VSC (A)); end vec_any_lt; function vec_any_lt (A : vector_signed_char; B : vector_signed_char) return c_int is begin return vcmpgtsb_p (CR6_EQ_REV, To_LL_VSC (B), To_LL_VSC (A)); end vec_any_lt; function vec_any_lt (A : vector_bool_short; B : vector_unsigned_short) return c_int is begin return vcmpgtuh_p (CR6_EQ_REV, To_LL_VSS (B), To_LL_VSS (A)); end vec_any_lt; function vec_any_lt (A : vector_unsigned_short; B : vector_bool_short) return c_int is begin return vcmpgtuh_p (CR6_EQ_REV, To_LL_VSS (B), To_LL_VSS (A)); end vec_any_lt; function vec_any_lt (A : vector_unsigned_short; B : vector_unsigned_short) return c_int is begin return vcmpgtuh_p (CR6_EQ_REV, To_LL_VSS (B), To_LL_VSS (A)); end vec_any_lt; function vec_any_lt (A : vector_bool_short; B : vector_signed_short) return c_int is begin return vcmpgtsh_p (CR6_EQ_REV, To_LL_VSS (B), To_LL_VSS (A)); end vec_any_lt; function vec_any_lt (A : vector_signed_short; B : vector_bool_short) return c_int is begin return vcmpgtsh_p (CR6_EQ_REV, To_LL_VSS (B), To_LL_VSS (A)); end vec_any_lt; function vec_any_lt (A : vector_signed_short; B : vector_signed_short) return c_int is begin return vcmpgtsh_p (CR6_EQ_REV, To_LL_VSS (B), To_LL_VSS (A)); end vec_any_lt; function vec_any_lt (A : vector_bool_int; B : vector_unsigned_int) return c_int is begin return vcmpgtuw_p (CR6_EQ_REV, To_LL_VSI (B), To_LL_VSI (A)); end vec_any_lt; function vec_any_lt (A : vector_unsigned_int; B : vector_bool_int) return c_int is begin return vcmpgtuw_p (CR6_EQ_REV, To_LL_VSI (B), To_LL_VSI (A)); end vec_any_lt; function vec_any_lt (A : vector_unsigned_int; B : vector_unsigned_int) return c_int is begin return vcmpgtuw_p (CR6_EQ_REV, To_LL_VSI (B), To_LL_VSI (A)); end vec_any_lt; function vec_any_lt (A : vector_bool_int; B : vector_signed_int) return c_int is begin return vcmpgtsw_p (CR6_EQ_REV, To_LL_VSI (B), To_LL_VSI (A)); end vec_any_lt; function vec_any_lt (A : vector_signed_int; B : vector_bool_int) return c_int is begin return vcmpgtsw_p (CR6_EQ_REV, To_LL_VSI (B), To_LL_VSI (A)); end vec_any_lt; function vec_any_lt (A : vector_signed_int; B : vector_signed_int) return c_int is begin return vcmpgtsw_p (CR6_EQ_REV, To_LL_VSI (B), To_LL_VSI (A)); end vec_any_lt; function vec_any_lt (A : vector_float; B : vector_float) return c_int is begin return vcmpgtfp_p (CR6_EQ_REV, To_LL_VF (B), To_LL_VF (A)); end vec_any_lt; -- vec_any_nan -- function vec_any_nan (A : vector_float) return c_int is begin return vcmpeqfp_p (CR6_LT_REV, To_LL_VF (A), To_LL_VF (A)); end vec_any_nan; -- vec_any_ne -- function vec_any_ne (A : vector_signed_char; B : vector_bool_char) return c_int is begin return vcmpequb_p (CR6_LT_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_ne; function vec_any_ne (A : vector_signed_char; B : vector_signed_char) return c_int is begin return vcmpequb_p (CR6_LT_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_ne; function vec_any_ne (A : vector_unsigned_char; B : vector_bool_char) return c_int is begin return vcmpequb_p (CR6_LT_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_ne; function vec_any_ne (A : vector_unsigned_char; B : vector_unsigned_char) return c_int is begin return vcmpequb_p (CR6_LT_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_ne; function vec_any_ne (A : vector_bool_char; B : vector_bool_char) return c_int is begin return vcmpequb_p (CR6_LT_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_ne; function vec_any_ne (A : vector_bool_char; B : vector_unsigned_char) return c_int is begin return vcmpequb_p (CR6_LT_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_ne; function vec_any_ne (A : vector_bool_char; B : vector_signed_char) return c_int is begin return vcmpequb_p (CR6_LT_REV, To_LL_VSC (A), To_LL_VSC (B)); end vec_any_ne; function vec_any_ne (A : vector_signed_short; B : vector_bool_short) return c_int is begin return vcmpequh_p (CR6_LT_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_ne; function vec_any_ne (A : vector_signed_short; B : vector_signed_short) return c_int is begin return vcmpequh_p (CR6_LT_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_ne; function vec_any_ne (A : vector_unsigned_short; B : vector_bool_short) return c_int is begin return vcmpequh_p (CR6_LT_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_ne; function vec_any_ne (A : vector_unsigned_short; B : vector_unsigned_short) return c_int is begin return vcmpequh_p (CR6_LT_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_ne; function vec_any_ne (A : vector_bool_short; B : vector_bool_short) return c_int is begin return vcmpequh_p (CR6_LT_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_ne; function vec_any_ne (A : vector_bool_short; B : vector_unsigned_short) return c_int is begin return vcmpequh_p (CR6_LT_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_ne; function vec_any_ne (A : vector_bool_short; B : vector_signed_short) return c_int is begin return vcmpequh_p (CR6_LT_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_ne; function vec_any_ne (A : vector_pixel; B : vector_pixel) return c_int is begin return vcmpequh_p (CR6_LT_REV, To_LL_VSS (A), To_LL_VSS (B)); end vec_any_ne; function vec_any_ne (A : vector_signed_int; B : vector_bool_int) return c_int is begin return vcmpequw_p (CR6_LT_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_ne; function vec_any_ne (A : vector_signed_int; B : vector_signed_int) return c_int is begin return vcmpequw_p (CR6_LT_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_ne; function vec_any_ne (A : vector_unsigned_int; B : vector_bool_int) return c_int is begin return vcmpequw_p (CR6_LT_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_ne; function vec_any_ne (A : vector_unsigned_int; B : vector_unsigned_int) return c_int is begin return vcmpequw_p (CR6_LT_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_ne; function vec_any_ne (A : vector_bool_int; B : vector_bool_int) return c_int is begin return vcmpequw_p (CR6_LT_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_ne; function vec_any_ne (A : vector_bool_int; B : vector_unsigned_int) return c_int is begin return vcmpequw_p (CR6_LT_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_ne; function vec_any_ne (A : vector_bool_int; B : vector_signed_int) return c_int is begin return vcmpequw_p (CR6_LT_REV, To_LL_VSI (A), To_LL_VSI (B)); end vec_any_ne; function vec_any_ne (A : vector_float; B : vector_float) return c_int is begin return vcmpeqfp_p (CR6_LT_REV, To_LL_VF (A), To_LL_VF (B)); end vec_any_ne; -- vec_any_nge -- function vec_any_nge (A : vector_float; B : vector_float) return c_int is begin return vcmpgefp_p (CR6_LT_REV, To_LL_VF (A), To_LL_VF (B)); end vec_any_nge; -- vec_any_ngt -- function vec_any_ngt (A : vector_float; B : vector_float) return c_int is begin return vcmpgtfp_p (CR6_LT_REV, To_LL_VF (A), To_LL_VF (B)); end vec_any_ngt; -- vec_any_nle -- function vec_any_nle (A : vector_float; B : vector_float) return c_int is begin return vcmpgefp_p (CR6_LT_REV, To_LL_VF (B), To_LL_VF (A)); end vec_any_nle; -- vec_any_nlt -- function vec_any_nlt (A : vector_float; B : vector_float) return c_int is begin return vcmpgtfp_p (CR6_LT_REV, To_LL_VF (B), To_LL_VF (A)); end vec_any_nlt; -- vec_any_numeric -- function vec_any_numeric (A : vector_float) return c_int is begin return vcmpeqfp_p (CR6_EQ_REV, To_LL_VF (A), To_LL_VF (A)); end vec_any_numeric; -- vec_any_out -- function vec_any_out (A : vector_float; B : vector_float) return c_int is begin return vcmpbfp_p (CR6_EQ_REV, To_LL_VF (A), To_LL_VF (B)); end vec_any_out; -- vec_step -- function vec_step (V : vector_unsigned_char) return Integer is pragma Unreferenced (V); begin return 16; end vec_step; function vec_step (V : vector_signed_char) return Integer is pragma Unreferenced (V); begin return 16; end vec_step; function vec_step (V : vector_bool_char) return Integer is pragma Unreferenced (V); begin return 16; end vec_step; function vec_step (V : vector_unsigned_short) return Integer is pragma Unreferenced (V); begin return 8; end vec_step; function vec_step (V : vector_signed_short) return Integer is pragma Unreferenced (V); begin return 8; end vec_step; function vec_step (V : vector_bool_short) return Integer is pragma Unreferenced (V); begin return 8; end vec_step; function vec_step (V : vector_unsigned_int) return Integer is pragma Unreferenced (V); begin return 4; end vec_step; function vec_step (V : vector_signed_int) return Integer is pragma Unreferenced (V); begin return 4; end vec_step; function vec_step (V : vector_bool_int) return Integer is pragma Unreferenced (V); begin return 4; end vec_step; function vec_step (V : vector_float) return Integer is pragma Unreferenced (V); begin return 4; end vec_step; function vec_step (V : vector_pixel) return Integer is pragma Unreferenced (V); begin return 4; end vec_step; end GNAT.Altivec.Vector_Operations;
with Ada.Text_IO; use Ada.Text_IO; with AAA.Strings; with CLIC.User_Input; use CLIC.User_Input; with GNAT.OS_Lib; package body CLIC_Ex.Commands.User_Input is function Valid_Number (Str : String) return Boolean is (for all C of Str => C in '0' .. '9'); ------------- -- Execute -- ------------- overriding procedure Execute (Cmd : in out Instance; Args : AAA.Strings.Vector) is begin declare Answer : Answer_Kind; begin Answer := Query (Question => "Do you like this tool?", Valid => (others => True), Default => Yes); if Answer = No then Put_Line ("Fine then."); GNAT.OS_Lib.OS_Exit (42); end if; end; declare Languages : constant AAA.Strings.Vector := AAA.Strings.Empty_Vector .Append ("Ada") .Append ("C") .Append ("C++") .Append ("Rust") .Append ("OCAML") .Append ("Fortran") .Append ("Go"); Answer : Positive; begin Answer := Query_Multi (Question => "What is you favorite programming language?", Choices => Languages); if Answer /= 1 then Put_Line ("Wrong answer."); GNAT.OS_Lib.OS_Exit (42); end if; end; Continue_Or_Abort; declare Answer : constant String := Query_String (Question => "Enter a number please", Default => "42", Validation => Valid_Number'Access); begin Put_Line ("Thanks for your answer: '" & Answer & "'"); end; end Execute; end CLIC_Ex.Commands.User_Input;
with Ada.Text_IO; with Ada.Numerics.Discrete_Random; with Ada.Numerics.Float_Random; with Ada.Strings.Fixed; with Ada.Strings.Maps; procedure Evolution is -- only upper case characters allowed, and space, which uses '@' in -- internal representation (allowing subtype of Character). subtype DNA_Char is Character range '@' .. 'Z'; -- DNA string is as long as target string. subtype DNA_String is String (1 .. 28); -- target string translated to DNA_Char string Target : constant DNA_String := "METHINKS@IT@IS@LIKE@A@WEASEL"; -- calculate the 'closeness' to the target DNA. -- it returns a number >= 0 that describes how many chars are correct. -- can be improved much to make evolution better, but keep simple for -- this example. function Fitness (DNA : DNA_String) return Natural is Result : Natural := 0; begin for Position in DNA'Range loop if DNA (Position) = Target (Position) then Result := Result + 1; end if; end loop; return Result; end Fitness; -- output the DNA using the mapping procedure Output_DNA (DNA : DNA_String; Prefix : String := "") is use Ada.Strings.Maps; Output_Map : Character_Mapping; begin Output_Map := To_Mapping (From => To_Sequence (To_Set (('@'))), To => To_Sequence (To_Set ((' ')))); Ada.Text_IO.Put (Prefix); Ada.Text_IO.Put (Ada.Strings.Fixed.Translate (DNA, Output_Map)); Ada.Text_IO.Put_Line (", fitness: " & Integer'Image (Fitness (DNA))); end Output_DNA; -- DNA_Char is a discrete type, use Ada RNG package Random_Char is new Ada.Numerics.Discrete_Random (DNA_Char); DNA_Generator : Random_Char.Generator; -- need generator for floating type, too Float_Generator : Ada.Numerics.Float_Random.Generator; -- returns a mutated copy of the parent, applying the given mutation rate function Mutate (Parent : DNA_String; Mutation_Rate : Float) return DNA_String is Result : DNA_String := Parent; begin for Position in Result'Range loop if Ada.Numerics.Float_Random.Random (Float_Generator) <= Mutation_Rate then Result (Position) := Random_Char.Random (DNA_Generator); end if; end loop; return Result; end Mutate; -- genetic algorithm to evolve the string -- could be made a function returning the final string procedure Evolve (Child_Count : Positive := 100; Mutation_Rate : Float := 0.2) is type Child_Array is array (1 .. Child_Count) of DNA_String; -- determine the fittest of the candidates function Fittest (Candidates : Child_Array) return DNA_String is The_Fittest : DNA_String := Candidates (1); begin for Candidate in Candidates'Range loop if Fitness (Candidates (Candidate)) > Fitness (The_Fittest) then The_Fittest := Candidates (Candidate); end if; end loop; return The_Fittest; end Fittest; Parent, Next_Parent : DNA_String; Children : Child_Array; Loop_Counter : Positive := 1; begin -- initialize Parent for Position in Parent'Range loop Parent (Position) := Random_Char.Random (DNA_Generator); end loop; Output_DNA (Parent, "First: "); while Parent /= Target loop -- mutation loop for Child in Children'Range loop Children (Child) := Mutate (Parent, Mutation_Rate); end loop; Next_Parent := Fittest (Children); -- don't allow weaker children as the parent if Fitness (Next_Parent) > Fitness (Parent) then Parent := Next_Parent; end if; -- output every 20th generation if Loop_Counter mod 20 = 0 then Output_DNA (Parent, Integer'Image (Loop_Counter) & ": "); end if; Loop_Counter := Loop_Counter + 1; end loop; Output_DNA (Parent, "Final (" & Integer'Image (Loop_Counter) & "): "); end Evolve; begin -- initialize the random number generators Random_Char.Reset (DNA_Generator); Ada.Numerics.Float_Random.Reset (Float_Generator); -- evolve! Evolve; end Evolution;
with Ada.Text_IO; use Ada.Text_IO; with Readable_Sequences.String_Sequences; procedure String_Sequences_Test is use Readable_Sequences.String_Sequences; S : Sequence := Empty_Sequence; A : constant String := "pippo pluto e paperino"; b : constant string := " aldo giovanni e giacomo"; begin S.Append (A); S.Append (B); Put_Line (Boolean'Image (S.Length = A'Length + B'Length)); Put_Line (S.Dump); end String_Sequences_Test;
pragma License (Unrestricted); with Ada.Calendar.Time_Zones; package Ada.Calendar.Formatting is -- Day of the week: type Day_Name is ( Monday, Tuesday, Wednesday, Thursday, Friday, Saturday, Sunday); -- modified -- function Day_of_Week (Date : Time) return Day_Name; function Day_Of_Week ( Date : Time; Time_Zone : Time_Zones.Time_Offset := 0) -- additional return Day_Name; pragma Pure_Function (Day_Of_Week); pragma Inline (Day_Of_Week); -- Note: RM defined Day_*o*f_Week, but GNAT runtime defined Day_*O*f_Week. -- Hours:Minutes:Seconds access: subtype Hour_Number is Natural range 0 .. 23; subtype Minute_Number is Natural range 0 .. 59; subtype Second_Number is Natural range 0 .. 59; subtype Second_Duration is Day_Duration range 0.0 .. 1.0; function Year (Date : Time; Time_Zone : Time_Zones.Time_Offset := 0) return Year_Number; pragma Pure_Function (Year); pragma Inline (Year); function Month (Date : Time; Time_Zone : Time_Zones.Time_Offset := 0) return Month_Number; pragma Pure_Function (Month); pragma Inline (Month); function Day (Date : Time; Time_Zone : Time_Zones.Time_Offset := 0) return Day_Number; pragma Pure_Function (Day); pragma Inline (Day); function Hour (Date : Time; Time_Zone : Time_Zones.Time_Offset := 0) return Hour_Number; pragma Pure_Function (Hour); pragma Inline (Hour); function Minute (Date : Time; Time_Zone : Time_Zones.Time_Offset := 0) return Minute_Number; pragma Pure_Function (Minute); pragma Inline (Minute); function Second (Date : Time) return Second_Number; pragma Pure_Function (Second); pragma Inline (Second); function Sub_Second (Date : Time) return Second_Duration; pragma Pure_Function (Sub_Second); -- extended -- This function returns seconds in a day -- (including the offset of the time zone). function Seconds (Date : Time; Time_Zone : Time_Zones.Time_Offset := 0) return Day_Duration; pragma Pure_Function (Seconds); -- Note: Seconds is inefficient. function Seconds_Of ( Hour : Hour_Number; Minute : Minute_Number; Second : Second_Number := 0; Sub_Second : Second_Duration := 0.0) return Day_Duration; procedure Split ( Seconds : Day_Duration; Hour : out Hour_Number; Minute : out Minute_Number; Second : out Second_Number; Sub_Second : out Second_Duration); function Time_Of ( Year : Year_Number; Month : Month_Number; Day : Day_Number; Hour : Hour_Number; Minute : Minute_Number; Second : Second_Number; Sub_Second : Second_Duration := 0.0; Leap_Second : Boolean := False; Time_Zone : Time_Zones.Time_Offset := 0) return Time; function Time_Of ( Year : Year_Number; Month : Month_Number; Day : Day_Number; Seconds : Day_Duration := 0.0; Leap_Second : Boolean := False; Time_Zone : Time_Zones.Time_Offset := 0) return Time; procedure Split ( Date : Time; Year : out Year_Number; Month : out Month_Number; Day : out Day_Number; Hour : out Hour_Number; Minute : out Minute_Number; Second : out Second_Number; Sub_Second : out Second_Duration; Time_Zone : Time_Zones.Time_Offset := 0); procedure Split ( Date : Time; Year : out Year_Number; Month : out Month_Number; Day : out Day_Number; Hour : out Hour_Number; Minute : out Minute_Number; Second : out Second_Number; Sub_Second : out Second_Duration; Leap_Second : out Boolean; Time_Zone : Time_Zones.Time_Offset := 0); procedure Split ( Date : Time; Year : out Year_Number; Month : out Month_Number; Day : out Day_Number; Seconds : out Day_Duration; Leap_Second : out Boolean; Time_Zone : Time_Zones.Time_Offset := 0); -- Simple image and value: function Image ( Date : Time; Include_Time_Fraction : Boolean := False; Time_Zone : Time_Zones.Time_Offset := 0) return String; function Value ( Date : String; Time_Zone : Time_Zones.Time_Offset := 0) return Time; function Image ( Elapsed_Time : Duration; Include_Time_Fraction : Boolean := False) return String; function Value (Elapsed_Time : String) return Duration; -- extended -- The format of time-zone is "+00:00". function Image (Time_Zone : Time_Zones.Time_Offset) return String; function Value (Time_Zone : String) return Time_Zones.Time_Offset; end Ada.Calendar.Formatting;
-- from ACATS 2.6 tests package Switches is -- Switches type Toggle is tagged private; ---------------------------------- Toggle procedure Flip ( It : in out Toggle ); private type Toggle is tagged record On : Boolean := False; end record; end Switches;
------------------------------------------------------------------------------- -- -- -- 0MQ Ada-binding -- -- -- -- Z M Q . M E S S A G E S -- -- -- -- B o d y -- -- -- -- Copyright (C) 2020-2030, per.s.sandberg@bahnhof.se -- -- -- -- Permission is hereby granted, free of charge, to any person obtaining a -- -- copy of this software and associated documentation files -- -- (the "Software"), to deal in the Software without restriction, including -- -- without limitation the rights to use, copy, modify, merge, publish, -- -- distribute, sublicense, and / or sell copies of the Software, and to -- -- permit persons to whom the Software is furnished to do so, subject to -- -- the following conditions : -- -- -- -- The above copyright notice and this permission notice shall be included -- -- in all copies or substantial portions of the Software. -- -- -- -- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS -- -- OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -- -- MERCHANTABILITY, -- -- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL -- -- THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR -- -- OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, -- -- ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR -- -- OTHER DEALINGS IN THE SOFTWARE. -- ------------------------------------------------------------------------------- with Interfaces.C; with GNAT.OS_Lib; with GNAT.Source_Info; with Ada.Unchecked_Conversion; with System.Address_To_Access_Conversions; package body ZMQ.Messages is use Interfaces.C; -- ======================================================================== -- Initialize with size -- ======================================================================== procedure Initialize (Self : in out Message; Size : Natural) is Ret : int; begin if Size > 0 then Ret := Low_Level.zmq_msg_init_size (Self.Msg'Access, size_t (Size)); else Ret := Low_Level.zmq_msg_init (Self.Msg'Access); end if; if Ret /= 0 then raise ZMQ_Error with Error_Message (GNAT.OS_Lib.Errno) & " in " & GNAT.Source_Info.Enclosing_Entity; end if; end Initialize; -- ======================================================================== -- Initialize with data -- ======================================================================== procedure Initialize (Self : in out Message; Data : System.Address; Size : Natural) is type Data_Type is new String (1 .. Size); package Conv is new System.Address_To_Access_Conversions (Data_Type); begin Self.Initialize (Size); Conv.To_Pointer ((Self.GetData)).all := Conv.To_Pointer (Data).all; end Initialize; procedure Initialize (Self : in out Message; Data : String) is begin Self.Initialize (Data'Address, Data'Length); end Initialize; procedure Initialize (Self : in out Message; Data : Ada.Streams.Stream_Element_Array) is begin Self.Initialize (Data'Address, Data'Length); end Initialize; -- ======================================================================== -- Initialize with data ref and free -- ======================================================================== procedure Initialize (Self : in out Message; Message : System.Address; Size : Natural; Free : Free_Proc; Hint : System.Address := System.Null_Address) is Ret : int; begin Ret := Low_Level.zmq_msg_init_data (Self.Msg'Access, Message, size_t (Size), Free, Hint); if Ret /= 0 then raise ZMQ_Error with Error_Message (GNAT.OS_Lib.Errno) & " in " & GNAT.Source_Info.Enclosing_Entity; end if; end Initialize; ------------------------ -- Initialize_Generic -- ------------------------ procedure Initialize_Generic (Self : in out Message; Data : Element_Access) is function Conv is new Ada.Unchecked_Conversion (Source => System.Address, Target => Element_Access); procedure Internal_Free (Data : System.Address; Hint : System.Address); procedure Internal_Free (Data : System.Address; Hint : System.Address) is pragma Unreferenced (Hint); Temp : Element_Access := Conv (Data); begin Free (Temp); end Internal_Free; begin Self.Initialize (Data.all'Address, Data.all'Size / 8, Internal_Free'Unrestricted_Access); end Initialize_Generic; ---------------------------------- -- Initialize_Generic_With_Hint -- ---------------------------------- procedure Initialize_Generic_With_Hint (Self : in out Message; Data : Element_Access; Hint : Hint_Access) is function ConvHint is new Ada.Unchecked_Conversion (Source => System.Address, Target => Hint_Access); function Conv is new Ada.Unchecked_Conversion (Source => System.Address, Target => Element_Access); procedure Internal_Free (Data : System.Address; Hint : System.Address); procedure Internal_Free (Data : System.Address; Hint : System.Address) is Temp_Data : Element_Access := Conv (Data); Temp_Hint : constant Hint_Access := ConvHint (Hint); begin Free (Temp_Data, Temp_Hint); end Internal_Free; begin Self.Initialize (Data.all'Address, Data.all'Size / 8, Internal_Free'Unrestricted_Access, Hint.all'Address); end Initialize_Generic_With_Hint; -- ======================================================================== -- GetData / GetSize -- ======================================================================== --------------- -- getData -- --------------- function GetData (Self : Message) return System.Address is begin return Low_Level.zmq_msg_data (Self.Msg'Unrestricted_Access); end GetData; --------------- -- getData -- --------------- function GetData (Self : Message) return String is type Data_Type is new String (1 .. Self.GetSize); package Conv is new System.Address_To_Access_Conversions (Data_Type); begin return String (Conv.To_Pointer (Self.GetData).all); end GetData; --------------- -- getData -- --------------- function GetData (Self : Message) return Ada.Streams.Stream_Element_Array is type Data_Type is new Ada.Streams.Stream_Element_Array (1 .. Ada.Streams.Stream_Element_Offset (Self.GetSize)); package Conv is new System.Address_To_Access_Conversions (Data_Type); begin return Ada.Streams.Stream_Element_Array (Conv.To_Pointer (Self.GetData).all); end GetData; --------------- -- getData -- --------------- function GetData (Self : Message) return Ada.Strings.Unbounded.Unbounded_String is type Data_Type is new String (1 .. Self.GetSize); package Conv is new System.Address_To_Access_Conversions (Data_Type); begin return Ada.Strings.Unbounded.To_Unbounded_String (String (Conv.To_Pointer (Self.GetData).all)); end GetData; ----------------------- -- getData_Generic -- ----------------------- function GetData_Generic (Self : Message) return Element is package Conv is new System.Address_To_Access_Conversions (Element); begin return Conv.To_Pointer (Self.GetData).all; end GetData_Generic; --------------- -- getSize -- --------------- function GetSize (Self : Message) return Natural is begin return Natural (Low_Level.zmq_msg_size (Self.Msg'Unrestricted_Access)); end GetSize; -------------- -- Finalize -- -------------- procedure Finalize (Self : in out Message) is Ret : int; begin Ret := Low_Level.zmq_msg_close (Self.Msg'Access); if Ret /= 0 then raise ZMQ_Error with Error_Message (GNAT.OS_Lib.Errno) & " in " & GNAT.Source_Info.Enclosing_Entity; end if; end Finalize; ------------- -- getImpl -- ------------- function GetImpl (Self : Message) return not null Zmq_Msg_T_Access is begin return Self.Msg'Unrestricted_Access; end GetImpl; procedure Process_Data_Generic (Self : Message; Handle : access procedure (Item : Element)) is package Conv is new System.Address_To_Access_Conversions (Element); begin Handle (Conv.To_Pointer (Self.GetData).all); end Process_Data_Generic; end ZMQ.Messages;
with impact.d2.Contact, impact.d2.Solid, ada.Unchecked_Deallocation; package body impact.d2.Fixture is use type int32; function getKind (Self : in b2Fixture) return shape.Kind is begin return Self.m_shape.getKind; end getKind; function getShape (Self : in b2Fixture) return access Shape.b2Shape'Class is begin return Self.m_shape; end getShape; procedure setSensor (Self : in out b2Fixture; sensor : Boolean) is begin Self.m_isSensor := sensor; end setSensor; function IsSensor (Self : in b2Fixture) return Boolean is begin return Self.m_isSensor; end IsSensor; function GetFilterData (Self : in b2Fixture) return b2Filter is begin return Self.m_filter; end GetFilterData; procedure SetFilterData (Self : in out b2Fixture; filter : in b2Filter) is edge : access impact.d2.contact.b2ContactEdge; contact : access impact.d2.contact.b2Contact; fixtureA, fixtureB : access b2Fixture; begin Self.m_filter := filter; if Self.m_body = null then return; end if; -- Flag associated contacts for filtering. edge := Self.m_body.getContactList; while edge /= null loop contact := edge.contact; fixtureA := contact.GetFixtureA; fixtureB := contact.GetFixtureB; if fixtureA = Self'Access or else fixtureB = Self'Access then contact.FlagForFiltering; end if; edge := edge.next; end loop; end SetFilterData; function getBody (Self : in b2Fixture) return access Solid.b2Body'Class is begin return Self.m_body; end getBody; function GetNext (Self : in b2Fixture) return access b2Fixture is begin return Self.m_next; end GetNext; function GetUserData (Self : in b2Fixture) return access Any'Class is begin return Self.m_userData; end GetUserData; procedure SetUserData (Self : in out b2Fixture; data : access Any'Class) is begin Self.m_userData := data; end SetUserData; function TestPoint (Self : in b2Fixture; p : in b2Vec2) return Boolean is begin return Self.m_shape.TestPoint (Self.m_body.getTransform, p); end TestPoint; function RayCast (Self : in b2Fixture; output : access collision.b2RayCastOutput; input : in collision.b2RayCastInput; childIndex : in int32) return Boolean is begin return Self.m_shape.RayCast (output, input, Self.m_body.GetTransform); end RayCast; procedure GetMassData (Self : in b2Fixture; massData : access shape.b2MassData) is begin Self.m_shape.computeMass (massData, Self.m_density); end GetMassData; procedure SetDensity (Self : in out b2Fixture; density : in float32) is begin pragma Assert (b2IsValid (density) and then density >= 0.0); Self.m_density := density; end SetDensity; function GetDensity (Self : in b2Fixture) return float32 is begin return Self.m_density; end GetDensity; function GetFriction (Self : in b2Fixture) return float32 is begin return Self.m_friction; end GetFriction; procedure SetFriction (Self : in out b2Fixture; friction : in float32) is begin Self.m_friction := friction; end SetFriction; function GetRestitution (Self : in b2Fixture) return float32 is begin return Self.m_restitution; end GetRestitution; procedure SetRestitution (Self : in out b2Fixture; restitution : in float32) is begin Self.m_restitution := restitution; end SetRestitution; function GetAABB (Self : in b2Fixture) return collision.b2AABB is begin return Self.m_aabb; end GetAABB; procedure destruct (Self : in out b2Fixture) is use type Shape.view; begin pragma Assert (Self.m_shape = null); pragma Assert (Self.m_proxyId = BroadPhase.e_nullProxy); null; end destruct; -- We need separation create/destroy functions from the constructor/destructor because -- the destructor cannot access the allocator (no destructor arguments allowed by C++). -- procedure Create (Self : in out b2Fixture; Solid : access impact.d2.Solid.b2Body; def : in b2FixtureDef) is begin Self.m_body := Solid.all'Unchecked_Access; Self.m_userData := def.userData; Self.m_friction := def.friction; Self.m_restitution := def.restitution; Self.m_filter := def.filter; Self.m_isSensor := def.isSensor; Self.m_shape := def.shape.Clone; Self.m_density := def.density; end Create; procedure Destroy (Self : in out b2Fixture) is procedure free is new ada.Unchecked_Deallocation (Shape.b2Shape'Class, Shape.view); begin -- The proxy must be destroyed before calling this. pragma Assert (Self.m_proxyId = BroadPhase.e_nullProxy); -- Free the child shape. Self.m_shape.destruct; free (Self.m_shape); end Destroy; -- These support body activation/deactivation. -- procedure CreateProxy (Self : in out b2Fixture; broadPhase : access impact.d2.broadphase.b2BroadPhase; xf : in b2Transform) is begin pragma Assert (Self.m_proxyId = impact.d2.BroadPhase.e_nullProxy); -- Create proxy in the broad-phase. Self.m_shape.computeAABB (Self.m_aabb'Access, xf); Self.m_proxyId := broadPhase.createProxy (Self.m_aabb, Self'Access); end CreateProxy; procedure DestroyProxy (Self : in out b2Fixture; broadPhase : access impact.d2.broadphase.b2BroadPhase) is begin if Self.m_proxyId = impact.d2.BroadPhase.e_nullProxy then return; end if; -- Destroy proxy in the broad-phase. broadPhase.destroyProxy (Self.m_proxyId); Self.m_proxyId := impact.d2.BroadPhase.e_nullProxy; end DestroyProxy; procedure Synchronize (Self : in out b2Fixture; broadPhase : access impact.d2.broadphase.b2BroadPhase; xf1, xf2 : in b2Transform) is aabb1, aabb2 : aliased collision.b2AABB; displacement : b2Vec2; begin if Self.m_proxyId = impact.d2.BroadPhase.e_nullProxy then return; end if; -- Compute an AABB that covers the swept shape (may miss some rotation effect). Self.m_shape.ComputeAABB (aabb1'Access, xf1); Self.m_shape.ComputeAABB (aabb2'Access, xf2); collision.Combine (Self.m_aabb, aabb1, aabb2); displacement := xf2.position - xf1.position; broadPhase.MoveProxy (Self.m_proxyId, Self.m_aabb, displacement); end Synchronize; --- 'protected' subprograms for use by C 'friend's. -- function m_proxyId (Self : in b2Fixture) return int32 is begin return Self.m_proxyId; end m_proxyId; procedure m_next_is (Self : in out b2Fixture; Now : in Fixture.view) is begin Self.m_next := Now; end m_next_is; procedure m_body_is (Self : in out b2Fixture; Now : in Solid_view) is begin Self.m_body := Now; end m_body_is; procedure free (Self : in out View) is procedure deallocate is new ada.Unchecked_Deallocation (b2Fixture'Class, View); begin deallocate (Self); end free; end impact.d2.Fixture;
-------------------------------------------------------------------------- -- package Jacobi_Eigen, Jacobi iterative eigen-decomposition -- Copyright (C) 2008-2018 Jonathan S. Parker -- -- Permission to use, copy, modify, and/or distribute this software for any -- purpose with or without fee is hereby granted, provided that the above -- copyright notice and this permission notice appear in all copies. -- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES -- WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF -- MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR -- ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES -- WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN -- ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF -- OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. --------------------------------------------------------------------------- -- package Jacobi_Eigen -- -- Jacobi's iterative algorithm for eigen-decomposition of -- square real-valued symmetric matrices. -- -- The Jacobi method converges quadratically and with high -- reliability, but it is usually several times slower than the -- standard Golub-Reinsch algorithm (unless the matrix is small). -- Jacobi is usually best if accuracy and reliability are more -- important than speed. -- -- procedure Eigen_Decompose -- -- Works on arbitrary diagonal blocks of input matrix. For other blocks just -- copy the matrix to desired position; copy overhead is negligible compared -- to the O(N^3) running time of the decomposition. -- -- Procedure Eigen_Decompose is based on the Heinz Rutishauser ALGOL routine. -- If you want to see the original program in its full glory, you should -- be able to find it by googling "Rutishauser, Jacobi, Algol, ethistory". -- It was written over half a century ago! Changes are few: -- Slightly different calculation of the rotation angles. -- Also a bit more care in avoiding overflows; the test suite -- caught a few of them in the original routine. -- generic type Real is digits <>; type Index is range <>; type Matrix is array (Index, Index) of Real; package Jacobi_Eigen is type Col_Vector is array(Index) of Real; -- procedure Eigen_Decompose -- -- Standard Jacobi iterative eigendecomposition. The routine returns -- eigenvectors and eigenvalues of any real-valued square symmetric matrix. -- -- The orthonormal (unordered) eigenvectors are the Columns of Q. -- The orthonormal (unordered) eigenvectors are returned as the Rows of Q'=Q_tr. -- Eigenvals (returned in array Eigenvals) are ordered the same as Eigvecs in Q. -- So A = QEQ'. The diagonal elements of diagonal matrix E are the eigvals. -- The routine performs the eigen-decomposition on arbitrary square -- diagonal blocks of matrix A. -- It is assumed the blocks are symmetric. -- The upper left corner of the square matrix is (Start_Col, Start_Col). -- The lower rgt corner of the square matrix is (Final_Col, Final_Col). -- Matrix A doesn't need to be positive definite, or semi-definite. -- If Eigenvectors_Desired = False, then Q_tr is not calculated. -- -- Routine only sees and operates on the upper triangle of matrix. -- -- Input matrix A is destroyed. Save a copy of A if you need it. -- -- Eigenvectors of A are returned as the ROWS of matrix: Q_tr -- -- so Q_tr * A * Q = Diagonal_Eigs -- procedure Eigen_Decompose (A : in out Matrix; -- destroyed Q_tr : out Matrix; -- rows of Q_tr are the eigvecs Eigenvals : out Col_Vector; No_of_Sweeps_Performed : out Natural; Total_No_of_Rotations : out Natural; Start_Col : in Index := Index'First; Final_Col : in Index := Index'Last; Eigenvectors_Desired : in Boolean := True); procedure Sort_Eigs (Eigenvals : in out Col_Vector; Q_tr : in out Matrix; -- rows of Q_tr are the eigvecs Start_Col : in Index := Index'First; Final_Col : in Index := Index'Last; Sort_Eigvecs_Also : in Boolean := True); Standard_Threshold_Policy : constant Boolean := True; -- True is faster. -- False sometimes improves accuracy if the matrix is badly scaled. end Jacobi_Eigen;
with HAL; use HAL; with HAL.Framebuffer; use HAL.Framebuffer; with Framebuffer_LTDC; private with ILI9341; private with STM32.GPIO; private with STM32.Device; package Framebuffer_ILI9341 is type Frame_Buffer is limited new Framebuffer_LTDC.Frame_Buffer with private; procedure Initialize (Display : in out Frame_Buffer; Orientation : HAL.Framebuffer.Display_Orientation := Default; Mode : HAL.Framebuffer.Wait_Mode := Interrupt); private -- Chip select and Data/Command select for the LCD screen LCD_CSX : STM32.GPIO.GPIO_Point renames STM32.Device.PC2; LCD_WRX_DCX : STM32.GPIO.GPIO_Point renames STM32.Device.PD13; LCD_RESET : STM32.GPIO.GPIO_Point renames STM32.Device.PD12; type Frame_Buffer is limited new Framebuffer_LTDC.Frame_Buffer with record Device : ILI9341.ILI9341_Device (STM32.Device.SPI_5'Access, Chip_Select => LCD_CSX'Access, WRX => LCD_WRX_DCX'Access, Reset => LCD_RESET'Access); end record; end Framebuffer_ILI9341;
------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- I M P U N I T -- -- -- -- B o d y -- -- -- -- Copyright (C) 2000-2016, Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -- -- for more details. You should have received a copy of the GNU General -- -- Public License distributed with GNAT; see file COPYING3. If not, go to -- -- http://www.gnu.org/licenses for a complete copy of the license. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ with Atree; use Atree; with Errout; use Errout; with Sinfo; use Sinfo; with Fname.UF; use Fname.UF; with Lib; use Lib; with Namet; use Namet; with Opt; use Opt; with Uname; use Uname; -- Note: this package body is used by GPS and GNATBench to supply a list of -- entries for help on available library routines. package body Impunit is subtype File_Name_8 is String (1 .. 8); type File_Name_Record is record Fname : File_Name_8; -- 8 character name of unit RMdef : Boolean; -- True if unit is RM defined. False for any unit that is implementation -- defined (and thus not with'able in No_Implementation_Units mode). end record; type File_List is array (Nat range <>) of File_Name_Record; T : constant Boolean := True; F : constant Boolean := False; -- Short hand for RM_Defined values in lists below ------------------ -- Ada 95 Units -- ------------------ -- The following is a giant string list containing the names of all non- -- implementation internal files, i.e. the complete list of files for -- internal units which a program may legitimately WITH when operating in -- either Ada 95 or Ada 2005 mode. -- Note that this list should match the list of units documented in the -- "GNAT Library" section of the GNAT Reference Manual. A unit listed here -- must either be documented in that section or described in the Ada RM. Non_Imp_File_Names_95 : constant File_List := ( ------------------------------------------------------ -- Ada Hierarchy Units from Ada-95 Reference Manual -- ------------------------------------------------------ ("a-astaco", T), -- Ada.Asynchronous_Task_Control ("a-calend", T), -- Ada.Calendar ("a-chahan", T), -- Ada.Characters.Handling ("a-charac", T), -- Ada.Characters ("a-chlat1", T), -- Ada.Characters.Latin_1 ("a-comlin", T), -- Ada.Command_Line ("a-decima", T), -- Ada.Decimal ("a-direio", T), -- Ada.Direct_IO ("a-dynpri", T), -- Ada.Dynamic_Priorities ("a-except", T), -- Ada.Exceptions ("a-finali", T), -- Ada.Finalization ("a-flteio", T), -- Ada.Float_Text_IO ("a-fwteio", T), -- Ada.Float_Wide_Text_IO ("a-inteio", T), -- Ada.Integer_Text_IO ("a-interr", T), -- Ada.Interrupts ("a-intnam", T), -- Ada.Interrupts.Names ("a-ioexce", T), -- Ada.IO_Exceptions ("a-iwteio", T), -- Ada.Integer_Wide_Text_IO ("a-ncelfu", T), -- Ada.Numerics.Complex_Elementary_Functions ("a-ngcefu", T), -- Ada.Numerics.Generic_Complex_Elementary_Functions ("a-ngcoty", T), -- Ada.Numerics.Generic_Complex_Types ("a-ngelfu", T), -- Ada.Numerics.Generic_Elementary_Functions ("a-nucoty", T), -- Ada.Numerics.Complex_Types ("a-nudira", T), -- Ada.Numerics.Discrete_Random ("a-nuelfu", T), -- Ada.Numerics.Elementary_Functions ("a-nuflra", T), -- Ada.Numerics.Float_Random ("a-numeri", T), -- Ada.Numerics ("a-reatim", T), -- Ada.Real_Time ("a-sequio", T), -- Ada.Sequential_IO ("a-stmaco", T), -- Ada.Strings.Maps.Constants ("a-storio", T), -- Ada.Storage_IO ("a-strbou", T), -- Ada.Strings.Bounded ("a-stream", T), -- Ada.Streams ("a-strfix", T), -- Ada.Strings.Fixed ("a-string", T), -- Ada.Strings ("a-strmap", T), -- Ada.Strings.Maps ("a-strunb", T), -- Ada.Strings.Unbounded ("a-ststio", T), -- Ada.Streams.Stream_IO ("a-stwibo", T), -- Ada.Strings.Wide_Bounded ("a-stwifi", T), -- Ada.Strings.Wide_Fixed ("a-stwima", T), -- Ada.Strings.Wide_Maps ("a-stwiun", T), -- Ada.Strings.Wide_Unbounded ("a-swmwco", T), -- Ada.Strings.Wide_Maps.Wide_Constants ("a-sytaco", T), -- Ada.Synchronous_Task_Control ("a-tags ", T), -- Ada.Tags ("a-tasatt", T), -- Ada.Task_Attributes ("a-taside", T), -- Ada.Task_Identification ("a-teioed", T), -- Ada.Text_IO.Editing ("a-textio", T), -- Ada.Text_IO ("a-ticoio", T), -- Ada.Text_IO.Complex_IO ("a-titest", T), -- Ada.Text_IO.Text_Streams ("a-unccon", T), -- Ada.Unchecked_Conversion ("a-uncdea", T), -- Ada.Unchecked_Deallocation ("a-witeio", T), -- Ada.Wide_Text_IO ("a-wtcoio", T), -- Ada.Wide_Text_IO.Complex_IO ("a-wtedit", T), -- Ada.Wide_Text_IO.Editing ("a-wttest", T), -- Ada.Wide_Text_IO.Text_Streams ------------------------------------------------- -- RM Required Additions to Ada for GNAT Types -- ------------------------------------------------- -- Note: Long versions are considered RM defined, but not the Long Long, -- Short, or Short_Short versions. ("a-lfteio", T), -- Ada.Long_Float_Text_IO ("a-lfwtio", T), -- Ada.Long_Float_Wide_Text_IO ("a-liteio", T), -- Ada.Long_Integer_Text_IO ("a-liwtio", T), -- Ada.Long_Integer_Wide_Text_IO ("a-llftio", T), -- Ada.Long_Long_Float_Text_IO ("a-llfwti", T), -- Ada.Long_Long_Float_Wide_Text_IO ("a-llitio", T), -- Ada.Long_Long_Integer_Text_IO ("a-lliwti", F), -- Ada.Long_Long_Integer_Wide_Text_IO ("a-nlcefu", F), -- Ada.Long_Complex_Elementary_Functions ("a-nlcoty", T), -- Ada.Numerics.Long_Complex_Types ("a-nlelfu", T), -- Ada.Numerics.Long_Elementary_Functions ("a-nllcef", F), -- Ada.Long_Long_Complex_Elementary_Functions ("a-nllefu", F), -- Ada.Numerics.Long_Long_Elementary_Functions ("a-nllcty", F), -- Ada.Numerics.Long_Long_Complex_Types ("a-nscefu", F), -- Ada.Short_Complex_Elementary_Functions ("a-nscoty", F), -- Ada.Numerics.Short_Complex_Types ("a-nselfu", F), -- Ada.Numerics.Short_Elementary_Functions ("a-sfteio", F), -- Ada.Short_Float_Text_IO ("a-sfwtio", F), -- Ada.Short_Float_Wide_Text_IO ("a-siteio", F), -- Ada.Short_Integer_Text_IO ("a-siwtio", F), -- Ada.Short_Integer_Wide_Text_IO ("a-ssitio", F), -- Ada.Short_Short_Integer_Text_IO ("a-ssiwti", F), -- Ada.Short_Short_Integer_Wide_Text_IO ----------------------------------- -- GNAT Defined Additions to Ada -- ----------------------------------- ("a-calcon", F), -- Ada.Calendar.Conversions ("a-chlat9", F), -- Ada.Characters.Latin_9 ("a-clrefi", F), -- Ada.Command_Line.Response_File ("a-colien", F), -- Ada.Command_Line.Environment ("a-colire", F), -- Ada.Command_Line.Remove ("a-cwila1", F), -- Ada.Characters.Wide_Latin_1 ("a-cwila9", F), -- Ada.Characters.Wide_Latin_9 ("a-diocst", F), -- Ada.Direct_IO.C_Streams ("a-einuoc", F), -- Ada.Exceptions.Is_Null_Occurrence ("a-elchha", F), -- Ada.Exceptions.Last_Chance_Handler ("a-exctra", F), -- Ada.Exceptions.Traceback ("a-siocst", F), -- Ada.Sequential_IO.C_Streams ("a-ssicst", F), -- Ada.Streams.Stream_IO.C_Streams ("a-suteio", F), -- Ada.Strings.Unbounded.Text_IO ("a-swuwti", F), -- Ada.Strings.Wide_Unbounded.Wide_Text_IO ("a-tiocst", F), -- Ada.Text_IO.C_Streams ("a-wtcstr", F), -- Ada.Wide_Text_IO.C_Streams -- Note: strictly the next two should be Ada 2005 units, but it seems -- harmless (and useful) to make then available in Ada 95 mode, since -- they only deal with Wide_Character, not Wide_Wide_Character. ("a-wichun", F), -- Ada.Wide_Characters.Unicode ("a-widcha", F), -- Ada.Wide_Characters -- Note: strictly the following should be Ada 2012 units, but it seems -- harmless (and useful) to make then available in Ada 95 mode, since -- they do not deal with Wide_Wide_Character. ("a-wichha", F), -- Ada.Wide_Characters.Handling ("a-stuten", F), -- Ada.Strings.UTF_Encoding ("a-suenco", F), -- Ada.Strings.UTF_Encoding.Conversions ("a-suenst", F), -- Ada.Strings.UTF_Encoding.Strings ("a-suewst", F), -- Ada.Strings.UTF_Encoding.Wide_Strings --------------------------- -- GNAT Special IO Units -- --------------------------- -- As further explained elsewhere (see Sem_Ch10), the internal packages of -- Text_IO and Wide_Text_IO are actually implemented as separate children, -- but this fact is intended to be hidden from the user completely. Any -- attempt to WITH one of these units will be diagnosed as an error later -- on, but for now we do not consider these internal implementation units -- (if we did, then we would get a junk warning which would be confusing -- and unnecessary, given that we generate a clear error message). ("a-tideio", F), -- Ada.Text_IO.Decimal_IO ("a-tienio", F), -- Ada.Text_IO.Enumeration_IO ("a-tifiio", F), -- Ada.Text_IO.Fixed_IO ("a-tiflio", F), -- Ada.Text_IO.Float_IO ("a-tiinio", F), -- Ada.Text_IO.Integer_IO ("a-tiinio", F), -- Ada.Text_IO.Integer_IO ("a-timoio", F), -- Ada.Text_IO.Modular_IO ("a-wtdeio", F), -- Ada.Wide_Text_IO.Decimal_IO ("a-wtenio", F), -- Ada.Wide_Text_IO.Enumeration_IO ("a-wtfiio", F), -- Ada.Wide_Text_IO.Fixed_IO ("a-wtflio", F), -- Ada.Wide_Text_IO.Float_IO ("a-wtinio", F), -- Ada.Wide_Text_IO.Integer_IO ("a-wtmoio", F), -- Ada.Wide_Text_IO.Modular_IO ------------------------ -- GNAT Library Units -- ------------------------ ("g-altive", F), -- GNAT.Altivec ("g-altcon", F), -- GNAT.Altivec.Conversions ("g-alveop", F), -- GNAT.Altivec.Vector_Operations ("g-alvety", F), -- GNAT.Altivec.Vector_Types ("g-alvevi", F), -- GNAT.Altivec.Vector_Views ("g-arrspl", F), -- GNAT.Array_Split ("g-awk ", F), -- GNAT.AWK ("g-binenv", F), -- GNAT.Bind_Environment ("g-boubuf", F), -- GNAT.Bounded_Buffers ("g-boumai", F), -- GNAT.Bounded_Mailboxes ("g-bubsor", F), -- GNAT.Bubble_Sort ("g-busora", F), -- GNAT.Bubble_Sort_A ("g-busorg", F), -- GNAT.Bubble_Sort_G ("g-byorma", F), -- GNAT.Byte_Order_Mark ("g-bytswa", F), -- GNAT.Byte_Swapping ("g-calend", F), -- GNAT.Calendar ("g-catiio", F), -- GNAT.Calendar.Time_IO ("g-casuti", F), -- GNAT.Case_Util ("g-cgi ", F), -- GNAT.CGI ("g-cgicoo", F), -- GNAT.CGI.Cookie ("g-cgideb", F), -- GNAT.CGI.Debug ("g-comlin", F), -- GNAT.Command_Line ("g-comver", F), -- GNAT.Compiler_Version ("g-cppexc", F), -- GNAT.CPP_Exceptions ("g-crc32 ", F), -- GNAT.CRC32 ("g-ctrl_c", F), -- GNAT.Ctrl_C ("g-curexc", F), -- GNAT.Current_Exception ("g-debpoo", F), -- GNAT.Debug_Pools ("g-debuti", F), -- GNAT.Debug_Utilities ("g-decstr", F), -- GNAT.Decode_String ("g-deutst", F), -- GNAT.Decode_UTF8_String ("g-dirope", F), -- GNAT.Directory_Operations ("g-diopit", F), -- GNAT.Directory_Operations.Iteration ("g-dynhta", F), -- GNAT.Dynamic_HTables ("g-dyntab", F), -- GNAT.Dynamic_Tables ("g-encstr", F), -- GNAT.Encode_String ("g-enutst", F), -- GNAT.Encode_UTF8_String ("g-excact", F), -- GNAT.Exception_Actions ("g-except", F), -- GNAT.Exceptions ("g-exctra", F), -- GNAT.Exception_Traces ("g-expect", F), -- GNAT.Expect ("g-exptty", F), -- GNAT.Expect.TTY ("g-flocon", F), -- GNAT.Float_Control ("g-forstr", F), -- GNAT.Formatted_String ("g-heasor", F), -- GNAT.Heap_Sort ("g-hesora", F), -- GNAT.Heap_Sort_A ("g-hesorg", F), -- GNAT.Heap_Sort_G ("g-htable", F), -- GNAT.Htable ("g-io ", F), -- GNAT.IO ("g-io_aux", F), -- GNAT.IO_Aux ("g-locfil", F), -- GNAT.Lock_Files ("g-mbdira", F), -- GNAT.MBBS_Discrete_Random ("g-mbflra", F), -- GNAT.MBBS_Float_Random ("g-md5 ", F), -- GNAT.MD5 ("g-memdum", F), -- GNAT.Memory_Dump ("g-moreex", F), -- GNAT.Most_Recent_Exception ("g-os_lib", F), -- GNAT.Os_Lib ("g-pehage", F), -- GNAT.Perfect_Hash_Generators ("g-rannum", F), -- GNAT.Random_Numbers ("g-regexp", F), -- GNAT.Regexp ("g-regist", F), -- GNAT.Registry ("g-regpat", F), -- GNAT.Regpat ("g-rewdat", F), -- GNAT.Rewrite_Data ("g-semaph", F), -- GNAT.Semaphores ("g-sercom", F), -- GNAT.Serial_Communications ("g-sestin", F), -- GNAT.Secondary_Stack_Info ("g-sha1 ", F), -- GNAT.SHA1 ("g-sha224", F), -- GNAT.SHA224 ("g-sha256", F), -- GNAT.SHA256 ("g-sha384", F), -- GNAT.SHA384 ("g-sha512", F), -- GNAT.SHA512 ("g-signal", F), -- GNAT.Signals ("g-socket", F), -- GNAT.Sockets ("g-souinf", F), -- GNAT.Source_Info ("g-speche", F), -- GNAT.Spell_Checker ("g-spchge", F), -- GNAT.Spell_Checker_Generic ("g-spitbo", F), -- GNAT.Spitbol ("g-spipat", F), -- GNAT.Spitbol.Patterns ("g-sptabo", F), -- GNAT.Spitbol.Table_Boolean ("g-sptain", F), -- GNAT.Spitbol.Table_Integer ("g-sptavs", F), -- GNAT.Spitbol.Table_Vstring ("g-strhas", F), -- GNAT.String_Hash ("g-string", F), -- GNAT.Strings ("g-strspl", F), -- GNAT.String_Split ("g-sse ", F), -- GNAT.SSE ("g-ssvety", F), -- GNAT.SSE.Vector_Types ("g-table ", F), -- GNAT.Table ("g-tasloc", F), -- GNAT.Task_Lock ("g-tastus", F), -- GNAT.Task_Stack_Usage ("g-thread", F), -- GNAT.Threads ("g-timsta", F), -- GNAT.Time_Stamp ("g-traceb", F), -- GNAT.Traceback ("g-trasym", F), -- GNAT.Traceback.Symbolic ("g-tty ", F), -- GNAT.TTY ("g-utf_32", F), -- GNAT.UTF_32 ("g-u3spch", F), -- GNAT.UTF_32_Spelling_Checker ("g-wispch", F), -- GNAT.Wide_Spelling_Checker ("g-wistsp", F), -- GNAT.Wide_String_Split ----------------------------------------------------- -- Interface Hierarchy Units from Reference Manual -- ----------------------------------------------------- ("i-c ", T), -- Interfaces.C ("i-cobol ", T), -- Interfaces.Cobol ("i-cpoint", T), -- Interfaces.C.Pointers ("i-cstrin", T), -- Interfaces.C.Strings ("i-fortra", T), -- Interfaces.Fortran ------------------------------------------ -- GNAT Defined Additions to Interfaces -- ------------------------------------------ ("i-cexten", F), -- Interfaces.C.Extensions ("i-cil ", F), -- Interfaces.CIL ("i-cilobj", F), -- Interfaces.CIL.Object ("i-cstrea", F), -- Interfaces.C.Streams ("i-java ", F), -- Interfaces.Java ("i-javjni", F), -- Interfaces.Java.JNI ("i-pacdec", F), -- Interfaces.Packed_Decimal ("i-vxinco", F), -- Interfaces.VxWorks.Int_Connection ("i-vxwoio", F), -- Interfaces.VxWorks.IO ("i-vxwork", F), -- Interfaces.VxWorks -------------------------------------------------- -- System Hierarchy Units from Reference Manual -- -------------------------------------------------- ("s-atacco", T), -- System.Address_To_Access_Conversions ("s-maccod", T), -- System.Machine_Code ("s-rpc ", T), -- System.Rpc ("s-stoele", T), -- System.Storage_Elements ("s-stopoo", T), -- System.Storage_Pools -------------------------------------- -- GNAT Defined Additions to System -- -------------------------------------- ("s-addima", F), -- System.Address_Image ("s-atocou", F), -- System.Atomic_Counters ("s-assert", F), -- System.Assertions ("s-diflio", F), -- System.Dim.Float_IO ("s-diinio", F), -- System.Dim.Integer_IO ("s-dimkio", F), -- System.Dim.Mks_IO ("s-dimmks", F), -- System.Dim.Mks ("s-dmotpr", F), -- System.Dim.Mks.Other_Prefixes ("s-memory", F), -- System.Memory ("s-parint", F), -- System.Partition_Interface ("s-pooglo", F), -- System.Pool_Global ("s-pooloc", F), -- System.Pool_Local ("s-restri", F), -- System.Restrictions ("s-rident", F), -- System.Rident ("s-ststop", F), -- System.Strings.Stream_Ops ("s-tasinf", F), -- System.Task_Info ("s-unstyp", F), -- System.Unsigned_Types ("s-wchcnv", F), -- System.WCh_Cnv ("s-wchcon", F), -- System.WCh_Con -- The following are strictly speaking Ada 2012 units, but we are allowed -- to add children to system, so we consider them to be implementation -- defined additions to System in earlier versions of Ada. ("s-multip", T), -- System.Multiprocessors ("s-mudido", T)); -- System.Multiprocessors.Dispatching_Domains -------------------- -- Ada 2005 Units -- -------------------- -- The following units should be used only in Ada 05 mode Non_Imp_File_Names_05 : constant File_List := ( -------------------------------------------------------- -- Ada Hierarchy Units from Ada 2005 Reference Manual -- -------------------------------------------------------- ("a-assert", T), -- Ada.Assertions ("a-calari", T), -- Ada.Calendar.Arithmetic ("a-calfor", T), -- Ada.Calendar.Formatting ("a-catizo", T), -- Ada.Calendar.Time_Zones ("a-cdlili", T), -- Ada.Containers.Doubly_Linked_Lists ("a-cgarso", T), -- Ada.Containers.Generic_Array_Sort ("a-cgcaso", T), -- Ada.Containers.Generic_Constrained_Array_Sort ("a-chacon", T), -- Ada.Characters.Conversions ("a-cidlli", T), -- Ada.Containers.Indefinite_Doubly_Linked_Lists ("a-cihama", T), -- Ada.Containers.Indefinite_Hashed_Maps ("a-cihase", T), -- Ada.Containers.Indefinite_Hashed_Sets ("a-ciorma", T), -- Ada.Containers.Indefinite_Ordered_Maps ("a-ciorse", T), -- Ada.Containers.Indefinite_Ordered_Sets ("a-cohama", T), -- Ada.Containers.Hashed_Maps ("a-cohase", T), -- Ada.Containers.Hashed_Sets ("a-coinve", T), -- Ada.Containers.Indefinite_Vectors ("a-contai", T), -- Ada.Containers ("a-convec", T), -- Ada.Containers.Vectors ("a-coorma", T), -- Ada.Containers.Ordered_Maps ("a-coorse", T), -- Ada.Containers.Ordered_Sets ("a-coteio", T), -- Ada.Complex_Text_IO ("a-direct", T), -- Ada.Directories ("a-dinopr", T), -- Ada.Dispatching.Non_Preemptive ("a-diroro", T), -- Ada.Dispatching.Round_Robin ("a-disedf", T), -- Ada.Dispatching.EDF ("a-dispat", T), -- Ada.Dispatching ("a-envvar", T), -- Ada.Environment_Variables ("a-etgrbu", T), -- Ada.Execution_Time.Group_Budgets ("a-exetim", T), -- Ada.Execution_Time ("a-extiti", T), -- Ada.Execution_Time.Timers ("a-izteio", T), -- Ada.Integer_Wide_Wide_Text_IO ("a-rttiev", T), -- Ada.Real_Time.Timing_Events ("a-ngcoar", T), -- Ada.Numerics.Generic_Complex_Arrays ("a-ngrear", T), -- Ada.Numerics.Generic_Real_Arrays ("a-nucoar", T), -- Ada.Numerics.Complex_Arrays ("a-nurear", T), -- Ada.Numerics.Real_Arrays ("a-stboha", T), -- Ada.Strings.Bounded.Hash ("a-stfiha", T), -- Ada.Strings.Fixed.Hash ("a-strhas", T), -- Ada.Strings.Hash ("a-stunha", T), -- Ada.Strings.Unbounded.Hash ("a-stwiha", T), -- Ada.Strings.Wide_Hash ("a-stzbou", T), -- Ada.Strings.Wide_Wide_Bounded ("a-stzfix", T), -- Ada.Strings.Wide_Wide_Fixed ("a-stzhas", T), -- Ada.Strings.Wide_Wide_Hash ("a-stzmap", T), -- Ada.Strings.Wide_Wide_Maps ("a-stzunb", T), -- Ada.Strings.Wide_Wide_Unbounded ("a-swbwha", T), -- Ada.Strings.Wide_Bounded.Wide_Hash ("a-swfwha", T), -- Ada.Strings.Wide_Fixed.Wide_Hash ("a-swuwha", T), -- Ada.Strings.Wide_Unbounded.Wide_Hash ("a-szbzha", T), -- Ada.Strings.Wide_Wide_Bounded.Wide_Wide_Hash ("a-szfzha", T), -- Ada.Strings.Wide_Wide_Fixed.Wide_Wide_Hash ("a-szmzco", T), -- Ada.Strings.Wide_Wide_Maps.Wide_Wide_Constants ("a-szuzha", T), -- Ada.Strings.Wide_Wide_Unbounded.Wide_Wide_Hash ("a-taster", T), -- Ada.Task_Termination ("a-tgdico", T), -- Ada.Tags.Generic_Dispatching_Constructor ("a-tiboio", T), -- Ada.Text_IO.Bounded_IO ("a-tiunio", T), -- Ada.Text_IO.Unbounded_IO ("a-wichun", T), -- Ada.Wide_Characters.Unicode ("a-wwboio", T), -- Ada.Wide_Text_IO.Wide_Bounded_IO ("a-wwunio", T), -- Ada.Wide_Text_IO.Wide_Unbounded_IO ("a-zchara", T), -- Ada.Wide_Wide_Characters ("a-zchhan", T), -- Ada.Wide_Wide_Characters.Handling ("a-ztcoio", T), -- Ada.Wide_Wide_Text_IO.Complex_IO ("a-ztedit", T), -- Ada.Wide_Wide_Text_IO.Editing ("a-zttest", T), -- Ada.Wide_Wide_Text_IO.Text_Streams ("a-ztexio", T), -- Ada.Wide_Wide_Text_IO ("a-zzboio", T), -- Ada.Wide_Wide_Text_IO.Wide_Wide_Bounded_IO ("a-zzunio", T), -- Ada.Wide_Wide_Text_IO.Wide_Wide_Unbounded_IO ------------------------------------------------------ -- RM Required Additions to Ada 2005 for GNAT Types -- ------------------------------------------------------ -- Note: Long versions are considered RM defined, but not the Long Long, -- Short, or Short_Short versions. ("a-lcteio", T), -- Ada.Long_Complex_Text_IO ("a-lfztio", T), -- Ada.Long_Float_Wide_Wide_Text_IO ("a-liztio", T), -- Ada.Long_Integer_Wide_Wide_Text_IO ("a-llctio", T), -- Ada.Long_Long_Complex_Text_IO ("a-llfzti", T), -- Ada.Long_Long_Float_Wide_Wide_Text_IO ("a-llizti", T), -- Ada.Long_Long_Integer_Wide_Wide_Text_IO ("a-nlcoar", T), -- Ada.Numerics.Long_Complex_Arrays ("a-nllcar", T), -- Ada.Numerics.Long_Long_Complex_Arrays ("a-nllrar", T), -- Ada.Numerics.Long_Long_Real_Arrays ("a-nlrear", T), -- Ada.Numerics.Long_Real_Arrays ("a-scteio", F), -- Ada.Short_Complex_Text_IO ("a-sfztio", F), -- Ada.Short_Float_Wide_Wide_Text_IO ("a-siztio", F), -- Ada.Short_Integer_Wide_Wide_Text_IO ("a-ssizti", F), -- Ada.Short_Short_Integer_Wide_Wide_Text_IO ---------------------------------------- -- GNAT Defined Additions to Ada 2005 -- ---------------------------------------- ("a-cgaaso", F), -- Ada.Containers.Generic_Anonymous_Array_Sort ("a-chzla1", F), -- Ada.Characters.Wide_Wide_Latin_1 ("a-chzla9", F), -- Ada.Characters.Wide_Wide_Latin_9 ("a-ciormu", F), -- Ada.Containers.Indefinite_Ordered_Multisets ("a-coormu", F), -- Ada.Containers.Ordered_Multisets ("a-crdlli", F), -- Ada.Containers.Restricted_Doubly_Linked_Lists ("a-szuzti", F), -- Ada.Strings.Wide_Wide_Unbounded.Wide_Wide_Text_IO ("a-zchuni", F), -- Ada.Wide_Wide_Characters.Unicode ("a-ztcstr", F), -- Ada.Wide_Wide_Text_IO.C_Streams -- Note: strictly the following should be Ada 2012 units, but it seems -- harmless (and useful) to make then available in Ada 2005 mode. ("a-cogeso", T), -- Ada.Containers.Generic_Sort ("a-dhfina", T), -- Ada.Directories.Hierarchical_File_Names ("a-secain", T), -- Ada.Strings.Equal_Case_Insensitive ("a-shcain", T), -- Ada.Strings.Hash_Case_Insensitive ("a-slcain", T), -- Ada.Strings.Less_Case_Insensitive ("a-sfecin", T), -- Ada.Strings.Fixed.Equal_Case_Insensitive ("a-sfhcin", T), -- Ada.Strings.Fixed.Hash_Case_Insensitive ("a-sflcin", T), -- Ada.Strings.Fixed.Less_Case_Insensitive ("a-sbecin", T), -- Ada.Strings.Bounded.Equal_Case_Insensitive ("a-sbhcin", T), -- Ada.Strings.Bounded.Hash_Case_Insensitive ("a-sblcin", T), -- Ada.Strings.Bounded.Less_Case_Insensitive ("a-suecin", T), -- Ada.Strings.Unbounded.Equal_Case_Insensitive ("a-suhcin", T), -- Ada.Strings.Unbounded.Hash_Case_Insensitive ("a-sulcin", T), -- Ada.Strings.Unbounded.Less_Case_Insensitive ("a-suezst", T), -- Ada.Strings.UTF_Encoding.Wide_Wide_Strings --------------------------- -- GNAT Special IO Units -- --------------------------- -- See Ada 95 section for further information. These packages are for the -- implementation of the Wide_Wide_Text_IO generic packages. ("a-ztdeio", F), -- Ada.Wide_Wide_Text_IO.Decimal_IO ("a-ztenio", F), -- Ada.Wide_Wide_Text_IO.Enumeration_IO ("a-ztfiio", F), -- Ada.Wide_Wide_Text_IO.Fixed_IO ("a-ztflio", F), -- Ada.Wide_Wide_Text_IO.Float_IO ("a-ztinio", F), -- Ada.Wide_Wide_Text_IO.Integer_IO ("a-ztmoio", F), -- Ada.Wide_Wide_Text_IO.Modular_IO ------------------------ -- GNAT Library Units -- ------------------------ ("g-zspche", F), -- GNAT.Wide_Wide_Spelling_Checker ("g-zstspl", F)); -- GNAT.Wide_Wide_String_Split -------------------- -- Ada 2012 Units -- -------------------- -- The following units should be used only in Ada 2012 mode Non_Imp_File_Names_12 : constant File_List := ( ("s-stposu", T), -- System.Storage_Pools.Subpools ("a-cobove", T), -- Ada.Containers.Bounded_Vectors ("a-cbdlli", T), -- Ada.Containers.Bounded_Doubly_Linked_Lists ("a-cborse", T), -- Ada.Containers.Bounded_Ordered_Sets ("a-cborma", T), -- Ada.Containers.Bounded_Ordered_Maps ("a-cbhase", T), -- Ada.Containers.Bounded_Hashed_Sets ("a-cbhama", T), -- Ada.Containers.Bounded_Hashed_Maps ("a-coinho", T), -- Ada.Containers.Indefinite_Holders ("a-comutr", T), -- Ada.Containers.Multiway_Trees ("a-cimutr", T), -- Ada.Containers.Indefinite_Multiway_Trees ("a-cbmutr", T), -- Ada.Containers.Bounded_Multiway_Trees ("a-csquin", T), -- Ada.Containers.Synchronized_Queue_Interfaces ("a-cusyqu", T), -- Ada.Containers.Unbounded_Synchronized_Queues ("a-cuprqu", T), -- Ada.Containers.Unbounded_Priority_Queues ("a-cbsyqu", T), -- Ada.Containers.Bounded_Synchronized_Queues ("a-cbprqu", T), -- Ada.Containers.Bounded_Priority_Queues ("a-extiin", T), -- Ada.Execution_Time.Interrupts ("a-iteint", T), -- Ada.Iterator_Interfaces ("a-locale", T), -- Ada.Locales ("a-stcoed", T), -- Ada.Synchronous_Task_Control.EDF ("a-synbar", T), -- Ada.Synchronous_Barriers ("a-undesu", T), -- Ada.Unchecked_Deallocate_Subpool ---------------------------------------- -- GNAT Defined Additions to Ada 2012 -- ---------------------------------------- ("a-cfinve", F), -- Ada.Containers.Formal_Indefinite_Vectors ("a-coboho", F), -- Ada.Containers.Bounded_Holders ("a-cofove", F), -- Ada.Containers.Formal_Vectors ("a-cfdlli", F), -- Ada.Containers.Formal_Doubly_Linked_Lists ("a-cforse", F), -- Ada.Containers.Formal_Ordered_Sets ("a-cforma", F), -- Ada.Containers.Formal_Ordered_Maps ("a-cfhase", F), -- Ada.Containers.Formal_Hashed_Sets ("a-cfhama", F)); -- Ada.Containers.Formal_Hashed_Maps ----------------------- -- Alternative Units -- ----------------------- -- For some implementation units, there is a unit in the GNAT library -- that has identical functionality that is usable. If we have such a -- case we record the appropriate Unit name in Error_Msg_String. type Aunit_Record is record Fname : String (1 .. 6); Aname : String_Ptr_Const; end record; -- Array of alternative unit names Scasuti : aliased constant String := "GNAT.Case_Util"; Scrc32 : aliased constant String := "GNAT.CRC32"; Shtable : aliased constant String := "GNAT.HTable"; Sos_lib : aliased constant String := "GNAT.OS_Lib"; Sregexp : aliased constant String := "GNAT.Regexp"; Sregpat : aliased constant String := "GNAT.Regpat"; Sstring : aliased constant String := "GNAT.Strings"; Sstusta : aliased constant String := "GNAT.Task_Stack_Usage"; Stasloc : aliased constant String := "GNAT.Task_Lock"; Sutf_32 : aliased constant String := "GNAT.UTF_32"; -- Array giving mapping Map_Array : constant array (1 .. 10) of Aunit_Record := ( ("casuti", Scasuti'Access), ("crc32 ", Scrc32 'Access), ("htable", Shtable'Access), ("os_lib", Sos_lib'Access), ("regexp", Sregexp'Access), ("regpat", Sregpat'Access), ("string", Sstring'Access), ("stusta", Sstusta'Access), ("tasloc", Stasloc'Access), ("utf_32", Sutf_32'Access)); ---------------------- -- Get_Kind_Of_File -- ---------------------- function Get_Kind_Of_File (File : String) return Kind_Of_Unit is pragma Assert (File'First = 1); Buffer : String (1 .. 8); begin Error_Msg_Strlen := 0; -- Ada/System/Interfaces are all Ada 95 units if File = "ada.ads" or else File = "interfac.ads" or else File = "system.ads" then return Ada_95_Unit; end if; -- If length of file name is greater than 12, not predefined. The value -- 12 here is an 8 char name with extension .ads. if File'Length > 12 then return Not_Predefined_Unit; end if; -- Not predefined if file name does not start with a- g- s- i- if File'Length < 3 or else File (2) /= '-' or else (File (1) /= 'a' and then File (1) /= 'g' and then File (1) /= 'i' and then File (1) /= 's') then return Not_Predefined_Unit; end if; -- To be considered predefined, the file name must end in .ads or .adb. -- File names with other extensions (coming from the use of non-standard -- file naming schemes) can never be predefined. -- Note that in the context of a compiler, the .adb case will never -- arise. However it can arise for other tools, e.g. gnatprove uses -- this routine to detect when a construct comes from an instance of -- a generic defined in a predefined unit. if File (File'Last - 3 .. File'Last) /= ".ads" and then File (File'Last - 3 .. File'Last) /= ".adb" then return Not_Predefined_Unit; end if; -- Otherwise normalize file name to 8 characters Buffer (1 .. File'Length - 4) := File (1 .. File'Length - 4); for J in File'Length - 3 .. 8 loop Buffer (J) := ' '; end loop; -- See if name is in 95 list for J in Non_Imp_File_Names_95'Range loop if Buffer = Non_Imp_File_Names_95 (J).Fname then return Ada_95_Unit; end if; end loop; -- See if name is in 2005 list for J in Non_Imp_File_Names_05'Range loop if Buffer = Non_Imp_File_Names_05 (J).Fname then return Ada_2005_Unit; end if; end loop; -- See if name is in 2012 list for J in Non_Imp_File_Names_12'Range loop if Buffer = Non_Imp_File_Names_12 (J).Fname then return Ada_2012_Unit; end if; end loop; -- Only remaining special possibilities are children of System.RPC and -- System.Garlic and special files of the form System.Aux... if File (1 .. 5) = "s-aux" or else File (1 .. 5) = "s-gar" or else File (1 .. 5) = "s-rpc" then return Ada_95_Unit; end if; -- All tests failed, this is definitely an implementation unit. See if -- we have an alternative name. if File'Length in 11 .. 12 and then File (1 .. 2) = "s-" and then File (File'Last - 3 .. File'Last) = ".ads" then for J in Map_Array'Range loop if (File'Length = 12 and then File (3 .. 8) = Map_Array (J).Fname) or else (File'Length = 11 and then File (3 .. 7) = Map_Array (J).Fname (1 .. 5)) then Error_Msg_Strlen := Map_Array (J).Aname'Length; Error_Msg_String (1 .. Error_Msg_Strlen) := Map_Array (J).Aname.all; end if; end loop; end if; return Implementation_Unit; end Get_Kind_Of_File; ---------------------- -- Get_Kind_Of_Unit -- ---------------------- function Get_Kind_Of_Unit (U : Unit_Number_Type) return Kind_Of_Unit is begin Get_Name_String (Unit_File_Name (U)); return Get_Kind_Of_File (Name_Buffer (1 .. Name_Len)); end Get_Kind_Of_Unit; ------------------- -- Is_Known_Unit -- ------------------- function Is_Known_Unit (Nam : Node_Id) return Boolean is Unam : Unit_Name_Type; Fnam : File_Name_Type; begin -- If selector is not an identifier (e.g. it is a character literal or -- some junk from a previous error), then definitely not a known unit. if Nkind (Selector_Name (Nam)) /= N_Identifier then return False; end if; -- Otherwise get corresponding file name Unam := Get_Unit_Name (Nam); Fnam := Get_File_Name (Unam, Subunit => False); Get_Name_String (Fnam); Error_Msg_Strlen := 0; -- Ada/System/Interfaces are all Ada 95 units if (Name_Len = 7 and then Name_Buffer (1 .. 7) = "ada.ads") or else (Name_Len = 10 and then Name_Buffer (1 .. 10) = "system.ads") or else (Name_Len = 12 and then Name_Buffer (1 .. 12) = "interfac.ads") then return True; end if; -- Remove extension from file name if Name_Buffer (Name_Len - 3 .. Name_Len) = ".adb" or else Name_Buffer (Name_Len - 3 .. Name_Len) = ".ads" then Name_Len := Name_Len - 4; else return False; end if; -- Pad name to 8 characters while Name_Len < 8 loop Name_Len := Name_Len + 1; Name_Buffer (Name_Len) := ' '; end loop; -- If length more than 8, definitely not a match if Name_Len /= 8 then return False; end if; -- If length is 8, search our tables for J in Non_Imp_File_Names_95'Range loop if Name_Buffer (1 .. 8) = Non_Imp_File_Names_95 (J).Fname then return True; end if; end loop; for J in Non_Imp_File_Names_05'Range loop if Name_Buffer (1 .. 8) = Non_Imp_File_Names_05 (J).Fname then return True; end if; end loop; for J in Non_Imp_File_Names_12'Range loop if Name_Buffer (1 .. 8) = Non_Imp_File_Names_12 (J).Fname then return True; end if; end loop; -- If not found, not known return False; -- A safety guard, if we get an exception during this processing then it -- is most likely the result of a previous error, or a peculiar case we -- have not thought of. Since this routine is only used for error message -- refinement, we will just return False. exception when others => return False; end Is_Known_Unit; --------------------------- -- Not_Impl_Defined_Unit -- --------------------------- function Not_Impl_Defined_Unit (U : Unit_Number_Type) return Boolean is Fname : constant File_Name_Type := Unit_File_Name (U); begin Error_Msg_Strlen := 0; Get_Name_String (Fname); -- Ada/System/Interfaces are all RM-defined Ada 95 units if (Name_Len = 7 and then Name_Buffer (1 .. 7) = "ada.ads") or else (Name_Len = 10 and then Name_Buffer (1 .. 10) = "system.ads") or else (Name_Len = 12 and then Name_Buffer (1 .. 12) = "interfac.ads") then return True; end if; -- If length of file name is greater than 12, then it's a user unit -- and not a GNAT implementation defined unit. if Name_Len > 12 then return True; end if; -- Implementation defined if unit in the gnat hierarchy if (Name_Len = 8 and then Name_Buffer (1 .. 8) = "gnat.ads") or else (Name_Len > 2 and then Name_Buffer (1 .. 2) = "g-") then return False; end if; -- Not implementation defined if file name does not start with a- s- i- if Name_Len < 3 or else Name_Buffer (2) /= '-' or else (Name_Buffer (1) /= 'a' and then Name_Buffer (1) /= 'i' and then Name_Buffer (1) /= 's') then return True; end if; -- Not impl-defined if file name does not end in .ads. This can happen -- when non-standard file names are being used. if Name_Buffer (Name_Len - 3 .. Name_Len) /= ".ads" then return True; end if; -- Otherwise normalize file name to 8 characters Name_Len := Name_Len - 4; while Name_Len < 8 loop Name_Len := Name_Len + 1; Name_Buffer (Name_Len) := ' '; end loop; -- Check our lists of names, if we find a match, return corresponding -- indication of whether the file is RM defined, respecting the RM -- version in which it is defined. for J in Non_Imp_File_Names_95'Range loop if Name_Buffer (1 .. 8) = Non_Imp_File_Names_95 (J).Fname then return Non_Imp_File_Names_95 (J).RMdef; end if; end loop; for J in Non_Imp_File_Names_05'Range loop if Name_Buffer (1 .. 8) = Non_Imp_File_Names_05 (J).Fname then return Non_Imp_File_Names_05 (J).RMdef and then Ada_Version >= Ada_2005; end if; end loop; for J in Non_Imp_File_Names_12'Range loop if Name_Buffer (1 .. 8) = Non_Imp_File_Names_12 (J).Fname then return Non_Imp_File_Names_95 (J).RMdef and then Ada_Version >= Ada_2012; end if; end loop; -- If unit is in System, Ada or Interfaces hierarchies and did not match -- any entry in the list, means it is an internal implementation defined -- unit which the restriction should definition forbid. return True; end Not_Impl_Defined_Unit; end Impunit;
------------------------------------------------------------------------------ -- -- -- GNAT COMPILER COMPONENTS -- -- -- -- S E M _ C H 1 1 -- -- -- -- B o d y -- -- -- -- $Revision$ -- -- -- Copyright (C) 1992-2001 Free Software Foundation, Inc. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 2, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License -- -- for more details. You should have received a copy of the GNU General -- -- Public License distributed with GNAT; see file COPYING. If not, write -- -- to the Free Software Foundation, 59 Temple Place - Suite 330, Boston, -- -- MA 02111-1307, USA. -- -- -- -- GNAT was originally developed by the GNAT team at New York University. -- -- Extensive contributions were provided by Ada Core Technologies Inc. -- -- -- ------------------------------------------------------------------------------ with Atree; use Atree; with Einfo; use Einfo; with Errout; use Errout; with Lib; use Lib; with Lib.Xref; use Lib.Xref; with Nlists; use Nlists; with Nmake; use Nmake; with Opt; use Opt; with Restrict; use Restrict; with Rtsfind; use Rtsfind; with Sem; use Sem; with Sem_Ch5; use Sem_Ch5; with Sem_Ch8; use Sem_Ch8; with Sem_Res; use Sem_Res; with Sem_Util; use Sem_Util; with Sinfo; use Sinfo; with Stand; use Stand; with Uintp; use Uintp; package body Sem_Ch11 is ----------------------------------- -- Analyze_Exception_Declaration -- ----------------------------------- procedure Analyze_Exception_Declaration (N : Node_Id) is Id : constant Entity_Id := Defining_Identifier (N); PF : constant Boolean := Is_Pure (Current_Scope); begin Generate_Definition (Id); Enter_Name (Id); Set_Ekind (Id, E_Exception); Set_Exception_Code (Id, Uint_0); Set_Etype (Id, Standard_Exception_Type); Set_Is_Statically_Allocated (Id); Set_Is_Pure (Id, PF); end Analyze_Exception_Declaration; -------------------------------- -- Analyze_Exception_Handlers -- -------------------------------- procedure Analyze_Exception_Handlers (L : List_Id) is Handler : Node_Id; Choice : Entity_Id; Id : Node_Id; H_Scope : Entity_Id := Empty; procedure Check_Duplication (Id : Node_Id); -- Iterate through the identifiers in each handler to find duplicates ----------------------- -- Check_Duplication -- ----------------------- procedure Check_Duplication (Id : Node_Id) is Handler : Node_Id; Id1 : Node_Id; begin Handler := First_Non_Pragma (L); while Present (Handler) loop Id1 := First (Exception_Choices (Handler)); while Present (Id1) loop -- Only check against the exception choices which precede -- Id in the handler, since the ones that follow Id have not -- been analyzed yet and will be checked in a subsequent call. if Id = Id1 then return; elsif Nkind (Id1) /= N_Others_Choice and then Entity (Id) = Entity (Id1) then if Handler /= Parent (Id) then Error_Msg_Sloc := Sloc (Id1); Error_Msg_NE ("exception choice duplicates &#", Id, Id1); else if Ada_83 and then Comes_From_Source (Id) then Error_Msg_N ("(Ada 83): duplicate exception choice&", Id); end if; end if; end if; Next_Non_Pragma (Id1); end loop; Next (Handler); end loop; end Check_Duplication; -- Start processing for Analyze_Exception_Handlers begin Handler := First (L); Check_Restriction (No_Exceptions, Handler); Check_Restriction (No_Exception_Handlers, Handler); -- Loop through handlers (which can include pragmas) while Present (Handler) loop -- If pragma just analyze it if Nkind (Handler) = N_Pragma then Analyze (Handler); -- Otherwise we have a real exception handler else -- Deal with choice parameter. The exception handler is -- a declarative part for it, so it constitutes a scope -- for visibility purposes. We create an entity to denote -- the whole exception part, and use it as the scope of all -- the choices, which may even have the same name without -- conflict. This scope plays no other role in expansion or -- or code generation. Choice := Choice_Parameter (Handler); if Present (Choice) then if No (H_Scope) then H_Scope := New_Internal_Entity (E_Block, Current_Scope, Sloc (Choice), 'E'); end if; New_Scope (H_Scope); Set_Etype (H_Scope, Standard_Void_Type); -- Set the Finalization Chain entity to Error means that it -- should not be used at that level but the parent one -- should be used instead. -- ??? this usage needs documenting in Einfo/Exp_Ch7 ??? -- ??? using Error for this non-error condition is nasty ??? Set_Finalization_Chain_Entity (H_Scope, Error); Enter_Name (Choice); Set_Ekind (Choice, E_Variable); Set_Etype (Choice, RTE (RE_Exception_Occurrence)); Generate_Definition (Choice); end if; Id := First (Exception_Choices (Handler)); while Present (Id) loop if Nkind (Id) = N_Others_Choice then if Present (Next (Id)) or else Present (Next (Handler)) or else Present (Prev (Id)) then Error_Msg_N ("OTHERS must appear alone and last", Id); end if; else Analyze (Id); if not Is_Entity_Name (Id) or else Ekind (Entity (Id)) /= E_Exception then Error_Msg_N ("exception name expected", Id); else if Present (Renamed_Entity (Entity (Id))) then Set_Entity (Id, Renamed_Entity (Entity (Id))); end if; Check_Duplication (Id); -- Check for exception declared within generic formal -- package (which is illegal, see RM 11.2(8)) declare Ent : Entity_Id := Entity (Id); Scop : Entity_Id := Scope (Ent); begin while Scop /= Standard_Standard and then Ekind (Scop) = E_Package loop -- If the exception is declared in an inner -- instance, nothing else to check. if Is_Generic_Instance (Scop) then exit; elsif Nkind (Declaration_Node (Scop)) = N_Package_Specification and then Nkind (Original_Node (Parent (Declaration_Node (Scop)))) = N_Formal_Package_Declaration then Error_Msg_NE ("exception& is declared in " & "generic formal package", Id, Ent); Error_Msg_N ("\and therefore cannot appear in " & "handler ('R'M 11.2(8))", Id); exit; end if; Scop := Scope (Scop); end loop; end; end if; end if; Next (Id); end loop; Analyze_Statements (Statements (Handler)); if Present (Choice) then End_Scope; end if; end if; Next (Handler); end loop; end Analyze_Exception_Handlers; -------------------------------- -- Analyze_Handled_Statements -- -------------------------------- procedure Analyze_Handled_Statements (N : Node_Id) is Handlers : constant List_Id := Exception_Handlers (N); begin Analyze_Statements (Statements (N)); if Present (Handlers) then Analyze_Exception_Handlers (Handlers); elsif Present (At_End_Proc (N)) then Analyze (At_End_Proc (N)); end if; end Analyze_Handled_Statements; ----------------------------- -- Analyze_Raise_Statement -- ----------------------------- procedure Analyze_Raise_Statement (N : Node_Id) is Exception_Id : constant Node_Id := Name (N); Exception_Name : Entity_Id := Empty; P : Node_Id; Nkind_P : Node_Kind; begin Check_Unreachable_Code (N); -- Check exception restrictions on the original source if Comes_From_Source (N) then Check_Restriction (No_Exceptions, N); end if; -- Reraise statement if No (Exception_Id) then P := Parent (N); Nkind_P := Nkind (P); while Nkind_P /= N_Exception_Handler and then Nkind_P /= N_Subprogram_Body and then Nkind_P /= N_Package_Body and then Nkind_P /= N_Task_Body and then Nkind_P /= N_Entry_Body loop P := Parent (P); Nkind_P := Nkind (P); end loop; if Nkind (P) /= N_Exception_Handler then Error_Msg_N ("reraise statement must appear directly in a handler", N); end if; -- Normal case with exception id present else Analyze (Exception_Id); if Is_Entity_Name (Exception_Id) then Exception_Name := Entity (Exception_Id); if Present (Renamed_Object (Exception_Name)) then Set_Entity (Exception_Id, Renamed_Object (Exception_Name)); end if; end if; if No (Exception_Name) or else Ekind (Exception_Name) /= E_Exception then Error_Msg_N ("exception name expected in raise statement", Exception_Id); end if; end if; end Analyze_Raise_Statement; ----------------------------- -- Analyze_Raise_xxx_Error -- ----------------------------- -- Normally, the Etype is already set (when this node is used within -- an expression, since it is copied from the node which it rewrites). -- If this node is used in a statement context, then we set the type -- Standard_Void_Type. This is used both by Gigi and by the front end -- to distinguish the statement use and the subexpression use. -- The only other required processing is to take care of the Condition -- field if one is present. procedure Analyze_Raise_xxx_Error (N : Node_Id) is begin if No (Etype (N)) then Set_Etype (N, Standard_Void_Type); end if; if Present (Condition (N)) then Analyze_And_Resolve (Condition (N), Standard_Boolean); end if; -- Deal with static cases in obvious manner if Nkind (Condition (N)) = N_Identifier then if Entity (Condition (N)) = Standard_True then Set_Condition (N, Empty); elsif Entity (Condition (N)) = Standard_False then Rewrite (N, Make_Null_Statement (Sloc (N))); end if; end if; end Analyze_Raise_xxx_Error; ----------------------------- -- Analyze_Subprogram_Info -- ----------------------------- procedure Analyze_Subprogram_Info (N : Node_Id) is begin Set_Etype (N, RTE (RE_Code_Loc)); end Analyze_Subprogram_Info; end Sem_Ch11;
------------------------------------------------------------------------------ -- -- -- GNAT RUN-TIME LIBRARY (GNARL) COMPONENTS -- -- -- -- S Y S T E M . T A S K I N G . R E N D E Z V O U S -- -- -- -- B o d y -- -- -- -- Copyright (C) 1992-2020, Free Software Foundation, Inc. -- -- -- -- GNARL is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- -- -- -- GNARL was developed by the GNARL team at Florida State University. -- -- Extensive contributions were provided by Ada Core Technologies, Inc. -- -- -- ------------------------------------------------------------------------------ with System.Task_Primitives.Operations; with System.Tasking.Entry_Calls; with System.Tasking.Initialization; with System.Tasking.Queuing; with System.Tasking.Utilities; with System.Tasking.Protected_Objects.Operations; with System.Tasking.Debug; with System.Restrictions; package body System.Tasking.Rendezvous is package STPO renames System.Task_Primitives.Operations; package POO renames Protected_Objects.Operations; package POE renames Protected_Objects.Entries; use Task_Primitives.Operations; type Select_Treatment is ( Accept_Alternative_Selected, -- alternative with non-null body Accept_Alternative_Completed, -- alternative with null body Else_Selected, Terminate_Selected, Accept_Alternative_Open, No_Alternative_Open); ---------------- -- Local Data -- ---------------- Default_Treatment : constant array (Select_Modes) of Select_Treatment := (Simple_Mode => No_Alternative_Open, Else_Mode => Else_Selected, Terminate_Mode => Terminate_Selected, Delay_Mode => No_Alternative_Open); New_State : constant array (Boolean, Entry_Call_State) of Entry_Call_State := (True => (Never_Abortable => Never_Abortable, Not_Yet_Abortable => Now_Abortable, Was_Abortable => Now_Abortable, Now_Abortable => Now_Abortable, Done => Done, Cancelled => Cancelled), False => (Never_Abortable => Never_Abortable, Not_Yet_Abortable => Not_Yet_Abortable, Was_Abortable => Was_Abortable, Now_Abortable => Now_Abortable, Done => Done, Cancelled => Cancelled) ); ----------------------- -- Local Subprograms -- ----------------------- procedure Local_Defer_Abort (Self_Id : Task_Id) renames System.Tasking.Initialization.Defer_Abort_Nestable; procedure Local_Undefer_Abort (Self_Id : Task_Id) renames System.Tasking.Initialization.Undefer_Abort_Nestable; -- Florist defers abort around critical sections that make entry calls -- to the Interrupt_Manager task, which violates the general rule about -- top-level runtime system calls from abort-deferred regions. It is not -- that this is unsafe, but when it occurs in "normal" programs it usually -- means either the user is trying to do a potentially blocking operation -- from within a protected object, or there is a runtime system/compiler -- error that has failed to undefer an earlier abort deferral. Thus, for -- debugging it may be wise to modify the above renamings to the -- non-nestable forms. procedure Local_Complete_Rendezvous (Ex : Ada.Exceptions.Exception_Id); -- Internal version of Complete_Rendezvous, used to implement -- Complete_Rendezvous and Exceptional_Complete_Rendezvous. -- Should be called holding no locks, generally with abort -- not yet deferred. procedure Boost_Priority (Call : Entry_Call_Link; Acceptor : Task_Id); pragma Inline (Boost_Priority); -- Call this only with abort deferred and holding lock of Acceptor procedure Call_Synchronous (Acceptor : Task_Id; E : Task_Entry_Index; Uninterpreted_Data : System.Address; Mode : Call_Modes; Rendezvous_Successful : out Boolean); pragma Inline (Call_Synchronous); -- This call is used to make a simple or conditional entry call. -- Called from Call_Simple and Task_Entry_Call. procedure Setup_For_Rendezvous_With_Body (Entry_Call : Entry_Call_Link; Acceptor : Task_Id); pragma Inline (Setup_For_Rendezvous_With_Body); -- Call this only with abort deferred and holding lock of Acceptor. When -- a rendezvous selected (ready for rendezvous) we need to save previous -- caller and adjust the priority. Also we need to make this call not -- Abortable (Cancellable) since the rendezvous has already been started. procedure Wait_For_Call (Self_Id : Task_Id); pragma Inline (Wait_For_Call); -- Call this only with abort deferred and holding lock of Self_Id. An -- accepting task goes into Sleep by calling this routine waiting for a -- call from the caller or waiting for an abort. Make sure Self_Id is -- locked before calling this routine. ----------------- -- Accept_Call -- ----------------- procedure Accept_Call (E : Task_Entry_Index; Uninterpreted_Data : out System.Address) is Self_Id : constant Task_Id := STPO.Self; Caller : Task_Id := null; Open_Accepts : aliased Accept_List (1 .. 1); Entry_Call : Entry_Call_Link; begin Initialization.Defer_Abort (Self_Id); STPO.Write_Lock (Self_Id); if not Self_Id.Callable then pragma Assert (Self_Id.Pending_ATC_Level = Level_Completed_Task); pragma Assert (Self_Id.Pending_Action); STPO.Unlock (Self_Id); Initialization.Undefer_Abort (Self_Id); -- Should never get here ??? pragma Assert (False); raise Standard'Abort_Signal; end if; Queuing.Dequeue_Head (Self_Id.Entry_Queues (E), Entry_Call); if Entry_Call /= null then Caller := Entry_Call.Self; Setup_For_Rendezvous_With_Body (Entry_Call, Self_Id); Uninterpreted_Data := Entry_Call.Uninterpreted_Data; else -- Wait for a caller Open_Accepts (1).Null_Body := False; Open_Accepts (1).S := E; Self_Id.Open_Accepts := Open_Accepts'Unrestricted_Access; -- Wait for normal call pragma Debug (Debug.Trace (Self_Id, "Accept_Call: wait", 'R')); Wait_For_Call (Self_Id); pragma Assert (Self_Id.Open_Accepts = null); if Self_Id.Common.Call /= null then Caller := Self_Id.Common.Call.Self; pragma Assert (Caller.ATC_Nesting_Level > Level_No_ATC_Occurring); Uninterpreted_Data := Caller.Entry_Calls (Caller.ATC_Nesting_Level).Uninterpreted_Data; else -- Case of an aborted task Uninterpreted_Data := System.Null_Address; end if; end if; -- Self_Id.Common.Call should already be updated by the Caller. On -- return, we will start the rendezvous. STPO.Unlock (Self_Id); Initialization.Undefer_Abort (Self_Id); end Accept_Call; -------------------- -- Accept_Trivial -- -------------------- procedure Accept_Trivial (E : Task_Entry_Index) is Self_Id : constant Task_Id := STPO.Self; Caller : Task_Id := null; Open_Accepts : aliased Accept_List (1 .. 1); Entry_Call : Entry_Call_Link; begin Initialization.Defer_Abort_Nestable (Self_Id); STPO.Write_Lock (Self_Id); if not Self_Id.Callable then pragma Assert (Self_Id.Pending_ATC_Level = Level_Completed_Task); pragma Assert (Self_Id.Pending_Action); STPO.Unlock (Self_Id); Initialization.Undefer_Abort_Nestable (Self_Id); -- Should never get here ??? pragma Assert (False); raise Standard'Abort_Signal; end if; Queuing.Dequeue_Head (Self_Id.Entry_Queues (E), Entry_Call); if Entry_Call = null then -- Need to wait for entry call Open_Accepts (1).Null_Body := True; Open_Accepts (1).S := E; Self_Id.Open_Accepts := Open_Accepts'Unrestricted_Access; pragma Debug (Debug.Trace (Self_Id, "Accept_Trivial: wait", 'R')); Wait_For_Call (Self_Id); pragma Assert (Self_Id.Open_Accepts = null); -- No need to do anything special here for pending abort. -- Abort_Signal will be raised by Undefer on exit. STPO.Unlock (Self_Id); -- Found caller already waiting else pragma Assert (Entry_Call.State < Done); STPO.Unlock (Self_Id); Caller := Entry_Call.Self; STPO.Write_Lock (Caller); Initialization.Wakeup_Entry_Caller (Self_Id, Entry_Call, Done); STPO.Unlock (Caller); end if; Initialization.Undefer_Abort_Nestable (Self_Id); end Accept_Trivial; -------------------- -- Boost_Priority -- -------------------- procedure Boost_Priority (Call : Entry_Call_Link; Acceptor : Task_Id) is Caller : constant Task_Id := Call.Self; Caller_Prio : constant System.Any_Priority := Get_Priority (Caller); Acceptor_Prio : constant System.Any_Priority := Get_Priority (Acceptor); begin if Caller_Prio > Acceptor_Prio then Call.Acceptor_Prev_Priority := Acceptor_Prio; Set_Priority (Acceptor, Caller_Prio); else Call.Acceptor_Prev_Priority := Priority_Not_Boosted; end if; end Boost_Priority; ----------------- -- Call_Simple -- ----------------- procedure Call_Simple (Acceptor : Task_Id; E : Task_Entry_Index; Uninterpreted_Data : System.Address) is Rendezvous_Successful : Boolean; pragma Unreferenced (Rendezvous_Successful); begin -- If pragma Detect_Blocking is active then Program_Error must be -- raised if this potentially blocking operation is called from a -- protected action. if System.Tasking.Detect_Blocking and then STPO.Self.Common.Protected_Action_Nesting > 0 then raise Program_Error with "potentially blocking operation"; end if; Call_Synchronous (Acceptor, E, Uninterpreted_Data, Simple_Call, Rendezvous_Successful); end Call_Simple; ---------------------- -- Call_Synchronous -- ---------------------- procedure Call_Synchronous (Acceptor : Task_Id; E : Task_Entry_Index; Uninterpreted_Data : System.Address; Mode : Call_Modes; Rendezvous_Successful : out Boolean) is Self_Id : constant Task_Id := STPO.Self; Level : ATC_Level; Entry_Call : Entry_Call_Link; begin pragma Assert (Mode /= Asynchronous_Call); Local_Defer_Abort (Self_Id); Self_Id.ATC_Nesting_Level := Self_Id.ATC_Nesting_Level + 1; pragma Debug (Debug.Trace (Self_Id, "CS: entered ATC level: " & ATC_Level'Image (Self_Id.ATC_Nesting_Level), 'A')); Level := Self_Id.ATC_Nesting_Level; Entry_Call := Self_Id.Entry_Calls (Level)'Access; Entry_Call.Next := null; Entry_Call.Mode := Mode; Entry_Call.Cancellation_Attempted := False; -- If this is a call made inside of an abort deferred region, -- the call should be never abortable. Entry_Call.State := (if Self_Id.Deferral_Level > 1 then Never_Abortable else Now_Abortable); Entry_Call.E := Entry_Index (E); Entry_Call.Prio := Get_Priority (Self_Id); Entry_Call.Uninterpreted_Data := Uninterpreted_Data; Entry_Call.Called_Task := Acceptor; Entry_Call.Exception_To_Raise := Ada.Exceptions.Null_Id; Entry_Call.With_Abort := True; -- Note: the caller will undefer abort on return (see WARNING above) if not Task_Do_Or_Queue (Self_Id, Entry_Call) then STPO.Write_Lock (Self_Id); Utilities.Exit_One_ATC_Level (Self_Id); STPO.Unlock (Self_Id); Local_Undefer_Abort (Self_Id); raise Tasking_Error; end if; STPO.Write_Lock (Self_Id); pragma Debug (Debug.Trace (Self_Id, "Call_Synchronous: wait", 'R')); Entry_Calls.Wait_For_Completion (Entry_Call); pragma Debug (Debug.Trace (Self_Id, "Call_Synchronous: done waiting", 'R')); Rendezvous_Successful := Entry_Call.State = Done; STPO.Unlock (Self_Id); Local_Undefer_Abort (Self_Id); Entry_Calls.Check_Exception (Self_Id, Entry_Call); end Call_Synchronous; -------------- -- Callable -- -------------- function Callable (T : Task_Id) return Boolean is Result : Boolean; Self_Id : constant Task_Id := STPO.Self; begin Initialization.Defer_Abort_Nestable (Self_Id); STPO.Write_Lock (T); Result := T.Callable; STPO.Unlock (T); Initialization.Undefer_Abort_Nestable (Self_Id); return Result; end Callable; ---------------------------- -- Cancel_Task_Entry_Call -- ---------------------------- procedure Cancel_Task_Entry_Call (Cancelled : out Boolean) is begin Entry_Calls.Try_To_Cancel_Entry_Call (Cancelled); end Cancel_Task_Entry_Call; ------------------------- -- Complete_Rendezvous -- ------------------------- procedure Complete_Rendezvous is begin Local_Complete_Rendezvous (Ada.Exceptions.Null_Id); end Complete_Rendezvous; ------------------------------------- -- Exceptional_Complete_Rendezvous -- ------------------------------------- procedure Exceptional_Complete_Rendezvous (Ex : Ada.Exceptions.Exception_Id) is procedure Internal_Reraise; pragma No_Return (Internal_Reraise); pragma Import (C, Internal_Reraise, "__gnat_reraise"); begin Local_Complete_Rendezvous (Ex); Internal_Reraise; -- ??? Do we need to give precedence to Program_Error that might be -- raised due to failure of finalization, over Tasking_Error from -- failure of requeue? end Exceptional_Complete_Rendezvous; ------------------------------- -- Local_Complete_Rendezvous -- ------------------------------- procedure Local_Complete_Rendezvous (Ex : Ada.Exceptions.Exception_Id) is Self_Id : constant Task_Id := STPO.Self; Entry_Call : Entry_Call_Link := Self_Id.Common.Call; Caller : Task_Id; Called_PO : STPE.Protection_Entries_Access; Acceptor_Prev_Priority : Integer; Ceiling_Violation : Boolean; use type Ada.Exceptions.Exception_Id; procedure Transfer_Occurrence (Target : Ada.Exceptions.Exception_Occurrence_Access; Source : Ada.Exceptions.Exception_Occurrence); pragma Import (C, Transfer_Occurrence, "__gnat_transfer_occurrence"); begin -- The deferral level is critical here, since we want to raise an -- exception or allow abort to take place, if there is an exception or -- abort pending. pragma Debug (Debug.Trace (Self_Id, "Local_Complete_Rendezvous", 'R')); if Ex = Ada.Exceptions.Null_Id then -- The call came from normal end-of-rendezvous, so abort is not yet -- deferred. Initialization.Defer_Abort (Self_Id); elsif ZCX_By_Default then -- With ZCX, aborts are not automatically deferred in handlers Initialization.Defer_Abort (Self_Id); end if; -- We need to clean up any accepts which Self may have been serving when -- it was aborted. if Ex = Standard'Abort_Signal'Identity then while Entry_Call /= null loop Entry_Call.Exception_To_Raise := Tasking_Error'Identity; -- All forms of accept make sure that the acceptor is not -- completed, before accepting further calls, so that we -- can be sure that no further calls are made after the -- current calls are purged. Caller := Entry_Call.Self; -- Take write lock. This follows the lock precedence rule that -- Caller may be locked while holding lock of Acceptor. Complete -- the call abnormally, with exception. STPO.Write_Lock (Caller); Initialization.Wakeup_Entry_Caller (Self_Id, Entry_Call, Done); STPO.Unlock (Caller); Entry_Call := Entry_Call.Acceptor_Prev_Call; end loop; else Caller := Entry_Call.Self; if Entry_Call.Needs_Requeue then -- We dare not lock Self_Id at the same time as Caller, for fear -- of deadlock. Entry_Call.Needs_Requeue := False; Self_Id.Common.Call := Entry_Call.Acceptor_Prev_Call; if Entry_Call.Called_Task /= null then -- Requeue to another task entry if not Task_Do_Or_Queue (Self_Id, Entry_Call) then Initialization.Undefer_Abort (Self_Id); raise Tasking_Error; end if; else -- Requeue to a protected entry Called_PO := POE.To_Protection (Entry_Call.Called_PO); STPE.Lock_Entries_With_Status (Called_PO, Ceiling_Violation); if Ceiling_Violation then pragma Assert (Ex = Ada.Exceptions.Null_Id); Entry_Call.Exception_To_Raise := Program_Error'Identity; STPO.Write_Lock (Caller); Initialization.Wakeup_Entry_Caller (Self_Id, Entry_Call, Done); STPO.Unlock (Caller); else POO.PO_Do_Or_Queue (Self_Id, Called_PO, Entry_Call); POO.PO_Service_Entries (Self_Id, Called_PO); end if; end if; Entry_Calls.Reset_Priority (Self_Id, Entry_Call.Acceptor_Prev_Priority); else -- The call does not need to be requeued Self_Id.Common.Call := Entry_Call.Acceptor_Prev_Call; Entry_Call.Exception_To_Raise := Ex; STPO.Write_Lock (Caller); -- Done with Caller locked to make sure that Wakeup is not lost if Ex /= Ada.Exceptions.Null_Id then Transfer_Occurrence (Caller.Common.Compiler_Data.Current_Excep'Access, Self_Id.Common.Compiler_Data.Current_Excep); end if; Acceptor_Prev_Priority := Entry_Call.Acceptor_Prev_Priority; Initialization.Wakeup_Entry_Caller (Self_Id, Entry_Call, Done); STPO.Unlock (Caller); Entry_Calls.Reset_Priority (Self_Id, Acceptor_Prev_Priority); end if; end if; Initialization.Undefer_Abort (Self_Id); end Local_Complete_Rendezvous; ------------------------------------- -- Requeue_Protected_To_Task_Entry -- ------------------------------------- procedure Requeue_Protected_To_Task_Entry (Object : STPE.Protection_Entries_Access; Acceptor : Task_Id; E : Task_Entry_Index; With_Abort : Boolean) is Entry_Call : constant Entry_Call_Link := Object.Call_In_Progress; begin pragma Assert (STPO.Self.Deferral_Level > 0); Entry_Call.E := Entry_Index (E); Entry_Call.Called_Task := Acceptor; Entry_Call.Called_PO := Null_Address; Entry_Call.With_Abort := With_Abort; Object.Call_In_Progress := null; end Requeue_Protected_To_Task_Entry; ------------------------ -- Requeue_Task_Entry -- ------------------------ procedure Requeue_Task_Entry (Acceptor : Task_Id; E : Task_Entry_Index; With_Abort : Boolean) is Self_Id : constant Task_Id := STPO.Self; Entry_Call : constant Entry_Call_Link := Self_Id.Common.Call; begin Initialization.Defer_Abort (Self_Id); Entry_Call.Needs_Requeue := True; Entry_Call.With_Abort := With_Abort; Entry_Call.E := Entry_Index (E); Entry_Call.Called_Task := Acceptor; Initialization.Undefer_Abort (Self_Id); end Requeue_Task_Entry; -------------------- -- Selective_Wait -- -------------------- procedure Selective_Wait (Open_Accepts : Accept_List_Access; Select_Mode : Select_Modes; Uninterpreted_Data : out System.Address; Index : out Select_Index) is Self_Id : constant Task_Id := STPO.Self; Entry_Call : Entry_Call_Link; Treatment : Select_Treatment; Caller : Task_Id; Selection : Select_Index; Open_Alternative : Boolean; begin Initialization.Defer_Abort (Self_Id); STPO.Write_Lock (Self_Id); if not Self_Id.Callable then pragma Assert (Self_Id.Pending_ATC_Level = Level_Completed_Task); pragma Assert (Self_Id.Pending_Action); STPO.Unlock (Self_Id); -- ??? In some cases abort is deferred more than once. Need to -- figure out why this happens. if Self_Id.Deferral_Level > 1 then Self_Id.Deferral_Level := 1; end if; Initialization.Undefer_Abort (Self_Id); -- Should never get here ??? pragma Assert (False); raise Standard'Abort_Signal; end if; pragma Assert (Open_Accepts /= null); Uninterpreted_Data := Null_Address; Queuing.Select_Task_Entry_Call (Self_Id, Open_Accepts, Entry_Call, Selection, Open_Alternative); -- Determine the kind and disposition of the select Treatment := Default_Treatment (Select_Mode); Self_Id.Chosen_Index := No_Rendezvous; if Open_Alternative then if Entry_Call /= null then if Open_Accepts (Selection).Null_Body then Treatment := Accept_Alternative_Completed; else Setup_For_Rendezvous_With_Body (Entry_Call, Self_Id); Treatment := Accept_Alternative_Selected; end if; Self_Id.Chosen_Index := Selection; elsif Treatment = No_Alternative_Open then Treatment := Accept_Alternative_Open; end if; end if; -- Handle the select according to the disposition selected above case Treatment is when Accept_Alternative_Selected => -- Ready to rendezvous Uninterpreted_Data := Self_Id.Common.Call.Uninterpreted_Data; -- In this case the accept body is not Null_Body. Defer abort -- until it gets into the accept body. The compiler has inserted -- a call to Abort_Undefer as part of the entry expansion. pragma Assert (Self_Id.Deferral_Level = 1); Initialization.Defer_Abort_Nestable (Self_Id); STPO.Unlock (Self_Id); when Accept_Alternative_Completed => -- Accept body is null, so rendezvous is over immediately STPO.Unlock (Self_Id); Caller := Entry_Call.Self; STPO.Write_Lock (Caller); Initialization.Wakeup_Entry_Caller (Self_Id, Entry_Call, Done); STPO.Unlock (Caller); when Accept_Alternative_Open => -- Wait for caller Self_Id.Open_Accepts := Open_Accepts; pragma Debug (Debug.Trace (Self_Id, "Selective_Wait: wait", 'R')); Wait_For_Call (Self_Id); pragma Assert (Self_Id.Open_Accepts = null); -- Self_Id.Common.Call should already be updated by the Caller if -- not aborted. It might also be ready to do rendezvous even if -- this wakes up due to an abort. Therefore, if the call is not -- empty we need to do the rendezvous if the accept body is not -- Null_Body. -- Aren't the first two conditions below redundant??? if Self_Id.Chosen_Index /= No_Rendezvous and then Self_Id.Common.Call /= null and then not Open_Accepts (Self_Id.Chosen_Index).Null_Body then Uninterpreted_Data := Self_Id.Common.Call.Uninterpreted_Data; pragma Assert (Self_Id.Deferral_Level = 1 or else (Self_Id.Deferral_Level = 0 and then not Restrictions.Abort_Allowed)); Initialization.Defer_Abort_Nestable (Self_Id); -- Leave abort deferred until the accept body -- The compiler has inserted a call to Abort_Undefer as part of -- the entry expansion. end if; STPO.Unlock (Self_Id); when Else_Selected => pragma Assert (Self_Id.Open_Accepts = null); STPO.Unlock (Self_Id); when Terminate_Selected => -- Terminate alternative is open Self_Id.Open_Accepts := Open_Accepts; Self_Id.Common.State := Acceptor_Sleep; -- Notify ancestors that this task is on a terminate alternative STPO.Unlock (Self_Id); Utilities.Make_Passive (Self_Id, Task_Completed => False); STPO.Write_Lock (Self_Id); -- Wait for normal entry call or termination Wait_For_Call (Self_Id); pragma Assert (Self_Id.Open_Accepts = null); if Self_Id.Terminate_Alternative then -- An entry call should have reset this to False, so we must be -- aborted. We cannot be in an async. select, since that is not -- legal, so the abort must be of the entire task. Therefore, -- we do not need to cancel the terminate alternative. The -- cleanup will be done in Complete_Master. pragma Assert (Self_Id.Pending_ATC_Level = Level_Completed_Task); pragma Assert (Self_Id.Awake_Count = 0); STPO.Unlock (Self_Id); Index := Self_Id.Chosen_Index; Initialization.Undefer_Abort_Nestable (Self_Id); if Self_Id.Pending_Action then Initialization.Do_Pending_Action (Self_Id); end if; return; else -- Self_Id.Common.Call and Self_Id.Chosen_Index -- should already be updated by the Caller. if Self_Id.Chosen_Index /= No_Rendezvous and then not Open_Accepts (Self_Id.Chosen_Index).Null_Body then Uninterpreted_Data := Self_Id.Common.Call.Uninterpreted_Data; pragma Assert (Self_Id.Deferral_Level = 1); -- We need an extra defer here, to keep abort -- deferred until we get into the accept body -- The compiler has inserted a call to Abort_Undefer as part -- of the entry expansion. Initialization.Defer_Abort_Nestable (Self_Id); end if; end if; STPO.Unlock (Self_Id); when No_Alternative_Open => -- In this case, Index will be No_Rendezvous on return, which -- should cause a Program_Error if it is not a Delay_Mode. -- If delay alternative exists (Delay_Mode) we should suspend -- until the delay expires. Self_Id.Open_Accepts := null; if Select_Mode = Delay_Mode then Self_Id.Common.State := Delay_Sleep; loop exit when Self_Id.Pending_ATC_Level < Self_Id.ATC_Nesting_Level; Sleep (Self_Id, Delay_Sleep); end loop; Self_Id.Common.State := Runnable; STPO.Unlock (Self_Id); else STPO.Unlock (Self_Id); Initialization.Undefer_Abort (Self_Id); raise Program_Error with "entry call not a delay mode"; end if; end case; -- Caller has been chosen -- Self_Id.Common.Call should already be updated by the Caller. -- Self_Id.Chosen_Index should either be updated by the Caller -- or by Test_Selective_Wait. -- On return, we sill start rendezvous unless the accept body is -- null. In the latter case, we will have already completed the RV. Index := Self_Id.Chosen_Index; Initialization.Undefer_Abort_Nestable (Self_Id); end Selective_Wait; ------------------------------------ -- Setup_For_Rendezvous_With_Body -- ------------------------------------ procedure Setup_For_Rendezvous_With_Body (Entry_Call : Entry_Call_Link; Acceptor : Task_Id) is begin Entry_Call.Acceptor_Prev_Call := Acceptor.Common.Call; Acceptor.Common.Call := Entry_Call; if Entry_Call.State = Now_Abortable then Entry_Call.State := Was_Abortable; end if; Boost_Priority (Entry_Call, Acceptor); end Setup_For_Rendezvous_With_Body; ---------------- -- Task_Count -- ---------------- function Task_Count (E : Task_Entry_Index) return Natural is Self_Id : constant Task_Id := STPO.Self; Return_Count : Natural; begin Initialization.Defer_Abort (Self_Id); STPO.Write_Lock (Self_Id); Return_Count := Queuing.Count_Waiting (Self_Id.Entry_Queues (E)); STPO.Unlock (Self_Id); Initialization.Undefer_Abort (Self_Id); return Return_Count; end Task_Count; ---------------------- -- Task_Do_Or_Queue -- ---------------------- function Task_Do_Or_Queue (Self_ID : Task_Id; Entry_Call : Entry_Call_Link) return Boolean is E : constant Task_Entry_Index := Task_Entry_Index (Entry_Call.E); Old_State : constant Entry_Call_State := Entry_Call.State; Acceptor : constant Task_Id := Entry_Call.Called_Task; Parent : constant Task_Id := Acceptor.Common.Parent; Null_Body : Boolean; begin -- Find out whether Entry_Call can be accepted immediately -- If the Acceptor is not callable, return False. -- If the rendezvous can start, initiate it. -- If the accept-body is trivial, also complete the rendezvous. -- If the acceptor is not ready, enqueue the call. -- This should have a special case for Accept_Call and Accept_Trivial, -- so that we don't have the loop setup overhead, below. -- The call state Done is used here and elsewhere to include both the -- case of normal successful completion, and the case of an exception -- being raised. The difference is that if an exception is raised no one -- will pay attention to the fact that State = Done. Instead the -- exception will be raised in Undefer_Abort, and control will skip past -- the place where we normally would resume from an entry call. pragma Assert (not Queuing.Onqueue (Entry_Call)); -- We rely that the call is off-queue for protection, that the caller -- will not exit the Entry_Caller_Sleep, and so will not reuse the call -- record for another call. We rely on the Caller's lock for call State -- mod's. -- If Acceptor.Terminate_Alternative is True, we need to lock Parent and -- Acceptor, in that order; otherwise, we only need a lock on Acceptor. -- However, we can't check Acceptor.Terminate_Alternative until Acceptor -- is locked. Therefore, we need to lock both. Attempts to avoid locking -- Parent tend to result in race conditions. It would work to unlock -- Parent immediately upon finding Acceptor.Terminate_Alternative to be -- False, but that violates the rule of properly nested locking (see -- System.Tasking). STPO.Write_Lock (Parent); STPO.Write_Lock (Acceptor); -- If the acceptor is not callable, abort the call and return False if not Acceptor.Callable then STPO.Unlock (Acceptor); STPO.Unlock (Parent); pragma Assert (Entry_Call.State < Done); -- In case we are not the caller, set up the caller -- to raise Tasking_Error when it wakes up. STPO.Write_Lock (Entry_Call.Self); Entry_Call.Exception_To_Raise := Tasking_Error'Identity; Initialization.Wakeup_Entry_Caller (Self_ID, Entry_Call, Done); STPO.Unlock (Entry_Call.Self); return False; end if; -- Try to serve the call immediately if Acceptor.Open_Accepts /= null then for J in Acceptor.Open_Accepts'Range loop if Entry_Call.E = Entry_Index (Acceptor.Open_Accepts (J).S) then -- Commit acceptor to rendezvous with us Acceptor.Chosen_Index := J; Null_Body := Acceptor.Open_Accepts (J).Null_Body; Acceptor.Open_Accepts := null; -- Prevent abort while call is being served if Entry_Call.State = Now_Abortable then Entry_Call.State := Was_Abortable; end if; if Acceptor.Terminate_Alternative then -- Cancel terminate alternative. See matching code in -- Selective_Wait and Vulnerable_Complete_Master. Acceptor.Terminate_Alternative := False; Acceptor.Awake_Count := Acceptor.Awake_Count + 1; if Acceptor.Awake_Count = 1 then -- Notify parent that acceptor is awake pragma Assert (Parent.Awake_Count > 0); Parent.Awake_Count := Parent.Awake_Count + 1; if Parent.Common.State = Master_Completion_Sleep and then Acceptor.Master_Of_Task = Parent.Master_Within then Parent.Common.Wait_Count := Parent.Common.Wait_Count + 1; end if; end if; end if; if Null_Body then -- Rendezvous is over immediately STPO.Wakeup (Acceptor, Acceptor_Sleep); STPO.Unlock (Acceptor); STPO.Unlock (Parent); STPO.Write_Lock (Entry_Call.Self); Initialization.Wakeup_Entry_Caller (Self_ID, Entry_Call, Done); STPO.Unlock (Entry_Call.Self); else Setup_For_Rendezvous_With_Body (Entry_Call, Acceptor); -- For terminate_alternative, acceptor may not be asleep -- yet, so we skip the wakeup if Acceptor.Common.State /= Runnable then STPO.Wakeup (Acceptor, Acceptor_Sleep); end if; STPO.Unlock (Acceptor); STPO.Unlock (Parent); end if; return True; end if; end loop; -- The acceptor is accepting, but not this entry end if; -- If the acceptor was ready to accept this call, -- we would not have gotten this far, so now we should -- (re)enqueue the call, if the mode permits that. -- If the call is timed, it may have timed out before the requeue, -- in the unusual case where the current accept has taken longer than -- the given delay. In that case the requeue is cancelled, and the -- outer timed call will be aborted. if Entry_Call.Mode = Conditional_Call or else (Entry_Call.Mode = Timed_Call and then Entry_Call.With_Abort and then Entry_Call.Cancellation_Attempted) then STPO.Unlock (Acceptor); STPO.Unlock (Parent); STPO.Write_Lock (Entry_Call.Self); pragma Assert (Entry_Call.State >= Was_Abortable); Initialization.Wakeup_Entry_Caller (Self_ID, Entry_Call, Cancelled); STPO.Unlock (Entry_Call.Self); else -- Timed_Call, Simple_Call, or Asynchronous_Call Queuing.Enqueue (Acceptor.Entry_Queues (E), Entry_Call); -- Update abortability of call pragma Assert (Old_State < Done); Entry_Call.State := New_State (Entry_Call.With_Abort, Entry_Call.State); STPO.Unlock (Acceptor); STPO.Unlock (Parent); if Old_State /= Entry_Call.State and then Entry_Call.State = Now_Abortable and then Entry_Call.Mode /= Simple_Call and then Entry_Call.Self /= Self_ID -- Asynchronous_Call or Conditional_Call then -- Because of ATCB lock ordering rule STPO.Write_Lock (Entry_Call.Self); if Entry_Call.Self.Common.State = Async_Select_Sleep then -- Caller may not yet have reached wait-point STPO.Wakeup (Entry_Call.Self, Async_Select_Sleep); end if; STPO.Unlock (Entry_Call.Self); end if; end if; return True; end Task_Do_Or_Queue; --------------------- -- Task_Entry_Call -- --------------------- procedure Task_Entry_Call (Acceptor : Task_Id; E : Task_Entry_Index; Uninterpreted_Data : System.Address; Mode : Call_Modes; Rendezvous_Successful : out Boolean) is Self_Id : constant Task_Id := STPO.Self; Entry_Call : Entry_Call_Link; begin -- If pragma Detect_Blocking is active then Program_Error must be -- raised if this potentially blocking operation is called from a -- protected action. if System.Tasking.Detect_Blocking and then Self_Id.Common.Protected_Action_Nesting > 0 then raise Program_Error with "potentially blocking operation"; end if; if Mode = Simple_Call or else Mode = Conditional_Call then Call_Synchronous (Acceptor, E, Uninterpreted_Data, Mode, Rendezvous_Successful); else -- This is an asynchronous call -- Abort must already be deferred by the compiler-generated code. -- Without this, an abort that occurs between the time that this -- call is made and the time that the abortable part's cleanup -- handler is set up might miss the cleanup handler and leave the -- call pending. Self_Id.ATC_Nesting_Level := Self_Id.ATC_Nesting_Level + 1; pragma Debug (Debug.Trace (Self_Id, "TEC: entered ATC level: " & ATC_Level'Image (Self_Id.ATC_Nesting_Level), 'A')); Entry_Call := Self_Id.Entry_Calls (Self_Id.ATC_Nesting_Level)'Access; Entry_Call.Next := null; Entry_Call.Mode := Mode; Entry_Call.Cancellation_Attempted := False; Entry_Call.State := Not_Yet_Abortable; Entry_Call.E := Entry_Index (E); Entry_Call.Prio := Get_Priority (Self_Id); Entry_Call.Uninterpreted_Data := Uninterpreted_Data; Entry_Call.Called_Task := Acceptor; Entry_Call.Called_PO := Null_Address; Entry_Call.Exception_To_Raise := Ada.Exceptions.Null_Id; Entry_Call.With_Abort := True; if not Task_Do_Or_Queue (Self_Id, Entry_Call) then STPO.Write_Lock (Self_Id); Utilities.Exit_One_ATC_Level (Self_Id); STPO.Unlock (Self_Id); Initialization.Undefer_Abort (Self_Id); raise Tasking_Error; end if; -- The following is special for async. entry calls. If the call was -- not queued abortably, we need to wait until it is before -- proceeding with the abortable part. -- Wait_Until_Abortable can be called unconditionally here, but it is -- expensive. if Entry_Call.State < Was_Abortable then Entry_Calls.Wait_Until_Abortable (Self_Id, Entry_Call); end if; -- Note: following assignment needs to be atomic Rendezvous_Successful := Entry_Call.State = Done; end if; end Task_Entry_Call; ----------------------- -- Task_Entry_Caller -- ----------------------- function Task_Entry_Caller (D : Task_Entry_Nesting_Depth) return Task_Id is Self_Id : constant Task_Id := STPO.Self; Entry_Call : Entry_Call_Link; begin Entry_Call := Self_Id.Common.Call; for Depth in 1 .. D loop Entry_Call := Entry_Call.Acceptor_Prev_Call; pragma Assert (Entry_Call /= null); end loop; return Entry_Call.Self; end Task_Entry_Caller; -------------------------- -- Timed_Selective_Wait -- -------------------------- procedure Timed_Selective_Wait (Open_Accepts : Accept_List_Access; Select_Mode : Select_Modes; Uninterpreted_Data : out System.Address; Timeout : Duration; Mode : Delay_Modes; Index : out Select_Index) is Self_Id : constant Task_Id := STPO.Self; Treatment : Select_Treatment; Entry_Call : Entry_Call_Link; Caller : Task_Id; Selection : Select_Index; Open_Alternative : Boolean; Timedout : Boolean := False; Yielded : Boolean := True; begin pragma Assert (Select_Mode = Delay_Mode); Initialization.Defer_Abort (Self_Id); -- If we are aborted here, the effect will be pending STPO.Write_Lock (Self_Id); if not Self_Id.Callable then pragma Assert (Self_Id.Pending_ATC_Level = Level_Completed_Task); pragma Assert (Self_Id.Pending_Action); STPO.Unlock (Self_Id); Initialization.Undefer_Abort (Self_Id); -- Should never get here ??? pragma Assert (False); raise Standard'Abort_Signal; end if; Uninterpreted_Data := Null_Address; pragma Assert (Open_Accepts /= null); Queuing.Select_Task_Entry_Call (Self_Id, Open_Accepts, Entry_Call, Selection, Open_Alternative); -- Determine the kind and disposition of the select Treatment := Default_Treatment (Select_Mode); Self_Id.Chosen_Index := No_Rendezvous; if Open_Alternative then if Entry_Call /= null then if Open_Accepts (Selection).Null_Body then Treatment := Accept_Alternative_Completed; else Setup_For_Rendezvous_With_Body (Entry_Call, Self_Id); Treatment := Accept_Alternative_Selected; end if; Self_Id.Chosen_Index := Selection; elsif Treatment = No_Alternative_Open then Treatment := Accept_Alternative_Open; end if; end if; -- Handle the select according to the disposition selected above case Treatment is when Accept_Alternative_Selected => -- Ready to rendezvous. In this case the accept body is not -- Null_Body. Defer abort until it gets into the accept body. Uninterpreted_Data := Self_Id.Common.Call.Uninterpreted_Data; Initialization.Defer_Abort_Nestable (Self_Id); STPO.Unlock (Self_Id); when Accept_Alternative_Completed => -- Rendezvous is over STPO.Unlock (Self_Id); Caller := Entry_Call.Self; STPO.Write_Lock (Caller); Initialization.Wakeup_Entry_Caller (Self_Id, Entry_Call, Done); STPO.Unlock (Caller); when Accept_Alternative_Open => -- Wait for caller Self_Id.Open_Accepts := Open_Accepts; -- Wait for a normal call and a pending action until the -- Wakeup_Time is reached. Self_Id.Common.State := Acceptor_Delay_Sleep; -- Try to remove calls to Sleep in the loop below by letting the -- caller a chance of getting ready immediately, using Unlock -- Yield. See similar action in Wait_For_Completion/Wait_For_Call. Unlock (Self_Id); if Self_Id.Open_Accepts /= null then Yield; end if; Write_Lock (Self_Id); -- Check if this task has been aborted while the lock was released if Self_Id.Pending_ATC_Level < Self_Id.ATC_Nesting_Level then Self_Id.Open_Accepts := null; end if; loop exit when Self_Id.Open_Accepts = null; if Timedout then Sleep (Self_Id, Acceptor_Delay_Sleep); else STPO.Timed_Sleep (Self_Id, Timeout, Mode, Acceptor_Delay_Sleep, Timedout, Yielded); end if; if Timedout then Self_Id.Open_Accepts := null; end if; end loop; Self_Id.Common.State := Runnable; -- Self_Id.Common.Call should already be updated by the Caller if -- not aborted. It might also be ready to do rendezvous even if -- this wakes up due to an abort. Therefore, if the call is not -- empty we need to do the rendezvous if the accept body is not -- Null_Body. if Self_Id.Chosen_Index /= No_Rendezvous and then Self_Id.Common.Call /= null and then not Open_Accepts (Self_Id.Chosen_Index).Null_Body then Uninterpreted_Data := Self_Id.Common.Call.Uninterpreted_Data; pragma Assert (Self_Id.Deferral_Level = 1); Initialization.Defer_Abort_Nestable (Self_Id); -- Leave abort deferred until the accept body end if; STPO.Unlock (Self_Id); when No_Alternative_Open => -- In this case, Index will be No_Rendezvous on return. We sleep -- for the time we need to. -- Wait for a signal or timeout. A wakeup can be made -- for several reasons: -- 1) Delay is expired -- 2) Pending_Action needs to be checked -- (Abort, Priority change) -- 3) Spurious wakeup Self_Id.Open_Accepts := null; Self_Id.Common.State := Acceptor_Delay_Sleep; STPO.Timed_Sleep (Self_Id, Timeout, Mode, Acceptor_Delay_Sleep, Timedout, Yielded); Self_Id.Common.State := Runnable; STPO.Unlock (Self_Id); when others => -- Should never get here pragma Assert (False); null; end case; if not Yielded then Yield; end if; -- Caller has been chosen -- Self_Id.Common.Call should already be updated by the Caller -- Self_Id.Chosen_Index should either be updated by the Caller -- or by Test_Selective_Wait Index := Self_Id.Chosen_Index; Initialization.Undefer_Abort_Nestable (Self_Id); -- Start rendezvous, if not already completed end Timed_Selective_Wait; --------------------------- -- Timed_Task_Entry_Call -- --------------------------- procedure Timed_Task_Entry_Call (Acceptor : Task_Id; E : Task_Entry_Index; Uninterpreted_Data : System.Address; Timeout : Duration; Mode : Delay_Modes; Rendezvous_Successful : out Boolean) is Self_Id : constant Task_Id := STPO.Self; Level : ATC_Level; Entry_Call : Entry_Call_Link; Yielded : Boolean; pragma Unreferenced (Yielded); begin -- If pragma Detect_Blocking is active then Program_Error must be -- raised if this potentially blocking operation is called from a -- protected action. if System.Tasking.Detect_Blocking and then Self_Id.Common.Protected_Action_Nesting > 0 then raise Program_Error with "potentially blocking operation"; end if; Initialization.Defer_Abort (Self_Id); Self_Id.ATC_Nesting_Level := Self_Id.ATC_Nesting_Level + 1; pragma Debug (Debug.Trace (Self_Id, "TTEC: entered ATC level: " & ATC_Level'Image (Self_Id.ATC_Nesting_Level), 'A')); Level := Self_Id.ATC_Nesting_Level; Entry_Call := Self_Id.Entry_Calls (Level)'Access; Entry_Call.Next := null; Entry_Call.Mode := Timed_Call; Entry_Call.Cancellation_Attempted := False; -- If this is a call made inside of an abort deferred region, -- the call should be never abortable. Entry_Call.State := (if Self_Id.Deferral_Level > 1 then Never_Abortable else Now_Abortable); Entry_Call.E := Entry_Index (E); Entry_Call.Prio := Get_Priority (Self_Id); Entry_Call.Uninterpreted_Data := Uninterpreted_Data; Entry_Call.Called_Task := Acceptor; Entry_Call.Called_PO := Null_Address; Entry_Call.Exception_To_Raise := Ada.Exceptions.Null_Id; Entry_Call.With_Abort := True; -- Note: the caller will undefer abort on return (see WARNING above) if not Task_Do_Or_Queue (Self_Id, Entry_Call) then STPO.Write_Lock (Self_Id); Utilities.Exit_One_ATC_Level (Self_Id); STPO.Unlock (Self_Id); Initialization.Undefer_Abort (Self_Id); raise Tasking_Error; end if; Write_Lock (Self_Id); Entry_Calls.Wait_For_Completion_With_Timeout (Entry_Call, Timeout, Mode, Yielded); Unlock (Self_Id); -- ??? Do we need to yield in case Yielded is False Rendezvous_Successful := Entry_Call.State = Done; Initialization.Undefer_Abort (Self_Id); Entry_Calls.Check_Exception (Self_Id, Entry_Call); end Timed_Task_Entry_Call; ------------------- -- Wait_For_Call -- ------------------- procedure Wait_For_Call (Self_Id : Task_Id) is begin Self_Id.Common.State := Acceptor_Sleep; -- Try to remove calls to Sleep in the loop below by letting the caller -- a chance of getting ready immediately, using Unlock & Yield. -- See similar action in Wait_For_Completion & Timed_Selective_Wait. Unlock (Self_Id); if Self_Id.Open_Accepts /= null then Yield; end if; Write_Lock (Self_Id); -- Check if this task has been aborted while the lock was released if Self_Id.Pending_ATC_Level < Self_Id.ATC_Nesting_Level then Self_Id.Open_Accepts := null; end if; loop exit when Self_Id.Open_Accepts = null; Sleep (Self_Id, Acceptor_Sleep); end loop; Self_Id.Common.State := Runnable; end Wait_For_Call; end System.Tasking.Rendezvous;
------------------------------------------------------------------------------ -- -- -- GNAT LIBRARY COMPONENTS -- -- -- -- A D A . C O N T A I N E R S . B O U N D E D _ H O L D E R S -- -- -- -- S p e c -- -- -- -- Copyright (C) 2015-2019, Free Software Foundation, Inc. -- -- -- -- This specification is derived from the Ada Reference Manual for use with -- -- GNAT. The copyright notice above, and the license provisions that follow -- -- apply solely to the contents of the part following the private keyword. -- -- -- -- GNAT is free software; you can redistribute it and/or modify it under -- -- terms of the GNU General Public License as published by the Free Soft- -- -- ware Foundation; either version 3, or (at your option) any later ver- -- -- sion. GNAT is distributed in the hope that it will be useful, but WITH- -- -- OUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY -- -- or FITNESS FOR A PARTICULAR PURPOSE. -- -- -- -- As a special exception under Section 7 of GPL version 3, you are granted -- -- additional permissions described in the GCC Runtime Library Exception, -- -- version 3.1, as published by the Free Software Foundation. -- -- -- -- You should have received a copy of the GNU General Public License and -- -- a copy of the GCC Runtime Library Exception along with this program; -- -- see the files COPYING3 and COPYING.RUNTIME respectively. If not, see -- -- <http://www.gnu.org/licenses/>. -- ------------------------------------------------------------------------------ private with System; generic type Element_Type (<>) is private; Max_Size_In_Storage_Elements : Natural := Element_Type'Max_Size_In_Storage_Elements; with function "=" (Left, Right : Element_Type) return Boolean is <>; package Ada.Containers.Bounded_Holders is pragma Annotate (CodePeer, Skip_Analysis); -- This package is patterned after Ada.Containers.Indefinite_Holders. It is -- used to treat indefinite subtypes as definite, but without using heap -- allocation. For example, you might like to say: -- -- type A is array (...) of T'Class; -- illegal -- -- Instead, you can instantiate this package with Element_Type => T'Class, -- and say: -- -- type A is array (...) of Holder; -- -- Each object of type Holder is allocated Max_Size_In_Storage_Elements -- bytes. If you try to create a holder from an object of type Element_Type -- that is too big, an exception is raised (assuming assertions are -- enabled). This applies to To_Holder and Set. If you pass an Element_Type -- object that is smaller than Max_Size_In_Storage_Elements, it works fine, -- but some space is wasted. -- -- NOTE: If assertions are disabled, and you try to use an Element that is -- too big, execution is erroneous, and anything can happen, such as -- overwriting arbitrary memory locations. -- -- Element_Type must not be an unconstrained array type. It can be a -- class-wide type or a type with non-defaulted discriminants. -- -- The 'Size of each Element_Type object must be a multiple of -- System.Storage_Unit; e.g. creating Holders from 5-bit objects won't -- work. type Holder is private; function "=" (Left, Right : Holder) return Boolean; function To_Holder (New_Item : Element_Type) return Holder; function "+" (New_Item : Element_Type) return Holder renames To_Holder; function Get (Container : Holder) return Element_Type; procedure Set (Container : in out Holder; New_Item : Element_Type); private -- The implementation uses low-level tricks (Address clauses and unchecked -- conversions of access types) to treat the elements as storage arrays. pragma Assert (Element_Type'Alignment <= Standard'Maximum_Alignment); -- This prevents elements with a user-specified Alignment that is too big type Storage_Element is mod 2 ** System.Storage_Unit; type Storage_Array is array (Positive range <>) of Storage_Element; type Holder is record Data : Storage_Array (1 .. Max_Size_In_Storage_Elements); end record with Alignment => Standard'Maximum_Alignment; -- We would like to say "Alignment => Element_Type'Alignment", but that -- is illegal because it's not static, so we use the maximum possible -- (default) alignment instead. type Element_Access is access all Element_Type; pragma Assert (Element_Access'Size = Standard'Address_Size, "cannot instantiate with an array type"); -- If Element_Access is a fat pointer, Element_Type must be an -- unconstrained array, which is not allowed. Arrays won't work, because -- the 'Address of an array points to the first element, thus losing the -- bounds. pragma No_Strict_Aliasing (Element_Access); -- Needed because we are unchecked-converting from Address to -- Element_Access (see package body), which is a violation of the -- normal aliasing rules enforced by gcc. end Ada.Containers.Bounded_Holders;
with Interfaces; use Interfaces; with STM32GD.Board; use STM32GD.Board; with STM32_SVD; use STM32_SVD; with Host_Message; package body Modem is RX_Address : constant Radio.Address_Type := (16#00#, 16#F0#, 16#F0#, 16#F0#, 16#F0#); Channel : constant Radio.Channel_Type := 70; Packet: Radio.Packet_Type (1 .. 32); Host_Packet : Host_Message.Packet_Type (1 .. 32); Packet_Length : Natural; Now : RTC.Date_Time_Type; Wait_Time : RTC.Second_Delta_Type := 30; procedure Print_Registers is new Radio.Print_Registers (Put_Line => Text_IO.Put_Line); function Init return Boolean is begin STM32GD.Board.Init; Host_Message.Send_Hello; Radio.Init; Radio.Set_Channel (Channel); Radio.Set_RX_Address (RX_Address); if Radio.Get_Channel = Channel then IRQ.Configure_Trigger (Falling => True); STM32GD.Clear_Event; return True; else return False; end if; end Init; procedure Run is begin Radio.RX_Mode; RTC.Read (Now); RTC.Add_Seconds (Now, Wait_Time); RTC.Set_Alarm (Now); loop STM32GD.Wait_For_Event; if Radio.RX_Available then LED.Set; Radio.Clear_IRQ; Radio.RX (Packet, Packet_Length); for I in 1 .. Packet_Length loop Host_Packet (I) := Unsigned_8 (Packet (I)); end loop; Host_Message.Send_Packet (Host_Packet, Packet_Length); LED.Clear; end if; if RTC.Alarm_Triggered then RTC.Clear_Alarm; Host_Message.Send_Heartbeat; RTC.Read (Now); RTC.Add_Seconds (Now, Wait_Time); RTC.Set_Alarm (Now); end if; end loop; end Run; procedure Error is begin loop RTC.Read (Now); RTC.Add_Seconds (Now, Wait_Time); RTC.Set_Alarm (Now); STM32GD.Wait_For_Event; if RTC.Alarm_Triggered then RTC.Clear_Alarm; Host_Message.Send_Error_Message ("Modem init failed"); end if; end loop; end Error; end Modem;
with Simple_Logging; use Simple_Logging; with GNAT.OS_Lib; use GNAT.OS_Lib; with CLIC.User_Input; with CLIC.TTY; with FSmaker.Commands.Init; with FSmaker.Commands.Mkdir; with FSmaker.Commands.Tree; with FSmaker.Commands.Import; with FSmaker.Commands.Cat; with FSmaker.Commands.Hexdump; with FSmaker.Commands.Export; with FSmaker.Commands.Build; with FSmaker.Target.LittleFS; package body FSmaker.Commands is subtype Dispatch is Command'Class; No_Color : aliased Boolean := False; -- Force-disable color output No_TTY : aliased Boolean := False; -- Used to disable control characters in output ------------------------- -- Set_Global_Switches -- ------------------------- procedure Set_Global_Switches (Config : in out CLIC.Subcommand.Switches_Configuration) is use CLIC.Subcommand; begin Define_Switch (Config, Sw_Format'Access, "-f=", "--format=", "Filesystem format (only 'littlefs' so far)"); Define_Switch (Config, Sw_Image'Access, "-i=", "--img=", "Path to the image file to create/modify"); Define_Switch (Config, "-h", "--help", "Display general or command-specific help"); Define_Switch (Config, Sw_Verbose'Access, "-v", Help => "Be more verbose (use twice for extra detail)"); Define_Switch (Config, Sw_Debug'Access, "-d", Long_Switch => "--debug", Help => "Enable debug-specific log messages"); Define_Switch (Config, CLIC.User_Input.Not_Interactive'Access, "-n", "--non-interactive", "Assume default answers for all user prompts"); Define_Switch (Config, No_Color'Access, Long_Switch => "--no-color", Help => "Disables colors in output"); Define_Switch (Config, No_TTY'Access, Long_Switch => "--no-tty", Help => "Disables control characters in output"); end Set_Global_Switches; ------------- -- Execute -- ------------- procedure Execute is begin Sub_Cmd.Parse_Global_Switches; if No_TTY then CLIC.TTY.Force_Disable_TTY; end if; if not No_Color and then not No_TTY then CLIC.TTY.Enable_Color (Force => False); -- This may still not enable color if TTY is detected to be incapable end if; Sub_Cmd.Execute; end Execute; --------------- -- Put_Error -- --------------- procedure Put_Error (Str : String) is begin Simple_Logging.Error (Str); end Put_Error; ----------------- -- Setup_Image -- ----------------- procedure Setup_Image (This : in out Command; To_Format : Boolean := False) is use CLIC.User_Input; begin if Sw_Format = null or else Sw_Format.all = "" then This.Usage_Error ("Missing required -f/--format switch"); elsif Sw_Format.all /= "littlefs" then This.Usage_Error ("Invalid format (-f/--format) must be 'littlefs'"); end if; if Sw_Image = null then This.Usage_Error ("Missing required -i/--img switch"); end if; if To_Format then if not GNAT.OS_Lib.Is_Regular_File (Image_Path) then -- The file doesn't exists, we try to create it This.FD := Create_File (Image_Path, Binary); if This.FD = Invalid_FD then This.Failure ("Cannot create file '" & Image_Path & "'"); else -- Create_File opens in read-only mode, so we close and re-open -- in read-write mode. This.Close_Image; This.FD := Open_Read_Write (Image_Path, Binary); end if; elsif not GNAT.OS_Lib.Is_Owner_Writable_File (Image_Path) then This.Failure ("Image file '" & Image_Path & "' is not writable"); else Always ("Existing image file '" & Image_Path & "' will be overwritten."); if Query ("Do you want to continue?", Valid => (Yes | No => True, Always => False), Default => Yes) = Yes then This.FD := Open_Read_Write (Image_Path, Binary); else This.Failure ("Cannot overwrite existing file"); end if; end if; else -- The image file should exists and be writable if not GNAT.OS_Lib.Is_Regular_File (Image_Path) then This.Failure ("Image file '" & Image_Path & "' does not exists"); elsif not GNAT.OS_Lib.Is_Owner_Writable_File (Image_Path) then This.Failure ("Image file '" & Image_Path & "' is not writable"); else This.FD := Open_Read_Write (Image_Path, Binary); end if; end if; if This.FD = Invalid_FD then This.Failure ("Cannot open image file '" & Image_Path & "'"); end if; This.Target := new FSmaker.Target.LittleFS.Instance; if not To_Format then This.Target.Mount (This.FD); end if; end Setup_Image; ----------------- -- Close_Image -- ----------------- procedure Close_Image (This : in out Command) is begin if This.FD /= Invalid_FD and then This.FD /= Null_FD then Simple_Logging.Debug ("Closing FD"); Close (This.FD); This.FD := Invalid_FD; end if; end Close_Image; ------------- -- Success -- ------------- procedure Success (This : in out Command) is begin Always (Dispatch (This).Name & " success"); This.Close_Image; end Success; ------------- -- Failure -- ------------- procedure Failure (This : in out Command; Msg : String) is begin Error (Dispatch (This).Name & " failed: " & Msg); This.Close_Image; GNAT.OS_Lib.OS_Exit (1); end Failure; ----------------- -- Usage_Error -- ----------------- procedure Usage_Error (This : in out Command; Msg : String) is begin Error (Dispatch (This).Name & ": " & Msg); This.Close_Image; Sub_Cmd.Display_Usage; GNAT.OS_Lib.OS_Exit (1); end Usage_Error; begin Sub_Cmd.Register (new Sub_Cmd.Builtin_Help); Sub_Cmd.Register (new FSmaker.Commands.Init.Instance); Sub_Cmd.Register (new FSmaker.Commands.Mkdir.Instance); Sub_Cmd.Register (new FSmaker.Commands.Tree.Instance); Sub_Cmd.Register (new FSmaker.Commands.Import.Instance); Sub_Cmd.Register (new FSmaker.Commands.Cat.Instance); Sub_Cmd.Register (new FSmaker.Commands.Hexdump.Instance); Sub_Cmd.Register (new FSmaker.Commands.Export.Instance); Sub_Cmd.Register (new FSmaker.Commands.Build.Instance); end FSmaker.Commands;
--////////////////////////////////////////////////////////// -- SFML - Simple and Fast Multimedia Library -- Copyright (C) 2007-2018 Laurent Gomila (laurent@sfml-dev.org) -- This software is provided 'as-is', without any express or implied warranty. -- In no event will the authors be held liable for any damages arising from the use of this software. -- Permission is granted to anyone to use this software for any purpose, -- including commercial applications, and to alter it and redistribute it freely, -- subject to the following restrictions: -- 1. The origin of this software must not be misrepresented; -- you must not claim that you wrote the original software. -- If you use this software in a product, an acknowledgment -- in the product documentation would be appreciated but is not required. -- 2. Altered source versions must be plainly marked as such, -- and must not be misrepresented as being the original software. -- 3. This notice may not be removed or altered from any source distribution. --////////////////////////////////////////////////////////// --////////////////////////////////////////////////////////// with Sf.System.Vector2; package Sf.Window.Cursor is --////////////////////////////////////////////////////////// --////////////////////////////////////////////////////////// --////////////////////////////////////////////////////////// --////////////////////////////////////////////////////////// --////////////////////////////////////////////////////////// --/ @brief Enumeration of the native system cursor types --/ --/ Refer to the following table to determine which cursor --/ is available on which platform. --/ --/ Type | Linux | Mac OS X | Windows --/ ------------------------------------|:-----:|:--------:|:--------: --/ sfCursorArrow | yes | yes | yes --/ sfCursorArrowWait | no | no | yes --/ sfCursorWait | yes | no | yes --/ sfCursorText | yes | yes | yes --/ sfCursorHand | yes | yes | yes --/ sfCursorSizeHorizontal | yes | yes | yes --/ sfCursorSizeVertical | yes | yes | yes --/ sfCursorSizeTopLeftBottomRight | no | no | yes --/ sfCursorSizeBottomLeftTopRight | no | no | yes --/ sfCursorSizeAll | yes | no | yes --/ sfCursorCross | yes | yes | yes --/ sfCursorHelp | yes | no | yes --/ sfCursorNotAllowed | yes | yes | yes --/ --////////////////////////////////////////////////////////// --/< Arrow cursor (default) --/< Busy arrow cursor --/< Busy cursor --/< I-beam, cursor when hovering over a field allowing text entry --/< Pointing hand cursor --/< Horizontal double arrow cursor --/< Vertical double arrow cursor --/< Double arrow cursor going from top-left to bottom-right --/< Double arrow cursor going from bottom-left to top-right --/< Combination of SizeHorizontal and SizeVertical --/< Crosshair cursor --/< Help cursor --/< Action not allowed cursor type sfCursorType is (sfCursorArrow, sfCursorArrowWait, sfCursorWait, sfCursorText, sfCursorHand, sfCursorSizeHorizontal, sfCursorSizeVertical, sfCursorSizeTopLeftBottomRight, sfCursorSizeBottomLeftTopRight, sfCursorSizeAll, sfCursorCross, sfCursorHelp, sfCursorNotAllowed); --////////////////////////////////////////////////////////// --/ @brief Create a cursor with the provided image --/ --/ @a pixels must be an array of @a width by @a height pixels --/ in 32-bit RGBA format. If not, this will cause undefined behavior. --/ --/ If @a pixels is null or either @a width or @a height are 0, --/ the current cursor is left unchanged and the function will --/ return false. --/ --/ In addition to specifying the pixel data, you can also --/ specify the location of the hotspot of the cursor. The --/ hotspot is the pixel coordinate within the cursor image --/ which will be located exactly where the mouse pointer --/ position is. Any mouse actions that are performed will --/ return the window/screen location of the hotspot. --/ --/ @warning On Unix, the pixels are mapped into a monochrome --/ bitmap: pixels with an alpha channel to 0 are --/ transparent, black if the RGB channel are close --/ to zero, and white otherwise. --/ --/ @param pixels Array of pixels of the image --/ @param size Width and height of the image --/ @param hotspot (x,y) location of the hotspot --/ @return A new sfCursor object --/ --////////////////////////////////////////////////////////// function createFromPixels (pixels : access sfUint8; size : Sf.System.Vector2.sfVector2u; hotspot : Sf.System.Vector2.sfVector2u) return sfCursor_Ptr; --////////////////////////////////////////////////////////// --/ @brief Create a native system cursor --/ --/ Refer to the list of cursor available on each system --/ (see sfCursorType) to know whether a given cursor is --/ expected to load successfully or is not supported by --/ the operating system. --/ --/ @param cursorType Native system cursor type --/ @return A new sfCursor object --/ --////////////////////////////////////////////////////////// function createFromSystem (cursorType : sfCursorType) return sfCursor_Ptr; --////////////////////////////////////////////////////////// --/ @brief Destroy a cursor --/ --/ @param cursor Cursor to destroy --/ --////////////////////////////////////////////////////////// procedure destroy (cursor : sfCursor_Ptr); private pragma Convention (C, sfCursorType); pragma Import (C, createFromPixels, "sfCursor_createFromPixels"); pragma Import (C, createFromSystem, "sfCursor_createFromSystem"); pragma Import (C, destroy, "sfCursor_destroy"); end Sf.Window.Cursor;
-- -- Copyright (C) 2020, AdaCore -- -- This spec has been automatically generated from STM32F401.svd -- This is a version for the STM32F401 MCU package Ada.Interrupts.Names is -- All identifiers in this unit are implementation defined pragma Implementation_Defined; ---------------- -- Interrupts -- ---------------- -- System tick Sys_Tick_Interrupt : constant Interrupt_ID := -1; -- PVD through EXTI line detection interrupt PVD_Interrupt : constant Interrupt_ID := 1; -- Tamper and TimeStamp interrupts through the EXTI line TAMP_STAMP_Interrupt : constant Interrupt_ID := 2; -- RTC Wakeup interrupt through the EXTI line RTC_WKUP_Interrupt : constant Interrupt_ID := 3; -- FLASH global interrupt FLASH_Interrupt : constant Interrupt_ID := 4; -- RCC global interrupt RCC_Interrupt : constant Interrupt_ID := 5; -- EXTI Line0 interrupt EXTI0_Interrupt : constant Interrupt_ID := 6; -- EXTI Line1 interrupt EXTI1_Interrupt : constant Interrupt_ID := 7; -- EXTI Line2 interrupt EXTI2_Interrupt : constant Interrupt_ID := 8; -- EXTI Line3 interrupt EXTI3_Interrupt : constant Interrupt_ID := 9; -- EXTI Line4 interrupt EXTI4_Interrupt : constant Interrupt_ID := 10; -- ADC1 global interrupt ADC_Interrupt : constant Interrupt_ID := 18; -- EXTI Line[9:5] interrupts EXTI9_5_Interrupt : constant Interrupt_ID := 23; -- TIM1 Break interrupt and TIM9 global interrupt TIM1_BRK_TIM9_Interrupt : constant Interrupt_ID := 24; -- TIM1 Update interrupt and TIM10 global interrupt TIM1_UP_TIM10_Interrupt : constant Interrupt_ID := 25; -- TIM1 Trigger and Commutation interrupts and TIM11 global interrupt TIM1_TRG_COM_TIM11_Interrupt : constant Interrupt_ID := 26; -- TIM1 Capture Compare interrupt TIM1_CC_Interrupt : constant Interrupt_ID := 27; -- TIM2 global interrupt TIM2_Interrupt : constant Interrupt_ID := 28; -- TIM3 global interrupt TIM3_Interrupt : constant Interrupt_ID := 29; -- I2C1 event interrupt I2C1_EV_Interrupt : constant Interrupt_ID := 31; -- I2C1 error interrupt I2C1_ER_Interrupt : constant Interrupt_ID := 32; -- I2C2 event interrupt I2C2_EV_Interrupt : constant Interrupt_ID := 33; -- I2C2 error interrupt I2C2_ER_Interrupt : constant Interrupt_ID := 34; -- SPI1 global interrupt SPI1_Interrupt : constant Interrupt_ID := 35; -- SPI2 global interrupt SPI2_Interrupt : constant Interrupt_ID := 36; -- EXTI Line[15:10] interrupts EXTI15_10_Interrupt : constant Interrupt_ID := 40; -- RTC Alarms (A and B) through EXTI line interrupt RTC_Alarm_Interrupt : constant Interrupt_ID := 41; -- USB On-The-Go FS Wakeup through EXTI line interrupt OTG_FS_WKUP_Interrupt : constant Interrupt_ID := 42; -- SDIO global interrupt SDIO_Interrupt : constant Interrupt_ID := 49; -- SPI3 global interrupt SPI3_Interrupt : constant Interrupt_ID := 51; -- USB On The Go FS global interrupt OTG_FS_Interrupt : constant Interrupt_ID := 67; -- I2C3 event interrupt I2C3_EV_Interrupt : constant Interrupt_ID := 72; -- I2C3 error interrupt I2C3_ER_Interrupt : constant Interrupt_ID := 73; -- FPU global interrupt FPU_Interrupt : constant Interrupt_ID := 81; -- SPI4 global interrupt SPI4_Interrupt : constant Interrupt_ID := 84; end Ada.Interrupts.Names;
-- CC3606B.ADA -- Grant of Unlimited Rights -- -- Under contracts F33600-87-D-0337, F33600-84-D-0280, MDA903-79-C-0687, -- F08630-91-C-0015, and DCA100-97-D-0025, the U.S. Government obtained -- unlimited rights in the software and documentation contained herein. -- Unlimited rights are defined in DFAR 252.227-7013(a)(19). By making -- this public release, the Government intends to confer upon all -- recipients unlimited rights equal to those held by the Government. -- These rights include rights to use, duplicate, release or disclose the -- released technical data and computer software in whole or in part, in -- any manner and for any purpose whatsoever, and to have or permit others -- to do so. -- -- DISCLAIMER -- -- ALL MATERIALS OR INFORMATION HEREIN RELEASED, MADE AVAILABLE OR -- DISCLOSED ARE AS IS. THE GOVERNMENT MAKES NO EXPRESS OR IMPLIED -- WARRANTY AS TO ANY MATTER WHATSOEVER, INCLUDING THE CONDITIONS OF THE -- SOFTWARE, DOCUMENTATION OR OTHER INFORMATION RELEASED, MADE AVAILABLE -- OR DISCLOSED, OR THE OWNERSHIP, MERCHANTABILITY, OR FITNESS FOR A -- PARTICULAR PURPOSE OF SAID MATERIAL. --* -- OBJECTIVE: -- CHECK THAT ANY CONSTRAINTS SPECIFIED FOR THE ACTUAL -- SUBPROGRAM'S PARAMETERS ARE USED IN PLACE OF THOSE -- ASSOCIATED WITH THE FORMAL SUBPROGRAM'S PARAMETERS -- (INCLUDING PARAMETERS SPECIFIED WITH A FORMAL GENERIC TYPE). -- HISTORY: -- LDC 06/30/88 CREATED ORIGINAL TEST. -- PWN 05/31/96 Corrected spelling problems. WITH REPORT; USE REPORT; PROCEDURE CC3606B IS SUBTYPE ONE_TO_TEN IS INTEGER RANGE IDENT_INT (1) .. IDENT_INT (10); SUBTYPE ONE_TO_FIVE IS INTEGER RANGE IDENT_INT (1) .. IDENT_INT (5); BEGIN TEST ( "CC3606B", "CHECK THAT ANY CONSTRAINTS SPECIFIED FOR " & "THE ACTUAL SUBPROGRAM'S PARAMETERS ARE USED " & "IN PLACE OF THOSE ASSOCIATED WITH THE " & "FORMAL SUBPROGRAM'S PARAMETERS (INCLUDING " & "PARAMETERS SPECIFIED WITH A FORMAL GENERIC " & "TYPE)"); DECLARE GENERIC BRIAN : IN OUT INTEGER; WITH PROCEDURE PASSED_PROC(LYNN :IN OUT ONE_TO_TEN); PACKAGE GEN IS END GEN; DOUG : INTEGER := 10; PACKAGE BODY GEN IS BEGIN PASSED_PROC(BRIAN); FAILED("WRONG CONSTRAINTS FOR ACTUAL PARAMETER IN GEN"); EXCEPTION WHEN CONSTRAINT_ERROR => NULL; WHEN OTHERS => FAILED("OTHER EXCEPTION WAS RAISED FOR ACTUAL " & "PARAMETER"); END GEN; PROCEDURE PROC(JODIE : IN OUT ONE_TO_FIVE) IS JOHN : ONE_TO_TEN; BEGIN JOHN := IDENT_INT(JODIE); EXCEPTION WHEN OTHERS => FAILED("EXCEPTION RAISED INSIDE PROCEDURE"); END PROC; PACKAGE GEN_PCK IS NEW GEN( DOUG, PROC); BEGIN NULL; END; DECLARE TYPE ENUM IS (DAYTON, BEAVERCREEK, CENTERVILLE, ENGLEWOOD, FAIRBORN, HUBER_HEIGHTS, KETTERING, MIAMISBURG, OAKWOOD, RIVERSIDE, TROTWOOD, WEST_CARROLLTON, VANDALIA); SUBTYPE SUB_ENUM IS ENUM RANGE CENTERVILLE..FAIRBORN; GENERIC TYPE T_TYPE IS (<>); BRIAN : T_TYPE; WITH FUNCTION PASSED_FUNC(LYNN : T_TYPE) RETURN T_TYPE; PACKAGE GEN_TWO IS END GEN_TWO; DOUG : ENUM := ENUM'FIRST; PACKAGE BODY GEN_TWO IS DAVE : T_TYPE; BEGIN DAVE := PASSED_FUNC(BRIAN); FAILED("WRONG CONSTRAINTS FOR ACTUAL PARAMETER IN " & "GEN_TWO"); EXCEPTION WHEN CONSTRAINT_ERROR => NULL; WHEN OTHERS => FAILED("OTHER EXCEPTION WAS " & "RAISED FOR ACTUAL " & "PARAMETER"); END GEN_TWO; FUNCTION FUNC(JODIE : SUB_ENUM) RETURN SUB_ENUM IS BEGIN RETURN ENUM'VAL(IDENT_INT(ENUM'POS(JODIE))); EXCEPTION WHEN OTHERS => FAILED("EXCEPTION RAISED INSIDE PROCEDURE"); END FUNC; PACKAGE GEN_PCK_TWO IS NEW GEN_TWO( ENUM, DOUG, FUNC); BEGIN RESULT; END; END CC3606B;
----------------------------------------------------------------------- -- awa-wikis-tests -- Unit tests for wikis module -- Copyright (C) 2018, 2019 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with Util.Test_Caller; with Util.Strings; with Servlet.Streams; with ASF.Requests.Mockup; with ASF.Responses.Mockup; with ASF.Tests; with AWA.Tests.Helpers.Users; package body AWA.Wikis.Tests is use Ada.Strings.Unbounded; use AWA.Tests; package Caller is new Util.Test_Caller (Test, "Wikis.Beans"); procedure Add_Tests (Suite : in Util.Tests.Access_Test_Suite) is begin Caller.Add_Test (Suite, "Test AWA.Wikis.Beans.Load_List (Anonymous)", Test_Anonymous_Access'Access); Caller.Add_Test (Suite, "Test AWA.Wikis.Beans.Save", Test_Create_Wiki'Access); Caller.Add_Test (Suite, "Test AWA.Wikis.Beans.Load (missing)", Test_Missing_Page'Access); end Add_Tests; -- ------------------------------ -- Get some access on the wiki as anonymous users. -- ------------------------------ procedure Verify_Anonymous (T : in out Test; Page : in String; Title : in String) is pragma Unreferenced (Title); function Get_Link (Title : in String) return String; Wiki : constant String := To_String (T.Wiki_Ident); Request : ASF.Requests.Mockup.Request; Reply : ASF.Responses.Mockup.Response; function Get_Link (Title : in String) return String is Stream : Servlet.Streams.Print_Stream := Reply.Get_Output_Stream; Content : Ada.Strings.Unbounded.Unbounded_String; begin Reply.Read_Content (Content); Stream.Write (Content); return AWA.Tests.Helpers.Extract_Link (To_String (Content), Title); end Get_Link; begin ASF.Tests.Do_Get (Request, Reply, "/wikis/list/" & Wiki & "/recent", "wiki-list-recent.html"); ASF.Tests.Assert_Contains (T, "List of pages", Reply, "Wiki list recent page is invalid"); ASF.Tests.Do_Get (Request, Reply, "/wikis/tags/" & Wiki, "wiki-list-tagged.html"); ASF.Tests.Assert_Contains (T, "List of pages", Reply, "Wiki tag page is invalid"); if Page'Length > 0 then ASF.Tests.Do_Get (Request, Reply, "/wikis/view/" & Wiki & "/" & Page, "wiki-page-" & Page & ".html"); ASF.Tests.Assert_Contains (T, "The wiki page content", Reply, "Wiki page " & Page & " is invalid"); declare Info : constant String := Get_Link ("Info"); History : constant String := Get_Link ("History"); begin Util.Tests.Assert_Matches (T, "/asfunit/wikis/info/[0-9]+/[0-9]+$", Info, "Invalid wiki info link in the response"); Util.Tests.Assert_Matches (T, "/asfunit/wikis/history/[0-9]+/[0-9]+$", History, "Invalid wiki history link in the response"); -- Get the information page. ASF.Tests.Do_Get (Request, Reply, Info (Info'First + 8 .. Info'Last), "wiki-info-" & Page & ".html"); ASF.Tests.Assert_Contains (T, "wiki-word-list", Reply, "Wiki info page " & Page & " is invalid"); -- Get the history page. ASF.Tests.Do_Get (Request, Reply, History (History'First + 8 .. History'Last), "wiki-history-" & Page & ".html"); ASF.Tests.Assert_Contains (T, "wiki-page-version", Reply, "Wiki history page " & Page & " is invalid"); end; end if; end Verify_Anonymous; -- ------------------------------ -- Verify that the wiki lists contain the given page. -- ------------------------------ procedure Verify_List_Contains (T : in out Test; Page : in String) is Wiki : constant String := To_String (T.Wiki_Ident); Request : ASF.Requests.Mockup.Request; Reply : ASF.Responses.Mockup.Response; begin ASF.Tests.Do_Get (Request, Reply, "/wikis/list/" & Wiki & "/recent", "wiki-list-recent.html"); ASF.Tests.Assert_Contains (T, "List of pages", Reply, "Wiki list recent page is invalid"); ASF.Tests.Assert_Contains (T, "/wikis/view/" & To_String (T.Wiki_Ident) & "/" & Page, Reply, "Wiki list recent page does not reference the page"); ASF.Tests.Do_Get (Request, Reply, "/wikis/list/" & Wiki & "/popular", "wiki-list-popular.html"); ASF.Tests.Assert_Contains (T, "List of pages", Reply, "Wiki list popular page is invalid"); ASF.Tests.Assert_Contains (T, "/wikis/view/" & To_String (T.Wiki_Ident) & "/" & Page, Reply, "Wiki list popular page does not reference the page"); ASF.Tests.Do_Get (Request, Reply, "/wikis/list/" & Wiki & "/name", "wiki-list-name.html"); ASF.Tests.Assert_Contains (T, "List of pages", Reply, "Wiki list name page is invalid"); ASF.Tests.Assert_Contains (T, "/wikis/view/" & To_String (T.Wiki_Ident) & "/" & Page, Reply, "Wiki list name page does not reference the page"); ASF.Tests.Do_Get (Request, Reply, "/wikis/list/" & Wiki & "/name/grid", "wiki-list-name-grid.html"); ASF.Tests.Assert_Contains (T, "List of pages", Reply, "Wiki list name/grid page is invalid"); ASF.Tests.Assert_Contains (T, "/wikis/view/" & To_String (T.Wiki_Ident) & "/" & Page, Reply, "Wiki list name/grid page does not reference the page"); end Verify_List_Contains; -- ------------------------------ -- Test access to the blog as anonymous user. -- ------------------------------ procedure Test_Anonymous_Access (T : in out Test) is begin T.Verify_Anonymous ("", ""); end Test_Anonymous_Access; -- ------------------------------ -- Test creation of blog by simulating web requests. -- ------------------------------ procedure Test_Create_Wiki (T : in out Test) is procedure Create_Page (Name : in String; Title : in String); Request : ASF.Requests.Mockup.Request; Reply : ASF.Responses.Mockup.Response; procedure Create_Page (Name : in String; Title : in String) is begin Request.Set_Parameter ("page-wiki-id", To_String (T.Wiki_Ident)); Request.Set_Parameter ("post", "1"); Request.Set_Parameter ("page-title", Title); Request.Set_Parameter ("text", "# Main title" & ASCII.LF & "* The wiki page content." & ASCII.LF & "* Second item." & ASCII.LF); Request.Set_Parameter ("name", Name); Request.Set_Parameter ("comment", "Created wiki page " & Name); Request.Set_Parameter ("save", "1"); Request.Set_Parameter ("page-is-public", "1"); Request.Set_Parameter ("wiki-format", "FORMAT_MARKDOWN"); ASF.Tests.Do_Post (Request, Reply, "/wikis/create.html", "create-wiki.html"); T.Page_Ident := Helpers.Extract_Redirect (Reply, "/asfunit/wikis/view/" & To_String (T.Wiki_Ident) & "/"); Util.Tests.Assert_Equals (T, Name, To_String (T.Page_Ident), "Invalid redirect after wiki page creation"); -- Remove the 'wikiPage' bean from the request so that we get a new instance -- for the next call. Request.Remove_Attribute ("wikiPage"); end Create_Page; begin AWA.Tests.Helpers.Users.Login ("test-wiki@test.com", Request); Request.Set_Parameter ("title", "The Wiki Space Title"); Request.Set_Parameter ("post", "1"); Request.Set_Parameter ("create", "1"); ASF.Tests.Do_Post (Request, Reply, "/wikis/setup.html", "setup-wiki.html"); T.Assert (Reply.Get_Status = ASF.Responses.SC_MOVED_TEMPORARILY, "Invalid response after wiki space creation"); declare Ident : constant String := Helpers.Extract_Redirect (Reply, "/asfunit/wikis/list/"); Pos : constant Natural := Util.Strings.Index (Ident, '/'); begin Util.Tests.Assert_Matches (T, "^[0-9]+/recent/grid$", Ident, "Invalid wiki space identifier in the response"); T.Wiki_Ident := To_Unbounded_String (Ident (Ident'First .. Pos - 1)); end; Create_Page ("WikiPageTestName", "Wiki page title1"); T.Verify_List_Contains (To_String (T.Page_Ident)); Create_Page ("WikiSecondPageName", "Wiki page title2"); T.Verify_List_Contains (To_String (T.Page_Ident)); Create_Page ("WikiThirdPageName", "Wiki page title3"); T.Verify_Anonymous ("WikiPageTestName", "Wiki page title1"); T.Verify_Anonymous ("WikiSecondPageName", "Wiki page title2"); T.Verify_Anonymous ("WikiThirdPageName", "Wiki page title3"); end Test_Create_Wiki; -- ------------------------------ -- Test getting a wiki page which does not exist. -- ------------------------------ procedure Test_Missing_Page (T : in out Test) is Wiki : constant String := To_String (T.Wiki_Ident); Request : ASF.Requests.Mockup.Request; Reply : ASF.Responses.Mockup.Response; begin ASF.Tests.Do_Get (Request, Reply, "/wikis/view/" & Wiki & "/MissingPage", "wiki-page-missing.html"); ASF.Tests.Assert_Matches (T, ".title.Wiki page does not exist./title.", Reply, "Wiki page 'MissingPage' is invalid", ASF.Responses.SC_NOT_FOUND); ASF.Tests.Assert_Matches (T, ".h2.MissingPage./h2.", Reply, "Wiki page 'MissingPage' header is invalid", ASF.Responses.SC_NOT_FOUND); end Test_Missing_Page; end AWA.Wikis.Tests;
with Ada.Text_IO; use Ada.Text_IO; with Colors; with Flags; with Input; procedure Main is Map : Flags.Map_T; begin loop Put ("Enter key value: "); declare Str : constant String := Get_Line; Key : Flags.Key_T; Description : Colors.Color_Set_T; Success : Boolean; begin exit when Str'length = 0; Key := Flags.Key_T'value (Str); Description := Input.Get; if Flags.Exists (Map, Key) then Flags.Modify (Map, Key, Description, Success); else Flags.Add (Map, Key, Description, Success); end if; end; end loop; Put_Line (Flags.Image (Map)); end Main;
with Agar.Core.Thin; with Interfaces; package Agar.Core.Data_Source is subtype Data_Source_Access_t is Thin.Data_Source.Data_Source_Access_t; subtype Data_Source_Not_Null_Access_t is Thin.Data_Source.Data_Source_Not_Null_Access_t; -- -- Open. -- procedure Open_File (Path : in String; Mode : in String; Source : out Data_Source_Access_t); -- -- I/O -- type IO_Status_t is new Thin.Data_Source.IO_Status_t; subtype Byte_Offset_t is Interfaces.Unsigned_64; generic type Element_Type is private; type Element_Count_Type is range <>; type Element_Array_Index_Type is (<>); type Element_Array_Type is array (Element_Array_Index_Type range <>) of Element_Type; package IO is procedure Read (Source : in Data_Source_Not_Null_Access_t; Buffer : out Element_Array_Type; Read : out Element_Count_Type; Status : out IO_Status_t); procedure Read_At_Offset (Source : in Data_Source_Not_Null_Access_t; Offset : in Byte_Offset_t; Buffer : out Element_Array_Type; Read : out Element_Count_Type; Status : out IO_Status_t); procedure Write (Source : in Data_Source_Not_Null_Access_t; Buffer : in Element_Array_Type; Wrote : out Element_Count_Type; Status : out IO_Status_t); procedure Write_At_Offset (Source : in Data_Source_Not_Null_Access_t; Offset : in Byte_Offset_t; Buffer : in Element_Array_Type; Wrote : out Element_Count_Type; Status : out IO_Status_t); end IO; -- -- Close. -- procedure Close_File (Source : in Data_Source_Not_Null_Access_t); end Agar.Core.Data_Source;
with ada.Text_IO, ada.Integer_Text_IO, ada.Strings.fixed, ada.Strings.unbounded; package body openGL.IO.wavefront is package real_Text_IO is new Ada.Text_IO.Float_IO (openGL.Real); function to_Text (Self : in String) return Text is begin return ada.Strings.unbounded.to_unbounded_String (Self); end to_Text; function to_Vector_3 (Self : in String) return Vector_3 is use real_Text_IO; X, Y, Z : Real; Last : Natural; begin get (Self, X, Last); get (Self (Last + 1 .. Self'Last), Y, Last); get (Self (Last + 1 .. Self'Last), Z, Last); return (X, Y, Z); end to_Vector_3; function to_Coordinate (Self : in String) return Coordinate_2D is use real_Text_IO; U, V : Real; Last : Natural; begin get (Self, U, Last); get (Self (Last + 1 .. Self'Last), V, Last); return (U, V); end to_Coordinate; function to_Facet (Self : in String) return IO.Face is use ada.Integer_Text_IO; site_Id, coord_Id, normal_Id : Integer; the_Vertices : Vertices (1 .. 5_000); vertex_Count : long_Index_t := 0; Last : Natural := Self'First - 1; begin loop get (Self (Last + 1 .. Self'Last), site_Id, Last); if Last = Self'Last or else Self (Last + 1) = ' ' then -- Both texture coord and normal are absent. coord_Id := Integer (null_Id); normal_Id := Integer (null_Id); elsif Self (Last + 1) = '/' then if Self (Last + 2) = '/' then -- Texture coord is absent. coord_Id := Integer (null_Id); get (Self (Last + 3 .. Self'Last), normal_Id, Last); else get (Self (Last + 2 .. Self'Last), coord_Id, Last); if Last = Self'Last or else Self (Last + 1) = ' ' then -- Lighting normal is absent. normal_Id := Integer (null_Id); elsif Self (Last + 1) = '/' then get (Self (Last + 2 .. Self'Last), normal_Id, Last); else raise Constraint_Error with "Invalid indices: " & Self & "."; end if; end if; else raise Constraint_Error with "Invalid indices: " & Self & "."; end if; if site_Id < 0 or else coord_Id < 0 or else normal_Id < 0 then raise Constraint_Error with "Negative indices not implemented: " & Self & "."; end if; vertex_Count := vertex_Count + 1; the_Vertices (vertex_Count) := (long_Index_t ( site_Id), long_Index_t ( coord_Id), long_Index_t (normal_Id), null_Id); exit when Last + 1 >= Self'Last; end loop; case vertex_Count is when 3 => return (Triangle, the_Vertices (1 .. 3)); when 4 => return (Quad, the_Vertices (1 .. 4)); when others => return (Polygon, new Vertices' (the_Vertices (1 .. vertex_Count))); end case; end to_Facet; function to_Model (model_File : in String) return IO.Model is use ada.Strings.fixed, ada.Text_IO; the_File : File_Type; max_Elements : constant := 200_000; the_Sites : Sites_view := new many_Sites (1 .. max_Elements); the_Coords : Coords_view := new many_Coordinates_2D (1 .. max_Elements); the_Normals : Normals_view := new many_Normals (1 .. max_Elements); the_Faces : IO.Faces_view := new IO.Faces' (1 .. max_Elements => <>); site_Count : long_Index_t := 0; coord_Count : long_Index_t := 0; normal_Count : long_Index_t := 0; face_Count : long_Index_t := 0; begin open (the_File, In_File, model_File); while not end_of_File (the_File) loop declare the_Line : constant String := get_Line (the_File); begin if the_Line'Length = 0 or else the_Line (1) = '#' then null; elsif Head (the_Line, 6) = "mtllib" then null; -- TODO elsif Head (the_Line, 2) = "f " then face_Count := face_Count + 1; the_Faces (face_Count) := to_Facet (the_Line (3 .. the_Line'Last)); elsif Head (the_Line, 2) = "v " then site_Count := site_Count + 1; the_Sites (site_Count) := to_Vector_3 (the_Line (3 .. the_Line'Last)); elsif Head (the_Line, 3) = "vt " then coord_Count := coord_Count + 1; the_Coords (coord_Count) := to_Coordinate (the_Line (4 .. the_Line'Last)); elsif Head (the_Line, 3) = "vn " then normal_Count := normal_Count + 1; the_Normals (normal_Count) := to_Vector_3 (the_Line (4 .. the_Line'Last)); elsif Head (the_Line, 2) = "o " then null; -- Currently ignored. TODO elsif Head (the_Line, 2) = "g " then null; -- Currently ignored. TODO elsif Head (the_Line, 2) = "s " then null; -- Currently ignored. TODO else null; -- Currently ignored. TODO end if; end; end loop; close (the_File); declare used_Sites : constant IO. Sites_view := new many_Sites' (the_Sites (1 .. site_Count)); used_Coords : constant IO. Coords_view := new many_Coordinates_2D' (the_Coords (1 .. coord_Count)); used_Normals : constant IO.Normals_view := new many_Normals' (the_Normals (1 .. normal_Count)); used_Faces : constant IO. Faces_view := new IO.Faces' (the_Faces (1 .. face_Count)); begin free (the_Sites); free (the_Coords); free (the_Normals); free (the_Faces); return (Sites => used_Sites, Coords => used_Coords, Normals => used_Normals, Weights => null, Faces => used_Faces); end; end to_Model; ---------- --- Images -- function Image (Self : in IO.Face) return String is use ada.Strings.unbounded; the_Vertices : Vertices renames Vertices_of (Self); the_Image : unbounded_String := to_unbounded_String ("f "); function id_Image (Self : in long_Index_t) return String is use ada.Strings.fixed; begin return Trim (long_Index_t'Image (Self), ada.Strings.left); end id_Image; begin for i in the_Vertices'Range loop append (the_Image, id_Image (the_Vertices (i).site_Id)); if the_Vertices (i).coord_Id = null_Id then if the_Vertices (i).normal_Id /= null_Id then append (the_Image, "/"); end if; else append (the_Image, "/" & id_Image (the_Vertices (i).coord_Id)); end if; if the_Vertices (i).normal_Id /= null_Id then append (the_Image, "/" & id_Image (the_Vertices (i).normal_Id)); end if; append (the_Image, " "); end loop; return to_String (the_Image); end Image; function Image (Self : in wavefront.Group) return String is use ada.Strings.unbounded; begin case Self.Kind is when object_Name => return "o " & to_String (Self.object_Name); when group_Name => return "g " & to_String (Self. group_Name); when smoothing_Group => return "s" & Self.smooth_group_Id'Image; when merging_Group => return ""; -- TODO end case; end Image; function Image (Self : in wavefront.Face) return String is begin case Self.Kind is when a_Group => return Image (Self.Group); when a_Facet => return Image (Self.Facet); end case; end Image; -------------- --- Deprecated ~ TODO: Rid this. -- type wf_Faces_view is access all wavefront.Faces; function to_Model (model_Path : in String) return wavefront.Model is use ada.Strings.fixed, ada.Text_IO; the_File : File_Type; the_Sites : Sites (Index_t); site_Count : Index_t := 0; the_Coords : Coordinates_2D (Index_t); coord_Count : Index_t := 0; the_Normals : Normals (Index_t); normal_Count : Index_t := 0; the_Faces : wf_Faces_view := new Faces'(1 .. 50_000 => <>); face_Count : long_Index_t := 0; begin Open (the_File, In_File, model_Path); while not End_Of_File (the_File) loop declare the_Line : constant String := Get_Line (the_File); begin if the_Line'Length = 0 or else the_Line (1) = '#' then null; elsif Head (the_Line, 6) = "mtllib" then null; -- tbd elsif Head (the_Line, 2) = "f " then face_Count := face_Count + 1; the_Faces (face_Count) := (a_Facet, to_Facet (the_Line (3 .. the_Line'Last))); elsif Head (the_Line, 2) = "v " then site_Count := site_Count + 1; the_Sites (site_Count) := to_Vector_3 (the_Line (3 .. the_Line'Last)); elsif Head (the_Line, 3) = "vt " then coord_Count := coord_Count + 1; the_Coords (coord_Count) := to_Coordinate (the_Line (4 .. the_Line'Last)); elsif Head (the_Line, 3) = "vn " then normal_Count := normal_Count + 1; the_Normals (normal_Count) := to_Vector_3 (the_Line (4 .. the_Line'Last)); elsif Head (the_Line, 2) = "o " then face_Count := face_Count + 1; the_Faces (face_Count) := (a_Group, (object_Name, object_Name => to_Text (the_Line (3 .. the_Line'Last)))); elsif Head (the_Line, 2) = "g " then face_Count := face_Count + 1; the_Faces (face_Count) := (a_Group, (group_Name, group_Name => to_Text (the_Line (3 .. the_Line'Last)))); elsif Head (the_Line, 2) = "s " then declare use Ada.Integer_Text_IO; the_Id : Natural; Last : Natural; begin if Head (the_Line, 5) = "s off" then the_Id := 0; else Get (the_Line (3 .. the_Line'Last), the_Id, Last); end if; face_Count := face_Count + 1; the_Faces (face_Count) := (a_Group, (smoothing_Group, smooth_group_Id => the_Id)); end; else put_Line ("openGL.io.wavefront ~ Unhandled line in " & model_Path & ": '" & the_Line & "'"); end if; end; end loop; Close (the_File); declare procedure free is new Ada.Unchecked_Deallocation (Faces, wf_Faces_view); used_Faces : constant wf_Faces_view := new wavefront.Faces'(the_Faces (1 .. face_Count)); begin free (the_Faces); return (Sites => new openGL.Sites'(the_Sites (1 .. site_Count)), Coords => new Coordinates_2D'(the_Coords (1 .. coord_Count)), Normals => new openGL.Normals'(the_Normals (1 .. normal_Count)), Faces => used_Faces); end; end to_Model; procedure write (the_Model : in wavefront.Model; to_File : in String) is use ada.Text_IO; the_File : File_type; use Real_text_IO; begin Create (the_File, Out_File, Name => to_File); -- Write sites. -- for Each in the_Model.Sites'Range loop Put (the_File, "v "); Put (the_File, the_Model.Sites (Each) (1), Aft => 19, Exp => 0); Put (the_File, " "); Put (the_File, the_Model.Sites (Each) (2), Aft => 19, Exp => 0); Put (the_File, " "); Put (the_File, the_Model.Sites (Each) (3), Aft => 19, Exp => 0); New_Line (the_File); end loop; New_Line (the_File); -- Write texture coords. -- for Each in the_Model.Coords'Range loop Put (the_File, "vt "); Put (the_File, the_Model.Coords (Each).S, Aft => 19, Exp => 0); Put (the_File, " "); Put (the_File, the_Model.Coords (Each).T, Aft => 19, Exp => 0); New_Line (the_File); end loop; New_Line (the_File); -- Write normals. -- for Each in the_Model.Normals'Range loop Put (the_File, "vn "); Put (the_File, the_Model.Normals (Each) (1), Aft => 19, Exp => 0); Put (the_File, " "); Put (the_File, the_Model.Normals (Each) (2), Aft => 19, Exp => 0); Put (the_File, " "); Put (the_File, the_Model.Normals (Each) (3), Aft => 19, Exp => 0); New_Line (the_File); end loop; New_Line (the_File); -- Write faces. -- for Each in the_Model.Faces'Range loop Put_Line (the_File, Image (the_Model.Faces (Each))); end loop; Close (the_File); end write; end openGL.IO.wavefront;
-- { dg-do run } with Ada.Real_Time.Timing_Events; use Ada.Real_Time, Ada.Real_Time.Timing_Events; procedure Timer_Cancel is E : Timing_Event; C : Boolean; protected Dummy is procedure Trigger (Event : in out Timing_Event); end Dummy; protected body Dummy is procedure Trigger (Event : in out Timing_Event) is begin null; end Trigger; end Dummy; begin Set_Handler (E, Time_Last, Dummy.Trigger'Unrestricted_Access); if Time_Of_Event (E) /= Time_Last then raise Program_Error with "Event time not set correctly"; end if; Cancel_Handler (E, C); if not C then raise Program_Error with "Event triggered already"; end if; if Time_Of_Event (E) /= Time_First then raise Program_Error with "Event time not reset correctly"; end if; end Timer_Cancel;
-- { dg-do compile } -- { dg-options "-gnatws" } with FRUnaligned1; use FRUnaligned1; function FRUnaligned return r is ss : s; begin return ss.y; end;
function Palindrome (message: String) return Boolean is -- Palindrome checker rev, orig : String(message'First..message'Last); counter, rev_count : Integer := 0; begin -- Remove any spaces for c in message'First..message'Last loop if message(c) /= ' ' then counter := counter + 1; orig(counter..counter) := message(c..c); end if; end loop; -- Reverse the string for d in reverse 1..counter loop rev_count := rev_count + 1; rev(rev_count..rev_count) := orig(d..d); end loop; -- Compare and return return orig(1..counter) = rev(1..counter); end Palindrome;
with Ada.Unchecked_Deallocation; with Courbes.Visiteurs; use Courbes.Visiteurs; package body Courbes is use Liste_Points; procedure Liberer_Courbe (Self : in out Courbe_Ptr) is procedure Liberer_Delivrer is new Ada.Unchecked_Deallocation (Courbe'Class, Courbe_Ptr); begin -- Libération de la memoire allouée par le Ctor -- Note: cela fonctionne aussi sur les types dérivés Liberer_Delivrer (Self); end; function Obtenir_Debut (Self : Courbe) return Point2D is begin return Self.Debut; end; function Obtenir_Fin (Self : Courbe) return Point2D is begin return Self.Fin; end; procedure Accepter (Self : Courbe; Visiteur : Courbes.Visiteurs.Visiteur_Courbe'Class) is begin Visiteur.Visiter(Self); end; end Courbes;
----------------------------------------------------------------------- -- awa-wikis-previews -- Wiki preview management -- Copyright (C) 2015, 2018, 2020 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with Ada.Strings.Unbounded; with Util.Log.Loggers; with Util.Beans.Objects; with Util.Files; with Util.Processes; with Util.Streams.Pipes; with Util.Streams.Texts; with EL.Contexts.TLS; with Servlet.Core; with ASF.Requests.Mockup; with ASF.Responses.Mockup; with AWA.Applications; with AWA.Modules.Get; package body AWA.Wikis.Previews is Log : constant Util.Log.Loggers.Logger := Util.Log.Loggers.Create ("AWA.Wikis.Preview"); -- ------------------------------ -- The worker procedure that performs the preview job. -- ------------------------------ procedure Preview_Worker (Job : in out AWA.Jobs.Services.Abstract_Job_Type'Class) is Previewer : constant Preview_Module_Access := Get_Preview_Module; begin Previewer.Do_Preview_Job (Job); end Preview_Worker; -- ------------------------------ -- Initialize the wikis module. -- ------------------------------ overriding procedure Initialize (Plugin : in out Preview_Module; App : in AWA.Modules.Application_Access; Props : in ASF.Applications.Config) is begin Log.Info ("Initializing the wiki preview module"); AWA.Modules.Module (Plugin).Initialize (App, Props); end Initialize; -- ------------------------------ -- Configures the module after its initialization and after having read its XML configuration. -- ------------------------------ overriding procedure Configure (Plugin : in out Preview_Module; Props : in ASF.Applications.Config) is pragma Unreferenced (Props); begin Plugin.Template := Plugin.Get_Config (PARAM_PREVIEW_TEMPLATE); Plugin.Command := Plugin.Get_Config (PARAM_PREVIEW_COMMAND); Plugin.Html := Plugin.Get_Config (PARAM_PREVIEW_HTML); Plugin.Add_Listener (AWA.Wikis.Modules.NAME, Plugin'Unchecked_Access); Plugin.Job_Module := AWA.Jobs.Modules.Get_Job_Module; Plugin.Job_Module.Register (Definition => Preview_Job_Definition.Factory); end Configure; -- ------------------------------ -- Execute the preview job and make the thumbnail preview. The page is first rendered in -- an HTML text file and the preview is rendered by using an external command. -- ------------------------------ procedure Do_Preview_Job (Plugin : in Preview_Module; Job : in out AWA.Jobs.Services.Abstract_Job_Type'Class) is pragma Unreferenced (Job); use Util.Beans.Objects; Ctx : constant EL.Contexts.ELContext_Access := EL.Contexts.TLS.Current; Template : constant String := To_String (Plugin.Template.Get_Value (Ctx.all)); Command : constant String := To_String (Plugin.Command.Get_Value (Ctx.all)); Html_File : constant String := To_String (Plugin.Html.Get_Value (Ctx.all)); begin Log.Info ("Preview {0} with {1}", Template, Command); declare Req : ASF.Requests.Mockup.Request; Reply : ASF.Responses.Mockup.Response; Dispatcher : constant Servlet.Core.Request_Dispatcher := Plugin.Get_Application.Get_Request_Dispatcher (Template); Result : Ada.Strings.Unbounded.Unbounded_String; begin Req.Set_Request_URI (Template); Req.Set_Method ("GET"); Servlet.Core.Forward (Dispatcher, Req, Reply); Reply.Read_Content (Result); Util.Files.Write_File (Html_File, Result); end; declare Pipe : aliased Util.Streams.Pipes.Pipe_Stream; Input : Util.Streams.Texts.Reader_Stream; begin Log.Info ("Running preview command {0}", Command); Pipe.Open (Command, Util.Processes.READ_ALL); Input.Initialize (Pipe'Unchecked_Access, 1024); while not Input.Is_Eof loop declare Line : Ada.Strings.Unbounded.Unbounded_String; begin Input.Read_Line (Line, False); Log.Info ("Received: {0}", Line); end; end loop; Pipe.Close; if Pipe.Get_Exit_Status /= 0 then Log.Error ("Command {0} exited with status {1}", Command, Integer'Image (Pipe.Get_Exit_Status)); end if; end; end Do_Preview_Job; -- ------------------------------ -- Create a preview job and schedule the job to generate a new thumbnail preview for the page. -- ------------------------------ procedure Make_Preview_Job (Plugin : in Preview_Module; Page : in AWA.Wikis.Models.Wiki_Page_Ref'Class) is pragma Unreferenced (Plugin); J : AWA.Jobs.Services.Job_Type; begin J.Set_Parameter ("wiki_space_id", Page.Get_Wiki); J.Set_Parameter ("wiki_page_id", Page); J.Schedule (Preview_Job_Definition.Factory.all); end Make_Preview_Job; -- ------------------------------ -- The `On_Create` procedure is called by `Notify_Create` to notify the creation of the page. -- ------------------------------ overriding procedure On_Create (Instance : in Preview_Module; Item : in AWA.Wikis.Models.Wiki_Page_Ref'Class) is begin Instance.Make_Preview_Job (Item); end On_Create; -- ------------------------------ -- The `On_Update` procedure is called by `Notify_Update` to notify the update of the page. -- ------------------------------ overriding procedure On_Update (Instance : in Preview_Module; Item : in AWA.Wikis.Models.Wiki_Page_Ref'Class) is begin Instance.Make_Preview_Job (Item); end On_Update; -- ------------------------------ -- The `On_Delete` procedure is called by `Notify_Delete` to notify the deletion of the page. -- ------------------------------ overriding procedure On_Delete (Instance : in Preview_Module; Item : in AWA.Wikis.Models.Wiki_Page_Ref'Class) is begin null; end On_Delete; -- ------------------------------ -- Get the preview module instance associated with the current application. -- ------------------------------ function Get_Preview_Module return Preview_Module_Access is function Get is new AWA.Modules.Get (Preview_Module, Preview_Module_Access, NAME); begin return Get; end Get_Preview_Module; end AWA.Wikis.Previews;
-- Standard Ada library specification -- Copyright (c) 2003-2018 Maxim Reznik <reznikmm@gmail.com> -- Copyright (c) 2004-2016 AXE Consultants -- Copyright (c) 2004, 2005, 2006 Ada-Europe -- Copyright (c) 2000 The MITRE Corporation, Inc. -- Copyright (c) 1992, 1993, 1994, 1995 Intermetrics, Inc. -- SPDX-License-Identifier: BSD-3-Clause and LicenseRef-AdaReferenceManual --------------------------------------------------------------------------- with Ada.Characters.Conversions; package Ada.Characters.Handling is pragma Pure (Handling); -- Character classification functions function Is_Control (Item : in Character) return Boolean; function Is_Graphic (Item : in Character) return Boolean; function Is_Letter (Item : in Character) return Boolean; function Is_Lower (Item : in Character) return Boolean; function Is_Upper (Item : in Character) return Boolean; function Is_Basic (Item : in Character) return Boolean; function Is_Digit (Item : in Character) return Boolean; function Is_Decimal_Digit (Item : in Character) return Boolean renames Is_Digit; function Is_Hexadecimal_Digit (Item : in Character) return Boolean; function Is_Alphanumeric (Item : in Character) return Boolean; function Is_Special (Item : in Character) return Boolean; function Is_Line_Terminator (Item : in Character) return Boolean; function Is_Mark (Item : in Character) return Boolean; function Is_Other_Format (Item : in Character) return Boolean; function Is_Punctuation_Connector (Item : in Character) return Boolean; function Is_Space (Item : in Character) return Boolean; -- Conversion functions for Character and String function To_Lower (Item : in Character) return Character; function To_Upper (Item : in Character) return Character; function To_Basic (Item : in Character) return Character; function To_Lower (Item : in String) return String; function To_Upper (Item : in String) return String; function To_Basic (Item : in String) return String; -- Classifications of and conversions between Character and ISO 646 subtype ISO_646 is Character range Character'Val(0) .. Character'Val(127); function Is_ISO_646 (Item : in Character) return Boolean; function Is_ISO_646 (Item : in String) return Boolean; function To_ISO_646 (Item : in Character; Substitute : in ISO_646 := ' ') return ISO_646; function To_ISO_646 (Item : in String; Substitute : in ISO_646 := ' ') return String; -- The functions Is_Character, Is_String, To_Character, To_String, -- To_Wide_Character and To_Wide_String are obsolescent; see J.14. function Is_Character (Item : in Wide_Character) return Boolean renames Conversions.Is_Character; function Is_String (Item : in Wide_String) return Boolean renames Conversions.Is_String; function To_Character (Item : in Wide_Character; Substitute : in Character := ' ') return Character renames Conversions.To_Character; function To_String (Item : in Wide_String; Substitute : in Character := ' ') return String renames Conversions.To_String; function To_Wide_Character (Item : in Character) return Wide_Character renames Conversions.To_Wide_Character; function To_Wide_String (Item : in String) return Wide_String renames Conversions.To_Wide_String; end Ada.Characters.Handling;
-- Abstract : -- -- See spec. -- -- Copyright (C) 2018 - 2020 Free Software Foundation, Inc. -- -- This library is free software; you can redistribute it and/or modify it -- under terms of the GNU General Public License as published by the Free -- Software Foundation; either version 3, or (at your option) any later -- version. This library is distributed in the hope that it will be useful, -- but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHAN- -- TABILITY or FITNESS FOR A PARTICULAR PURPOSE. -- As a special exception under Section 7 of GPL version 3, you are granted -- additional permissions described in the GCC Runtime Library Exception, -- version 3.1, as published by the Free Software Foundation. pragma License (Modified_GPL); with Ada.Exceptions; with SAL.Gen_Bounded_Definite_Queues; with WisiToken.Parse.LR.McKenzie_Recover.Parse; with WisiToken.Parse.LR.Parser; package body WisiToken.Parse.LR.McKenzie_Recover.Explore is procedure Do_Shift (Label : in String; Super : not null access Base.Supervisor; Shared : not null access Base.Shared; Parser_Index : in SAL.Peek_Type; Local_Config_Heap : in out Config_Heaps.Heap_Type; Config : in out Configuration; State : in State_Index; ID : in Token_ID; Cost_Delta : in Integer; Strategy : in Strategies) is use Config_Op_Arrays; McKenzie_Param : McKenzie_Param_Type renames Shared.Table.McKenzie_Param; Op : constant Config_Op := (Insert, ID, Config.Current_Shared_Token); begin Config.Strategy_Counts (Strategy) := Config.Strategy_Counts (Strategy) + 1; if Is_Full (Config.Ops) then Super.Config_Full ("do_shift ops", Parser_Index); raise Bad_Config; else Append (Config.Ops, Op); end if; if Cost_Delta = 0 then Config.Cost := Config.Cost + McKenzie_Param.Insert (ID); else -- Cost_Delta /= 0 comes from Insert_Minimal_Complete_Actions. That -- doesn't mean it is better than any other solution, so don't let -- cost be 0. -- -- We don't just eliminate all cost for Minimal_Complete_Actions; -- that leads to using it far too much at the expense of better -- solutions. Config.Cost := Integer'Max (1, Config.Cost + McKenzie_Param.Insert (ID) + Cost_Delta); end if; Config.Error_Token.ID := Invalid_Token_ID; Config.Check_Status := (Label => WisiToken.Semantic_Checks.Ok); if Config.Stack.Is_Full then Super.Config_Full ("do_shift stack", Parser_Index); raise Bad_Config; else Config.Stack.Push ((State, Invalid_Node_Index, (ID, Virtual => True, others => <>))); end if; if Trace_McKenzie > Detail then Base.Put ((if Label'Length > 0 then Label & ": " else "") & "insert " & Image (ID, Super.Trace.Descriptor.all), Super, Shared, Parser_Index, Config); end if; Local_Config_Heap.Add (Config); end Do_Shift; procedure Do_Reduce_1 (Label : in String; Super : not null access Base.Supervisor; Shared : not null access Base.Shared; Parser_Index : in SAL.Peek_Type; Local_Config_Heap : in out Config_Heaps.Heap_Type; Config : in out Configuration; Action : in Reduce_Action_Rec; Do_Language_Fixes : in Boolean := True) is use all type Semantic_Checks.Check_Status_Label; use all type WisiToken.Parse.LR.Parser.Language_Fixes_Access; Prev_State : constant Unknown_State_Index := Config.Stack.Peek.State; Descriptor : WisiToken.Descriptor renames Super.Trace.Descriptor.all; Table : Parse_Table renames Shared.Table.all; Nonterm : Recover_Token; New_State : Unknown_State_Index; begin Config.Check_Status := Parse.Reduce_Stack (Shared, Config.Stack, Action, Nonterm, Default_Virtual => True); case Config.Check_Status.Label is when Ok => null; when Semantic_Checks.Error => Config.Error_Token := Nonterm; Config.Check_Token_Count := Action.Token_Count; if Do_Language_Fixes then if Shared.Language_Fixes /= null then Shared.Language_Fixes (Super.Trace.all, Shared.Lexer, Super.Label (Parser_Index), Shared.Table.all, Shared.Terminals.all, Super.Parser_State (Parser_Index).Tree, Local_Config_Heap, Config); end if; end if; -- Finish the reduce; ignore the check fail. if Config.Stack.Depth < SAL.Base_Peek_Type (Config.Check_Token_Count) then raise SAL.Programmer_Error; else Config.Stack.Pop (SAL.Base_Peek_Type (Config.Check_Token_Count)); end if; Config.Error_Token.ID := Invalid_Token_ID; Config.Check_Status := (Label => Ok); end case; if Config.Stack.Depth = 0 or else Config.Stack.Peek.State = Unknown_State then raise Bad_Config; end if; New_State := Goto_For (Table, Config.Stack.Peek.State, Action.Production.LHS); if New_State = Unknown_State then if Trace_McKenzie > Extra then Put_Line (Super.Trace.all, Super.Label (Parser_Index), Label & ": Do_Reduce_1: unknown_State " & Config.Stack.Peek.State'Image & " " & Image (Action.Production.LHS, Descriptor)); end if; raise Bad_Config; end if; Config.Stack.Push ((New_State, Invalid_Node_Index, Nonterm)); if Trace_McKenzie > Extra and Label'Length > 0 then Put_Line (Super.Trace.all, Super.Label (Parser_Index), Label & ": state" & State_Index'Image (Prev_State) & " reduce" & Ada.Containers.Count_Type'Image (Action.Token_Count) & " to " & Image (Action.Production.LHS, Descriptor) & ", goto" & State_Index'Image (New_State) & " via" & State_Index'Image (Config.Stack.Peek (2).State)); end if; end Do_Reduce_1; procedure Do_Reduce_2 (Label : in String; Super : not null access Base.Supervisor; Shared : not null access Base.Shared; Parser_Index : in SAL.Peek_Type; Local_Config_Heap : in out Config_Heaps.Heap_Type; Config : in out Configuration; Inserted_ID : in Token_ID; Cost_Delta : in Integer; Strategy : in Strategies) is -- Perform reduce actions until shift Inserted_ID; if all succeed, -- add the final configuration to the heap, return True. If a conflict is -- encountered, process the other action the same way. If a semantic -- check fails, enqueue possible solutions. For parse table error -- actions, or exception Bad_Config, return False. Orig_Config : Configuration; Table : Parse_Table renames Shared.Table.all; Next_Action : Parse_Action_Node_Ptr := Action_For (Table, Config.Stack.Peek.State, Inserted_ID); begin if Next_Action.Next /= null then Orig_Config := Config; end if; case Next_Action.Item.Verb is when Shift => Do_Shift (Label, Super, Shared, Parser_Index, Local_Config_Heap, Config, Next_Action.Item.State, Inserted_ID, Cost_Delta, Strategy); when Reduce => Do_Reduce_1 (Label, Super, Shared, Parser_Index, Local_Config_Heap, Config, Next_Action.Item); Do_Reduce_2 (Label, Super, Shared, Parser_Index, Local_Config_Heap, Config, Inserted_ID, Cost_Delta, Strategy); when Accept_It => raise SAL.Programmer_Error with "found test case for Do_Reduce Accept_It"; when Error => if Trace_McKenzie > Extra and Label'Length > 0 then Put_Line (Super.Trace.all, Super.Label (Parser_Index), Label & ": error on " & Image (Inserted_ID, Super.Trace.Descriptor.all) & " in state" & State_Index'Image (Config.Stack.Peek.State)); end if; end case; loop exit when Next_Action.Next = null; -- There is a conflict; create a new config to shift or reduce. declare New_Config : Configuration := Orig_Config; Action : Parse_Action_Rec renames Next_Action.Next.Item; begin case Action.Verb is when Shift => Do_Shift (Label, Super, Shared, Parser_Index, Local_Config_Heap, New_Config, Action.State, Inserted_ID, Cost_Delta, Strategy); when Reduce => Do_Reduce_1 (Label, Super, Shared, Parser_Index, Local_Config_Heap, New_Config, Action); Do_Reduce_2 (Label, Super, Shared, Parser_Index, Local_Config_Heap, New_Config, Inserted_ID, Cost_Delta, Strategy); when Accept_It => raise SAL.Programmer_Error with "found test case for Do_Reduce Accept_It conflict"; when Error => null; end case; end; Next_Action := Next_Action.Next; end loop; exception when Bad_Config => if Debug_Mode then raise; end if; end Do_Reduce_2; function Edit_Point_Matches_Ops (Config : in Configuration) return Boolean is use Config_Op_Arrays, Config_Op_Array_Refs; pragma Assert (Length (Config.Ops) > 0); Op : Config_Op renames Constant_Ref (Config.Ops, Last_Index (Config.Ops)); begin return Config.Current_Shared_Token = (case Op.Op is when Fast_Forward => Op.FF_Token_Index, when Undo_Reduce => Invalid_Token_Index, -- ie, "we don't know", so return False. when Push_Back => Op.PB_Token_Index, when Insert => Op.Ins_Token_Index, when Delete => Op.Del_Token_Index + 1); end Edit_Point_Matches_Ops; procedure Fast_Forward (Super : not null access Base.Supervisor; Shared : not null access Base.Shared; Parser_Index : in SAL.Base_Peek_Type; Local_Config_Heap : in out Config_Heaps.Heap_Type; Config : in Configuration) is -- Apply the ops in Config; they were inserted by some fix. -- Leaves Config.Error_Token, Config.Check_Status set. -- If there are conflicts, all are parsed; if more than one succeed. -- All configs are enqueued in Local_Config_Heap. use Parse.Parse_Item_Arrays; use Config_Op_Arrays; Parse_Items : aliased Parse.Parse_Item_Arrays.Vector; Dummy : Boolean := Parse.Parse (Super, Shared, Parser_Index, Parse_Items, Config, Shared_Token_Goal => Invalid_Token_Index, All_Conflicts => True, Trace_Prefix => "fast_forward"); begin -- This solution is from Language_Fixes (see gate on call site -- below); any cost increase is done there. -- -- We used to handle the Parse_Items.Length = 1 case specially, and -- return Continue. Maintaining that requires too much code -- duplication. for I in First_Index (Parse_Items) .. Last_Index (Parse_Items) loop declare Item : Parse.Parse_Item renames Parse.Parse_Item_Array_Refs.Variable_Ref (Parse_Items, I); begin if Item.Parsed and Item.Config.Current_Insert_Delete = No_Insert_Delete then -- Item.Config.Error_Token.ID, Check_Status are correct. if not Edit_Point_Matches_Ops (Item.Config) then if Is_Full (Item.Config.Ops) then Super.Config_Full ("fast_forward 1", Parser_Index); raise Bad_Config; else Append (Item.Config.Ops, (Fast_Forward, Item.Config.Current_Shared_Token)); end if; end if; Item.Config.Minimal_Complete_State := None; Item.Config.Matching_Begin_Done := False; Local_Config_Heap.Add (Item.Config); if Trace_McKenzie > Detail then Base.Put ("fast forward enqueue", Super, Shared, Parser_Index, Item.Config); end if; end if; exception when Bad_Config => null; end; end loop; end Fast_Forward; function Check (Super : not null access Base.Supervisor; Shared : not null access Base.Shared; Parser_Index : in SAL.Base_Peek_Type; Config : in out Configuration; Local_Config_Heap : in out Config_Heaps.Heap_Type) return Check_Status is use Config_Op_Arrays, Config_Op_Array_Refs; use Parse.Parse_Item_Arrays; use all type Semantic_Checks.Check_Status_Label; Parse_Items : aliased Parse.Parse_Item_Arrays.Vector; Result : Check_Status := Continue; begin if Length (Config.Ops) > 0 then declare Op : Config_Op renames Constant_Ref (Config.Ops, Last_Index (Config.Ops)); begin case Op.Op is when Push_Back => -- Check would undo the Push_Back, leading to -- duplicate results. See test_mckenzie_recover.adb Do_Delete_First and -- three_action_conflict_lalr.parse_good for examples. return Continue; when Undo_Reduce => if Config.Check_Status.Label /= Ok then -- This is the "ignore error" solution for a check fail; check it. Config.Check_Status := (Label => Ok); Config.Error_Token.ID := Invalid_Token_ID; else -- Check would undo the Undo_Reduce, leading to -- duplicate results. return Continue; end if; when others => -- Check it null; end case; end; end if; if Parse.Parse (Super, Shared, Parser_Index, Parse_Items, Config, Config.Resume_Token_Goal, All_Conflicts => False, Trace_Prefix => "check") then Config.Error_Token.ID := Invalid_Token_ID; -- FIXME: if there were conflicts, enqueue them; they might yield a -- cheaper or same cost solution? if Trace_McKenzie > Extra then Put_Line (Super.Trace.all, Super.Label (Parser_Index), "check result: SUCCESS"); end if; return Success; end if; -- Set Config.error to reflect failure, if it is at current token, so -- Use_Minimal_Complete_Actions can see it. declare Item : Parse.Parse_Item renames Parse.Parse_Item_Array_Refs.Constant_Ref (Parse_Items, First_Index (Parse_Items)); begin if Item.Config.Check_Status.Label /= Ok then Config.Check_Status := Item.Config.Check_Status; Config.Error_Token := Item.Config.Error_Token; -- Explore cannot fix a check fail; only Language_Fixes can. The -- "ignore error" case is handled immediately on return from -- Language_Fixes in Process_One, below. Result := Abandon; elsif Item.Config.Error_Token.ID /= Invalid_Token_ID then if Item.Shift_Count = 0 then Config.Error_Token := Item.Config.Error_Token; Config.Check_Status := (Label => Ok); else -- Error is not at current token, but Explore might find something -- that will help (see test_mckenzie_recover.adb Extra_Begin). On the -- other hand, this can lead to lots of bogus configs (see -- If_In_Handler). Config.Error_Token.ID := Invalid_Token_ID; Config.Check_Status := (Label => Ok); end if; end if; end; -- All Parse_Items either failed or were not parsed; if they failed -- and made progress, enqueue them. for I in First_Index (Parse_Items) .. Last_Index (Parse_Items) loop declare Item : Parse.Parse_Item renames Parse.Parse_Item_Array_Refs.Variable_Ref (Parse_Items, I); begin -- When Parse starts above, Config.Current_Shared_Token matches -- Config.Ops. So if Item.Config.Current_Shared_Token > -- Config.Current_Shared_Token, it made some progress. Append or -- update a Fast_Forward to indicate the changed edit point. if Item.Config.Error_Token.ID /= Invalid_Token_ID and Item.Config.Current_Shared_Token > Config.Current_Shared_Token then Item.Config.Minimal_Complete_State := None; Item.Config.Matching_Begin_Done := False; if Constant_Ref (Item.Config.Ops, Last_Index (Item.Config.Ops)).Op = Fast_Forward then -- Update the trailing Fast_Forward. Variable_Ref (Item.Config.Ops, Last_Index (Item.Config.Ops)).FF_Token_Index := Item.Config.Current_Shared_Token; else if Is_Full (Item.Config.Ops) then Super.Config_Full ("check 1", Parser_Index); raise Bad_Config; else Append (Item.Config.Ops, (Fast_Forward, Item.Config.Current_Shared_Token)); end if; end if; Local_Config_Heap.Add (Item.Config); if Trace_McKenzie > Detail then Base.Put ("new error point ", Super, Shared, Parser_Index, Item.Config); end if; end if; end; end loop; if Trace_McKenzie > Extra then Put_Line (Super.Trace.all, Super.Label (Parser_Index), "check result: " & Result'Image); end if; return Result; exception when Bad_Config => return Abandon; end Check; function Check_Reduce_To_Start (Super : not null access Base.Supervisor; Shared : not null access Base.Shared; Parser_Index : in SAL.Base_Peek_Type; Orig_Config : in Configuration) return Boolean -- Returns True if Config reduces to the start nonterm. is Table : Parse_Table renames Shared.Table.all; function To_Reduce_Action (Item : in Minimal_Action) return Reduce_Action_Rec is begin return (Reduce, Item.Production, null, null, Item.Token_Count); end To_Reduce_Action; Local_Config_Heap : Config_Heaps.Heap_Type; -- never used, because Do_Language_Fixes is False. Config : Configuration := Orig_Config; Actions : Minimal_Action_Arrays.Vector := Table.States (Config.Stack.Peek.State).Minimal_Complete_Actions; begin loop case Actions.Length is when 0 => if (for some Item of Table.States (Config.Stack.Peek.State).Kernel => Item.Production.LHS = Super.Trace.Descriptor.Accept_ID) then return True; else return False; end if; when 1 => case Actions (Actions.First_Index).Verb is when Shift => return False; when Reduce => Do_Reduce_1 ("", Super, Shared, Parser_Index, Local_Config_Heap, Config, To_Reduce_Action (Actions (Actions.First_Index)), Do_Language_Fixes => False); Actions := Table.States (Config.Stack.Peek.State).Minimal_Complete_Actions; end case; when others => return False; end case; -- loop only exits via returns above end loop; exception when Bad_Config => -- From Do_Reduce_1 return False; end Check_Reduce_To_Start; procedure Try_Push_Back (Super : not null access Base.Supervisor; Shared : not null access Base.Shared; Parser_Index : in SAL.Base_Peek_Type; Config : in Configuration; Local_Config_Heap : in out Config_Heaps.Heap_Type) is Trace : WisiToken.Trace'Class renames Super.Trace.all; McKenzie_Param : McKenzie_Param_Type renames Shared.Table.McKenzie_Param; Prev_Recover : constant WisiToken.Base_Token_Index := Super.Parser_State (Parser_Index).Resume_Token_Goal; Token : constant Recover_Token := Config.Stack.Peek.Token; begin -- Try pushing back the stack top, to allow insert and other -- operations at that point. -- -- Since we are not actually changing the source text, it is tempting -- to give this operation zero cost. But then we keep doing push_back -- forever, making no progress. So we give it a cost. if Token.Min_Terminal_Index /= Invalid_Token_Index and -- No point in pushing back an empty nonterm; that leads to duplicate -- solutions with Undo_Reduce; see test_mckenzie_recover.adb Error_2. (Prev_Recover = Invalid_Token_Index or else Prev_Recover < Token.Min_Terminal_Index) -- Don't push back past previous error recover (that would require -- keeping track of previous inserts/deletes, and would not be useful -- in most cases). then declare use Config_Op_Arrays; New_Config : Configuration := Config; begin New_Config.Error_Token.ID := Invalid_Token_ID; New_Config.Check_Status := (Label => WisiToken.Semantic_Checks.Ok); New_Config.Stack.Pop; if Is_Full (New_Config.Ops) then Super.Config_Full ("push_back 1", Parser_Index); raise Bad_Config; else if Token.Min_Terminal_Index = Invalid_Token_Index then -- Token is empty; Config.current_shared_token does not change, no -- cost increase. Append (New_Config.Ops, (Push_Back, Token.ID, New_Config.Current_Shared_Token)); else New_Config.Cost := New_Config.Cost + McKenzie_Param.Push_Back (Token.ID); Append (New_Config.Ops, (Push_Back, Token.ID, Token.Min_Terminal_Index)); New_Config.Current_Shared_Token := Token.Min_Terminal_Index; end if; end if; New_Config.Strategy_Counts (Push_Back) := New_Config.Strategy_Counts (Push_Back) + 1; Local_Config_Heap.Add (New_Config); if Trace_McKenzie > Detail then Base.Put ("push_back " & Image (Token.ID, Trace.Descriptor.all), Super, Shared, Parser_Index, New_Config); end if; end; end if; end Try_Push_Back; function Just_Pushed_Back_Or_Deleted (Config : in Configuration; ID : in Token_ID) return Boolean is use Config_Op_Arrays, Config_Op_Array_Refs; Last_Token_Index : WisiToken.Token_Index := Config.Current_Shared_Token; -- Index of token in last op checked. begin -- This function is called when considering whether to insert ID before -- Config.Current_Shared_Token. -- -- We need to consider more than one recent op here; see test_mckenzie_recover.adb -- Check_Multiple_Delete_For_Insert. Checking only one op allows this solution there: -- -- ... (DELETE, END, 7), (DELETE, SEMICOLON, 8), (INSERT, END, 9), (INSERT, SEMICOLON, 9) -- for I in reverse First_Index (Config.Ops) .. Last_Index (Config.Ops) loop declare Op : Config_Op renames Constant_Ref (Config.Ops, I); begin case Op.Op is when Push_Back => -- The case we are preventing for Push_Back is typically one of: -- (PUSH_BACK, Identifier, 2), (INSERT, Identifier, 2) -- (PUSH_BACK, Identifier, 2), (PUSH_BACK, END, 3), (INSERT, Identifier, 3), (INSERT, END, 3), if Op.PB_Token_Index = Last_Token_Index then if Op.PB_ID = ID then return True; else if Op.PB_Token_Index = WisiToken.Token_Index'First then return False; else Last_Token_Index := Op.PB_Token_Index - 1; end if; end if; else -- Op is at a different edit point. return False; end if; when Delete => if Op.Del_Token_Index = Last_Token_Index - 1 then if Op.Del_ID = ID then return True; else Last_Token_Index := Op.Del_Token_Index; end if; else -- Op is at a different edit point. return False; end if; when Fast_Forward | Insert | Undo_Reduce => return False; end case; end; end loop; return False; end Just_Pushed_Back_Or_Deleted; procedure Try_Undo_Reduce (Super : not null access Base.Supervisor; Shared : not null access Base.Shared; Parser_Index : in SAL.Base_Peek_Type; Config : in Configuration; Local_Config_Heap : in out Config_Heaps.Heap_Type) is use Config_Op_Arrays; Trace : WisiToken.Trace'Class renames Super.Trace.all; McKenzie_Param : McKenzie_Param_Type renames Shared.Table.McKenzie_Param; Token : constant Recover_Token := Config.Stack.Peek.Token; New_Config : Configuration := Config; Token_Count : Ada.Containers.Count_Type; begin -- Try expanding the nonterm on the stack top, to allow pushing_back -- its components, or insert and other operations at that point. New_Config.Error_Token.ID := Invalid_Token_ID; New_Config.Check_Status := (Label => WisiToken.Semantic_Checks.Ok); Token_Count := Undo_Reduce (New_Config.Stack, Super.Parser_State (Parser_Index).Tree); if Token.Min_Terminal_Index /= Invalid_Token_Index then -- If Token is empty no cost increase. New_Config.Cost := New_Config.Cost + McKenzie_Param.Undo_Reduce (Token.ID); end if; if Is_Full (New_Config.Ops) then Super.Config_Full ("undo_reduce 1", Parser_Index); raise Bad_Config; else Append (New_Config.Ops, (Undo_Reduce, Token.ID, Token_Count)); end if; New_Config.Strategy_Counts (Undo_Reduce) := New_Config.Strategy_Counts (Undo_Reduce) + 1; Local_Config_Heap.Add (New_Config); if Trace_McKenzie > Detail then Base.Put ("undo_reduce " & Image (Token.ID, Trace.Descriptor.all), Super, Shared, Parser_Index, New_Config); end if; end Try_Undo_Reduce; procedure Insert_From_Action_List (Super : not null access Base.Supervisor; Shared : not null access Base.Shared; Parser_Index : in SAL.Base_Peek_Type; Config : in Configuration; Minimal_Insert : in Token_ID_Arrays.Vector; Local_Config_Heap : in out Config_Heaps.Heap_Type) is Table : Parse_Table renames Shared.Table.all; EOF_ID : Token_ID renames Super.Trace.Descriptor.EOI_ID; Descriptor : WisiToken.Descriptor renames Super.Trace.Descriptor.all; -- Find terminal insertions from the current state's action_list to try. -- -- We perform any needed reductions and one shift, so the config is -- in a consistent state, and enqueue the result. If there are any -- conflicts or semantic check fails encountered, they create other -- configs to enqueue. Current_Token : constant Token_ID := Current_Token_ID_Peek (Shared.Terminals.all, Config.Current_Shared_Token, Config.Insert_Delete, Config.Current_Insert_Delete); Cached_Config : Configuration; Cached_Action : Reduce_Action_Rec; -- Most of the time, all the reductions in a state are the same. So -- we cache the first result. This includes one reduction; if an -- associated semantic check failed, this does not include the fixes. I : Parse_Action_Node_Ptr; begin for Node of Table.States (Config.Stack.Peek.State).Action_List loop I := Node.Actions; loop exit when I = null; declare ID : constant Token_ID := Node.Symbol; Action : Parse_Action_Rec renames I.Item; begin if ID /= EOF_ID and then -- can't insert eof ID /= Invalid_Token_ID -- invalid when Verb = Error then if Just_Pushed_Back_Or_Deleted (Config, ID) then if Trace_McKenzie > Extra then Put_Line (Super.Trace.all, Super.Label (Parser_Index), "Insert: abandon " & Image (ID, Descriptor) & ": undo push_back"); end if; elsif ID = Current_Token then -- This is needed because we allow explore when the error is not at -- the explore point; it prevents inserting useless tokens (ie -- 'identifier ;' in ada_lite). if Trace_McKenzie > Extra then Put_Line (Super.Trace.all, Super.Label (Parser_Index), "Insert: abandon " & Image (ID, Descriptor) & ": current token"); end if; elsif (for some Minimal of Minimal_Insert => ID = Minimal) then -- Was inserted by Insert_Minimal_Complete_Actions null; else case Action.Verb is when Shift => declare New_Config : Configuration := Config; begin Do_Shift ("Insert", Super, Shared, Parser_Index, Local_Config_Heap, New_Config, Action.State, ID, Cost_Delta => 0, Strategy => Insert); end; when Reduce => if not Equal (Action, Cached_Action) then declare New_Config : Configuration := Config; begin New_Config.Error_Token.ID := Invalid_Token_ID; New_Config.Check_Status := (Label => WisiToken.Semantic_Checks.Ok); Do_Reduce_1 ("Insert", Super, Shared, Parser_Index, Local_Config_Heap, New_Config, Action); Cached_Config := New_Config; Cached_Action := Action; Do_Reduce_2 ("Insert", Super, Shared, Parser_Index, Local_Config_Heap, New_Config, ID, Cost_Delta => 0, Strategy => Insert); end; else declare New_Config : Configuration := Cached_Config; begin Do_Reduce_2 ("Insert", Super, Shared, Parser_Index, Local_Config_Heap, New_Config, ID, Cost_Delta => 0, Strategy => Insert); end; end if; when Accept_It => raise SAL.Programmer_Error with "found test case for Process_One Accept_It"; when Error => null; end case; end if; end if; end; I := I.Next; end loop; end loop; end Insert_From_Action_List; function Insert_Minimal_Complete_Actions (Super : not null access Base.Supervisor; Shared : not null access Base.Shared; Parser_Index : in SAL.Base_Peek_Type; Orig_Config : in out Configuration; Local_Config_Heap : in out Config_Heaps.Heap_Type) return Token_ID_Arrays.Vector -- Return tokens inserted (empty if none). is use Ada.Containers; Table : Parse_Table renames Shared.Table.all; Descriptor : WisiToken.Descriptor renames Super.Trace.Descriptor.all; Inserted : Token_ID_Array (1 .. 10) := (others => Invalid_Token_ID); Inserted_Last : Integer := Inserted'First - 1; type Work_Item is record Action : Minimal_Action; Cost_Delta : Integer; Config : Configuration; end record; package Item_Queues is new SAL.Gen_Bounded_Definite_Queues (Work_Item); use Item_Queues; Work : Queue_Type (10); -- The required queue size depends on the number of multiple-item -- Minimal_Complete_Actions encountered. That is limited by compound -- statement nesting, and by the frequency of such actions. procedure Safe_Add_Work (Label : in String; Item : in Work_Item) is begin if Is_Full (Work) then Super.Config_Full ("Minimal_Complete_Actions " & Label, Parser_Index); raise Bad_Config; else Add (Work, Item); end if; end Safe_Add_Work; function To_Reduce_Action (Action : in Minimal_Action) return Reduce_Action_Rec is (Reduce, Action.Production, null, null, Action.Token_Count); procedure Minimal_Do_Shift (Action : in Minimal_Action; Cost_Delta : in Integer; Config : in out Configuration) is begin if Just_Pushed_Back_Or_Deleted (Config, Action.ID) then if Trace_McKenzie > Extra then Put_Line (Super.Trace.all, Super.Label (Parser_Index), "Minimal_Complete_Actions: abandon " & Image (Action.ID, Descriptor) & ": undo push back"); end if; else Config.Check_Status := (Label => WisiToken.Semantic_Checks.Ok); Config.Minimal_Complete_State := Active; Inserted_Last := Inserted_Last + 1; if Inserted_Last <= Inserted'Last then Inserted (Inserted_Last) := Action.ID; else Super.Config_Full ("minimal_do_shift Inserted", Parser_Index); raise Bad_Config; end if; Do_Shift ("Minimal_Complete_Actions", Super, Shared, Parser_Index, Local_Config_Heap, Config, Action.State, Action.ID, Cost_Delta, Strategy => Minimal_Complete); end if; end Minimal_Do_Shift; procedure Enqueue_Min_Actions (Label : in String; Actions : in Minimal_Action_Arrays.Vector; Config : in Configuration) is use SAL; Length : array (Actions.First_Index .. Actions.Last_Index) of Count_Type := (others => Count_Type'Last); Min_Length : Count_Type := Count_Type'Last; begin if Trace_McKenzie > Extra then Put_Line (Super.Trace.all, Super.Label (Parser_Index), "Minimal_Complete_Actions: " & Label & Image (Actions, Descriptor)); end if; if Actions.Length = 0 then return; elsif Actions.Length = 1 then Safe_Add_Work ("1", (Actions (Actions.First_Index), Table.McKenzie_Param.Minimal_Complete_Cost_Delta, Config)); return; end if; -- More than one minimal action in State; try to use next states and -- recursion to pick one. Actions_Loop : for I in Actions.First_Index .. Actions.Last_Index loop declare function Matches (Item : in Kernel_Info; Action : in Minimal_Action) return Boolean is begin case Action.Verb is when Shift => return Item.Before_Dot = Action.ID; when Reduce => return Item.Before_Dot = Action.Production.LHS; end case; end Matches; function Length_After_Dot (Item : in Kernel_Info; Action : in Minimal_Action; Stack : in Recover_Stacks.Stack) return Ada.Containers.Count_Type is Match_ID : Token_ID; New_Stack : Recover_Stacks.Stack := Stack; Next_State : Unknown_State_Index; Result : Ada.Containers.Count_Type; Min_Result : Ada.Containers.Count_Type := Ada.Containers.Count_Type'Last; begin case Action.Verb is when Shift => New_Stack.Push ((Action.State, Invalid_Node_Index, (ID => Action.ID, others => <>))); Next_State := Action.State; Match_ID := Action.ID; when Reduce => New_Stack.Pop (SAL.Base_Peek_Type (Action.Token_Count)); Next_State := Goto_For (Shared.Table.all, New_Stack.Peek.State, Action.Production.LHS); if Next_State = Unknown_State then -- We get here when Insert_From_Action_Table started us down a bad path raise Bad_Config; end if; New_Stack.Push ((Next_State, Invalid_Node_Index, (ID => Action.Production.LHS, others => <>))); Match_ID := Action.Production.LHS; end case; if Trace_McKenzie > Extra then Super.Trace.Put (Next_State'Image & " " & Trimmed_Image (Item.Production)); end if; for Item of Shared.Table.States (Next_State).Kernel loop if Item.Before_Dot = Match_ID then if Item.Length_After_Dot = 0 then Result := Length_After_Dot (Item, (Reduce, Item.Reduce_Production, Item.Reduce_Count), New_Stack); else Result := Item.Length_After_Dot; end if; end if; if Result < Min_Result then Min_Result := Result; end if; end loop; return Min_Result; end Length_After_Dot; Action : constant Minimal_Action := Actions (I); Next_State : constant State_Index := (case Action.Verb is when Shift => Action.State, when Reduce => Goto_For (Shared.Table.all, Config.Stack.Peek (Base_Peek_Type (Action.Token_Count) + 1).State, Action.Production.LHS)); begin if Trace_McKenzie > Extra then Super.Trace.Put ("task" & Task_Attributes.Value'Image & Super.Label (Parser_Index)'Image & ": Minimal_Complete_Actions: " & Image (Action, Descriptor)); end if; for Item of Shared.Table.States (Next_State).Kernel loop if Matches (Item, Action) then -- For Action.Verb = Reduce, more than one item may match if Item.Length_After_Dot = 0 then -- Set Length from a non-zero-length non-recursive item. Length (I) := Length_After_Dot (Item, Action, Config.Stack); elsif Item.Length_After_Dot < Length (I) then if Trace_McKenzie > Extra then -- Length_After_Dot outputs this in other branch Super.Trace.Put (Next_State'Image & " " & Trimmed_Image (Item.Production)); end if; Length (I) := Item.Length_After_Dot; end if; if Trace_McKenzie > Extra then Super.Trace.Put (" length" & Length (I)'Image); end if; if Length (I) < Min_Length then Min_Length := Length (I); end if; end if; end loop; if Trace_McKenzie > Extra then Super.Trace.New_Line; end if; end; end loop Actions_Loop; for I in Length'Range loop if Length (I) = Min_Length then Safe_Add_Work ("2", (Actions (I), Table.McKenzie_Param.Minimal_Complete_Cost_Delta, Config)); elsif Trace_McKenzie > Extra then Put_Line (Super.Trace.all, Super.Label (Parser_Index), "Minimal_Complete_Actions: drop " & Image (Actions (I), Descriptor) & " not minimal or recursive"); end if; end loop; end Enqueue_Min_Actions; begin if Orig_Config.Stack.Depth = 1 then -- Get here with an empty source file, or a syntax error on the first -- token. return Token_ID_Arrays.Empty_Vector; elsif Orig_Config.Minimal_Complete_State = Done then if Trace_McKenzie > Extra then Put_Line (Super.Trace.all, Super.Label (Parser_Index), "Minimal_Complete_Actions: done"); end if; return Token_ID_Arrays.Empty_Vector; end if; Enqueue_Min_Actions ("", Table.States (Orig_Config.Stack.Peek.State).Minimal_Complete_Actions, Orig_Config); loop exit when Is_Empty (Work); declare Item : Work_Item := Get (Work); begin if Trace_McKenzie > Extra then Put_Line (Super.Trace.all, Super.Label (Parser_Index), "Minimal_Complete_Actions: dequeue work item " & Image (Item.Action, Descriptor)); end if; case Item.Action.Verb is when Reduce => -- Do a reduce, look at resulting state. Keep reducing until we can't -- anymore. declare Reduce_Action : Reduce_Action_Rec := To_Reduce_Action (Item.Action); Actions : Minimal_Action_Arrays.Vector; begin loop Do_Reduce_1 ("Minimal_Complete_Actions", Super, Shared, Parser_Index, Local_Config_Heap, Item.Config, Reduce_Action, Do_Language_Fixes => False); Actions := Table.States (Item.Config.Stack.Peek.State).Minimal_Complete_Actions; case Actions.Length is when 0 => if Trace_McKenzie > Extra then Put_Line (Super.Trace.all, Super.Label (Parser_Index), "Minimal_Complete_Actions abandoned: no actions"); end if; exit; when 1 => case Actions (Actions.First_Index).Verb is when Shift => Minimal_Do_Shift (Actions (Actions.First_Index), Item.Cost_Delta, Item.Config); exit; when Reduce => Reduce_Action := To_Reduce_Action (Actions (Actions.First_Index)); end case; when others => Enqueue_Min_Actions ("multiple actions ", Actions, Item.Config); exit; end case; end loop; end; when Shift => Minimal_Do_Shift (Item.Action, Item.Cost_Delta, Item.Config); end case; end; end loop; if Inserted_Last = Inserted'First - 1 then -- Nothing inserted this round. if Orig_Config.Minimal_Complete_State = Active then Orig_Config.Minimal_Complete_State := Done; end if; end if; return To_Vector (Inserted (1 .. Inserted_Last)); exception when Bad_Config => return Token_ID_Arrays.Empty_Vector; end Insert_Minimal_Complete_Actions; procedure Insert_Matching_Begin (Super : not null access Base.Supervisor; Shared : not null access Base.Shared; Parser_Index : in SAL.Base_Peek_Type; Config : in Configuration; Local_Config_Heap : in out Config_Heaps.Heap_Type; Matching_Begin_Tokens : in Token_ID_Arrays.Vector) is Table : Parse_Table renames Shared.Table.all; Descriptor : WisiToken.Descriptor renames Super.Trace.Descriptor.all; begin -- We don't check for insert = current token; that's either ok or a -- severe bug in Shared.Language_Matching_Begin_Tokens. if Config.Matching_Begin_Done then if Trace_McKenzie > Extra then Put_Line (Super.Trace.all, Super.Label (Parser_Index), "Matching_Begin abandoned: done"); end if; return; end if; if Just_Pushed_Back_Or_Deleted (Config, Matching_Begin_Tokens (Matching_Begin_Tokens.First_Index)) then if Trace_McKenzie > Extra then Put_Line (Super.Trace.all, Super.Label (Parser_Index), "Matching_Begin abandoned " & Image (Matching_Begin_Tokens (Matching_Begin_Tokens.First_Index), Descriptor) & ": undo push_back"); end if; return; end if; declare New_Config : Configuration := Config; begin for ID of Matching_Begin_Tokens loop Insert (New_Config, ID); end loop; declare use Parse.Parse_Item_Arrays; Parse_Items : aliased Parse.Parse_Item_Arrays.Vector; Dummy : constant Boolean := Parse.Parse (Super, Shared, Parser_Index, Parse_Items, New_Config, Shared_Token_Goal => Invalid_Token_Index, All_Conflicts => True, Trace_Prefix => "parse Matching_Begin"); begin for I in First_Index (Parse_Items) .. Last_Index (Parse_Items) loop declare Item : Parse.Parse_Item renames Parse.Parse_Item_Array_Refs.Variable_Ref (Parse_Items, I); begin if Item.Parsed and Item.Config.Current_Insert_Delete = No_Insert_Delete then Item.Config.Matching_Begin_Done := True; Item.Config.Cost := Item.Config.Cost + Table.McKenzie_Param.Matching_Begin; Item.Config.Strategy_Counts (Matching_Begin) := Item.Config.Strategy_Counts (Matching_Begin) + 1; Item.Config.Error_Token.ID := Invalid_Token_ID; Item.Config.Check_Status := (Label => WisiToken.Semantic_Checks.Ok); if Trace_McKenzie > Detail then Base.Put ("Matching_Begin: insert " & Image (Matching_Begin_Tokens, Descriptor), Super, Shared, Parser_Index, Item.Config); end if; Local_Config_Heap.Add (Item.Config); else if Trace_McKenzie > Detail then Base.Put ("Matching_Begin: abandon " & Image (Matching_Begin_Tokens, Descriptor) & ": parse fail", Super, Shared, Parser_Index, Item.Config); end if; end if; end; end loop; end; end; exception when SAL.Container_Full => -- From config_ops_sorted Super.Config_Full ("Minimal_Complete_Actions 3", Parser_Index); end Insert_Matching_Begin; procedure Try_Insert_Terminal (Super : not null access Base.Supervisor; Shared : not null access Base.Shared; Parser_Index : in SAL.Base_Peek_Type; Config : in out Configuration; Local_Config_Heap : in out Config_Heaps.Heap_Type) is use all type WisiToken.Parse.LR.Parser.Language_Matching_Begin_Tokens_Access; Tokens : Token_ID_Array_1_3; Matching_Begin_Tokens : Token_ID_Arrays.Vector; Forbid_Minimal_Insert : Boolean := False; Minimal_Inserted : Token_ID_Arrays.Vector; begin if Shared.Language_Matching_Begin_Tokens /= null then Current_Token_ID_Peek_3 (Shared.Terminals.all, Config.Current_Shared_Token, Config.Insert_Delete, Config.Current_Insert_Delete, Tokens); Shared.Language_Matching_Begin_Tokens (Tokens, Config, Matching_Begin_Tokens, Forbid_Minimal_Insert); end if; if not Forbid_Minimal_Insert then -- See test_mckenzie_recover.adb Forbid_Minimal_Insert for rationale. Minimal_Inserted := Insert_Minimal_Complete_Actions (Super, Shared, Parser_Index, Config, Local_Config_Heap); end if; if Matching_Begin_Tokens.Length > 0 then Insert_Matching_Begin (Super, Shared, Parser_Index, Config, Local_Config_Heap, Matching_Begin_Tokens); end if; -- We always do all three; Insert_Minimal_Complete (unless -- Forbid_Minimal_Insert), Insert_Matching_Begin, -- Insert_From_Action_List; in general it's not possible to tell when -- one will be better (see test_mckenzie_recover.adb -- Always_Minimal_Complete, Always_Matching_Begin). -- Insert_From_Action_List does not insert the Minimal_Inserted tokens, -- and it will never insert the Matching_Begin_Tokens, so there is no -- duplication. Insert_From_Action_List will normally be more -- expensive. Insert_From_Action_List (Super, Shared, Parser_Index, Config, Minimal_Inserted, Local_Config_Heap); -- It is tempting to use the Goto_List to find nonterms to insert. -- But that can easily lead to error states, and it turns out to be -- not useful, especially if the grammar has been relaxed so most -- expressions and lists can be empty. exception when Bad_Config => null; end Try_Insert_Terminal; procedure Try_Insert_Quote (Super : not null access Base.Supervisor; Shared : not null access Base.Shared; Parser_Index : in SAL.Base_Peek_Type; Config : in out Configuration; Local_Config_Heap : in out Config_Heaps.Heap_Type) is use Config_Op_Arrays; use all type Parser.Language_String_ID_Set_Access; Descriptor : WisiToken.Descriptor renames Shared.Trace.Descriptor.all; Check_Limit : WisiToken.Token_Index renames Shared.Table.McKenzie_Param.Check_Limit; Current_Line : constant Line_Number_Type := Shared.Terminals.all (Config.Current_Shared_Token).Line; Lexer_Error_Token : Base_Token; function Recovered_Lexer_Error (Line : in Line_Number_Type) return Base_Token_Index is begin -- We are assuming the list of lexer errors is short, so binary -- search would not be significantly faster. for Err of reverse Shared.Lexer.Errors loop if Err.Recover_Token /= Invalid_Token_Index and then Shared.Terminals.all (Err.Recover_Token).Line = Line then return Err.Recover_Token; end if; end loop; return Invalid_Token_Index; end Recovered_Lexer_Error; Lexer_Error_Token_Index : constant Base_Token_Index := Recovered_Lexer_Error (Current_Line); function String_ID_Set (String_ID : in Token_ID) return Token_ID_Set is begin if Shared.Language_String_ID_Set = null then return (String_ID .. String_ID => True); else return Shared.Language_String_ID_Set (Descriptor, String_ID); end if; end String_ID_Set; procedure String_Literal_In_Stack (Label : in String; New_Config : in out Configuration; Matching : in SAL.Peek_Type; String_Literal_ID : in Token_ID) is Saved_Shared_Token : constant WisiToken.Token_Index := New_Config.Current_Shared_Token; Tok : Recover_Token; J : WisiToken.Token_Index; Parse_Items : aliased Parse.Parse_Item_Arrays.Vector; begin -- Matching is the index of a token on New_Config.Stack containing a string -- literal. Push back thru that token, then delete all tokens after -- the string literal to Saved_Shared_Token. if not Has_Space (New_Config.Ops, Ada.Containers.Count_Type (Matching)) then Super.Config_Full ("insert quote 1 " & Label, Parser_Index); raise Bad_Config; end if; for I in 1 .. Matching loop if Push_Back_Valid (New_Config) then Tok := New_Config.Stack.Pop.Token; Append (New_Config.Ops, (Push_Back, Tok.ID, Tok.Min_Terminal_Index)); else -- Probably pushing back thru a previously inserted token raise Bad_Config; end if; end loop; New_Config.Current_Shared_Token := Tok.Min_Terminal_Index; -- Find last string literal in pushed back terminals. J := Saved_Shared_Token - 1; loop exit when Shared.Terminals.all (J).ID = String_Literal_ID; J := J - 1; end loop; begin if Parse.Parse (Super, Shared, Parser_Index, Parse_Items, New_Config, Shared_Token_Goal => J, All_Conflicts => False, Trace_Prefix => "insert quote parse pushback " & Label) then -- The non-deleted tokens parsed without error. We don't care if any -- conflicts were encountered; we are not using the parse result. New_Config := Parse.Parse_Item_Array_Refs.Constant_Ref (Parse_Items, 1).Config; Append (New_Config.Ops, (Fast_Forward, New_Config.Current_Shared_Token)); else raise SAL.Programmer_Error; end if; exception when Bad_Config => raise SAL.Programmer_Error; end; if New_Config.Current_Shared_Token < Saved_Shared_Token - 1 and then (not Has_Space (New_Config.Ops, Ada.Containers.Count_Type (Saved_Shared_Token - 1 - New_Config.Current_Shared_Token))) then Super.Config_Full ("insert quote 2 " & Label, Parser_Index); raise Bad_Config; end if; for J in New_Config.Current_Shared_Token .. Saved_Shared_Token - 1 loop Append (New_Config.Ops, (Delete, Shared.Terminals.all (J).ID, J)); end loop; New_Config.Current_Shared_Token := Saved_Shared_Token; end String_Literal_In_Stack; procedure Push_Back_Tokens (Full_Label : in String; New_Config : in out Configuration; Min_Pushed_Back_Index : out Base_Token_Index) is Item : Recover_Stack_Item; begin loop Item := New_Config.Stack.Peek; if Item.Token.Virtual then -- Don't push back an inserted token exit; elsif Item.Token.Byte_Region = Null_Buffer_Region then -- Don't need push_back for an empty token New_Config.Stack.Pop; elsif Item.Tree_Index = Invalid_Node_Index then -- Item was pushed on stack during recovery, and we do not know -- its Line. To avoid crossing a line boundary, we stop push_backs -- here. exit; else if Shared.Terminals.all (Super.Parser_State (Parser_Index).Tree.First_Shared_Terminal (Item.Tree_Index)).Line = Current_Line -- Don't let push_back cross a line boundary. then if Is_Full (New_Config.Ops) then Super.Config_Full (Full_Label, Parser_Index); raise Bad_Config; else New_Config.Stack.Pop; Append (New_Config.Ops, (Push_Back, Item.Token.ID, Item.Token.Min_Terminal_Index)); end if; end if; exit; end if; end loop; Min_Pushed_Back_Index := Item.Token.Min_Terminal_Index; end Push_Back_Tokens; procedure Finish (Label : in String; New_Config : in out Configuration; First, Last : in Base_Token_Index) is Adj_First : constant Base_Token_Index := (if First = Invalid_Token_Index then Last else First); Adj_Last : constant Base_Token_Index := (if Last = Invalid_Token_Index then First else Last); begin -- Delete tokens First .. Last; either First - 1 or Last + 1 should -- be a String_Literal. Leave Current_Shared_Token at Last + 1. if Adj_Last = Invalid_Token_Index or Adj_First = Invalid_Token_Index then pragma Assert (False); raise Bad_Config; end if; New_Config.Error_Token.ID := Invalid_Token_ID; New_Config.Check_Status := (Label => WisiToken.Semantic_Checks.Ok); -- This is a guess, so we give it a nominal cost New_Config.Cost := New_Config.Cost + 1; if not Has_Space (New_Config.Ops, Ada.Containers.Count_Type (Last - First)) then Super.Config_Full ("insert quote 3 " & Label, Parser_Index); raise Bad_Config; end if; for I in Adj_First .. Adj_Last loop Append (New_Config.Ops, (Delete, Shared.Terminals.all (I).ID, I)); end loop; New_Config.Current_Shared_Token := Last + 1; -- Let explore do insert after these deletes. Append (New_Config.Ops, (Fast_Forward, New_Config.Current_Shared_Token)); if New_Config.Resume_Token_Goal - Check_Limit < New_Config.Current_Shared_Token then New_Config.Resume_Token_Goal := New_Config.Current_Shared_Token + Check_Limit; if Trace_McKenzie > Extra then Put_Line (Super.Trace.all, Super.Label (Parser_Index), "resume_token_goal:" & WisiToken.Token_Index'Image (New_Config.Resume_Token_Goal)); end if; end if; New_Config.Strategy_Counts (String_Quote) := New_Config.Strategy_Counts (String_Quote) + 1; if Trace_McKenzie > Detail then Base.Put ("insert quote " & Label & " ", Super, Shared, Parser_Index, New_Config); end if; end Finish; begin -- When the lexer finds an unbalanced quote, it inserts a virtual -- balancing quote at the same character position as the unbalanced -- quote, returning an empty string literal token there. The parser -- does not see that as an error; it encounters a syntax error -- before, at, or after that string literal. -- -- Here we assume the parse error in Config.Error_Token is due to -- putting the balancing quote in the wrong place (although we do -- check that; see test_mckenzie_recover.adb String_Quote_6), and -- attempt to find a better place to put the balancing quote. Then -- all tokens from the balancing quote to the unbalanced quote are -- now part of a string literal, so delete them, leaving just the -- string literal created by Lexer error recovery. -- First we check to see if there is an unbalanced quote in the -- current line; if not, just return. Some lexer errors are for other -- unrecognized characters; see ada_mode-recover_bad_char.adb. -- -- An alternate strategy is to treat the lexer error as a parse error -- immediately, but that complicates the parse logic. Config.String_Quote_Checked := Current_Line; if Lexer_Error_Token_Index = Invalid_Token_Index then return; end if; Lexer_Error_Token := Shared.Terminals.all (Lexer_Error_Token_Index); -- It is not possible to tell where the best place to put the -- balancing quote is, so we always try all reasonable places. if Lexer_Error_Token.Byte_Region.First = Config.Error_Token.Byte_Region.First then -- The parse error token is the string literal at the lexer error. -- -- case a: Insert the balancing quote somewhere before the error -- point. There is no way to tell how far back to put the balancing -- quote, so we just do one non-empty token. See -- test_mckenzie_recover.adb String_Quote_0. So far we have not found -- a test case for more than one token. declare New_Config : Configuration := Config; Min_Pushed_Back_Index : Base_Token_Index; begin Push_Back_Tokens ("insert quote 4 a", New_Config, Min_Pushed_Back_Index); Finish ("a", New_Config, Min_Pushed_Back_Index, Config.Current_Shared_Token - 1); Local_Config_Heap.Add (New_Config); end; -- Note that it is not reasonable to insert a quote after the error -- in this case. If that were the right solution, the parser error -- token would not be the lexer repaired string literal, since a -- string literal would be legal here. elsif Lexer_Error_Token.Byte_Region.First < Config.Error_Token.Byte_Region.First then -- The unbalanced quote is before the parse error token; see -- test_mckenzie_recover.adb String_Quote_2. -- -- The missing quote belongs after the parse error token, before or -- at the end of the current line; try inserting it at the end of -- the current line. -- -- The lexer repaired string literal may be in a reduced token on the -- stack. declare Matching : SAL.Peek_Type := 1; begin Find_Descendant_ID (Super.Parser_State (Parser_Index).Tree, Config, Lexer_Error_Token.ID, String_ID_Set (Lexer_Error_Token.ID), Matching); if Matching = Config.Stack.Depth then -- String literal is in a virtual nonterm; give up. So far this only -- happens in a high cost non critical config. if Trace_McKenzie > Detail then Put_Line (Super.Trace.all, Super.Label (Parser_Index), "insert quote b abandon; string literal in virtual"); end if; return; end if; declare New_Config : Configuration := Config; begin String_Literal_In_Stack ("b", New_Config, Matching, Lexer_Error_Token.ID); Finish ("b", New_Config, Config.Current_Shared_Token, Shared.Line_Begin_Token.all (Current_Line + 1) - 1); Local_Config_Heap.Add (New_Config); end; end; else -- The unbalanced quote is after the parse error token. -- case c: Assume a missing quote belongs immediately before the current token. -- See test_mckenzie_recover.adb String_Quote_3. declare New_Config : Configuration := Config; begin Finish ("c", New_Config, Config.Current_Shared_Token, Lexer_Error_Token_Index - 1); Local_Config_Heap.Add (New_Config); exception when Bad_Config => null; end; -- case d: Assume a missing quote belongs somewhere farther before -- the current token; try one non-empty (as in case a above). See -- test_mckenzie_recover.adb String_Quote_4, String_Quote_6. declare New_Config : Configuration := Config; Min_Pushed_Back_Index : Base_Token_Index; begin Push_Back_Tokens ("insert quote 5 d", New_Config, Min_Pushed_Back_Index); Finish ("d", New_Config, Min_Pushed_Back_Index, Lexer_Error_Token_Index - 1); Local_Config_Heap.Add (New_Config); exception when SAL.Container_Empty => -- From Stack.Pop null; when Bad_Config => null; end; -- case e: Assume the actual error is an extra quote that terminates -- an intended string literal early, in which case there is a token -- on the stack containing the string literal that should be extended -- to the found quote. See test_mckenzie_recover.adb String_Quote_1. declare Matching : SAL.Peek_Type := 1; begin -- Lexer_Error_Token is a string literal; find a matching one. Find_Descendant_ID (Super.Parser_State (Parser_Index).Tree, Config, Lexer_Error_Token.ID, String_ID_Set (Lexer_Error_Token.ID), Matching); if Matching = Config.Stack.Depth then -- No matching string literal, so this case does not apply. null; else declare New_Config : Configuration := Config; begin String_Literal_In_Stack ("e", New_Config, Matching, Lexer_Error_Token.ID); Finish ("e", New_Config, Config.Current_Shared_Token, Lexer_Error_Token_Index); Local_Config_Heap.Add (New_Config); end; end if; end; end if; exception when Bad_Config => null; end Try_Insert_Quote; procedure Try_Delete_Input (Super : not null access Base.Supervisor; Shared : not null access Base.Shared; Parser_Index : in SAL.Base_Peek_Type; Config : in Configuration; Local_Config_Heap : in out Config_Heaps.Heap_Type) is -- Try deleting (= skipping) the current shared input token. use Config_Op_Arrays, Config_Op_Array_Refs; Trace : WisiToken.Trace'Class renames Super.Trace.all; EOF_ID : Token_ID renames Trace.Descriptor.EOI_ID; Check_Limit : WisiToken.Token_Index renames Shared.Table.McKenzie_Param.Check_Limit; McKenzie_Param : McKenzie_Param_Type renames Shared.Table.McKenzie_Param; ID : constant Token_ID := Shared.Terminals.all (Config.Current_Shared_Token).ID; begin if ID /= EOF_ID and then -- can't delete EOF (Length (Config.Ops) = 0 or else -- Don't delete an ID we just inserted; waste of time (not Equal (Constant_Ref (Config.Ops, Last_Index (Config.Ops)), (Insert, ID, Config.Current_Shared_Token)))) then declare New_Config : Configuration := Config; function Matching_Push_Back return Boolean is begin for I in reverse First_Index (New_Config.Ops) .. Last_Index (New_Config.Ops) loop declare Op : Config_Op renames Config_Op_Array_Refs.Variable_Ref (New_Config.Ops, I).Element.all; begin exit when not (Op.Op in Undo_Reduce | Push_Back | Delete); if Op = (Push_Back, ID, New_Config.Current_Shared_Token) then return True; end if; end; end loop; return False; end Matching_Push_Back; begin New_Config.Error_Token.ID := Invalid_Token_ID; New_Config.Check_Status := (Label => WisiToken.Semantic_Checks.Ok); New_Config.Cost := New_Config.Cost + McKenzie_Param.Delete (ID); New_Config.Strategy_Counts (Delete) := Config.Strategy_Counts (Delete) + 1; if Matching_Push_Back then -- We are deleting a push_back; cancel the push_back cost, to make -- this the same as plain deleting. New_Config.Cost := Natural'Max (Natural'First, New_Config.Cost - McKenzie_Param.Push_Back (ID)); end if; if Is_Full (New_Config.Ops) then Super.Config_Full ("delete", Parser_Index); raise Bad_Config; else Append (New_Config.Ops, (Delete, ID, Config.Current_Shared_Token)); end if; New_Config.Current_Shared_Token := New_Config.Current_Shared_Token + 1; if New_Config.Resume_Token_Goal - Check_Limit < New_Config.Current_Shared_Token then New_Config.Resume_Token_Goal := New_Config.Current_Shared_Token + Check_Limit; end if; Local_Config_Heap.Add (New_Config); if Trace_McKenzie > Detail then Base.Put ("delete " & Image (ID, Trace.Descriptor.all), Super, Shared, Parser_Index, New_Config); end if; end; end if; end Try_Delete_Input; procedure Process_One (Super : not null access Base.Supervisor; Shared : not null access Base.Shared; Config_Status : out Base.Config_Status) is -- Get one config from Super, check to see if it is a viable -- solution. If not, enqueue variations to check. use all type Base.Config_Status; use all type Parser.Language_Fixes_Access; use all type Semantic_Checks.Check_Status_Label; Trace : WisiToken.Trace'Class renames Super.Trace.all; Descriptor : WisiToken.Descriptor renames Super.Trace.Descriptor.all; Table : Parse_Table renames Shared.Table.all; Parser_Index : SAL.Base_Peek_Type; Config : Configuration; Local_Config_Heap : Config_Heaps.Heap_Type; -- We collect all the variants to enqueue, then deliver them all at -- once to Super, to minimizes task interactions. begin Super.Get (Parser_Index, Config, Config_Status); if Config_Status = All_Done then return; end if; if Trace_McKenzie > Detail then Base.Put ("dequeue", Super, Shared, Parser_Index, Config); if Trace_McKenzie > Extra then Put_Line (Trace, Super.Label (Parser_Index), "stack: " & Image (Config.Stack, Trace.Descriptor.all)); end if; end if; -- Fast_Forward; parse Insert, Delete in Config.Ops that have not -- been parsed yet. 'parse' here means adjusting Config.Stack and -- Current_Terminal_Index. Code in this file always parses when -- adding ops to Config (except as noted); Language_Fixes should use -- McKenzie_Recover.Insert, Delete instead. if Config.Current_Insert_Delete = 1 then -- Config is from Language_Fixes. Fast_Forward (Super, Shared, Parser_Index, Local_Config_Heap, Config); Super.Put (Parser_Index, Local_Config_Heap); return; end if; pragma Assert (Config.Current_Insert_Delete = 0); -- Config.Current_Insert_Delete > 1 is a programming error. if Config.Error_Token.ID /= Invalid_Token_ID then if Shared.Language_Fixes = null then null; else Shared.Language_Fixes (Trace, Shared.Lexer, Super.Label (Parser_Index), Shared.Table.all, Shared.Terminals.all, Super.Parser_State (Parser_Index).Tree, Local_Config_Heap, Config); -- The solutions enqueued by Language_Fixes should be lower cost than -- others (typically 0), so they will be checked first. end if; if Config.Check_Status.Label = Ok then -- Parse table Error action. -- -- We don't clear Config.Error_Token here, because -- Language_Use_Minimal_Complete_Actions needs it. We only clear it -- when a parse results in no error (or a different error), or a -- push_back moves the Current_Token. null; else -- Assume "ignore check error" is a viable solution. But give it a -- cost, so a solution provided by Language_Fixes is preferred. declare New_State : Unknown_State_Index; begin Config.Cost := Config.Cost + Table.McKenzie_Param.Ignore_Check_Fail; Config.Strategy_Counts (Ignore_Error) := Config.Strategy_Counts (Ignore_Error) + 1; -- finish reduce. Config.Stack.Pop (SAL.Base_Peek_Type (Config.Check_Token_Count)); New_State := Goto_For (Table, Config.Stack.Peek.State, Config.Error_Token.ID); if New_State = Unknown_State then if Config.Stack.Depth = 1 then -- Stack is empty, and we did not get Accept; really bad syntax got -- us here; abandon this config. See ada_mode-recover_bad_char.adb. Super.Put (Parser_Index, Local_Config_Heap); return; else raise SAL.Programmer_Error with "process_one found test case for new_state = Unknown; old state " & Trimmed_Image (Config.Stack.Peek.State) & " nonterm " & Image (Config.Error_Token.ID, Trace.Descriptor.all); end if; end if; Config.Stack.Push ((New_State, Invalid_Node_Index, Config.Error_Token)); -- We _don't_ clear Check_Status and Error_Token here; Check needs -- them, and sets them as appropriate. end; end if; end if; -- Call Check to see if this config succeeds. case Check (Super, Shared, Parser_Index, Config, Local_Config_Heap) is when Success => Super.Success (Parser_Index, Config, Local_Config_Heap); return; when Abandon => Super.Put (Parser_Index, Local_Config_Heap); return; when Continue => null; end case; if Trace_McKenzie > Detail then Base.Put ("continuing", Super, Shared, Parser_Index, Config); if Trace_McKenzie > Extra then Put_Line (Trace, Super.Label (Parser_Index), "stack: " & Image (Config.Stack, Trace.Descriptor.all)); end if; end if; -- Grouping these operations (push_back, delete, insert) ensures that -- there are no duplicate solutions found. We reset the grouping -- after each fast_forward. -- -- We do delete before insert so Insert_Matching_Begin can operate on -- the new next token, before Fast_Forwarding past it. -- -- All possible permutations will be explored. pragma Assert (Config.Stack.Depth > 0); Try_Insert_Terminal (Super, Shared, Parser_Index, Config, Local_Config_Heap); if Push_Back_Valid (Config) and then (not Check_Reduce_To_Start (Super, Shared, Parser_Index, Config)) -- If Config reduces to the start nonterm, there's no point in Push_Back or Undo_Reduce. then Try_Push_Back (Super, Shared, Parser_Index, Config, Local_Config_Heap); if Undo_Reduce_Valid (Config.Stack, Super.Parser_State (Parser_Index).Tree) then Try_Undo_Reduce (Super, Shared, Parser_Index, Config, Local_Config_Heap); end if; end if; if None_Since_FF (Config.Ops, Insert) then Try_Delete_Input (Super, Shared, Parser_Index, Config, Local_Config_Heap); end if; -- This is run once per input line, independent of what other ops -- have been done. if Config.Check_Status.Label = Ok and (Descriptor.String_1_ID /= Invalid_Token_ID or Descriptor.String_2_ID /= Invalid_Token_ID) and (Config.String_Quote_Checked = Invalid_Line_Number or else Config.String_Quote_Checked < Shared.Terminals.all (Config.Current_Shared_Token).Line) then -- See if there is a mismatched quote. The solution is to delete -- tokens, nominally replacing them with an expanded string literal. -- So we try this when it is ok to try delete. if None_Since_FF (Config.Ops, Insert) then Try_Insert_Quote (Super, Shared, Parser_Index, Config, Local_Config_Heap); end if; end if; Super.Put (Parser_Index, Local_Config_Heap); exception when Bad_Config => -- Just abandon this config; tell Super we are done. Super.Put (Parser_Index, Local_Config_Heap); when E : others => Super.Put (Parser_Index, Local_Config_Heap); if Debug_Mode then raise; elsif Trace_McKenzie > Outline then Put_Line (Super.Trace.all, Super.Label (Parser_Index), "Process_One: unhandled exception " & Ada.Exceptions.Exception_Name (E) & ": " & Ada.Exceptions.Exception_Message (E)); end if; end Process_One; end WisiToken.Parse.LR.McKenzie_Recover.Explore;
------------------------------------------------------------------------------ -- -- -- Copyright (C) 2020, AdaCore -- -- -- -- Redistribution and use in source and binary forms, with or without -- -- modification, are permitted provided that the following conditions are -- -- met: -- -- 1. Redistributions of source code must retain the above copyright -- -- notice, this list of conditions and the following disclaimer. -- -- 2. Redistributions in binary form must reproduce the above copyright -- -- notice, this list of conditions and the following disclaimer in -- -- the documentation and/or other materials provided with the -- -- distribution. -- -- 3. Neither the name of the copyright holder nor the names of its -- -- contributors may be used to endorse or promote products derived -- -- from this software without specific prior written permission. -- -- -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS -- -- "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT -- -- LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR -- -- A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT -- -- HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, -- -- SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT -- -- LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, -- -- DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY -- -- THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT -- -- (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE -- -- OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. -- -- -- ------------------------------------------------------------------------------ with STM32.GPIO; use STM32.GPIO; with STM32.SPI; use STM32.SPI; with STM32.Device; use STM32.Device; with STM32_H405; use STM32_H405; with HAL.Bitmap; use HAL.Bitmap; with HAL.SPI; use HAL.SPI; with PCD8544; use PCD8544; with Ravenscar_Time; procedure LCD_Test is procedure Configure_GPIO; procedure Configure_SPI; LCD_SPI : STM32.SPI.SPI_Port renames SPI_2; LCD_CLK : GPIO_Point renames EXT2_16; LCD_DIN : GPIO_Point renames EXT2_19; LCD_RST : GPIO_Point renames EXT2_9; LCD_CS : GPIO_Point renames EXT2_17; LCD_DC : GPIO_Point renames EXT2_2; procedure Configure_GPIO is begin Enable_Clock (LCD_DIN & LCD_CLK & LCD_RST & LCD_DC & LCD_CS); Configure_IO (LCD_RST & LCD_DC & LCD_CS, (Resistors => Pull_Up, Mode => Mode_Out, Output_Type => Push_Pull, Speed => Speed_25MHz)); Configure_IO (LCD_DIN & LCD_CLK, (Resistors => Pull_Up, Mode => Mode_AF, AF_Output_Type => Push_Pull, AF_Speed => Speed_25MHz, AF => GPIO_AF_SPI2_5)); end Configure_GPIO; procedure Configure_SPI is begin Enable_Clock (LCD_SPI); Configure (LCD_SPI, (Direction => D2Lines_FullDuplex, Mode => Master, Data_Size => Data_Size_8b, Clock_Polarity => High, Clock_Phase => P2Edge, Slave_Management => Software_Managed, Baud_Rate_Prescaler => BRP_8, First_Bit => MSB, CRC_Poly => 0)); Enable (LCD_SPI); end Configure_SPI; Display : PCD8544_Device (Port => LCD_SPI'Access, RST => LCD_RST'Access, CS => LCD_CS'Access, DC => LCD_DC'Access, Time => Ravenscar_Time.Delays); Bitmap : Any_Bitmap_Buffer; Cursor : Rect := (Position => (0, 0), Width => 8, Height => 8); begin Configure_GPIO; Configure_SPI; Display.Initialize; Display.Initialize_Layer (Layer => 1, Mode => M_1, X => 0, Y => 0, Width => Display.Width, Height => Display.Height); Bitmap := Display.Hidden_Buffer (1); loop for X in 0 .. ((Display.Width / Cursor.Width) - 1) loop for Y in 0 .. ((Display.Height / Cursor.Height) - 1) loop Bitmap.Set_Source (White); Bitmap.Fill; Cursor.Position := (X * Cursor.Width, Y * Cursor.Height); Bitmap.Set_Source (Black); Bitmap.Fill_Rect (Cursor); Display.Update_Layers; delay 0.250; end loop; end loop; end loop; end LCD_Test;
with FLTK.Widgets.Groups.Windows; package FLTK.Devices.Surfaces.Copy is type Copy_Surface is new Surface_Device with private; type Copy_Surface_Reference (Data : not null access Copy_Surface'Class) is limited null record with Implicit_Dereference => Data; package Forge is function Create (W, H : in Natural) return Copy_Surface; end Forge; function Get_W (This : in Copy_Surface) return Integer; function Get_H (This : in Copy_Surface) return Integer; procedure Draw_Widget (This : in out Copy_Surface; Item : in FLTK.Widgets.Widget'Class; Offset_X, Offset_Y : in Integer := 0); procedure Draw_Decorated_Window (This : in out Copy_Surface; Item : in FLTK.Widgets.Groups.Windows.Window'Class; Offset_X, Offset_Y : in Integer := 0); procedure Set_Current (This : in out Copy_Surface); private type Copy_Surface is new Surface_Device with null record; overriding procedure Finalize (This : in out Copy_Surface); pragma Inline (Get_W); pragma Inline (Get_H); pragma Inline (Draw_Widget); pragma Inline (Draw_Decorated_Window); pragma Inline (Set_Current); end FLTK.Devices.Surfaces.Copy;
generic package Ada_Lapack.Extras is ---------------------------------------------------------------------------------- -- Some extra procedures built upon the Lapack routines. -- determinants of a square marix ------------------------------------------------ function MatrixDeterm (Source : Real_Matrix) return Real; function MatrixDeterm (Source : Complex_Matrix) return Complex; -- eigenvalues of a square matrix ------------------------------------------------ function Eigenvalues (Source : Real_Matrix) return Complex_vector; function Eigenvalues (Source : Complex_Matrix) return Complex_vector; function EigenvaluesRealSymm (Source : Real_Matrix) return Real_Vector; function EigenvaluesHermSymm (Source : Complex_Matrix) return Real_Vector; -- eigenvalues and (right) eigenvectors of a square matrix ----------------------- procedure Eigensystem (Source : Real_Matrix; Eigenvalues : out Complex_Vector; Eigenvectors : out Complex_Matrix); procedure Eigensystem (Source : Complex_Matrix; Eigenvalues : out Complex_Vector; Eigenvectors : out Complex_Matrix); procedure EigensystemRealSymm (Source : Real_Matrix; Eigenvalues : out Real_Vector; Eigenvectors : out Real_Matrix); procedure EigensystemHermSymm (Source : Complex_Matrix; Eigenvalues : out Real_Vector; Eigenvectors : out Complex_Matrix); -- inverse of a square matrix ---------------------------------------------------- function MatrixInverse (Source : Real_Matrix) return Real_Matrix; function MatrixInverse (Source : Complex_Matrix) return Complex_Matrix; -- solutions of linear systems of equations -------------------------------------- function SolveSystem (Source_mat : Real_Matrix; Source_rhs : Real_Vector) return Real_Vector; function SolveSystem (Source_mat : Complex_Matrix; Source_rhs : Complex_Vector) return Complex_Vector; function SolveSystem (Source_mat : Real_Matrix; Source_rhs : Real_Matrix) return Real_Matrix; function SolveSystem (Source_mat : Complex_Matrix; Source_rhs : Complex_Matrix) return Complex_Matrix; function SolveSystemRealSymm (Source_mat : Real_Matrix; Source_rhs : Real_Matrix) return Real_Matrix; function SolveSystemHermSymm (Source_mat : Complex_Matrix; Source_rhs : Complex_Matrix) return Complex_Matrix; procedure SolveSystem (Solution : out Real_Vector; Source_mat : Real_Matrix; Source_rhs : Real_Vector; Size : Integer); procedure SolveSystem (Solution : out Complex_Vector; Source_mat : Complex_Matrix; Source_rhs : Complex_Vector; Size : Integer); end Ada_Lapack.Extras;
with Rejuvenation.Match_Patterns; use Rejuvenation.Match_Patterns; with Rejuvenation.Node_Locations; use Rejuvenation.Node_Locations; with Rejuvenation.Patterns; use Rejuvenation.Patterns; with Rejuvenation.Text_Rewrites; use Rejuvenation.Text_Rewrites; package Rejuvenation.Find_And_Replacer is function Accept_All_Matches (Match : Match_Pattern) return Boolean; procedure Find_And_Replace (TR : in out Text_Rewrite'Class; Node : Ada_Node'Class; Find_Pattern, Replace_Pattern : Pattern; Accept_Match : not null access function (Match : Match_Pattern) return Boolean := Accept_All_Matches'Access; Before, After : Node_Location := No_Trivia); function Find_And_Replace (File_Path : String; Find_Pattern, Replace_Pattern : Pattern; Accept_Match : not null access function (Match : Match_Pattern) return Boolean := Accept_All_Matches'Access; Before, After : Node_Location := No_Trivia) return Boolean; -- Find instances of the given pattern and -- for each accepted match replaces using the given replacement pattern. -- Placeholder names defined in the find pattern that occur -- in the replacement pattern are replaced -- by the matching string at the placeholder. -- Return value indicates whether any match was found and accepted -- Note: When a match is found and accepted, the file will be changed -- -- Note: When find-and-replacing all instances of a particular warning -- detected by your favorite linter, such as GNATcheck and CodePeer, -- you don't have to reimplement the semantic check of that warning, since -- you can just check whether the location of the found instance occurs -- in the list of reported locations by the linter. end Rejuvenation.Find_And_Replacer;
package Nilakantha is type NilakanthaSeries is tagged private; procedure Iterate (Self : in out NilakanthaSeries); function GetPi (Self : NilakanthaSeries) return Long_Float; private type NilakanthaSeries is tagged record A : Integer := 2; S : Integer := 1; Pi : Long_Float := 3.0; end record; end Nilakantha;
with Ada.Text_IO; procedure Nth is function Suffix(N: Natural) return String is begin if N mod 10 = 1 and then N mod 100 /= 11 then return "st"; elsif N mod 10 = 2 and then N mod 100 /= 12 then return "nd"; elsif N mod 10 = 3 and then N mod 100 /= 13 then return "rd"; else return "th"; end if; end Suffix; procedure Print_Images(From, To: Natural) is begin for I in From .. To loop Ada.Text_IO.Put(Natural'Image(I) & Suffix(I)); end loop; Ada.Text_IO.New_Line; end Print_Images; begin Print_Images( 0, 25); Print_Images( 250, 265); Print_Images(1000, 1025); end Nth;
-- (The MIT License) --Copyright (c) 2012 Erik Price -- Permission is hereby granted, free of charge, to any person obtaining a copy -- of this software and associated documentation files (the "Software"), to deal -- in the Software without restriction, including without limitation the rights to -- use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies -- of the Software, and to permit persons to whom the Software is furnished to -- do so, subject to the following conditions: -- The above copyright notice and this permission notice shall be included in all -- copies or substantial portions of the Software. -- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, -- INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR -- PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -- LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, -- TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE -- OR OTHER DEALINGS IN THE SOFTWARE. package body Irc.Commands is procedure Install_Commands (Conn : in out Connection) is begin -- general commands Conn.On_Message ("001", Join_On_Ident'Access); Conn.On_Message ("433", Nick_In_Use'Access); Conn.On_Message ("PING", Ping_Server'Access); Conn.On_Regexp (".*", Log_Line'Access); end Install_Commands; ---------------------------- -- Begin general commands -- ---------------------------- procedure Join_On_Ident (Conn : in out Connection; Msg : IrcMessage) is Channels : Bot.Unbounded_Vector.Vector := Conn.Get_Default_Channels; begin for I in Channels.First_Index .. Channels.Last_Index loop Conn.Join (SU.To_String (Channels.Element (I))); end loop; end Join_On_Ident; procedure Nick_In_Use (Conn : in out Connection; Msg : IrcMessage) is use SU; Attr : Bot.Nick_Attributes := Conn.Get_Attributes; New_Nick : SU.Unbounded_String := Attr.Nick & "_"; begin Attr.Nick := New_Nick; Conn.Command (Cmd => "NICK", Args => SU.To_String (New_Nick)); Conn.Set_Attributes (Attr); end Nick_In_Use; procedure Ping_Server (Conn : in out Connection; Msg : Message.Message) is begin Conn.Command (Cmd => "PONG", Args => SU.To_String (Msg.Args)); end Ping_Server; procedure Log_Line (Conn : in out Connection; Msg : IrcMessage) is begin Msg.Print; end Log_Line; end Irc.Commands;
------------------------------------------------------------------------------- -- This file is part of libsparkcrypto. -- -- Copyright (C) 2010, Alexander Senier -- Copyright (C) 2010, secunet Security Networks AG -- All rights reserved. -- -- Redistribution and use in source and binary forms, with or without -- modification, are permitted provided that the following conditions are met: -- -- * Redistributions of source code must retain the above copyright notice, -- this list of conditions and the following disclaimer. -- -- * Redistributions in binary form must reproduce the above copyright -- notice, this list of conditions and the following disclaimer in the -- documentation and/or other materials provided with the distribution. -- -- * Neither the name of the nor the names of its contributors may be used -- to endorse or promote products derived from this software without -- specific prior written permission. -- -- THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" -- AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE -- IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE -- ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS -- BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR -- CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF -- SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS -- INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN -- CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) -- ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE -- POSSIBILITY OF SUCH DAMAGE. ------------------------------------------------------------------------------- with LSC.Internal.Ops32; package body LSC.Internal.AES.CBC is procedure Encrypt (Context : in AES.AES_Enc_Context; IV : in AES.Block_Type; Plaintext : in AES.Message_Type; Length : in AES.Message_Index; Ciphertext : out AES.Message_Type) is Temp : AES.Block_Type; Next : AES.Block_Type; begin Next := IV; for I in AES.Message_Index range Ciphertext'First .. Ciphertext'Last loop pragma Loop_Invariant (Plaintext'First = Ciphertext'First and Plaintext'Last = Ciphertext'Last and Ciphertext'First + Length - 1 <= Plaintext'Last and Ciphertext'First + Length - 1 in AES.Message_Index); if I <= (Ciphertext'First - 1) + Length then Ops32.Block_XOR (Next, Plaintext (I), Temp); Next := AES.Encrypt (Context, Temp); Ciphertext (I) := Next; pragma Annotate (GNATprove, False_Positive, """Ciphertext"" might not be initialized", "Initialized in complete loop"); else Ciphertext (I) := AES.Null_Block; pragma Annotate (GNATprove, False_Positive, """Ciphertext"" might not be initialized", "Initialized in complete loop"); end if; end loop; end Encrypt; pragma Annotate (GNATprove, False_Positive, """Ciphertext"" might not be initialized in ""Encrypt""", "Initialized in complete loop"); ---------------------------------------------------------------------------- procedure Decrypt (Context : in AES.AES_Dec_Context; IV : in AES.Block_Type; Ciphertext : in AES.Message_Type; Length : in AES.Message_Index; Plaintext : out AES.Message_Type) is Temp : AES.Block_Type; Next : AES.Block_Type; begin Next := IV; for I in AES.Message_Index range Plaintext'First .. Plaintext'Last loop pragma Loop_Invariant (Plaintext'First = Ciphertext'First and Plaintext'Last = Ciphertext'Last and Plaintext'First + Length - 1 <= Ciphertext'Last and Plaintext'First + Length - 1 in AES.Message_Index); if I <= (Plaintext'First - 1) + Length then Temp := AES.Decrypt (Context, Ciphertext (I)); Ops32.Block_XOR (Temp, Next, Plaintext (I)); pragma Annotate (GNATprove, False_Positive, """Plaintext"" might not be initialized", "Initialized in complete loop"); Next := Ciphertext (I); else Plaintext (I) := AES.Null_Block; pragma Annotate (GNATprove, False_Positive, """Plaintext"" might not be initialized", "Initialized in complete loop"); end if; end loop; end Decrypt; pragma Annotate (GNATprove, False_Positive, """Plaintext"" might not be initialized in ""Decrypt""", "Initialized in complete loop"); end LSC.Internal.AES.CBC;
with MPI; package MPIUse is flag : MPI.Errorcode_Type := MPI.Errorcode_Type(-2); end MPIUse;
----------------------------------------------------------------------- -- awa-mail-components -- Mail UI Components -- Copyright (C) 2012, 2017 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use this file except in compliance with the License. -- You may obtain a copy of the License at -- -- http://www.apache.org/licenses/LICENSE-2.0 -- -- Unless required by applicable law or agreed to in writing, software -- distributed under the License is distributed on an "AS IS" BASIS, -- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -- See the License for the specific language governing permissions and -- limitations under the License. ----------------------------------------------------------------------- with ASF.Components.Core; with AWA.Mail.Clients; -- == Components == -- The <b>AWA.Mail.Components</b> package defines several UI components that represent -- a mail message in an ASF view. The components allow the creation, formatting and -- sending of a mail message using the same mechanism as the application presentation layer. -- Example: -- -- <f:view xmlns="mail:http://code.google.com/p/ada-awa/mail"> -- <mail:message> -- <mail:subject>Welcome</mail:subject> -- <mail:to name="Iorek Byrnison">Iorek.Byrnison@svalbard.com</mail:to> -- <mail:body> -- ... -- </mail:body> -- </mail:message> -- </f:view> -- -- When the view which contains these components is rendered, a mail message is built -- and initialized by rendering the inner components. The body and other components can use -- other application UI components to render useful content. The email is send after -- the <b>mail:message</b> has finished to render its inner children. -- -- The <b>mail:subject</b> component describes the mail subject. -- -- The <b>mail:to</b> component define the mail recipient. There can be several recepients. -- -- The <b>mail:body</b> component contains the mail body. package AWA.Mail.Components is type UIMailComponent is new ASF.Components.Core.UIComponentBase with private; -- Get the mail message instance. function Get_Message (UI : in UIMailComponent) return AWA.Mail.Clients.Mail_Message_Access; private type UIMailComponent is new ASF.Components.Core.UIComponentBase with null record; end AWA.Mail.Components;