Changed CodeInspector.inspectFile to accept provider.scanFile functions that return the result via a promise

This change enables third party extensions to use the CodeInspector APIs to report errors from external compilers that are triggered via node and thus must be run asynchronously. The change retains backwards compatibility.