TT3: /home/abw/web/london/tt3/slides/examples/text_concatenation.tt3

Template Source

[% a ~ b # infix text concatenation operator a ~ b ~ c; # chainable (note semi-colon to end expression) ~ a # ~ can be used as a "textify" prefix operator %]--EOF--

Source Tokens

tag_start@0[%
whitespace@2\n
variable@7a
whitespace@8
text combine@9~
whitespace@10
variable@11b
whitespace@12 # infix text concatenation operator\n
variable@63a
whitespace@64
text combine@65~
whitespace@66
variable@67b
whitespace@68
text combine@69~
whitespace@70
variable@71c
delimiter@72;
whitespace@73 # chainable (note semi-colon to end expression)\n
text convert@131~
whitespace@132
variable@133a
whitespace@134 # ~ can be used as a "textify" prefix operator\n
tag_end@194%]
eof@196

Parse Tree

binary expr@9a ~ b
variable element@7a
~
variable element@11b
binary expr@69a ~ b ~ c
binary expr@65a ~ b
variable element@63a
~
variable element@67b
~
variable element@71c
prefix unary expr@131~a
~
variable element@133a

Variables Used

a
Uses
@ line 2 a ~ b # infix text concatenation operator
@ line 3 a ~ b ~ c; # chainable (note semi-colon to end expression)
@ line 4 ~ a # ~ can be used as a "textify" prefix operator
b
Uses
@ line 2 a ~ b # infix text concatenation operator
@ line 3 a ~ b ~ c; # chainable (note semi-colon to end expression)
c
Uses
@ line 3 a ~ b ~ c; # chainable (note semi-colon to end expression)

Generated Output

TT3 undefined data error at line 2 of /home/abw/web/london/tt3/slides/examples/text_concatenation.tt3:
Error: Undefined value returned by expression: a
Source: a ~ b # infix text concatenation operator
^ here