Fix bound on int codec test
Refactor CoproductCodecBuilder.as