//===--- Implementation of a platform independent Dir data structure ------===// // // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. // See https://llvm.org/LICENSE.txt for license information. // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception // //===----------------------------------------------------------------------===// #include "dir.h" #include "src/__support/CPP/mutex.h" // lock_guard #include "src/__support/CPP/new.h" #include "src/__support/error_or.h" #include "src/__support/macros/config.h" #include "src/errno/libc_errno.h" // For error macros namespace LIBC_NAMESPACE_DECL { ErrorOr<Dir *> Dir::open(const char *path) { … } ErrorOr<struct ::dirent *> Dir::read() { … } int Dir::close() { … } } // namespace LIBC_NAMESPACE_DECL