fune/js/src/jsalloc.cpp
Brian Hackett db7742c7f9 Bug 1325050 - Structure reorganization for multithreaded runtimes, r=jandem,jonco,h4writer,luke,lhansen,nbp.
--HG--
extra : rebase_source : 53c8fbae972fbf2f5e9428ce4d2965c8f86e942d
2017-02-02 12:12:43 -07:00

23 lines
637 B
C++

/* -*- Mode: C++; tab-width: 8; indent-tabs-mode: nil; c-basic-offset: 4 -*-
* vim: set ts=8 sts=4 et sw=4 tw=99:
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#include "jsalloc.h"
#include "jscntxt.h"
using namespace js;
void*
TempAllocPolicy::onOutOfMemory(AllocFunction allocFunc, size_t nbytes, void* reallocPtr)
{
return cx_->onOutOfMemory(allocFunc, nbytes, reallocPtr);
}
void
TempAllocPolicy::reportAllocOverflow() const
{
ReportAllocationOverflow(cx_);
}