fix compile error
fix byte array grow logic
migrate SegmentTermsEnum constructor
fix constructor