diff options
author | William Joye <wjoye@cfa.harvard.edu> | 2016-10-27 19:39:39 (GMT) |
---|---|---|
committer | William Joye <wjoye@cfa.harvard.edu> | 2016-10-27 19:39:39 (GMT) |
commit | ea28451286d3ea4a772fa174483f9a7a66bb1ab3 (patch) | |
tree | 6ee9d8a7848333a7ceeee3b13d492e40225f8b86 /tcllib/modules/pt/include/format/options_container.inc | |
parent | b5ca09bae0d6a1edce939eea03594dd56383f2c8 (diff) | |
parent | 7c621da28f07e449ad90c387344f07a453927569 (diff) | |
download | blt-ea28451286d3ea4a772fa174483f9a7a66bb1ab3.zip blt-ea28451286d3ea4a772fa174483f9a7a66bb1ab3.tar.gz blt-ea28451286d3ea4a772fa174483f9a7a66bb1ab3.tar.bz2 |
Merge commit '7c621da28f07e449ad90c387344f07a453927569' as 'tcllib'
Diffstat (limited to 'tcllib/modules/pt/include/format/options_container.inc')
-rw-r--r-- | tcllib/modules/pt/include/format/options_container.inc | 60 |
1 files changed, 60 insertions, 0 deletions
diff --git a/tcllib/modules/pt/include/format/options_container.inc b/tcllib/modules/pt/include/format/options_container.inc new file mode 100644 index 0000000..4ebff51 --- /dev/null +++ b/tcllib/modules/pt/include/format/options_container.inc @@ -0,0 +1,60 @@ +[list_begin options] +[include options_std.inc] + +[opt_def -mode [const bulk]|[const incremental]] + +The value of this option controls which methods of + +[package pt::peg::container] instances are used to specify the +grammar, i.e. preload it into the container. There are two legal +values, as listed below. The default is [const bulk]. + +[list_begin definitions] +[def [const bulk]] + +In this mode the methods [method start], [method add], [method modes], +and [method rules] are used to specify the grammar in a bulk manner, +i.e. as a set of nonterminal symbols, and two dictionaries mapping +from the symbols to their semantic modes and parsing expressions. + +[para] + +This mode is the default. + +[def [const incremental]] + +In this mode the methods [method start], [method add], [method mode], +and [method rule] are used to specify the grammar piecemal, with each +nonterminal having its own block of defining commands. + +[list_end] + +[opt_def -template string] + +The value of this option is a string into which to put the generated +code and the other configuration settings. The various locations for +user-data are expected to be specified with the placeholders listed +below. The default value is "[const @code@]". + +[list_begin definitions] + +[def [const @user@]] +To be replaced with the value of the option [option -user]. + +[def [const @format@]] +To be replaced with the the constant [const CONTAINER]. + +[def [const @file@]] +To be replaced with the value of the option [option -file]. + +[def [const @name@]] +To be replaced with the value of the option [option -name]. + +[def [const @mode@]] +To be replaced with the value of the option [option -mode]. + +[def [const @code@]] +To be replaced with the generated code. + +[list_end] +[list_end] |