fixes test_memory_chunk.cpp
update test_parser2.cpp
update spseg.cpp
update ngseg.cpp