This implements waitable management for Events (and
implements Events). It also refactors PM to use new
Event/Waitable semantics, and also adds STS_ASSERT
as a macro for asserting a boolean expression. The
rest of stratosphere has been refactored to use
STS_ASSERT whenever possible.
* fs.mitm: Fix mismatched new[] / delete
Using delete instead of delete[] on a pointer given by new[] is
undefined behaviour.
For memory sources, malloc/free are used because cleaning up is tricky
when data can be either allocated with new (RomfsHeader) or new[]
(metadata).
* set.mitm: Fix mismatched new[] / delete