CDuce/Directives

From Wikibooks, open books for an open world
< CDuce
Jump to: navigation, search

Contents

[edit] #help

The CDuce directive #help lists the available toplevel directives:

#help;;
Toplevel directives:
  #quit;;                 quit the interpreter
  #env;;                  dump current environment
  #reinit_ns;;            reinitialize namespace processing
  #help;;                 shows this help message
  #print_type <type>;;
  #silent;;               turn off outputs from the toplevel
  #verbose;;              turn on outputs from the toplevel
  #builtins;;             shows embedded OCaml values

[edit] #quit

The CDuce directive #quit permits to quit (e.g. exit) the toplevel interpreter. The keys Ctrl-C and Ctrl-D do the same thing.

[edit] #env

The CDuce directive #env lists among other things the defined types.

#env;;
Types: Namespaces AnyXml String Record Latin1 Empty Arrow Float Pair Char Atom Bool Byte Any Int
...

[edit] #print_type

The CDuce directive #print_type shows a representation of a CDuce type.

#print_type String;;
[ Char* ]
Personal tools
Namespaces
Variants
Actions
Navigation
Community
Toolbox
Sister projects
Print/export