Exposed type inference for better code generation