package herdtools7

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Module Asllib.PPSource

Pretty-printers for ASL ASTs.

Utils

Sourcetype 'a printer = Format.formatter -> 'a -> unit

A general pretty-printer type.

Sourceval pp_print_seq : ?pp_sep:unit printer -> 'a printer -> 'a Seq.t printer

Re-exported from stdlib 4.12, print q sequence from its elements.

Sourceval pp_pos_str : 'a AST.annotated -> string
Sourceval pp_pos_str_no_char : 'a AST.annotated -> string

Print a position.

AST pretty-printers

Sourceval pp_literal : AST.literal printer

Print a literal from its components.

Sourceval pp_expr : AST.expr printer

Pretty-print an expression.

Sourceval pp_ty : AST.ty printer

Pretty-print a type.

Sourceval pp_typed_identifier : AST.typed_identifier printer

Pretty-print a variable and its type.

Sourceval pp_bitfields : AST.bitfield list printer

Pretty-print a list of bitfields.

Sourceval pp_lexpr : AST.lexpr printer

Pretty-print the left-hand side of an assignment.

Sourceval pp_for_direction : AST.for_direction -> string

Pretty-print keyword of for loop direction

Sourceval pp_stmt : AST.stmt printer

Pretty-print a statement.

Sourceval pp_slice : AST.slice printer

Pretty-print a slice.

Sourceval pp_slice_list : AST.slice list printer

Pretty-print a list of slices.

Sourceval pp_int_constraint : AST.int_constraint printer

Pretty-print an int constraint.

Sourceval pp_int_constraints : AST.int_constraint list printer

Pretty-print a list of int constraints.

Sourceval pp_local_decl_item : AST.local_decl_item printer

Pretty-print a local declaration item.

Sourceval pp_pattern : AST.pattern printer

Pretty-print a pattern.

Sourceval pp_t : AST.t printer

Print an AST from printer for a literal

Sourceval pp_version : [ `ASLv0 | `ASLv1 | `Any ] printer

Print the ASL version.

Pretty-print to strings

Sourceval literal_to_string : AST.literal -> string

Converts a literal into a string.

Sourceval binop_to_string : AST.binop -> string

Writes a binop as an ASL operator.

Sourceval unop_to_string : AST.unop -> string

Writes a unop as an ASL operator.

Sourceval ty_to_string : AST.ty -> string

Converts a type into a string.

Sourceval t_to_string : AST.t -> string

t_to_string v_to_string ast is a string representing ast with literals printed with v_to_string.

OCaml

Innovation. Community. Security.