Infer type of ctable or carray