Fixes issue #703.

The function declaration fd may be null on an indirect call.
LLVM 3.6 fix: stream constructor now takes std::error_code instead of std::string
Use LLVM intrinsic name as mangled name.

If the mangled name is viewed as the name emitted into IR code then the mangled name of an intrinsic is the intrinsic's name.
The name is unique because of the `llvm.` prefix. The only point is that overloaded intrinsics must be resolved earlier.

This commit moves the resolution of oveloaded intrinsics into the semantic analysis pass. The