cosmopolitan/test
Steven Dee (Jōshin) f9dd5683a4
Implement ctl::unique_ptr (#1216)
The way unique_ptr is supposed to work is as a purely compile-time check
that your raw pointers are getting deleted when they go out of scope. It
should ideally emit the same exact machine code as if you were using raw
pointers with manual deletes.

Part of what this means is that under normal circumstances, a unique_ptr
shouldn’t take up more space than a raw pointer - in other words, sizeof
unique_ptr<T> should == sizeof(T*).

The present PR doesn’t bother with the specialization for array types. I
also left a couple other parts of the STL API unimplemented. I’d love to
see someone else implement these, or I’ll get to them at some point.
2024-06-15 22:54:52 -04:00
..
ctl Implement ctl::unique_ptr (#1216) 2024-06-15 22:54:52 -04:00
dsp Run clang-format (#1197) 2024-06-01 16:30:43 -04:00
libc Rerun clang-format on the repo (#1217) 2024-06-15 16:34:48 -04:00
libcxx vim C++ filetype is still spelled "cpp" 2024-06-05 16:34:47 -07:00
math Make malloc() go 200x faster 2024-06-05 02:02:14 -07:00
net Refactor and improve CTL and other code 2024-06-04 05:45:48 -07:00
posix Add some noexcept annotations 2024-06-01 03:19:53 -07:00
tool Run clang-format (#1197) 2024-06-01 16:30:43 -04:00
BUILD.mk Introduce Cosmopolitan Templates Library (CTL) 2024-06-03 09:21:59 -07:00