warn on linking of external functions when they have non-matching types

This shows warnings in a project I was sent, where for some bizarre reason some libc functions have different types,

````
link warning: function prototype has non-matching types
i32 (i32)* bitcast (i32 (...)* @close to i32 (i32)*)
declare i32 @close(...) #23

link warning: function prototype has non-matching types
i32 (i32, i32, i32)* bitcast (i32 (...)* @lseek to i32 (i32, i32, i32)*)
declare i32 @lseek(...) #23

link warning: function prototype has non-matching types
i32 (i32, i8*, i32)* bitcast (i32 (...)* @write to i32 (i32, i8*, i32)*)
declare i32 @write(...) #23

link warning: function prototype has non-matching types
i32 (i32)* bitcast (i32 (...)* @close to i32 (i32)*)
declare i32 @close(...) #23

link warning: function prototype has non-matching types
i32 (i32, i8*, i32)* bitcast (i32 (...)* @write to i32 (i32, i8*, i32)*)
declare i32 @write(...) #23
````

The warning makes this much easier to debug (otherwise it could be a weird function pointer failure). But I'm not sure this is a good thing overall - thoughts?