Replace old C headers (xxx.h) with modern ones (cxxx) (#5080)

This commit is contained in:
pi1024e 2020-07-01 14:00:24 -04:00 committed by GitHub
parent b24579d2b0
commit 02d5f90837
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
32 changed files with 71 additions and 64 deletions

View File

@ -202,6 +202,7 @@ capslock
CARETBLINKINGENABLED
CARRIAGERETURN
cascadia
cassert
catid
cazamor
CBash
@ -268,12 +269,14 @@ clipbrd
CLIPCHILDREN
CLIPSIBLINGS
cliutils
clocale
closetest
cloudconsole
cls
CLSCTX
clsid
CLUSTERMAP
cmath
cmatrix
cmder
CMDEXT
@ -416,12 +419,16 @@ Csr
csrmsg
CSRSS
csrutil
cstdarg
cstddef
cstdio
cstdlib
cstr
cstring
cstyle
CSwitch
CText
ctime
ctl
ctlseqs
Ctlv

View File

@ -7,7 +7,7 @@
#include "targetver.h"
#include <stdio.h>
#include <cstdio>
#include <tchar.h>
// TODO: reference additional headers your program requires here

View File

@ -10,7 +10,7 @@
#include "AzureConnection.h"
#include "AzureClientID.h"
#include <sstream>
#include <stdlib.h>
#include <cstdlib>
#include <LibraryResources.h>
#include <unicode.hpp>

View File

@ -25,8 +25,8 @@ Abstract:
#include <windows.h>
#include <UIAutomation.h>
#include <stdlib.h>
#include <string.h>
#include <cstdlib>
#include <cstring>
#include <shellscalingapi.h>
#include <windowsx.h>

View File

@ -15,7 +15,7 @@ Author(s):
#include "precomp.h"
#include "..\inc\conattrs.hpp"
#include <math.h>
#include <cmath>
struct _HSL
{

View File

@ -56,7 +56,7 @@ Abstract:
#include <intsafe.h>
#pragma prefast(pop)
#include <strsafe.h>
#include <wchar.h>
#include <cwchar>
#include <mmsystem.h>
#include "utils.hpp"

View File

@ -11,7 +11,7 @@
#include "handle.h"
#include "../buffer/out/CharRow.hpp"
#include <math.h>
#include <cmath>
#include "../interactivity/inc/ServiceLocator.hpp"
#include "../types/inc/Viewport.hpp"
#include "../types/inc/GlyphWidth.hpp"

View File

@ -6,7 +6,7 @@
#include <Intsafe.h>
#include "Shlwapi.h"
#include "telemetry.hpp"
#include <time.h>
#include <ctime>
#include "history.h"

View File

@ -9,7 +9,7 @@
#include "globals.h"
#include <time.h>
#include <ctime>
#include "utils.hpp"

View File

@ -38,7 +38,7 @@
#include <vector>
#include <unordered_map>
#include <iterator>
#include <math.h>
#include <cmath>
#include <sstream>
#include <fstream>
#include <iomanip>

View File

@ -27,9 +27,9 @@
#include "LibraryIncludes.h"
#include <windowsx.h>
#include <stdlib.h>
#include <stdio.h>
#include <stddef.h>
#include <cstdlib>
#include <cstdio>
#include <cstddef>
#include <winbase.h>
#include <winconp.h>
#include <wingdi.h>
@ -43,7 +43,7 @@
#include <strsafe.h>
#include <intsafe.h>
#include <wchar.h>
#include <cwchar>
#include <shellapi.h>
#include "strid.h"

View File

@ -13,7 +13,7 @@
#include "..\host\conddkrefs.h"
#include <condrv.h>
#include <math.h>
#include <cmath>
#include <algorithm>
#include <exception>

View File

@ -10,7 +10,7 @@ Abstract:
- Avoid including internal project headers. Instead include them only in the classes that need them (helps with test project building).
--*/
#include <wchar.h>
#include <cwchar>
#include <sal.h>
// This includes support libraries from the CRT, STL, WIL, and GSL

View File

@ -1,6 +1,6 @@
#include "precomp.h"
#include <stdio.h>
#include <wchar.h>
#include <cstdio>
#include <cwchar>
#include "wincon.h"
int CALLBACK EnumFontFamiliesExProc(ENUMLOGFONTEX* lpelfe, NEWTEXTMETRICEX* lpntme, int FontType, LPARAM lParam)

View File

@ -10,7 +10,7 @@ Abstract:
- Avoid including internal project headers. Instead include them only in the classes that need them (helps with test project building).
--*/
#include <wchar.h>
#include <cwchar>
#include <sal.h>
// This includes support libraries from the CRT, STL, WIL, and GSL

View File

@ -8,7 +8,7 @@
// For _vcprintf
#include <conio.h>
#include <stdarg.h>
#include <cstdarg>
#pragma hdrstop

View File

@ -13,7 +13,7 @@
#include <condrv.h>
#include <math.h>
#include <cmath>
#include <exception>
#include <typeinfo>

View File

@ -13,7 +13,7 @@ Abstract:
// This includes support libraries from the CRT, STL, WIL, and GSL
#include "LibraryIncludes.h"
#include <math.h>
#include <cmath>
#define ENABLE_INTSAFE_SIGNED_FUNCTIONS
#include <intsafe.h>

View File

@ -21,7 +21,7 @@
#include <vector>
#include <limits>
#include <assert.h>
#include <cassert>
#include <strsafe.h>
#pragma warning(disable : 4505)

View File

@ -7,7 +7,7 @@
#include <windows.h>
#include <shlwapi.h>
#include <stdio.h>
#include <cstdio>
// This includes support libraries from the CRT, STL, WIL, and GSL
#include "LibraryIncludes.h"

View File

@ -18,8 +18,8 @@ Abstract:
#include <windows.h>
#include <stdlib.h>
#include <stdio.h>
#include <cstdlib>
#include <cstdio>
// This includes support libraries from the CRT, STL, WIL, and GSL
#include "LibraryIncludes.h"

View File

@ -14,7 +14,7 @@ Abstract:
#include <windows.h>
#include <winmeta.h>
#include <TraceLoggingProvider.h>
#include "limits.h"
#include "climits"
TRACELOGGING_DECLARE_PROVIDER(g_hConsoleVirtTermParserEventTraceProvider);

View File

@ -7,15 +7,15 @@
#include <wil\resource.h>
#include <wil\wistd_functional.h>
#include <wil\wistd_memory.h>
#include <stdlib.h> /* srand, rand */
#include <time.h> /* time */
#include <cstdlib> /* srand, rand */
#include <ctime> /* time */
#include <deque>
#include <memory>
#include <vector>
#include <string>
#include <sstream>
#include <assert.h>
#include <cassert>
using namespace std;
////////////////////////////////////////////////////////////////////////////////

View File

@ -193,12 +193,12 @@ EXAMPLE 3: race condition between process cleanup and close signaling
#endif
#include <windows.h>
#include <assert.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <wchar.h>
#include <locale.h>
#include <cassert>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <cwchar>
#include <clocale>
#include <algorithm>
#include <array>

View File

@ -6,10 +6,10 @@
// System headers
#include <windows.h>
// Standard library C-style
#include <wchar.h>
#include <stdlib.h>
#include <stdio.h>
// Standard C++ library
#include <cwchar>
#include <cstdlib>
#include <cstdio>
#include <string>
using namespace std;

View File

@ -2,8 +2,8 @@
// Licensed under the MIT license.
#include <windows.h>
#include <Stdlib.h>
#include <stdio.h>
#include <cstdlib>
#include <cstdio>
#include <appmodel.h>
#include <strsafe.h>

View File

@ -6,8 +6,8 @@
#include <ntrtl.h>
#include <nturtl.h>
#include <windows.h>
#include <wchar.h>
#include <stdio.h>
#include <cwchar>
#include <cstdio>
#include <shlwapi.h>
#include <propvarutil.h>
#include <initguid.h>

View File

@ -9,7 +9,7 @@
#include <nturtl.h>
#include <windows.h>
#include <stdio.h>
#include <cstdio>
#include <shlwapi.h>
#include <propvarutil.h>
#include <initguid.h>
@ -22,9 +22,9 @@
#include <sal.h>
// Standard library C-style
#include <wchar.h>
#include <stdlib.h>
#include <stdio.h>
#include <cwchar>
#include <cstdlib>
#include <cstdio>
// This includes support libraries from the CRT, STL, WIL, and GSL
#include "LibraryIncludes.h"

View File

@ -6,8 +6,8 @@
#include <ntrtl.h>
#include <nturtl.h>
#include <windows.h>
#include <wchar.h>
#include <stdio.h>
#include <cwchar>
#include <cstdio>
#include <shlwapi.h>
#include <propvarutil.h>
#include <initguid.h>

View File

@ -4,15 +4,15 @@
#include "..\..\inc\conpty.h"
#include "VtConsole.hpp"
#include <stdlib.h> /* srand, rand */
#include <time.h> /* time */
#include <cstdlib> /* srand, rand */
#include <ctime> /* time */
#include <deque>
#include <vector>
#include <string>
#include <sstream>
#include <iomanip>
#include <assert.h>
#include <cassert>
#include <wincon.h>
VtConsole::VtConsole(PipeReadCallback const pfnReadCallback,

View File

@ -7,15 +7,15 @@
#include <wil\resource.h>
#include <wil\wistd_functional.h>
#include <wil\wistd_memory.h>
#include <stdlib.h> /* srand, rand */
#include <time.h> /* time */
#include <cstdlib> /* srand, rand */
#include <ctime> /* time */
#include <deque>
#include <memory>
#include <vector>
#include <string>
#include <sstream>
#include <assert.h>
#include <cassert>
#include "VtConsole.hpp"

View File

@ -22,22 +22,22 @@ Notes:
#define NOMINMAX
#define _OLEAUT32_
#include <windows.h>
#include <ole2.h>
#include <windows.h>
extern "C" {
#include <winuser.h>
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
#include <limits.h>
#include <ime.h>
#include <strsafe.h>
#include <intsafe.h>
#include <strsafe.h>
}
#include <climits>
#include <cstdio>
#include <cstdlib>
#include <cstring>
#include <msctf.h> // Cicero header
#include <tsattrs.h> // ITextStore standard attributes
@ -48,5 +48,5 @@ extern "C" {
#include "globals.h"
#include "TfCtxtComp.h"
#include "ConsoleTSF.h"
#include "TfCtxtComp.h"