package catala
sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>
On This Page
Compiler and library for the literate programming language for tax code specification
Install
dune-project
Dependency
Authors
Maintainers
Sources
0.6.0.tar.gz
md5=b22e238d5d5c8452067109e9c7c0f427
sha512=ccc8c557c67c2f9d1bed4b957b2367f0f6afc0ef9b8b83237cf2a2912b3e8829b7e8af78ea7fe00b20ecf28b436ad04b591e5fff4f82fd08725d40a18c9924d0
doc/catala.scopelang/Scopelang/Ast/index.html
Module Scopelang.AstSource
Abstract syntax tree of the scope language
Identifiers
Source
type location = | ScopeVar of ScopeVar.t Utils.Pos.marked| SubScopeVar of ScopeName.t * SubScopeName.t Utils.Pos.marked * ScopeVar.t Utils.Pos.marked
Abstract syntax tree
Source
type typ = | TLit of Dcalc.Ast.typ_lit| TStruct of StructName.t| TEnum of EnumName.t| TArrow of typ Utils.Pos.marked * typ Utils.Pos.marked| TArray of typ| TAny
Source
type expr = | ELocation of location| EVar of expr Bindlib.var Utils.Pos.marked| EStruct of StructName.t * expr Utils.Pos.marked StructFieldMap.t| EStructAccess of expr Utils.Pos.marked * StructFieldName.t * StructName.t| EEnumInj of expr Utils.Pos.marked * EnumConstructor.t * EnumName.t| EMatch of expr Utils.Pos.marked * EnumName.t * expr Utils.Pos.marked EnumConstructorMap.t| ELit of Dcalc.Ast.lit| EAbs of (expr, expr Utils.Pos.marked) Bindlib.mbinder Utils.Pos.marked * typ Utils.Pos.marked list| EApp of expr Utils.Pos.marked * expr Utils.Pos.marked list| EOp of Dcalc.Ast.operator| EDefault of expr Utils.Pos.marked list * expr Utils.Pos.marked * expr Utils.Pos.marked| EIfThenElse of expr Utils.Pos.marked * expr Utils.Pos.marked * expr Utils.Pos.marked| EArray of expr Utils.Pos.marked list| ErrorOnEmpty of expr Utils.Pos.marked
The expressions use the Bindlib library, based on higher-order abstract syntax
Source
type io_input = | NoInput(*For an internal variable defined only in the scope, and does not appear in the input.
*)| OnlyInput(*For variables that should not be redefined in the scope, because they appear in the input.
*)| Reentrant(*For variables defined in the scope that can also be redefined by the caller as they appear in the input.
*)
This type characterizes the three levels of visibility for a given scope variable with regards to the scope's input and possible redefinitions inside the scope..
Source
type io = {io_output : bool Utils.Pos.marked;(*
*)trueis present in the output of the scope.io_input : io_input Utils.Pos.marked;
}Characterization of the input/output status of a scope variable.
Source
type rule = | Definition of location Utils.Pos.marked * typ Utils.Pos.marked * io * expr Utils.Pos.marked| Assertion of expr Utils.Pos.marked| Call of ScopeName.t * SubScopeName.t
Source
type scope_decl = {scope_decl_name : ScopeName.t;scope_sig : (typ Utils.Pos.marked * io) ScopeVarMap.t;scope_decl_rules : rule list;
}Source
type program = {program_scopes : scope_decl ScopeMap.t;program_enums : enum_ctx;program_structs : struct_ctx;
}Variable helpers
Source
val make_abs :
vars ->
expr Utils.Pos.marked Bindlib.box ->
Utils.Pos.t ->
typ Utils.Pos.marked list ->
Utils.Pos.t ->
expr Utils.Pos.marked Bindlib.boxSource
val make_app :
expr Utils.Pos.marked Bindlib.box ->
expr Utils.Pos.marked Bindlib.box list ->
Utils.Pos.t ->
expr Utils.Pos.marked Bindlib.boxSource
val make_let_in :
Var.t ->
typ Utils.Pos.marked ->
expr Utils.Pos.marked Bindlib.box ->
expr Utils.Pos.marked Bindlib.box ->
expr Utils.Pos.marked Bindlib.box sectionYPositions = computeSectionYPositions($el), 10)"
x-init="setTimeout(() => sectionYPositions = computeSectionYPositions($el), 10)"
>
On This Page