content stringlengths 23 1.05M |
|---|
with AUnit.Assertions; use AUnit.Assertions;
with Ada.Text_IO;
with System;
with System.Address_To_Access_Conversions;
with Tensor; use Tensor;
package body TensorTests is
procedure Register_Tests (T: in out TestCase) is
use AUnit.Test_Cases.Registration;
begin
Register_Routine (T, testTensor'Acces... |
------------------------------------------------------------------------------
-- --
-- GNAT COMPILER COMPONENTS --
-- --
-- ... |
-- This spec has been automatically generated from STM32L4x5.svd
pragma Restrictions (No_Elaboration_Code);
pragma Ada_2012;
pragma Style_Checks (Off);
with HAL;
with System;
package STM32_SVD.PWR is
pragma Preelaborate;
---------------
-- Registers --
---------------
subtype CR1_LPMS_Field is HAL.... |
------------------------------------------------------------------------------
-- --
-- GNAT LIBRARY COMPONENTS --
-- --
-- ... |
with HAL; use HAL;
with HAL.SPI; use HAL.SPI;
with STM32.Device; use STM32.Device;
with STM32.SPI; use STM32.SPI;
with STM32.SubGhzPhy; use STM32.SubGhzPhy;
with System;
package STM32.SubGhzRF is
type Set_Standby_Selection is
(RC_13_MHz,
HSE32);
type Set_RegulatorMode_S... |
-- MIT License
--
-- Copyright (c) 2020 Max Reznik
--
-- 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, mo... |
with Ada.Command_Line;
with Ada.Text_IO;
with AOC.AOC_2019;
procedure Main is
use Ada.Command_Line;
use Ada.Text_IO;
Year : Natural := Natural'Value (Argument (1));
Day_Number : Natural := Natural'Value (Argument (2));
Runner : AOC.Runner.Access_Runner := (case Year is
... |
with Ada.Text_IO;
package body My_Reader is
procedure Start_Element
(Handler : in out Reader;
Namespace_URI : Unicode.CES.Byte_Sequence := "";
Local_Name : Unicode.CES.Byte_Sequence := "";
Qname : Unicode.CES.Byte_Sequence := "";
Atts : Sax.Attributes.Attributes... |
pragma License (Unrestricted);
-- extended unit specialized for Windows
package Ada.Environment_Encoding.Names is
-- Constants for schemes of system-specific text encoding.
pragma Preelaborate;
UTF_8 : Encoding_Id
renames Environment_Encoding.UTF_8;
UTF_16 : Encoding_Id
renames Environment_En... |
--------------------------------------------------------------------------------------------------------------------
-- Copyright (c) 2013-2020, Luke A. Guest
--
-- 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 f... |
with Ada.Containers.Vectors;
with Ada.Strings.Unbounded; use Ada.Strings.Unbounded;
package Utils is
package Str_Vector is new Ada.Containers.Vectors
(Index_Type => Natural,
Element_Type => Unbounded_String);
end Utils;
|
package body System.File_IO is
procedure Check_File_Open (File : File_Control_Block.AFCB_Ptr) is
begin
raise Program_Error; -- unimplemented
end Check_File_Open;
end System.File_IO;
|
-- { dg-do compile }
package Last_Bit is
Max_Components : constant := 100;
type Count_Type is new Natural range 0 .. Max_Components;
subtype Index_Type is Count_Type range 1 .. Count_Type'Last;
type List_Type is array (Index_Type range <>) of Integer;
type Record_Type (Count : Count_Type := 0) is ... |
with
AdaM.Any,
Ada.Streams;
package AdaM.Entity
is
type Base is abstract tagged null record;
type Item is abstract new Base
and Any.item with private;
-- View
--
type View is access all Item'Class;
procedure View_write (Stream : not null access Ada.Streams.Roo... |
-- Copyright (C) 2019 Thierry Rascle <thierr26@free.fr>
-- MIT license. Please refer to the LICENSE file.
private with Ada.Exceptions;
private with Ada.Tags;
with Apsepp.Test_Node_Class.Case_Stub; use Apsepp.Test_Node_Class.Case_Stub;
use Apsepp.Test_Node_Class;
package Apsepp.Abstract_Early_Test_Case is
subtyp... |
-- Copyright (c) 2020 Raspberry Pi (Trading) Ltd.
--
-- SPDX-License-Identifier: BSD-3-Clause
-- This spec has been automatically generated from rp2040.svd
pragma Restrictions (No_Elaboration_Code);
pragma Ada_2012;
pragma Style_Checks (Off);
with HAL;
with System;
-- DW_apb_i2c address block
package RP_SVD.I2C... |
package body RTCH.Maths.Vectors is
function Normalise (V : in Vector) return Vector is
V_Length : constant Float := Magnitude (V);
begin
return Make_Vector (X => V.X / V_Length,
Y => V.Y / V_Length,
Z => V.Z / V_Length);
end Normalise;
end RTCH.Ma... |
with Interfaces;
with Atomic.Unsigned;
package Atomic.Unsigned_16 is new Atomic.Unsigned (Interfaces.Unsigned_16);
|
-- Abstract :
--
-- Types and operations for a packrat parser runtime.
--
-- References:
--
-- [ford thesis] Bryan Ford thesis http://bford.info/pub/lang/thesis
--
-- [langkit] AdaCore langkit https://github.com/adacore/langkit
--
-- [tratt 2010] http://tratt.net/laurie/research/pubs/papers/
-- ... |
limited with Pack1;
package limited_with is
procedure Print_2 (Obj : access Pack1.Nested.Rec_Typ);
end limited_with;
|
package Simple_Math is
type Float_T is digits 6 range -1_000.0 .. 1_000.0;
-- Define an exception that can be raised when the operation
-- is expected to fail
function Sqrt
(X : Float_T)
return Float_T;
function Square
(X : Float_T)
return Float_T;
function Multiply
(L, R... |
-- Copyright 2019 Simon Symeonidis (psyomn)
--
-- 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 la... |
with Ada.Containers.Hashed_Maps;
with Ada.Strings.Hash;
with Ada.Strings.Unbounded;
with Ada.Text_IO;
-- @description
-- This package provide a set of sub-programs to parse and configure environment variable from a file.
--
-- Environment variables in file shall have the following format: Key=Value
-- The value ca... |
------------------------------------------------------------------------------
-- --
-- GNAT COMPILER COMPONENTS --
-- --
-- ... |
package body Stack
with SPARK_Mode => On
is
Tab : array (1 .. Max_Size) of Board := (others => (others => (others => Empty)));
-- The stack. We push and pop pointers to Values.
-----------
-- Clear --
-----------
procedure Clear is
begin
Last := Tab'First - 1;
end Clear;
---------... |
with Globals_Example1;
package Globals_Example2 is
type Record2 is record
I_Attribute : Globals_Example1.Itype;
end record;
end Globals_Example2;
|
-- Auto_Counters_Suite
-- Unit tests for Auto_Counters packages
-- Copyright (c) 2016, James Humphry - see LICENSE file for details
with Smart_Ptrs_Tests;
with Auto_Counters_Suite.Unique_Ptrs_Tests;
with Auto_Counters_Suite.C_Resources_Tests;
with Auto_Counters_Suite.Refcounted_Flyweights_Tests;
with Auto_Counters_Su... |
-- Generated at 2014-10-01 17:18:35 +0000 by Natools.Static_Hash_Maps
-- from src/natools-s_expressions-templates-generic_integers-maps.sx
function Natools.Static_Maps.S_Expressions.Templates.Integers.T
return Boolean;
pragma Pure (Natools.Static_Maps.S_Expressions.Templates.Integers.T);
|
-- SPDX-License-Identifier: Apache-2.0
--
-- Copyright (c) 2012 Felix Krause <contact@flyx.org>
--
-- 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/licen... |
-- Example_Userdata
-- A simple example of an Ada type turned into a Lua userdata type
-- Copyright (c) 2015, James Humphry - see LICENSE for terms
with Lua, Lua.Userdata;
use Lua;
package Example_Userdata is
type Grandparent is abstract tagged
record
Flag : Boolean;
end record;
type Par... |
-- Copyright (c) 2013, Nordic Semiconductor ASA
-- 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
-- lis... |
-- Copyright (c) 2015-2017 Maxim Reznik <reznikmm@gmail.com>
--
-- SPDX-License-Identifier: MIT
-- License-Filename: LICENSE
-------------------------------------------------------------
with Ada.Containers.Vectors;
with League.Strings;
with XML.Templates.Streams;
package Tests.Commands is
pragma Preelaborate... |
--------------------------------------------------------------------------------
-- Copyright (c) 2013, Felix Krause <contact@flyx.org>
--
-- 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 pe... |
with Ada.Text_IO; use Ada.Text_IO;
with Constants;
package body Input is
-- Function implementation for getting integer value from user
-- Input value should use limits from Constants package to ensure
-- valid input data
end Input;
|
-- Copyright (c) 2020 Raspberry Pi (Trading) Ltd.
--
-- SPDX-License-Identifier: BSD-3-Clause
-- This spec has been automatically generated from rp2040.svd
pragma Restrictions (No_Elaboration_Code);
pragma Ada_2012;
pragma Style_Checks (Off);
with HAL;
with System;
-- DMA with separate read and write masters
pa... |
-----------------------------------------------------------------------
-- util-beans-objects-readers -- Datasets
-- Copyright (C) 2013 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... |
-- Copyright (C) 2019 Thierry Rascle <thierr26@free.fr>
-- MIT license. Please refer to the LICENSE file.
with Ada.Unchecked_Deallocation;
package body Apsepp_Test_Node_Barrier is
----------------------------------------------------------------------------
function Test_Reporter_Proc_Name
(Event_Kind : T... |
------------------------------------------------------------------------------
-- --
-- Copyright (c) 2016-2021 Vitalii Bondarenko <vibondare@gmail.com> --
-- --
----... |
------------------------------------------------------------------------------
-- --
-- Copyright (C) 2015, AdaCore --
-- --
-- ... |
Pragma Ada_2012;
With
Interfaces,
Ada.Streams,
Ada.Wide_Wide_Characters.Unicode,
Ada.Containers.Indefinite_Holders,
Ada.Containers.Indefinite_Ordered_Maps,
Ada.Containers.Indefinite_Vectors;
Package NSO.JSON with Elaborate_Body is
Type Value_Kind is ( VK_Object, VK_Array, VK_String, VK_Number,
... |
-- { dg-do compile }
-- { dg-options "-O -gnatN" }
with FE_Inlining_Helper;
procedure FE_Inlining is new FE_Inlining_Helper;
|
-- This file is covered by the Internet Software Consortium (ISC) License
-- Reference: ../License.txt
with GNAT.OS_Lib;
with Ada.Command_Line;
with Ada.Strings.Unbounded;
procedure SynthExec
is
package OSL renames GNAT.OS_Lib;
package CLI renames Ada.Command_Line;
package ASU renames Ada.Strings.Unbounded... |
with AUnit.Test_Suites;
package Suits is
function Suit return AUnit.Test_Suites.Access_Test_Suite;
end suits;
|
package body ACO.SDO_Sessions is
function Create_Download
(Endpoint : Endpoint_Type;
Index : ACO.OD_Types.Entry_Index)
return SDO_Session
is
((Service => Download,
Endpoint => Endpoint,
Index => Index,
Toggle => False));
function Create_Upload
... |
with Ada.Finalization;
with Ada.Text_IO;
package RAII is
type Controlled_File is new Ada.Finalization.Limited_Controlled with record
File : Ada.Text_IO.File_Type;
end record;
overriding procedure Finalize (This : in out Controlled_File);
end RAII;
|
------------------------------------------------------------------------------
-- --
-- GNAT COMPILER COMPONENTS --
-- --
-- ... |
with VisitablePackage, EnvironmentPackage, AbstractStrategyBasicPackage;
use VisitablePackage, EnvironmentPackage, AbstractStrategyBasicPackage;
with Ada.Text_IO; use Ada.Text_IO;
package body AllsStrategy is
----------------------------------------------------------------------------
-- Object implementation
---... |
-- SPDX-FileCopyrightText: 2019 Max Reznik <reznikmm@gmail.com>
--
-- SPDX-License-Identifier: MIT
-------------------------------------------------------------
package body Program.Nodes.Membership_Tests is
function Create
(Expression : not null Program.Elements.Expressions.Expression_Access;
Not_Token... |
with Ada.Real_Time; use Ada.Real_Time;
with Logging_Support;
with Ada.Text_IO; use Ada.Text_IO;
with System; use System;
with Epoch_Support; use Epoch_Support;
with XAda.Dispatching.TTS;
with TT_Utilities;
with TT_Patterns;
package body TTS_Example_A is
Number_Of_Work_Ids : constant := 6;
Number_Of_Sync_Ids :... |
with Ada.Containers.Vectors;
package Impact.d3.convex_Polyhedron
--
--
--
is
use Math;
TEST_INTERNAL_OBJECTS : constant Boolean := True;
package integer_Vectors is new Ada.Containers.Vectors (Positive, Integer);
subtype Integer_Vector is integer_Vectors.Vector;
--- Plane
--
type Plane... |
------------------------------------------------------------------------------
-- --
-- GNAT RUN-TIME COMPONENTS --
-- --
-- ... |
Function Connection_Combinations return Partial_Board is
begin
Return Result : Board do
declare
-- The Generate task takes two parameters
-- (1) a list of pegs already in use, and
-- (2) a partial-board
-- and, if the state given is a viable yet incomplete solution, it... |
------------------------------------------------------------------------------
-- --
-- GNAT COMPILER COMPONENTS --
-- --
-- ... |
-- Copyright (c) 2017 Maxim Reznik <reznikmm@gmail.com>
--
-- SPDX-License-Identifier: MIT
-- License-Filename: LICENSE
-------------------------------------------------------------
with Ada.Streams;
generic
type Element_Type is private;
package LSP.Generic_Optional is
pragma Preelaborate;
type Optional_T... |
with Matrices;
with Ada.Text_IO;
procedure Main is
package Float_IO is new Ada.Text_IO.Float_IO (Float);
package Float_Matrices is new Matrices (
Element_Type => Float,
Zero => 0.0);
procedure Print_Matrix (Matrix : in Float_Matrices.Matrix) is
begin
for Row in Matrix'Range (1) loop
... |
generic
type T_Cle is private; -- Type clé générique.
package Arbre_Binaire is
Cle_Presente_Exception_Bin : Exception; -- une clé est déjà présente dans un arbre.
Cle_Absente_Exception_Bin : Exception; -- une clé est absente d'un arbre.
Emplacement_Reserve_Exception_Bin : Exception; -- L'emplacement du noeud... |
-- part of OpenGLAda, (c) 2017 Felix Krause
-- released under the terms of the MIT license, see the file "COPYING"
with Ada.Unchecked_Conversion;
with Ada.Containers.Indefinite_Hashed_Maps;
with GL.API;
with GL.Helpers;
with GL.Enums.Getter;
with GL.Enums.Indexes;
with GL.Enums.Textures;
package body GL.Objects.Te... |
with Ada.Text_IO;
package generic_package_renaming_declaration is
generic package Enum_IO renames Ada.Text_IO.Enumeration_IO;
end generic_package_renaming_declaration;
|
package ext1 is
type I_Smiley is interface;
procedure Set_Mood (Obj : out I_Smiley) is abstract;
--
type Smiley (Max : Positive) is abstract new I_Smiley with record
S : String (1 .. Max);
end record;
--
type Regular_Smiley is new Smiley (3) with null record;
overriding
... |
package Fixed_Point_Definition is
type Type_1 is delta 0.1 range 0.0 .. 200.0;
type Type_2 is delta 0.01 digits 15;
end Fixed_Point_Definition;
|
-- -----------------------------------------------------------------------------
-- Copyright (C) 2003-2019 Stichting Mapcode Foundation (http://www.mapcode.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... |
package body agar.gui.widget.file_dialog is
use type c.int;
package cbinds is
function allocate_mru
(parent : widget_access_t;
key : cs.chars_ptr;
flags : flags_t) return file_dialog_access_t;
pragma import (c, allocate_mru, "AG_FileDlgNewMRU");
function set_directory
(d... |
with ada.text_io;
use ada.text_io;
package body intro is
-------------------------------
-- Name: Jon Spohn
-- David Rogina
-- Game Intro Package
-------------------------------
--Read in and display title page
procedure title_page(file:in file_type) is
char:character;
begin
while not end_of_... |
with STM32F4.LCD;
with STM32F4.I2C; use STM32F4.I2C;
with STM32F4.GPIO; use STM32F4.GPIO;
with STM32F429_Discovery; use STM32F429_Discovery;
package STM32F4.Touch_Panel is
type TP_State is record
Touch_Detected : Boolean;
X : LCD.Width;
Y : LCD.Height;
Z : Half_Word;
end record;
... |
package Poly with SPARK_Mode is
type Vector is array (Natural range <>) of Integer;
function Horner (X: Integer; A: Vector) return Integer;
end Poly;
|
-- Copyright (c) 2010 - 2018, Nordic Semiconductor ASA
--
-- All rights reserved.
--
-- 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, t... |
-- { dg-do compile }
package Machine_Attribute is
type R is null record;
pragma Machine_Attribute (R, "may_alias");
end Machine_Attribute;
|
with Globals_Example1;
package Md_Example4 is
type T is tagged record
Attribute : Globals_Example1.Itype;
end record;
-- Ada Rules state that all tagged operations must be defined here
function Unrelated (The_I : Globals_Example1.Itype)
return Globals_Example1.Itype;
-- No tagged operati... |
with
openGL.Palette,
openGL.Font,
openGL.IO,
openGL.Model.arrow .colored,
openGL.Model.billboard. textured,
openGL.Model.billboard.colored_textured,
openGL.Model.box .colored,
openGL.Model.box .textured,
openGL.Model.box .lit_colored_textured,
o... |
with AUnit;
with AUnit.Test_Caller;
with AUnit.Test_Fixtures;
package Tests.Device is
type UDC_Stub_Fixture is new AUnit.Test_Fixtures.Test_Fixture with record
A : Integer;
end record;
overriding
procedure Set_Up (T : in out UDC_Stub_Fixture);
private
package UDC_Stub_Caller is new AUnit.Test_... |
-----------------------------------------------------------------------
-- css-printer -- CSS printer tools
-- Copyright (C) 2017, 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... |
pragma License (Unrestricted);
with Ada.Text_IO;
package Ada.Short_Short_Integer_Text_IO is
new Text_IO.Integer_IO (Short_Short_Integer);
|
with Ada.Numerics.Generic_Elementary_Functions;
package body Mathutil with SPARK_Mode => Off is
package FloatingMath is
new Ada.Numerics.Generic_Elementary_Functions(FloatingNumber);
function ArcTan(Y : FloatingNumber; X : FloatingNumber) return FloatingNumber
is
begin
return FloatingMath.ArcTan(Y / X, 1.0... |
------------------------------------------------------------------------------
-- --
-- GNAT RUN-TIME LIBRARY (GNARL) COMPONENTS --
-- --
-- ... |
------------------------------------------------------------------------------
-- --
-- Matreshka Project --
-- --
-- ... |
with OpenAL.Extension.Float32_Thin;
with OpenAL.Global;
with OpenAL.Thin;
with System;
package body OpenAL.Extension.Float32 is
use type Types.Size_t;
function Is_Present return Boolean is
begin
return Global.Is_Extension_Present ("AL_EXT_FLOAT32");
end Is_Present;
procedure Set_Data_Mono_Float_32
... |
with Ada.Calendar.Arithmetic;
with Ada.Text_IO;
procedure Discordian is
use Ada.Calendar;
subtype Year_Number is Integer range 3067 .. 3565;
type Seasons is (Chaos, Discord, Confusion, Bureaucracy, The_Aftermath);
subtype Day_Number is Integer range 1 .. 73;
type Discordian_Date is record
Year ... |
-- part of AdaYaml, (c) 2017 Felix Krause
-- released under the terms of the MIT license, see the file "copying.txt"
with AUnit.Assertions; use AUnit.Assertions;
package body Yaml.Dom.Dumping.Test is
use type Text.Reference;
procedure Register_Tests (T : in out TC) is
use AUnit.Test_Cases.Registration;... |
with Ada.Text_IO;
package body Problem_52 is
package IO renames Ada.Text_IO;
procedure Solve is
type Digit is new Natural range 0 .. 9;
type Digit_Count is Array (Digit'Range) of Natural;
function Verify(num : Positive) return Boolean is
base : Digit_Count := (others => 0);
mul... |
-----------------------------------------------------------------------
-- awa-permissions-controllers -- Permission controllers
-- Copyright (C) 2011, 2012, 2013, 2014 Stephane Carrez
-- Written by Stephane Carrez (Stephane.Carrez@gmail.com)
--
-- Licensed under the Apache License, Version 2.0 (the "License")... |
package body Serialization is
use type Ada.Strings.Unbounded.Unbounded_String;
function Error_Message (Name, Value : String) return String is
begin
if Name = "" then
return Value;
else
return Name & ": " & Value;
end if;
end Error_Message;
-- private implementation
procedure Advance_Structure (
... |
-- { dg-do run }
procedure Atomic8 is
V : array (1 .. 2) of Natural := (0,0) with Atomic_Components;
task type TT1;
task body TT1 is
begin
while V (1) + V (2) < 1_000_000 loop
V (1) := V (1) + 1;
end loop;
end TT1;
task type TT2;
task body TT2 is
begin
while V (1) ... |
------------------------------------------------------------------------------
-- --
-- GNAT COMPILER COMPONENTS --
-- --
-- ... |
with Ada.Wide_Wide_Text_IO; use Ada.Wide_Wide_Text_IO;
procedure Test is
begin
Put ("Unicode """ & ''' & """" & Wide_Wide_Character'Val (10));
end Test;
|
package body Marble_Mania is
procedure Start (Game : in out Circle_Game) is
begin
Game.Board.Append (0);
Game.Current := Game.Board.First;
Game.Round := 1;
end Start;
procedure Play (Player : in Positive; Game : in out Circle_Game) is
procedure Next is
use Nat_List;
... |
pragma Ada_2005;
pragma Style_Checks (Off);
with Interfaces.C; use Interfaces.C;
with word_operations_hpp;
package instructionargs_hpp is
type ARG (discr : unsigned := 0) is record
case discr is
when 0 =>
word : aliased word_operations_hpp.uint16_t; -- ./instructionargs.hpp:6
... |
-- Copyright (C) 2019 Thierry Rascle <thierr26@free.fr>
-- MIT license. Please refer to the LICENSE file.
with Ada.Unchecked_Deallocation;
package body Apsepp.Test_Reporter_Data_Struct_Class.Impl is
----------------------------------------------------------------------------
not overriding
procedure Add_An... |
package body OpenGL.Matrix is
function Mode_To_Constant (Mode : in Mode_t) return Thin.Enumeration_t is
begin
case Mode is
when Texture => return Thin.GL_TEXTURE;
when Modelview => return Thin.GL_MODELVIEW;
when Color => return Thin.GL_COLOR;
when Projection => return Thin.GL_P... |
-- { dg-do run }
with GNAT.MD5; use GNAT.MD5;
procedure md5_test is
TEST7 : constant String := "abcdbcdecdefdefgefghfghighijhijkijkljklmklmnlmnomnopnopq";
Expected : constant Message_Digest :=
"8215ef0796a20bcaaae116d3876c664a";
MD : Context;
begin
Update (MD, TEST7);
if Digest (MD) /... |
with String_Vectors, Ada.Text_IO, Ada.Command_Line;
procedure Semordnilap is
function Backward(S: String) return String is
begin
if S'Length < 2 then
return S;
else
return (S(S'Last) & Backward(S(S'First+1 .. S'Last-1)) & S(S'First));
end if;
end Backward;
W: String_Ve... |
with STM32.Setup;
with STM32_SVD.RCC; use STM32_SVD.RCC;
with STM32_SVD.DBGMCU; use STM32_SVD.DBGMCU;
package body STM32.Board is
---------------------
-- Initialize_LEDs --
---------------------
procedure Initialize_LEDs is
Configuration : GPIO_Port_Configuration;
begin
Enable_Clock (... |
------------------------------------------------------------------------------
-- G E L A A S I S --
-- ASIS implementation for Gela project, a portable Ada compiler --
-- http://gela.ada-ru.org --
-- ... |
-- 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
-- (a... |
with Ada.Strings.Unbounded; use Ada.Strings.Unbounded;
with Ada.Text_IO, Ada.Characters.Latin_1;
procedure Longest_String_Challenge is
function "+"(S: String) return Unbounded_String renames To_Unbounded_String;
Separator: constant Character := Ada.Characters.Latin_1.NUL;
procedure Funny_Stuff(B, L: in out U... |
with Ada.Text_IO; use Ada.Text_IO;
with Ada.Strings.Unbounded; use Ada.Strings.Unbounded;
package body Offmt_Lib is
------------------
-- Pretty_Print --
------------------
procedure Pretty_Print (T : Trace) is
begin
Put_Line ("-- Format --");
Put_Line (" Original: '" & To_String (T.Origi... |
-- MIT License
-- Copyright (c) 2021 Stephen Merrony
-- 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,... |
procedure Linked_List is
type Node;
type Linked is access Node;
type Node is record
Value: Integer := 0;
Next: Linked;
end record;
procedure Delete_Node(Item: in out Linked) is
begin
Item.Value := Item.Next.Value;
Item.Next := Item.Next.Next;
end Delete_... |
------------------------------------------------------------------------------
-- --
-- GNAT ncurses Binding --
-- --
-- ... |
-- AoC 2020, Day 3
with Ada.Text_IO;
package body Day is
package TIO renames Ada.Text_IO;
function "<"(left, right : in Position) return Boolean is
begin
if left.y < right.y then
return true;
elsif left.y = right.y and left.x < right.x then
return true;
else
return false;
end if... |
pragma License (Unrestricted);
-- extended unit
with Ada.Strings.Wide_Functions.Maps;
package Ada.Strings.Bounded_Wide_Strings.Functions.Maps is
new Generic_Maps (Wide_Functions.Maps);
pragma Preelaborate (Ada.Strings.Bounded_Wide_Strings.Functions.Maps);
|
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.