Fixed missing return value in dom::Value::as_value
Consted a few functions that could/should be const.
Renamed token parameter in dom::Dictionary::get_raw to avoid hiding symbol in parent scope.
Made some comparisons with 0 explicit.
Renamed namespace holding state enum to state_types, to avoid name conflicts.
Removed some unused variables.
Fixed up initialisation of XParser object, and suppressed a few warnings.
as_string now checks that length written was as expected.
Tweak include so that speed_test.cpp would compile cleanly.
StringBuffers now reference-count their data, allowing for simpler (more conventional) copy/assign/destroy sematics.