modify Fields type class to use Prim