mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2025-07-31 05:09:12 +00:00
LibGC+Everywhere: Factor out a LibGC from LibJS
Resulting in a massive rename across almost everywhere! Alongside the namespace change, we now have the following names: * JS::NonnullGCPtr -> GC::Ref * JS::GCPtr -> GC::Ptr * JS::HeapFunction -> GC::Function * JS::CellImpl -> GC::Cell * JS::Handle -> GC::Root
This commit is contained in:
parent
ce23efc5f6
commit
f87041bf3a
Notes:
github-actions[bot]
2024-11-15 13:50:17 +00:00
Author: https://github.com/shannonbooth
Commit: f87041bf3a
Pull-request: https://github.com/LadybirdBrowser/ladybird/pull/2345
1722 changed files with 9939 additions and 9906 deletions
|
@ -13,19 +13,19 @@ namespace Web::IndexedDB {
|
|||
|
||||
class IDBRequest : public DOM::EventTarget {
|
||||
WEB_PLATFORM_OBJECT(IDBRequest, DOM::EventTarget);
|
||||
JS_DECLARE_ALLOCATOR(IDBRequest);
|
||||
GC_DECLARE_ALLOCATOR(IDBRequest);
|
||||
|
||||
public:
|
||||
virtual ~IDBRequest() override;
|
||||
|
||||
[[nodiscard]] JS::Value result() const { return m_result; }
|
||||
[[nodiscard]] JS::GCPtr<WebIDL::DOMException> error() const { return m_error; }
|
||||
[[nodiscard]] GC::Ptr<WebIDL::DOMException> error() const { return m_error; }
|
||||
[[nodiscard]] bool done() const { return m_done; }
|
||||
[[nodiscard]] bool processed() const { return m_processed; }
|
||||
|
||||
void set_done(bool done) { m_done = done; }
|
||||
void set_result(JS::Value result) { m_result = result; }
|
||||
void set_error(JS::GCPtr<WebIDL::DOMException> error) { m_error = error; }
|
||||
void set_error(GC::Ptr<WebIDL::DOMException> error) { m_error = error; }
|
||||
void set_processed(bool processed) { m_processed = processed; }
|
||||
|
||||
void set_onsuccess(WebIDL::CallbackType*);
|
||||
|
@ -46,7 +46,7 @@ private:
|
|||
bool m_done { false };
|
||||
// A request has a result and an error
|
||||
JS::Value m_result;
|
||||
JS::GCPtr<WebIDL::DOMException> m_error;
|
||||
GC::Ptr<WebIDL::DOMException> m_error;
|
||||
// FIXME: A request has a source object.
|
||||
// FIXME: A request has a transaction which is initially null.
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue