This commit is contained in:
syuilo 2019-04-13 14:45:51 +09:00
parent 084135141f
commit 78414dee29
No known key found for this signature in database
GPG Key ID: BDC4C49D06AB9D69

View File

@ -1,3 +1,6 @@
/**
* null undefined
*/
export function ensure<T>(x: T): NonNullable<T> { export function ensure<T>(x: T): NonNullable<T> {
if (x == null) { if (x == null) {
throw 'ぬるぽ'; throw 'ぬるぽ';