dymokomi/luce-browser-foundation
Source of release 0.6.1
0.6.1 / src / gc / types_weak.lucb
#==============================================================================================
#
# types_weak - declarations of Libraries/LibGC/Weak.h
#
# DESCRIPTION:
# Structs, enums, vtables, class information and cast helpers generated from
# Libraries/LibGC/Weak.h (Ladybird 47c82b38d0) by the skeleton generator (DESIGN.md
# ยง4.4). Regenerate rather than edit, except to fill a field the generator could not
# map.
#
#==============================================================================================
# mark: WeakImpl ================================================================================
## GC::WeakImpl (Libraries/LibGC/Weak.h:18). m_generation replaces m_ref_count (fixed by hand,
## weak.lucb): it counts the times the impl went back to its block's freelist.
pub struct WeakImpl:
pub var m_generation: u64
pub var m_state: WeakImplState # C++ default: { State :: Allocated }
pub var m_ptr: void*? # C++ default: { nullptr }
## GC::WeakImpl::the_null_weak_impl (Libraries/LibGC/Weak.h:21).
pub var weak_impl_the_null_weak_impl: WeakImpl
## GC::WeakImpl::State (Libraries/LibGC/Weak.h:44).
pub enum WeakImplState as i32:
allocated = 0
freelist = 1
# mark: WeakCallback ============================================================================
## The lambda GC::weak_callback returns (Libraries/LibGC/Weak.h:154): a Weak to the object and the
## callback it runs while the object lives.
pub struct WeakCallback[T]:
pub var weak: Weak[T]
pub var cb: ak.Function1[T*, unit]