Upgrade to 2022-era LLVM LIBCXX

This commit is contained in:
Justine Tunney 2024-05-27 02:12:27 -07:00
parent 2f4ca71f26
commit 8e68384e15
No known key found for this signature in database
GPG key ID: BE714B4575D6E328
2078 changed files with 165657 additions and 65010 deletions

View file

@ -1,5 +1,5 @@
// -*- C++ -*-
//===---------------------------- cstdio ----------------------------------===//
//===----------------------------------------------------------------------===//
//
// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
// See https://llvm.org/LICENSE.txt for license information.
@ -10,15 +10,6 @@
#ifndef _LIBCPP_CSTDIO
#define _LIBCPP_CSTDIO
#include "third_party/libcxx/__config"
#include "third_party/libcxx/stdio.h"
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
#pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD
/*
cstdio synopsis
@ -104,68 +95,85 @@ void perror(const char* s);
} // std
*/
using ::FILE;
using ::fpos_t;
using ::size_t;
#include <__assert> // all public C++ headers provide the assertion handler
#include <__config>
using ::fclose;
using ::fflush;
using ::setbuf;
using ::setvbuf;
using ::fprintf;
using ::fscanf;
using ::snprintf;
using ::sprintf;
using ::sscanf;
using ::vfprintf;
using ::vfscanf;
using ::vsscanf;
using ::vsnprintf;
using ::vsprintf;
using ::fgetc;
using ::fgets;
using ::fputc;
using ::fputs;
using ::getc;
using ::putc;
using ::ungetc;
using ::fread;
using ::fwrite;
using ::fgetpos;
using ::fseek;
using ::fsetpos;
using ::ftell;
using ::rewind;
using ::clearerr;
using ::feof;
using ::ferror;
using ::perror;
#include <stdio.h>
#ifndef _LIBCPP_HAS_NO_GLOBAL_FILESYSTEM_NAMESPACE
using ::fopen;
using ::freopen;
using ::remove;
using ::rename;
using ::tmpfile;
using ::tmpnam;
#ifndef _LIBCPP_STDIO_H
# error <cstdio> tried including <stdio.h> but didn't find libc++'s <stdio.h> header. \
This usually means that your header search paths are not configured properly. \
The header search paths should contain the C++ Standard Library headers before \
any C Standard Library, and you are probably using compiler flags that make that \
not be the case.
#endif
#ifndef _LIBCPP_HAS_NO_STDIN
using ::getchar;
#if !defined(_LIBCPP_HAS_NO_PRAGMA_SYSTEM_HEADER)
# pragma GCC system_header
#endif
_LIBCPP_BEGIN_NAMESPACE_STD
using ::FILE _LIBCPP_USING_IF_EXISTS;
using ::fpos_t _LIBCPP_USING_IF_EXISTS;
using ::size_t _LIBCPP_USING_IF_EXISTS;
using ::fclose _LIBCPP_USING_IF_EXISTS;
using ::fflush _LIBCPP_USING_IF_EXISTS;
using ::setbuf _LIBCPP_USING_IF_EXISTS;
using ::setvbuf _LIBCPP_USING_IF_EXISTS;
using ::fprintf _LIBCPP_USING_IF_EXISTS;
using ::fscanf _LIBCPP_USING_IF_EXISTS;
using ::snprintf _LIBCPP_USING_IF_EXISTS;
using ::sprintf _LIBCPP_USING_IF_EXISTS;
using ::sscanf _LIBCPP_USING_IF_EXISTS;
using ::vfprintf _LIBCPP_USING_IF_EXISTS;
using ::vfscanf _LIBCPP_USING_IF_EXISTS;
using ::vsscanf _LIBCPP_USING_IF_EXISTS;
using ::vsnprintf _LIBCPP_USING_IF_EXISTS;
using ::vsprintf _LIBCPP_USING_IF_EXISTS;
using ::fgetc _LIBCPP_USING_IF_EXISTS;
using ::fgets _LIBCPP_USING_IF_EXISTS;
using ::fputc _LIBCPP_USING_IF_EXISTS;
using ::fputs _LIBCPP_USING_IF_EXISTS;
using ::getc _LIBCPP_USING_IF_EXISTS;
using ::putc _LIBCPP_USING_IF_EXISTS;
using ::ungetc _LIBCPP_USING_IF_EXISTS;
using ::fread _LIBCPP_USING_IF_EXISTS;
using ::fwrite _LIBCPP_USING_IF_EXISTS;
#ifndef _LIBCPP_HAS_NO_FGETPOS_FSETPOS
using ::fgetpos _LIBCPP_USING_IF_EXISTS;
#endif
using ::fseek _LIBCPP_USING_IF_EXISTS;
#ifndef _LIBCPP_HAS_NO_FGETPOS_FSETPOS
using ::fsetpos _LIBCPP_USING_IF_EXISTS;
#endif
using ::ftell _LIBCPP_USING_IF_EXISTS;
using ::rewind _LIBCPP_USING_IF_EXISTS;
using ::clearerr _LIBCPP_USING_IF_EXISTS;
using ::feof _LIBCPP_USING_IF_EXISTS;
using ::ferror _LIBCPP_USING_IF_EXISTS;
using ::perror _LIBCPP_USING_IF_EXISTS;
using ::fopen _LIBCPP_USING_IF_EXISTS;
using ::freopen _LIBCPP_USING_IF_EXISTS;
using ::remove _LIBCPP_USING_IF_EXISTS;
using ::rename _LIBCPP_USING_IF_EXISTS;
using ::tmpfile _LIBCPP_USING_IF_EXISTS;
using ::tmpnam _LIBCPP_USING_IF_EXISTS;
using ::getchar _LIBCPP_USING_IF_EXISTS;
#if _LIBCPP_STD_VER <= 11 && !defined(_LIBCPP_C_HAS_NO_GETS)
using ::gets;
#endif
using ::scanf;
using ::vscanf;
using ::gets _LIBCPP_USING_IF_EXISTS;
#endif
using ::scanf _LIBCPP_USING_IF_EXISTS;
using ::vscanf _LIBCPP_USING_IF_EXISTS;
#ifndef _LIBCPP_HAS_NO_STDOUT
using ::printf;
using ::putchar;
using ::puts;
using ::vprintf;
#endif
using ::printf _LIBCPP_USING_IF_EXISTS;
using ::putchar _LIBCPP_USING_IF_EXISTS;
using ::puts _LIBCPP_USING_IF_EXISTS;
using ::vprintf _LIBCPP_USING_IF_EXISTS;
_LIBCPP_END_NAMESPACE_STD
#endif // _LIBCPP_CSTDIO
#endif // _LIBCPP_CSTDIO