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