CurryInfo: currypp-3.2.0

categories:
Programming Analysis
dependencies:
[Dependency "base" [[VGte "3.2.0",VLt "4.0.0"]],Dependency "abstract-curry" [[VGte "3.0.0",VLt "5.0.0"]],Dependency "cass-analysis" [[VGte "3.0.0",VLt "5.0.0"]],Dependency "cass" [[VGte "3.0.0",VLt "5.0.0"]],Dependency "cdbi" [[VGte "3.0.0",VLt "4.0.0"]],Dependency "containers" [[VGte "3.0.0",VLt "4.0.0"]],Dependency "contracts" [[VGte "3.0.0",VLt "4.0.0"]],Dependency "currycheck" [[VGte "3.0.0",VLt "5.0.0"]],Dependency "currypath" [[VGte "3.0.0",VLt "4.0.0"]],Dependency "directory" [[VGte "3.0.0",VLt "4.0.0"]],Dependency "filepath" [[VGte "3.0.0",VLt "4.0.0"]],Dependency "fl-parser" [[VGte "3.0.0",VLt "4.0.0"]],Dependency "flatcurry" [[VGte "3.0.0",VLt "5.0.0"]],Dependency "frontend-exec" [[VGte "3.0.0",VLt "4.0.0"]],Dependency "html2" [[VGte "3.0.0",VLt "4.0.0"]],Dependency "process" [[VGte "3.0.0",VLt "4.0.0"]],Dependency "printf" [[VGte "3.0.0",VLt "4.0.0"]],Dependency "regexp" [[VGte "4.0.0"]],Dependency "time" [[VGte "3.0.0",VLt "4.0.0"]],Dependency "wl-pprint" [[VGte "3.0.0",VLt "4.0.0"]],Dependency "xml" [[VGte "3.0.0",VLt "4.0.0"]]]
documentation:
The Curry Preprocessor
======================

This package contains the implementation of the
Curry preprocessor `currypp` which supports some
extensions for Curry programs, like

* integrated code, i.e., the integration of code
  written in some other language into Curry programs,
  like regular expressions, format specifications (`printf`),
  HTML and XML code,
* [default rules](http://doi.org/10.1017/S1471068416000168),
* [contracts](http://dx.doi.org/10.1007/978-3-642-27694-1_4).

Details about the usage can be found in the manual.
Here is a short summary how to use integrated code
in Curry programs.


General usage of the code integrator:
-------------------------------------

If the pre-processor is installed as the binary `currypp`,
Curry source files containing integrated code can be translated
by running `currypp` as follows:

    currypp <org-filename> <input-file> <output-file> foreigncode [-o]

The parameters are:

* The name of the original Curry source file.
* The name of the file containing the input to be translated.
* The name of the output file where the translated code should be stored.
* If the optional parameter `-o` is given, a copy of the translated code
  is stored in the file `org-filename.CURRYPP`.
* To preprocess SQL statements, you might add the option

       --model:<modelname>_SQLCode.info

  to use a non-standard info file for the database model


Writing files with integrated code:
-----------------------------------

The basic syntax of integrated code in Curry program looks like

    ``langtag expression''

Here, `langtag` is a tag indicating the kind of integrated language,
and `expression` is an expression of this language.

If enclosing accents are used in the expression itself,
the actual enclosing accents need to be of a higher number
than the inner graves, i.e., the following
integrated code expression is also allowed:

    ````langtag expression''''

The number of opening and closing accents must always be identical.

Currently, the following `langtag` values are supported:

* `format` - `printf` Syntax
* `printf` - same as above (but with an implicit `putStr` call)
* `regex`  - Polymorphic regex expressions
* `html`   - Standard HTML
* `xml`    - Standard XML
* `sql`    - SQL syntax

See the examples and source file comments for further details.
exportedmodules:
Main
modules:
CPP.CompileWithFrontend CPP.Contracts CPP.Config CPP.Helpers CPP.DefaultRules CPP.ICode.ICodeParser CPP.ICode.ParseMonad CPP.ICode.ParseError CPP.ICode.ParseTypes CPP.ICode.ParsePos CPP.ICode.ParseWarning CPP.ICode.TransICode CPP.ICode.Parser.RegexParser CPP.ICode.Parser.DummyParser CPP.ICode.Parser.FormatParser CPP.ICode.Parser.ML.Types CPP.ICode.Parser.ML.Translate CPP.ICode.Parser.ML.HTMLContentModel CPP.ICode.Parser.ML.Parser CPP.ICode.Parser.ML.Warning CPP.ICode.Parser.SQL.Converter CPP.ICode.Parser.SQL.ParserTypes CPP.ICode.Parser.SQL.Scanner CPP.ICode.Parser.SQL.AST CPP.ICode.Parser.SQL.ParserInfoType CPP.ICode.Parser.SQL.Typer CPP.ICode.Parser.SQL.Translator CPP.ICode.Parser.SQL.Namer CPP.ICode.Parser.SQL.Token CPP.ICode.Parser.SQL.Parser CPP.ICode.Parser.SQL.Consistency CPP.ICode.Parser.SQL.Symboltab Main
version:
3.2.0