Use square brackets instead of round brackets for internal tree
structure. This avoids the need for additional escaping since
square brackets are already escaped in Moses.
Also: tweak code style to match the rest of the source file, and
output less whitespace to make the extract files (marginally)
smaller.