import * as check from "../../../sync/check/undefined"; import {AssertError} from "../../../sync/error/AssertError"; export function assertUndefined (name : string, mixed : any) : (undefined)|never { const error = check.checkUndefined(mixed); if (error === undefined) { return mixed; } else { throw new AssertError(name, error, mixed); } }