content stringlengths 23 1.05M |
|---|
pragma License (Unrestricted);
-- implementation unit required by compiler
with Ada.Real_Time;
with System.Parameters;
with System.Task_Info;
with System.Tasks;
package System.Tasking.Stages is
-- required for task by compiler (s-tassta.ads)
procedure Create_Task (
Priority : Integer; -- range -1 .. Any_... |
-- -*- Mode: Ada -*-
-- Filename : ether-forms.adb
-- Description : Abstraction around the form data returned from the SCGI client (HTTP server).
-- Author : Luke A. Guest
-- Created On : Tue May 1 18:04:04 2012
with Ada.Text_IO; use Ada.Text_IO;
with Ada.Strin... |
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.DAC is
pragma Preelaborate;
---------------
-- Registers --
---------------
-- Control A
type DAC_CTRLA_Register is r... |
-- { dg-do compile }
-- { dg-options "-gnatws -O3" }
with Discr21_Pkg; use Discr21_Pkg;
package body Discr21 is
type Index is new Natural range 0 .. 100;
type Arr is array (Index range <> ) of Position;
type Rec(Size : Index := 1) is record
A : Arr(1 .. Size);
end record;
Data : Rec;
function To_... |
with ada.text_io;use ada.text_io;
procedure binary is
-- the digits in base 2
bit : array (0..1) of string (1..1) := ("0","1");
-- the conversion function itself
function bin_image (n : Natural) return string is (if n<2 then bit (n) else bin_image (n/2)&bit(n mod 2));
-- the values we want to test
test_values : a... |
-- Copyright (c) 2019 Maxim Reznik <reznikmm@gmail.com>
--
-- SPDX-License-Identifier: MIT
-- License-Filename: LICENSE
-------------------------------------------------------------
with Slim.Message_Visiters;
with Slim.Messages.BUTN;
package Slim.Players.Common_Play_Visiters is
type Visiter (Player : not nul... |
with Ada.Text_IO;
with Ada.Text_IO.Text_Streams;
with Ada.Streams.Stream_IO;
with Ada.Command_Line;
with Ada.Directories;
with Ada.Characters;
with Ada.Characters.Latin_1;
with GNAT.OS_Lib;
with Ada; use Ada;
procedure Ada_Formatter is
-- Nano formatting tool for the Ada language.
use Ada.Text_IO;
use Ada.Te... |
--
-- Copyright (C) 2015-2017 secunet Security Networks AG
--
-- This program 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 2 of the License, or
-- (at your option) any later version.
--
-- ... |
-- Copyright 2008-2016 Free Software Foundation, Inc.
--
-- This program 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.
--
-- ... |
pragma License (Unrestricted);
with System.Machine_Code;
package Machine_Code renames System.Machine_Code; -- If supported.
|
with Ada.Text_IO, Ada.Directories, Ada.Command_Line, Ada.IO_Exceptions;
use Ada.Text_IO;
procedure Remove_Lines_From_File is
Temporary: constant String := ".tmp";
begin
if Ada.Command_Line.Argument_Count /= 3 then
raise Constraint_Error;
end if;
declare
Filename: String := Ada.Command_Line.Argu... |
------------------------------------------------------------------------------
-- --
-- GNAT COMPILER COMPONENTS --
-- --
-- ... |
with Asis.Clauses;
with Asis.Elements;
package body Asis_Adapter.Element.Clauses is
------------
-- EXPORTED:
------------
procedure Do_Pre_Child_Processing
(Element : in Asis.Element;
State : in out Class)
is
Parent_Name : constant String := Module_Name;
Module_Name : constant S... |
-----------------------------------------------------------------------
-- GtkAda - Ada95 binding for the Gimp Toolkit --
-- --
-- Copyright (C) 1998-1999 --
-- Emmanuel Briot, Joel B... |
-- Ahven Unit Test Library
--
-- Copyright (c) 2007-2009 Tero Koskinen <tero.koskinen@iki.fi>
--
-- 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.
--
-- T... |
-- Ada_GUI implementation based on Gnoga. Adapted 2021
-- --
-- GNOGA - The GNU Omnificent GUI for Ada --
-- --
-- G N... |
------------------------------------------------------------------------------
-- --
-- Copyright (C) 2016, AdaCore --
-- --
-- ... |
-- { dg-do compile }
-- { dg-options "-O2 -fdump-tree-optimized" }
function Volatile6 return Integer is
type Vol is new Integer;
pragma Volatile (Vol);
V : Vol := 0;
begin
for J in 1 .. 10 loop
V := V + 1;
end loop;
return Integer (V);
end;
-- { dg-final { scan-tree-dump "goto" "optimized" } }
|
-------------------------------------------------------------------------------
-- LSE -- L-System Editor
-- Author: Heziode
--
-- License:
-- MIT License
--
-- Copyright (c) 2018 Quentin Dauprat (Heziode) <Heziode@protonmail.com>
--
-- Permission is hereby granted, free of charge, to any person obtaining a
-- c... |
-------------------------------------------------------------------------------
-- This file is part of libsparkcrypto.
--
-- Copyright (C) 2018 Componolit GmbH
-- Copyright (C) 2010, Alexander Senier
-- Copyright (C) 2010, secunet Security Networks AG
-- All rights reserved.
--
-- Redistribution and use in s... |
------------------------------------------------------------------------------
-- G E L A G R A M M A R S --
-- Library for dealing with grammars for Gela project, --
-- a portable Ada compiler --
-- ... |
pragma License (Unrestricted);
-- extended unit
package Ada.IO_Modes is
-- Root types of File_Mode and for the parameters Form.
pragma Pure;
type File_Mode is (In_File, Out_File, Append_File);
type Inout_File_Mode is (In_File, Inout_File, Out_File); -- Direct_IO
-- the types for the parameters Form ... |
package GESTE_Fonts.FreeSerifBold5pt7b is
Font : constant Bitmap_Font_Ref;
private
FreeSerifBold5pt7bBitmaps : aliased constant Font_Bitmap := (
16#00#, 16#00#, 16#00#, 16#00#, 16#00#, 16#40#, 16#10#, 16#04#, 16#01#,
16#00#, 16#40#, 16#00#, 16#06#, 16#00#, 16#00#, 16#00#, 16#00#, 16#00#,
16#00#, 16#00#, 1... |
-- Copyright (C) 2019 Thierry Rascle <thierr26@free.fr>
-- MIT license. Please refer to the LICENSE file.
with Ada.Exceptions; use Ada.Exceptions;
with Ada.Calendar.Time_Zones; use Ada.Calendar.Time_Zones;
private with Apsepp.Calendar;
package Apsepp.Debug_Trace_Class is
type Debug_Trace_Interfa is limit... |
-----------------------------------------------------------------------
-- awa-commands-drivers -- Driver for AWA commands for server or admin tool
-- Copyright (C) 2020 Stephane Carrez
-- Written by Stephane Carrez (Stephane.Carrez@gmail.com)
--
-- Licensed under the Apache License, Version 2.0 (the "License");
--... |
------------------------------------------------------------------------
-- Copyright (C) 2010-2020 by Heisenbug Ltd. (github@heisenbug.eu)
--
-- This work is free. You can redistribute it and/or modify it under
-- the terms of the Do What The Fuck You Want To Public License,
-- Version 2, as published by Sam Hocev... |
with datos; use datos;
procedure Insertar_en_psicion_N (
L : in out Lista;
Num : in Integer ) is
begin
end Insertar_en_psicion_N;
|
pragma License (Unrestricted);
-- implementation unit required by compiler
package System.WCh_WtS is
pragma Pure;
-- (s-wchcon.ads)
type WC_Encoding_Method is range 1 .. 6;
-- required for T'Wide_Value by compiler (s-wchwts.ads)
function Wide_String_To_String (
S : Wide_String;
EM : WC_E... |
-- { dg-do compile }
-- { dg-options "-O2" }
with System;
procedure Memtrap is
X : integer;
for X'address use System.Null_Address;
begin
X := 12;
exception
when others => null;
end;
-- { dg-final { scan-assembler "__gnat_begin_handler|__gnat_raise_nodefer" } }
|
-- Auto_Counters_Tests
-- Unit tests for Auto_Counters packages
-- Copyright (c) 2016, James Humphry - see LICENSE file for details
with Auto_Counters_Suite;
with AUnit.Run;
with AUnit.Reporter.Text;
procedure Auto_Counters_Tests is
procedure Run is new AUnit.Run.Test_Runner (Auto_Counters_Suite.Suite);
Repor... |
with Ada.Text_IO;
procedure Hamming is
generic
type Int_Type is private;
Zero : Int_Type;
One : Int_Type;
Two : Int_Type;
Three : Int_Type;
Five : Int_Type;
with function "mod" (Left, Right : Int_Type) return Int_Type is <>;
with function "/" (Left, Right : Int... |
-- part of ParserTools, (c) 2017 Felix Krause
-- released under the terms of the MIT license, see the file "copying.txt"
with Ada.Strings.Hash;
package body Text is
function "&" (Left, Right : Reference) return String is
(Ada.Strings.Unbounded.To_String (Left) & Ada.Strings.Unbounded.To_String (Right));
... |
with Arena_Pools;
use Arena_Pools;
procedure Test_Allocator is
Pool : Arena_Pools.Arena (1024);
type Integer_Ptr is access Integer;
for Integer_Ptr'Storage_Pool use Pool;
X : Integer_Ptr := new Integer'(1);
Y : Integer_Ptr := new Integer'(2);
Z : Integer_Ptr;
begin
Z := new Integer;
Z.all := ... |
-----------------------------------------------------------------------
-- awa-wikis-parsers -- Wiki parser
-- Copyright (C) 2011, 2012, 2013, 2014, 2015 Stephane Carrez
-- Written by Stephane Carrez (Stephane.Carrez@gmail.com)
--
-- Licensed under the Apache License, Version 2.0 (the "License");
-- you may not us... |
with Ada.Text_IO; use Ada.Text_IO;
with Ada.Numerics.Discrete_Random;
procedure Test_Bogosort is
generic
type Ordered is private;
type List is array (Positive range <>) of Ordered;
with function "<" (L, R : Ordered) return Boolean is <>;
procedure Bogosort (Data : in out List);
procedure B... |
-- { dg-do run }
-- { dg-options "-gnat12 -gnatVa" }
procedure In_Out_Parameter4 is
type Enum is (E_Undetermined, E_Down, E_Up);
subtype Status_T is Enum range E_Down .. E_Up;
function Recurse (Val : in out Integer) return Status_T is
Result : Status_T;
procedure Dummy (I : in out Integer) is be... |
with Ada.Command_Line;
package body MyCommandLine is
-- note we do not want SPARK to analyse this implementation since
-- Ada.Command_Line is not able to be handled by the SPARK Prover
function Command_Name return String is
begin
return Ada.Command_Line.Command_Name;
end Command_Name;
functio... |
-- 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.
... |
with Ada.Real_Time; use Ada.Real_Time;
with Ada.Text_IO;use Ada.Text_IO;
with Ada.Dispatching; use Ada.Dispatching;
procedure Periodic is
Interval : Time_Span := Milliseconds(30);
Next : Time;
begin
Next := Clock + Interval;
loop
Put_Line("Delay 30 ms" );
delay until Next;
Next := Next + I... |
------------------------------------------------------------------------------
-- --
-- JSON Parser/Constructor --
-- --
-- -... |
-----------------------------------------------------------------------
-- GtkAda - Ada95 binding for Gtk+/Gnome --
-- --
-- Copyright (C) 2010-2011, AdaCore --
-- ... |
-- Standard Ada library specification
-- 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-AdaRe... |
with Ada.Text_IO; use Ada.Text_IO;
with Ada.Text_IO.Text_Streams; use Ada.Text_IO;
with Ada.Streams; use Ada.Streams;
with Ada.Strings.Unbounded; use Ada.Strings.Unbounded;
with Ada.Command_Line; use Ada.Command_Line;
with AWS.Default;
with AWS.Net; use AWS;
with AWS.Net.SSL; use AWS.Net;
with Aids.Env; use Aids;
pr... |
-- SPDX-FileCopyrightText: 2020 Max Reznik <reznikmm@gmail.com>
--
-- SPDX-License-Identifier: MIT
----------------------------------------------------------------
with League.Strings;
with Jupyter.Kernels;
procedure Jupyter.Start_Kernel
(Kernel : in out Jupyter.Kernels.Kernel'Class;
File : League.Strings.U... |
with
lace.Subject.local;
package lace_demo_Keyboard
--
-- Provides a simulated keyboard which periodically emits 'key' events.
--
is
function as_event_Subject return lace.Subject.local.view;
procedure start;
procedure stop;
end lace_demo_Keyboard;
|
with AAA.Strings;
with CLIC.Subcommand;
with CLIC.TTY;
package CLIC_Ex.Commands.Topics.Example is
type Instance is new CLIC.Subcommand.Help_Topic with null record;
overriding
function Name (This : Instance) return CLIC.Subcommand.Identifier
is ("topic_example");
overriding
function Title (This : I... |
------------------------------------------------------------------------------
-- G E L A A S I S --
-- ASIS implementation for Gela project, a portable Ada compiler --
-- http://gela.ada-ru.org --
-- ... |
--
-- Copyright (C) 2015 secunet Security Networks AG
--
-- This program 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 2 of the License, or
-- (at your option) any later version.
--
-- This ... |
-----------------------------------------------------------------------
-- awa-settings-modules-tests -- Unit tests for settings module
-- Copyright (C) 2013, 2019 Stephane Carrez
-- Written by Stephane Carrez (Stephane.Carrez@gmail.com)
--
-- Licensed under the Apache License, Version 2.0 (the "License");
-- you ... |
with Ada.Text_IO, Ada.Strings.Unbounded, Ada.Strings.Unbounded.Text_IO, Ada.Characters.Handling;
use Ada.Text_IO, Ada.Strings.Unbounded, Ada.Strings.Unbounded.Text_IO, Ada.Characters.Handling;
procedure Hello is
Name : Unbounded_String;
Input : Character;
function Title_Case (Str : in String) return String is
... |
with Ada.Text_IO, tools;
use Ada.Text_IO;
package body hauntedhouse is
subtype Index is Positive range 1..5;
package Ind_Generator is new tools.Random_Generator(Index);
function GetRandPos return Position is
begin
return (Ind_Generator.GetRandom,Ind_Generator.GetRandom);
end GetRandPo... |
-- SPDX-FileCopyrightText: 2021 Max Reznik <reznikmm@gmail.com>
--
-- SPDX-License-Identifier: MIT
-------------------------------------------------------------
package Regions.Symbols is
pragma Pure;
type Symbol is mod 2 ** 32;
-- Symbol is case-insensitive representation of identifiers, operators
-- ... |
-- Generated at 2014-10-01 17:18:35 +0000 by Natools.Static_Hash_Maps
-- from src/natools-s_expressions-templates-generic_integers-maps.sx
with Natools.Static_Maps.S_Expressions.Templates.Integers.MC;
with Natools.Static_Maps.S_Expressions.Templates.Integers.AC;
function Natools.Static_Maps.S_Expressions.Templates.I... |
with Ada.Text_Io;
use Ada.Text_Io;
package body PMap is
task body pmap_apply is
value : Integer;
Func : func_type;
begin
accept PortIn(ValIn : in Integer; FuncIn : in not null func_type) do
value := ValIn;
Func := FuncIn;
end PortIn;
value := Func(value);
Put_Line(Integer'Image(value));
accept... |
-- Copyright (c) 2016 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 applic... |
------------------------------------------------------------------------------
-- --
-- GNAT RUN-TIME COMPONENTS --
-- --
-- ... |
-- 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,... |
-----------------------------------------------------------------------
-- wi2wic-rest -- REST entry points
-- Copyright (C) 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 co... |
------------------------------------------------------------------------------
-- --
-- GNAT RUN-TIME COMPONENTS --
-- --
-- ... |
with Ada.Numerics.Discrete_Random;
package body Set_Puzzle is
package Rand is new Ada.Numerics.Discrete_Random(Three);
R: Rand.Generator;
function Locate(Some: Cards; C: Card) return Natural is
-- returns index of card C in Some, or 0 if not found
begin
for I in Some'Range loop
if C = Some(... |
with Server;
with Ada.Text_IO;
procedure Client is
begin
Ada.Text_IO.Put_Line ("Calling Foo...");
Server.Foo;
Ada.Text_IO.Put_Line ("Calling Bar: " & Integer'Image (Server.Bar));
end Client;
|
-- Copyright 2016 Steven Stewart-Gallus
--
-- 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 agr... |
-- CA2002A0M.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.
-- Unlim... |
procedure Quadratic_Bezier
( Picture : in out Image;
P1, P2, P3 : Point;
Color : Pixel;
N : Positive := 20
) is
Points : array (0..N) of Point;
begin
for I in Points'Range loop
declare
T : constant Float := Float (I) / Fl... |
------------------------------------------------------------------------------
-- --
-- GNU ADA RUN-TIME LIBRARY (GNARL) COMPONENTS --
-- --
-- ... |
with Class1; use Class1;
package Class2 is
type Class3 is record
someClass1 : Class1.Class1;
end record;
end Class2; |
------------------------------------------------------------------------------
-- --
-- GNAT COMPILER COMPONENTS --
-- --
-- ... |
with Date_Package; use Date_Package;
with Ada.Text_IO; use Ada.Text_IO;
procedure Lab4a is
type Dates is array (1..10) of Date_Type;
procedure Test_Get(Date: out Date_Type) is
begin
loop
begin
Get(Date);
exit;
exception
when YEAR_ERROR => Put_Line("FEL: YEAR_ERROR");
when MONTH_ERR... |
with HAL; use HAL;
with HiFive1.LEDs; use HiFive1.LEDs;
with FE310;
with FE310.CLINT;
with FE310.Time; use FE310.Time;
with Interfaces; use Interfaces;
with IO;
with SPARKNaCl; use SPARKNaCl;
with SPARKNaCl.Core; use SPARKNaCl.Core;
with SPARKNaCl.Stream; use SPARKNaCl.Stream;
with TweetNaCl_API;
with RIS... |
#if RENAMED then
with Text_IO;
use Text_IO;
#else
with Ada.Text_IO;
use Ada.Text_IO;
#end if;
procedure preproc is
begin
Put_Line("Hello World");
end preproc;
|
with Ada.Finalization;
with Interfaces.C;
with Interfaces.C.Strings;
with System;
package LADSPA is
pragma Preelaborate;
package C renames Interfaces.C;
Version : constant String := "1.1";
Version_Major : constant := 1;
Version_Minor : constant := 1;
subtype Data is C.C_float; -- /usr/incl... |
--
-- Copyright 2018 The wookey project team <wookey@ssi.gouv.fr>
-- - Ryad Benadjila
-- - Arnauld Michelizza
-- - Mathieu Renard
-- - Philippe Thierry
-- - Philippe Trebuchet
--
-- Licensed under the Apache License, Version 2.0 (the "License");
-- you may not use this file except in compliance with the... |
-- (C) Copyright 1999 by John Halleck,All rights reserved.
-- Basic Transformation functions of NSA's Secure Hash Algorithm
-- This is part of a project at http://www.cc.utah.edu/~nahaj/
package body SHA.Process_Data is
Default_Context : Context; -- Standard context for people that don't need
-- ... |
pragma License (Unrestricted);
-- extended unit
package Ada.Enumeration is
-- Interfaces.C.Pointers-like utilities for enumeration types.
pragma Pure;
generic
type Enum is (<>);
type Distance is range <>;
package Arithmetic is
function "+" (Left : Enum; Right : Distance) return Enum
... |
-- Copyright (c) 2019 Maxim Reznik <reznikmm@gmail.com>
--
-- SPDX-License-Identifier: MIT
-- License-Filename: LICENSE
-------------------------------------------------------------
package body Torrent is
-----------
-- Image --
-----------
function Image (Value : SHA1) return SHA1_Image is
use... |
WITH Text_IO;
WITH My_Int_IO;
WITH My_Flt_IO;
WITH Math;
PROCEDURE SquareRoots IS
-- Illustrates the square root function provided by Math
MaxNumber : CONSTANT Positive := 20;
FltNum : Float;
BEGIN -- SquareRoots
Text_IO.Put (Item => "Number Square Root");
Text_IO.New_Line;
Text_IO.Put (Item => "... |
with Interfaces.C; use Interfaces.C;
with System;
package Mysql.My_list is
pragma Preelaborate;
-- arg-macro: function list_rest (a)
-- return (a).next;
-- arg-macro: function list_push (a, b)
-- return a):=list_cons((b),(a);
-- Copyright (C) 2000 MySQL AB
-- This program is free soft... |
-- Copyright (c) 2020-2021 Bartek thindil Jasicki <thindil@laeran.pl>
--
-- This program 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 vers... |
------------------------------------------------------------------------------
-- --
-- GNAT LIBRARY COMPONENTS --
-- --
-- ... |
package body GNAT.Directory_Operations is
procedure Make_Dir (Dir_Name : Dir_Name_Str) is
begin
Ada.Directories.Create_Directory (Dir_Name);
end Make_Dir;
procedure Remove_Dir (
Dir_Name : Dir_Name_Str;
Recursive : Boolean := False) is
begin
if Recursive then
Ada.Direct... |
package Weak2 is
Var : Integer;
pragma Import (Ada, Var, "var_name");
pragma Weak_External (Var);
function F return Integer;
end Weak2;
|
------------------------------------------------------------------------------
-- --
-- Copyright (C) 2019, Fabien Chouteau --
-- --
-- ... |
-----------------------------------------------------------------------
-- servlet-servlets-rest -- REST servlet
-- Copyright (C) 2016, 2017, 2018, 2019, 2020 Stephane Carrez
-- Written by Stephane Carrez (Stephane.Carrez@gmail.com)
--
-- Licensed under the Apache License, Version 2.0 (the "License");
-- you may n... |
package AOC.AOC_2019.Day01 is
type Day_01 is new Day.Day with private;
overriding procedure Init (D : in out Day_01; Root : String);
overriding function Part_1 (D : Day_01) return String;
overriding function Part_2 (D : Day_01) return String;
private
type Mass is new Natural;
subtype Fuel is Mass;
... |
with Helper; use Helper;
package body Normalisation is
-- Centre la figure sur l'axe X
-- Raccorde les extremités de la figure à l'axe
procedure Normaliser(Segments : in out Liste) is
Coords_Min : constant Point2D := Trouver_Coords_Min (Segments);
procedure Normaliser_Point(P : in ... |
-----------------------------------------------------------------------
-- keystore-gpg_tests -- Test AKT with GPG2
-- Copyright (C) 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 exce... |
-- SPDX-FileCopyrightText: 2021 Max Reznik <reznikmm@gmail.com>
--
-- SPDX-License-Identifier: MIT
-------------------------------------------------------------
with Ada.Unchecked_Conversion;
with Interfaces;
with League.String_Vectors;
with League.Regexps;
with League.Text_Codecs;
with League.Stream_Element_Vector... |
-- The Village of Vampire by YT, このソースコードはNYSLです
procedure Tabula.Users.Load (
Name : in String;
Info : in out User_Info);
|
package body Interface_utils
with SPARK_Mode
is
function Convert_C_Bool(input : Extensions.bool) return Boolean
is
begin
if (input > 0) then
return True;
else
return False;
end if;
end Convert_C_Bool;
begin
null;
end Interface_utils;
|
--
-- Provides Kafka functionality to manage messages
--
package Kafka.Message is
--
-- Frees resources for the specified Message and hands ownership back to
-- rdkafka.
--
-- librdkafka equivalent: rd_kafka_message_destroy
--
procedure Destroy(Message : access Message_Type)
with Imp... |
with Giza.Colors; use Giza.Colors;
with Giza.Window; use Giza.Window;
with Giza.Widget.Button; use Giza.Widget.Button;
with Giza.GUI;
use Giza;
package body Basic_Test_Window is
-------------
-- On_Init --
-------------
overriding procedure On_Init
(This : in out Test_Window)
is
... |
with Ada.Integer_Text_IO;
procedure Euler9 is
function Pythagorean(A, B, C: Positive) return Boolean is
(A * A + B * B = C * C);
C: Positive;
begin
for A in Positive range 1 .. 998 loop
for B in Positive range A .. 1000 - A - 1 loop
C := 1000 - A - B;
if Pythagorean(A, B, C) th... |
-- { dg-do compile }
-- { dg-options "-O -gnatn -fdump-tree-optimized" }
package body Array16 is
function F1 (A : access My_T1) return My_T1 is
begin
return A.all;
end;
function F2 (A : access My_T2) return My_T2 is
begin
return A.all;
end;
procedure Proc (A : access My_T1; B : access My_T2) i... |
-- This spec has been automatically generated from STM32WL5x_CM0P.svd
pragma Restrictions (No_Elaboration_Code);
pragma Ada_2012;
pragma Style_Checks (Off);
with HAL;
with System;
package STM32_SVD.TZSC is
pragma Preelaborate;
---------------
-- Registers --
---------------
-- TZIC interrupt enabl... |
-- Copyright (c) 2019 Maxim Reznik <reznikmm@gmail.com>
--
-- SPDX-License-Identifier: MIT
-- License-Filename: LICENSE
-------------------------------------------------------------
with Program.Library_Items;
with Program.Library_Unit_Bodies;
with Program.Library_Unit_Declarations;
with Program.Subunits;
package ... |
-- { dg-do compile }
package body Weak2 is
function F return Integer is
begin
return Var;
end;
end Weak2;
|
------------------------------------------------------------------------------
-- --
-- Ada User Repository Annex (AURA) --
-- ANNEXI-STRAYLINE Reference Implementation --
-- ... |
package Nested_Float_Packed is
type Float_Type is record
Value : Float;
Valid : Boolean;
end record;
type Data_Type is record
Data : Float_Type;
end record;
Default_Data : constant Data_Type :=
(Data => (Value => 1.0, Valid => False));
type Range_Type is (RV1, RV2, RV3);
... |
with Ada.Text_IO; use Ada.Text_IO;
procedure phrases is
function Maju (c : Character) return Character is
begin
if c in 'a'..'z' then
return Character'Val(Character'Pos(c) - 32);
else
return c;
end if;
end Maju;
ch : Character;
nb_a, nb_ne :... |
-- The MIT License (MIT)
--
-- Copyright (c) 2016 artium@nihamkin.com
--
-- 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
-... |
Subsets and Splits
No community queries yet
The top public SQL queries from the community will appear here once available.