std::experi...*,operator->(3)
okay so bestie, we're deep in the C++ Standard Libary man page (yes, that's the manual name, keep up π
), and today's main characters are std::experimental::filesystem::directory_iterator::operator* and std::experimental::filesystem::directory_iterator::operator->. they're literally the same vibe, just star vs arrow. let's get into it β¨
πΈ NAME πΈ
std::experimental::filesystem::directory_iterator::operator*, std::experimental::filesystem::directory_iterator::operator-> β and then literally the same thing again: std::experimental::filesystem::directory_iterator::operator*, std::experimental::filesystem::directory_iterator::operator-> π
π« Synopsis π«
const directory_entry& operator*() const;
(filesystem TS) β that's the tag, bestie, keep it moving π
const directory_entry* operator->() const;
what it does: accesses the pointed-to directory_entry. slay. π¦
β οΈ undefined behavior alert β οΈ the result ofoperator*oroperator->on the end iterator is undefined behavior. do not do it. not even ironically. π
π Parameters π
(none)β literally no parameters, bestie. zero. nada. π«Ά
π Return value π
- Value of the
directory_entryreferred to by this iterator. - Pointer to the
directory_entryreferred to by this iterator.
like, 1) gives you the value, 2) gives you the pointer β iconic behavior, no notes π
π Exceptions π
May throw implementation-defined exceptions. so like, the implementation gets to decide, no cap. π§
π See also π
operator*β accesses the pointed-to entryoperator->(public member function ofstd::experimental::filesystem::recursive_directory_iterator)
Category:
* Noindexed pages
okay that's the whole page, bestie. source is cppreference.com, version/date 2024.06.10, and the page is literally std::experi...*,operator->(3). go forth and dereference responsibly (but not the end iterator, never the end iterator) πβ¨π
π¦ where this page comes from
- nixpkgs unstable: stdman 2024.07.05
- opensuse-leap 16.0: stdman 2024.07.05-bp160.1.9 Β· MIT
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms