Instruction
stringlengths
14
778
input_code
stringlengths
0
4.24k
output_code
stringlengths
1
5.44k
Declare the method binding types
----------------------------------------------------------------------- -- EL.Beans.Methods -- Bean methods -- Copyright (C) 2010 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...
Define the set of string package
----------------------------------------------------------------------- -- Util-strings-sets -- Set of strings -- Copyright (C) 2011 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 i...
Define the ASF.Routes.Servlets.Rest package for the REST route
----------------------------------------------------------------------- -- asf-reoutes-servlets-rest -- Route for the REST API -- Copyright (C) 2016 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use thi...
Declare the Wiki.Plugins.Templates package with the Template_Plugin type
----------------------------------------------------------------------- -- wiki-plugins-template -- Template Plugin -- Copyright (C) 2016 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...
Test that a VIEW_CONVERT_EXPR used as an lvalue has the right type.
-- RUN: %llvmgcc -c %s -o /dev/null procedure VCE_LV is type P is access String ; type T is new P (5 .. 7); subtype U is String (5 .. 7); X : T := new U'(others => 'A'); begin null; end;
Refactor Buffered_Stream and Print_Stream - move the WTR package instantiation in a separate file
----------------------------------------------------------------------- -- util-streams-texts-tr -- Text translation utilities on streams -- Copyright (C) 2010, 2011, 2012, 2015, 2016, 2017 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0...
Define a simple HTML parser that can be used to parse HTML text embedded in wiki text
----------------------------------------------------------------------- -- wiki-parsers-html -- Wiki HTML parser -- Copyright (C) 2015 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 ...
Define the OAuth security filter for AWA applications
----------------------------------------------------------------------- -- awa-oauth-filters -- OAuth filter -- Copyright (C) 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 c...
Add tests for the Util.Commands.Drivers package
----------------------------------------------------------------------- -- util-commands-tests - Test for commands -- Copyright (C) 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 excep...
Define the ping command to ask the Bbox to ping the known devices
----------------------------------------------------------------------- -- druss-commands-ping -- Ping devices from the gateway -- Copyright (C) 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 th...
Implement the Get_Count and Get_Argument operations
----------------------------------------------------------------------- -- util-commands -- Support to make command line tools -- Copyright (C) 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 thi...
Implement the package to read the begin/end events and create the process instance
----------------------------------------------------------------------- -- mat-targets-readers - Definition and Analysis of process start events -- Copyright (C) 2014 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- y...
Add very simple examples for Objects
with Ada.Text_IO; with Ada.Command_Line; with Util.Beans.Objects; procedure ObjCalc is package UBO renames Util.Beans.Objects; use type UBO.Object; Value : UBO.Object := UBO.To_Object (Integer (0)); begin Value := Value + UBO.To_Object (Integer (123)); Value := Value - UBO.To_Object (String '("12")); ...
Implement a simple unit test for MAT.Targets package
----------------------------------------------------------------------- -- mat-readers-tests -- Unit tests for MAT readers -- Copyright (C) 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 fi...
Add new unit tests for the timer management package
----------------------------------------------------------------------- -- util-events-timers-tests -- Unit tests for timers -- Copyright (C) 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 ...
Add the ASIS file $i
------------------------------------------------------------------------------ -- -- -- ASIS-for-GNAT IMPLEMENTATION COMPONENTS -- -- -- -- ...
Implement the Initialize procedure with SSL support (AWS version starting from gnat-2015)
----------------------------------------------------------------------- -- awa-mail-clients-aws_smtp-initialize -- Initialize SMTP client with SSL support -- Copyright (C) 2016 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "Licens...
Add the package to build the generated Ada packages (UML packages test)
----------------------------------------------------------------------- -- Test -- Test the code generation -- Copyright (C) 2012 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...
Define the Facebook authentication by using OAuth and Facebook Graph API
----------------------------------------------------------------------- -- security-auth-oauth-facebook -- Facebook OAuth based authentication -- Copyright (C) 2013 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you...
Add test for YAML model support
----------------------------------------------------------------------- -- gen-artifacts-yaml-tests -- Tests for YAML model files -- Copyright (C) 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 ...
Add simple example for text transformations
----------------------------------------------------------------------- -- escape -- Text Transformations -- Copyright (C) 2001, 2002, 2003, 2006, 2008, 2009, 2010 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you ...
Implement a new test to verify the Base64 encoding stream
----------------------------------------------------------------------- -- util-streams-buffered-encoders-tests -- Unit tests for encoding buffered streams -- Copyright (C) 2017 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "Licen...
Implement the operations for the SHA256 package
----------------------------------------------------------------------- -- util-encoders-sha256 -- Compute SHA-1 hash -- Copyright (C) 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 ex...
Add missing ads file for package Orka.SIMD.AVX.Longs.Convert
-- 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/L...
Define the Cache_Control package with Cache_Control_Filter type to add a Cache-Control, Vary headers in the HTTP response
----------------------------------------------------------------------- -- asf-filters-cache_control -- HTTP response Cache-Control settings -- Copyright (C) 2015 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you m...
Implement the Get_Value procedure for the Counter_Bean
----------------------------------------------------------------------- -- awa-counters-beans -- Counter bean definition -- Copyright (C) 2015 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...
Implement the Initialize procedure for AWS version before gnat-2015 (aws 3.1)
----------------------------------------------------------------------- -- awa-mail-clients-aws_smtp-initialize -- Initialize SMTP client without SSL support -- Copyright (C) 2016 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "Lic...
Add the ASIS file $i
------------------------------------------------------------------------------ -- -- -- ASIS-for-GNAT IMPLEMENTATION COMPONENTS -- -- -- -- ...
Define the Facebook authentication by using OAuth and Facebook Graph API
----------------------------------------------------------------------- -- security-auth-oauth-facebook -- Facebook OAuth based authentication -- Copyright (C) 2013 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you...
Implement the new unit tests for the timer management
----------------------------------------------------------------------- -- util-events-timers-tests -- Unit tests for timers -- Copyright (C) 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 ...
Declare the Conditions package with the Condition_Plugin type for the support of conditional inclusion in wiki text
----------------------------------------------------------------------- -- wiki-plugins-conditions -- Condition Plugin -- Copyright (C) 2016 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 e...
Implement the Get_Permission and Register operations
----------------------------------------------------------------------- -- asf-rest -- REST Support -- Copyright (C) 2016 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...
Define some new tests for the database drivers support
----------------------------------------------------------------------- -- ado-drivers-tests -- Unit tests for database drivers -- Copyright (C) 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 th...
Add the new tests for Headers package
----------------------------------------------------------------------- -- util-http-headers-tests - Unit tests for Headers -- Copyright (C) 2022 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 f...
Define the store interface to support several storage services (file, database, Amazon)
----------------------------------------------------------------------- -- awa-storages-stores -- The storage interface -- Copyright (C) 2012 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 ...
Add the ASIS file $i
------------------------------------------------------------------------------ -- -- -- ASIS-for-GNAT IMPLEMENTATION COMPONENTS -- -- -- -- ...
Implement a test filter that counts the number of times it is traversed
----------------------------------------------------------------------- -- Filters Tests - Unit tests for ASF.Filters -- Copyright (C) 2015 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 ex...
Define the OAuth based authorization
----------------------------------------------------------------------- -- security-auth-oauth -- OAuth based authentication -- 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 ...
Define a method and binding for an Ada bean to receive an uploaded file
----------------------------------------------------------------------- -- asf-parts -- ASF Parts -- Copyright (C) 2011, 2012 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 compli...
Declare the Wiki.Streams.Html.Builders package for the HTML output stream
----------------------------------------------------------------------- -- wiki-streams-html-builders -- Wiki writer to a string builder -- Copyright (C) 2011, 2012, 2013, 2015, 2016 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "...
Declare the method binding types
----------------------------------------------------------------------- -- EL.Beans.Methods -- Bean methods -- Copyright (C) 2010 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...
Implement To_Identifier and To_Object operations
----------------------------------------------------------------------- -- ado-utils -- Utility operations for ADO -- 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 excep...
Declare the AWA.OAuth.Services package with the Auth_Manager
----------------------------------------------------------------------- -- awa-oauth-services -- OAuth Server Side -- Copyright (C) 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 excep...
Implement the Initialize, Get and Get_Gateways operations
----------------------------------------------------------------------- -- druss-config -- Configuration management for Druss -- Copyright (C) 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...
Add package AWA.Commands.Info to report configuration information
----------------------------------------------------------------------- -- akt-commands-info -- Info command to describe the current configuration -- Copyright (C) 2020 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- ...
Implement the GNAT_Parser package to parse arguments using GNAT Getopt
----------------------------------------------------------------------- -- util-commands-parsers.gnat_parser -- GNAT command line parser for command drivers -- Copyright (C) 2018 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "Lice...
Implement the unit test on datasets
----------------------------------------------------------------------- -- ado-datasets-tests -- Test executing queries and using 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...
Add a new set of unit tests for the date converter
----------------------------------------------------------------------- -- asf-converters-tests - Unit tests for ASF.Converters -- Copyright (C) 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 th...
Implement the Frames_Types package to protect the frame creation in multi-threaded contexts
----------------------------------------------------------------------- -- mat-frames-targets - Representation of stack frames -- Copyright (C) 2015 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use thi...
Implement the operations for the <mail:attachment> component
----------------------------------------------------------------------- -- awa-mail-components-attachments -- Mail UI Attachments -- 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 ...
Add navigation rule unit test
----------------------------------------------------------------------- -- asf-navigations-tests - Tests for ASF navigation -- 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 ...
Add a unit test for the babel stream compositions
----------------------------------------------------------------------- -- babel-streams-tests - Unit tests for babel streams -- Copyright (C) 2015 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...
Add the package to build the generated Ada packages (UML packages test)
----------------------------------------------------------------------- -- Test -- Test the code generation -- Copyright (C) 2012 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...
Define a vectors of objects
----------------------------------------------------------------------- -- Util.Beans.Objects.Vectors -- Object vectors -- Copyright (C) 2011 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 ...
Add the ASIS file $i
------------------------------------------------------------------------------ -- -- -- ASIS-for-GNAT IMPLEMENTATION COMPONENTS -- -- -- -- ...
Package ASF.Servlets.Files renames Servlet.Core.Files but make it obscolesent (provided as backward compatibility)
----------------------------------------------------------------------- -- asf-servlets-files -- Files servlet -- Copyright (C) 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...
Add unit tests for OAuth package and Create_Nonce operation
----------------------------------------------------------------------- -- Security-oauth-clients-tests - Unit tests for OAuth -- 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 thi...
Define the OAuth based authorization
----------------------------------------------------------------------- -- security-auth-oauth -- OAuth based authentication -- 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 ...
Implement the Set_Buffer and Finalize procedures
----------------------------------------------------------------------- -- babel-Streams -- Stream management -- Copyright (C) 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 use this file exce...
Implement the Cache_Control_Filter to add a Cache-Control and Vary header in the HTTP response
----------------------------------------------------------------------- -- asf-filters-cache_control -- HTTP response Cache-Control settings -- Copyright (C) 2015 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you m...
Add the ASIS file $i
------------------------------------------------------------------------------ -- -- -- ASIS-for-GNAT INTERFACE COMPONENTS -- -- -- -- ...
Declare the AWA.Images.Servlets package with the Image_Servlet type
----------------------------------------------------------------------- -- awa-images-servlets -- Serve images saved in the storage service -- Copyright (C) 2016 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you ma...
Define ASF.Rest package for the server-side API REST support
----------------------------------------------------------------------- -- asf-rest -- REST Support -- Copyright (C) 2016 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...
Add unit tests for JWT
----------------------------------------------------------------------- -- Security-oayth-jwt-tests - Unit tests for JSON Web Token -- 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 us...
Package to implement the Load_Schema procedure
----------------------------------------------------------------------- -- ado-schemas-sqlite -- SQLite Database Schemas -- Copyright (C) 2015 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...
Refactor Buffered_Stream and Print_Stream - move the TR package instantiation in a separate file
----------------------------------------------------------------------- -- util-streams-texts-tr -- Text translation utilities on streams -- Copyright (C) 2010, 2011, 2012, 2015, 2016, 2017 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0...
Implement operations to set the key and IV for AES-128/196/256 encryption and decryption streams
----------------------------------------------------------------------- -- util-streams-aes -- AES encoding and decoding streams -- Copyright (C) 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 t...
Implement the Print_Field procedure for addresses
----------------------------------------------------------------------- -- mat-consoles - Console interface -- Copyright (C) 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 co...
Add Split_Header (moved from Ada Server Faces)
----------------------------------------------------------------------- -- util-http-headers -- HTTP Headers -- Copyright (C) 2022 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 c...
Test handling of record fields with negative offsets.
-- RUN: %llvmgcc -c %s with System; procedure Negative_Field_Offset (N : Integer) is type String_Pointer is access String; -- Force use of a thin pointer. for String_Pointer'Size use System.Word_Size; P : String_Pointer; begin P := new String (1 .. N); end;
Test handling of ARRAY_REF when the component type is of unknown size.
-- RUN: %llvmgcc -c %s -o /dev/null procedure Array_Ref is type A is array (Natural range <>, Natural range <>) of Boolean; type A_Access is access A; function Get (X : A_Access) return Boolean is begin return X (0, 0); end; begin null; end;
Implement the implicit object 'requestScope'
----------------------------------------------------------------------- -- asf-beans-requests -- Bean giving access to the request object -- Copyright (C) 2017 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may ...
Implement the Insert and Get_Event_Counter operations
----------------------------------------------------------------------- -- mat-events-targets - Events received and collected from a target -- Copyright (C) 2014 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you ma...
Define a set of interface to send an email and have several possible implementations
----------------------------------------------------------------------- -- awa-mail-client -- Mail client interface -- Copyright (C) 2012 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...
Add unit test for Parse_Form procedure
----------------------------------------------------------------------- -- util-properties-form-tests -- Test reading form file into properties -- Copyright (C) 2020 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- yo...
Add unit tests for local store and Read_File/Write_File operations
----------------------------------------------------------------------- -- babel-stores-local-tests - Unit tests for babel streams -- Copyright (C) 2016 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may not use...
Add blog servlets definition with Image_Servlet type
----------------------------------------------------------------------- -- awa-blogs-servlets -- Serve files saved in the storage service -- Copyright (C) 2017 Stephane Carrez -- Written by Stephane Carrez (Stephane.Carrez@gmail.com) -- -- Licensed under the Apache License, Version 2.0 (the "License"); -- you may ...
Define the factory for the creation of widget components
----------------------------------------------------------------------- -- widgets-factory -- Factory for widget Components -- 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 f...
Move function-specific comment right before function
module Base.Change.Context {Type : Set} (ΔType : Type → Type) where -- Transform a context of values into a context of values and -- changes. open import Base.Syntax.Context Type ΔContext : Context → Context ΔContext ∅ = ∅ ΔContext (τ • Γ) = ΔType τ • τ • ΔContext Γ -- like ΔContext, but ΔType τ and τ are s...
module Base.Change.Context {Type : Set} (ΔType : Type → Type) where open import Base.Syntax.Context Type -- Transform a context of values into a context of values and -- changes. ΔContext : Context → Context ΔContext ∅ = ∅ ΔContext (τ • Γ) = ΔType τ • τ • ΔContext Γ -- like ΔContext, but ΔType τ and τ are s...
Add Any predicate for binary tree
{-# OPTIONS --without-K #-} open import Type hiding (★) module Data.Tree.Binary where data BinTree {a} (A : ★ a) : ★ a where empty : BinTree A leaf : A → BinTree A fork : (ℓ r : BinTree A) → BinTree A
{-# OPTIONS --without-K #-} open import Type hiding (★) open import Level open import Data.Zero open import Data.Sum module Data.Tree.Binary where data BinTree {a} (A : ★ a) : ★ a where empty : BinTree A leaf : A → BinTree A fork : (ℓ r : BinTree A) → BinTree A Any : ∀ {a p}{A : ★ a}(P : A → ★ p) → BinTree ...
Add alternative defintion for IND CPA
{-# OPTIONS --without-K #-} open import Type open import Data.Product open import Data.Bit module Game.IND-CPA-alt (PubKey : ★) (SecKey : ★) (Message : ★) (CipherText : ★) -- randomness supply for: encryption, key-generation, adversary, extensions (Rₑ Rₖ Rₐ : ★) (KeyGen : Rₖ → PubKey × SecK...
Add incomplete note on co-inductive natural numbers.
------------------------------------------------------------------------------ -- Definition of FOTC Conat using Agda's co-inductive combinators ------------------------------------------------------------------------------ {-# OPTIONS --allow-unsolved-metas #-} {-# OPTIONS --no-universe-polymorphism #-} {-# OPTIONS -...
Move function-specific comment right before function
module Base.Change.Context {Type : Set} (ΔType : Type → Type) where -- Transform a context of values into a context of values and -- changes. open import Base.Syntax.Context Type ΔContext : Context → Context ΔContext ∅ = ∅ ΔContext (τ • Γ) = ΔType τ • τ • ΔContext Γ -- like ΔContext, but ΔType τ and τ are s...
module Base.Change.Context {Type : Set} (ΔType : Type → Type) where open import Base.Syntax.Context Type -- Transform a context of values into a context of values and -- changes. ΔContext : Context → Context ΔContext ∅ = ∅ ΔContext (τ • Γ) = ΔType τ • τ • ΔContext Γ -- like ΔContext, but ΔType τ and τ are s...
Improve printing of resolved overloading.
module meaning where open import Level record Meaning (Syntax : Set) {ℓ : Level} : Set (suc ℓ) where constructor meaning field {Semantics} : Set ℓ ⟦_⟧ : Syntax → Semantics open Meaning {{...}} public
module meaning where open import Level record Meaning (Syntax : Set) {ℓ : Level} : Set (suc ℓ) where constructor meaning field {Semantics} : Set ℓ ⟨_⟩⟦_⟧ : Syntax → Semantics open Meaning {{...}} public renaming (⟨_⟩⟦_⟧ to ⟦_⟧) open Meaning public using (⟨_⟩⟦_⟧)
Add Any predicate for binary tree
{-# OPTIONS --without-K #-} open import Type hiding (★) module Data.Tree.Binary where data BinTree {a} (A : ★ a) : ★ a where empty : BinTree A leaf : A → BinTree A fork : (ℓ r : BinTree A) → BinTree A
{-# OPTIONS --without-K #-} open import Type hiding (★) open import Level open import Data.Zero open import Data.Sum module Data.Tree.Binary where data BinTree {a} (A : ★ a) : ★ a where empty : BinTree A leaf : A → BinTree A fork : (ℓ r : BinTree A) → BinTree A Any : ∀ {a p}{A : ★ a}(P : A → ★ p) → BinTree ...
Add alternative defintion for IND CPA
{-# OPTIONS --without-K #-} open import Type open import Data.Product open import Data.Bit module Game.IND-CPA-alt (PubKey : ★) (SecKey : ★) (Message : ★) (CipherText : ★) -- randomness supply for: encryption, key-generation, adversary, extensions (Rₑ Rₖ Rₐ : ★) (KeyGen : Rₖ → PubKey × SecK...
Add incomplete note on co-inductive natural numbers.
------------------------------------------------------------------------------ -- Definition of FOTC Conat using Agda's co-inductive combinators ------------------------------------------------------------------------------ {-# OPTIONS --allow-unsolved-metas #-} {-# OPTIONS --no-universe-polymorphism #-} {-# OPTIONS -...
Update grammar for our Workflow Catalog Query Language (WCQL)
grammar WorkflowCatalogQueryLanguage; @header { package org.ow2.proactive.workflow_catalog.rest.query; } clause: ATTRIBUTE OPERATOR VALUE ; clauses: clause ( CONJUNCTION clause )* ; statement: '(' clauses ')' | clauses ; ATTRIBUTE: ([a-z] | [A-Z])+ ([_.]+ ([a-z] | [A-Z] | [0-9])*)* ; CONJUNCTION: 'AND' | 'OR' ; O...
grammar WorkflowCatalogQueryLanguage; @header { package org.ow2.proactive.workflow_catalog.rest.query; } // PARSER expression : and_expression ; and_expression : or_expression (AND or_expression)* ; or_expression : clause (OR clause)* ; clause : (AttributeLiteral COMPARE_OPERATOR St...
Make investment size spec optional
grammar InvestmentSize; import Tokens; @header { import com.github.robozonky.strategy.natural.*; } investmentSizeExpression returns [Collection<InvestmentSize> result]: { Collection<InvestmentSize> result = new LinkedHashSet<>(); } (i=investmentSizeRatingExpression { result.add($i.result); })+ { $result = res...
grammar InvestmentSize; import Tokens; @header { import com.github.robozonky.strategy.natural.*; } investmentSizeExpression returns [Collection<InvestmentSize> result]: { Collection<InvestmentSize> result = new LinkedHashSet<>(); } (i=investmentSizeRatingExpression { result.add($i.result); })* { $result = res...
Add joinExpression to the relationalExpression
grammar Relational; relationalExpression : unionExpression ; unionExpression : 'union' '(' datasetExpression (',' datasetExpression )* ')' ; datasetExpression : 'datasetExpr' NUM+; NUM : '0'..'9' ; WS : [ \t\n\t] -> skip ;
grammar Relational; relationalExpression : unionExpression | joinExpression ; unionExpression : 'union' '(' datasetExpression (',' datasetExpression )* ')' ; datasetExpression : 'datasetExpr' NUM+; joinExpression : '[' (INNER | OUTER | CROSS ) datasetExpression (',' datasetExpression )* ']' joinClause (',' joinClau...
Change antler grammar to support new type API
grammar Type; CT : [A-Z][a-z]+ ; VT : [a-z]+ ; WS : [ \t\r\n]+ -> skip ; type : functionType | compoundType; // function type functionType : compoundType ('->' type)+ ; compoundType : concreteType | tupleType | listType | parenType ; tupleType : '(' type (',' type)+ ')' ; // tuple type, k>=2 listType : '[' type ']' ...
grammar Type; CT : [A-Z][a-z]+ ; VT : [a-z]+ ; WS : [ \t\r\n]+ -> skip ; type : functionType | compoundType ; // function type functionType : compoundType '->' type ; compoundType : constantType | variableType | tupleType | listType | parenType ; tupleType : '(' type (',' type)+ ')' ; // tuple type, k>=2 listType : ...
Allow numeric digits also in the identifier names.
grammar Expression; expression : sign = ('-' | '+') expression | subExpresion | left = expression op = POW right = expression | left = expression op = ( MULT | DIV ) right = expression | left = expression op = ( ADD | SUB ) right = expression | function | value = ( IDENT | CONST ) ; subExpresion...
grammar Expression; expression : sign = ('-' | '+') expression | subExpresion | left = expression op = POW right = expression | left = expression op = ( MULT | DIV ) right = expression | left = expression op = ( ADD | SUB ) right = expression | function | value = ( IDENT | CONST ) ; subExpresion...
Add comment to the parser grammar
/*- * #%L * Java VTL * %% * Copyright (C) 2016 Hadrien Kohl * %% * 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 req...
/*- * #%L * Java VTL * %% * Copyright (C) 2016 Hadrien Kohl * %% * 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 req...
Fix issue with lexing type classes with an uppercase character after the first position
grammar Type; CT : [A-Z][a-z]+ ; VT : [a-z]+ ; WS : [ \t\r\n]+ -> skip ; type : typeClasses ? innerType ; innerType : functionType | compoundType ; // function type functionType : compoundType '->' innerType ; compoundType : constantType | variableType | tupleType | listType | parenType ; tupleType : '(' innerType (...
grammar Type; CT : [A-Z][A-Za-z]+ ; VT : [a-z]+ ; WS : [ \t\r\n]+ -> skip ; type : (typeClasses '=>')? innerType ; innerType : functionType | compoundType ; // function type functionType : compoundType '->' innerType ; compoundType : constantType | variableType | tupleType | listType | parenType ; tupleType : '(' in...
Fix bug in Antlr grammar
grammar Type; CT : [A-Z][a-z]+ ; VT : [a-z]+ ; WS : [ \t\r\n]+ -> skip ; baseType : typeClasses ? type ; type : functionType | compoundType ; // function type functionType : compoundType '->' type ; compoundType : constantType | variableType | tupleType | listType | parenType ; tupleType : '(' type (',' type)+ ')' ;...
grammar Type; CT : [A-Z][a-z]+ ; VT : [a-z]+ ; WS : [ \t\r\n]+ -> skip ; type : typeClasses ? innerType ; innerType : functionType | compoundType ; // function type functionType : compoundType '->' innerType ; compoundType : constantType | variableType | tupleType | listType | parenType ; tupleType : '(' innerType (...
Add comments to input grammar.
grammar PTP; @header { package pt.up.fe.iart.proj1.parser; } map : stmt+ ; stmt : node_stmt #node | edge_stmt #edge ; edge_stmt : 'Edge' '(' from=node_stmt ',' to=node_stmt ',' weight=(INT|REAL) ')'; node_stmt : 'GasStation' '(' position ')' #GasStation | 'GenericLocation' '...
grammar PTP; @header { package pt.up.fe.iart.proj1.parser; } map : stmt+ ; stmt : node_stmt #node | edge_stmt #edge ; edge_stmt : 'Edge' '(' from=node_stmt ',' to=node_stmt ',' weight=(INT|REAL) ')'; node_stmt : 'GasStation' '(' position ')' #GasStation | 'GenericLocation' '...
Add single type class notation to type parser
grammar Type; CT : [A-Z][a-z]+ ; VT : [a-z]+ ; WS : [ \t\r\n]+ -> skip ; type : typeClasses ? innerType ; innerType : functionType | compoundType ; // function type functionType : compoundType '->' innerType ; compoundType : constantType | variableType | tupleType | listType | parenType ; tupleType : '(' innerType (...
grammar Type; CT : [A-Z][a-z]+ ; VT : [a-z]+ ; WS : [ \t\r\n]+ -> skip ; type : typeClasses ? innerType ; innerType : functionType | compoundType ; // function type functionType : compoundType '->' innerType ; compoundType : constantType | variableType | tupleType | listType | parenType ; tupleType : '(' innerType (...
Add first attempt at track grammar
grammar Track; track: track_decl decl* ; track_decl: 'track' '{' IDENT+ '}' ; decl: block_decl | channel_decl ; block_decl: IDENT '::' 'block' '{' block_body '}' ; block_body: (note)+ ; note: NOTENAME OCTAVE? LENGTH? ; channel_decl: IDENT '::' 'channel' WAVE '{' channel_body '}' ; channel_body: (block_name)+ ; blo...
Add grammar in ANTLR 4 format
grammar Viper; tokens { NAME , NEWLINE , INDENT , DEDENT , NUMBER , STRING } func_def: 'def' func_name parameters '->' func_type ':' suite ; func_name: NAME ; func_type: type_expr ; parameters: '(' params_list? ')' ; params_list: argless_parameter parameter* ; parameter: arg...
Remove .php extensions from url
server { server_name default; root /var/www/public; index main.php; client_max_body_size 100M; fastcgi_read_timeout 1800; location / { try_files $uri $uri/ /index.php$is_args$args; } location /status { access_log off; allow 172.17.0.0/16; deny all; include /etc/ng...
server { server_name default; root /var/www/public; index main.php; client_max_body_size 100M; fastcgi_read_timeout 1800; location / { try_files $uri $uri.html $uri/ @extensionless-php; } location @extensionless-php { rewrite ^(.*)$ $1.php last; } location /status { acc...