Commit graph

11 commits

Author SHA1 Message Date
Andreas Kling d343fb2429 AK: Rename Retainable.h => RefCounted.h. 2019-06-21 18:58:45 +02:00
Andreas Kling 77b9fa89dd AK: Rename Retainable => RefCounted.
(And various related renames that go along with it.)
2019-06-21 15:30:03 +02:00
Robin Burchell 0dc9af5f7e Add clang-format file
Also run it across the whole tree to get everything using the One True Style.
We don't yet run this in an automated fashion as it's a little slow, but
there is a snippet to do so in makeall.sh.
2019-05-28 17:31:20 +02:00
Andreas Kling dd5ca1940a AK: Hoist the assertion in Retainable::release() to RetainableBase.
This means we don't have to generate a __PRETTY_FUNCTION__ symbol there
for each and every specialization.
2019-03-16 13:48:56 +01:00
Andreas Kling 955a0ff477 AK: Reduce template bloat by hoisting non-typed parts of Retainable.
This is a bit of an old school hack, but it does remove a whole bunch of
generated symbols.
2019-03-16 12:47:19 +01:00
Andreas Kling 741349502f Ext2FS: Free Ext2FSInodes when the last user releases them.
The inode cache was keeping these alive forever. Added a cute little magic
trick to Retainable that calls T::one_retain_left() when the retain count
is decremented to 1.
2019-01-01 02:38:09 +01:00
Andreas Kling d0f06e5f3f Automatically call Inode::flush_metadata() before an Inode is destroyed.
Use a little template magic to have Retainable::release() call out to
T::will_be_destroyed() if such a function exists before actually calling
the destructor. This gives us full access to virtual functions in the
pre-destruction code.
2018-12-19 22:28:09 +01:00
Andreas Kling 8e640539ef Add an inode metadata cache to the ext2fs implementation. 2018-10-29 23:45:34 +01:00
Andreas Kling 5d465582a3 Start fixing up AK to work inside the kernel. 2018-10-16 13:59:28 +02:00
Andreas Kling 3e9a45d7f4 Add WeakPtr/Weakable templates. 2018-10-13 15:41:24 +02:00
Andreas Kling 5a30055157 Import all this stuff into a single repo called Serenity. 2018-10-10 11:53:07 +02:00