DOH readme correction
Tidy up scanner.c

Make local functions static and rename them accordingly
beautify scanner.c
More efficient end of template bracket (>>) handling
Fix seg fault with extra ) brackets and >>
Fix use of shift operators in expressions regression since 3.0.0
Further shift operator regression fixes