[2.0] More preparations to fix character casing issue. Reverted and completed ConditionalPrimary parsing and added more tests for this.