summaryrefslogtreecommitdiff
path: root/Userland/Libraries/LibJS/Runtime/SuppressedError.cpp
blob: a7edd888a9738de36ec645e411d8a4b0a4d5d7d9 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
/*
 * Copyright (c) 2022, David Tuin <davidot@serenityos.org>
 *
 * SPDX-License-Identifier: BSD-2-Clause
 */

#include <LibJS/Runtime/Error.h>
#include <LibJS/Runtime/GlobalObject.h>
#include <LibJS/Runtime/SuppressedError.h>

namespace JS {

NonnullGCPtr<SuppressedError> SuppressedError::create(Realm& realm)
{
    return *realm.heap().allocate<SuppressedError>(realm, *realm.intrinsics().suppressed_error_prototype()).release_allocated_value_but_fixme_should_propagate_errors();
}

SuppressedError::SuppressedError(Object& prototype)
    : Error(prototype)
{
}

}