Fix compiler type errors