[libc][NFC] Use operator delete to cleanup a File object.
authorSiva Chandra Reddy <sivachandra@google.com>
Thu, 22 Dec 2022 08:13:19 +0000 (08:13 +0000)
committerSiva Chandra Reddy <sivachandra@google.com>
Thu, 22 Dec 2022 22:31:06 +0000 (22:31 +0000)
commitf9868aa7292a0821f4ed29048d4d4214b17cbb92
treeb78b86b77ec8071cf851300ad7db65b301df5388
parentb27e0b2e6703710c140aefd2990091f1779841ac
[libc][NFC] Use operator delete to cleanup a File object.

The File API has been refactored to allow cleanup using operator delete.

Reviewed By: lntue

Differential Revision: https://reviews.llvm.org/D140574
libc/src/__support/File/file.cpp
libc/src/__support/File/file.h
libc/src/__support/File/linux_file.cpp
libc/src/stdio/fclose.cpp
libc/src/stdio/fopencookie.cpp
libc/test/src/__support/File/file_test.cpp
libc/test/src/__support/File/platform_file_test.cpp