Take out gcb2gtype and gtype2gcb fns. They were using symbols not defined