File: pp.sig

package info (click to toggle)
mlton 20210117%2Bdfsg-3
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 58,464 kB
  • sloc: ansic: 27,682; sh: 4,455; asm: 3,569; lisp: 2,879; makefile: 2,347; perl: 1,169; python: 191; pascal: 68; javascript: 7
file content (42 lines) | stat: -rw-r--r-- 1,608 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
(*
 * An ``intelligent'' pretty printer
 *)
signature PP =
sig

   type pp (* a piece of pretty printed text *)

   val ++       : pp * pp -> pp      (* combine two pieces of text *)
   val !        : string -> pp       (* an identifier *)
   val !!       : string -> pp       (* a symbol *)
   val int      : int -> pp          (* an integer *)
   val int32    : Int32.int -> pp    (* an integer *)
   val intinf   : IntInf.int -> pp   (* an integer *)
   val char     : char -> pp         (* an ML character *)
   val word     : word -> pp         (* an ML word constant *)
   val word32   : Word32.word -> pp  (* an ML word constant *)
   val real     : real -> pp         (* an ML real constant *)
   val string   : string -> pp       (* an ML string constant *)
   val bool     : bool -> pp         (* a boolean *)
   val nop      : pp                 (* empty text *)
   val indent   : pp                 (* add indentation *)
   val settab   : pp                 (* set the current position as tab *)
   val unindent : pp                 (* remove indentation *)
   val tab      : pp                 (* move to tab position *)
   val tab'     : int -> pp
   val setmode  : string -> pp
   val unsetmode : pp
   val select   : (string -> pp) -> pp
   val sp       : pp
   val nl       : pp
   val nl'      : int * int -> pp    
   val block    : pp -> pp
   val line     : pp -> pp
   val seq      : (pp * pp * pp) -> pp list -> pp
   val paren    : pp -> pp
   val group    : string * string -> pp -> pp
   val concat   : pp list -> pp
   val text     : pp -> string
   val textWidth : int -> pp

end