## ansi-terminal-prettyprinter.pkg
# Compiled by:
#
src/lib/prettyprint/big/prettyprinter.libstipulate
package fil = file__premicrothread; # file__premicrothread is from
src/lib/std/src/posix/file--premicrothread.pkg package out = ansi_terminal_prettyprint_output_stream; # ansi_terminal_prettyprint_output_stream is from
src/lib/prettyprint/big/src/out/ansi-terminal-prettyprint-output-stream.pkgherein
api Ansi_Terminal_Prettyprinter {
#
package tt: api { # "tt" == "traitful text"
include api Traitful_Text # Traitful_Text is from
src/lib/prettyprint/big/src/traitful-text.api where
Texttraits == out::Texttraits;
traitful_text: (out::Texttraits, String) -> Traitful_Text;
};
include api Base_Prettyprinter # Base_Prettyprinter is from
src/lib/prettyprint/big/src/base-prettyprinter.api where Prettyprint_Output_Stream == out::Prettyprint_Output_Stream
where Texttraits == out::Texttraits
where Traitful_Text == tt::Traitful_Text;
make_ansi_terminal_prettyprinter
:
{ output_stream: fil::Output_Stream
}
-> Prettyprinter;
};
package ansi_terminal_prettyprinter
: (weak) Ansi_Terminal_Prettyprinter
{
package tt # tt == "traitful test".
=
package {
Texttraits = out::Texttraits;
Traitful_Text = TRAITFUL_TEXT (Texttraits, String);
#
traitful_text = TRAITFUL_TEXT;
#
fun string (TRAITFUL_TEXT (texttraits, string)) = string;
fun texttraits (TRAITFUL_TEXT (texttraits, string)) = texttraits;
fun size (TRAITFUL_TEXT (texttraits, string)) = string::length_in_bytes string;
};
package pp
=
base_prettyprinter_g ( # base_prettyprinter_g is from
src/lib/prettyprint/big/src/base-prettyprinter-g.pkg package tt = tt;
package out = out;
);
include package pp;
fun make_ansi_terminal_prettyprinter arg
=
make_prettyprinter (out::make_ansi_terminal_output_stream arg) [];
};
end;
## COPYRIGHT (c) 2005 John Reppy (http://www.cs.uchicago.edu/~jhr)
## All rights reserved.
## Subsequent changes by Jeff Prothero Copyright (c) 2010-2015,
## released per terms of SMLNJ-COPYRIGHT.