declare const niceTry: { (fn: () => T): T | undefined; (val?: any): undefined; promise(fn: (() => PromiseLike) | (() => T)): Promise; promise(val?: any): Promise; }; export = niceTry;