ddc-core: make type synthesis work with let bindings