fix XCN type and change meaning of '~' as separator to first-level repeater