diff --git a/README.md b/README.md index 39cd378287d..532fac3c159 100644 --- a/README.md +++ b/README.md @@ -6,8 +6,8 @@ which ships as part of the MSVC toolset and the Visual Studio IDE. * Our [Changelog][] tracks which updates to this repository appear in each VS release. * Our [Status Chart][] displays our overall progress over time. * Join our [Discord server][]. - -[![Build Status](https://dev.azure.com/vclibs/STL/_apis/build/status/microsoft.STL?branchName=main)][Pipelines] +* [![CI Status Badge][STL-CI-badge]][STL-CI-link] (STL-CI build status) +* [![ASan CI Status Badge][STL-ASan-CI-badge]][STL-ASan-CI-link] (STL-ASan-CI build status) # What This Repo Is Useful For @@ -141,13 +141,12 @@ Just try to follow these rules, so we can spend more time fixing bugs and implem # How To Build With The Visual Studio IDE -1. Install Visual Studio 2022 17.8 Preview 2 or later. +1. Install Visual Studio 2022 17.8 Preview 3 or later. * Select "Windows 11 SDK (10.0.22000.0)" in the VS Installer. * We recommend selecting "C++ CMake tools for Windows" in the VS Installer. This will ensure that you're using supported versions of CMake and Ninja. * Otherwise, install [CMake][] 3.27.0 or later, and [Ninja][] 1.11.0 or later. - * We recommend selecting "Python 3 64-bit" in the VS Installer. - * Otherwise, make sure [Python][] 3.9 or later is available to CMake. + * Make sure [Python][] 3.12 or later is available to CMake. 2. Open Visual Studio, and choose the "Clone or check out code" option. Enter the URL of this repository, `https://github.com/microsoft/STL`. 3. Open a terminal in the IDE with `` Ctrl + ` `` (by default) or press on "View" in the top bar, and then "Terminal". @@ -157,13 +156,12 @@ Just try to follow these rules, so we can spend more time fixing bugs and implem # How To Build With A Native Tools Command Prompt -1. Install Visual Studio 2022 17.8 Preview 2 or later. +1. Install Visual Studio 2022 17.8 Preview 3 or later. * Select "Windows 11 SDK (10.0.22000.0)" in the VS Installer. * We recommend selecting "C++ CMake tools for Windows" in the VS Installer. This will ensure that you're using supported versions of CMake and Ninja. * Otherwise, install [CMake][] 3.27.0 or later, and [Ninja][] 1.11.0 or later. - * We recommend selecting "Python 3 64-bit" in the VS Installer. - * Otherwise, make sure [Python][] 3.9 or later is available to CMake. + * Make sure [Python][] 3.12 or later is available to CMake. 2. Open a command prompt. 3. Change directories to a location where you'd like a clone of this STL repository. 4. `git clone https://github.com/microsoft/STL --recurse-submodules` @@ -232,7 +230,7 @@ C:\Users\username\Desktop>dumpbin /DEPENDENTS .\example.exe | findstr msvcp # How To Run The Tests With A Native Tools Command Prompt 1. Follow either [How To Build With A Native Tools Command Prompt][] or [How To Build With The Visual Studio IDE][]. -2. Acquire [Python][] 3.9 or newer and have it on the `PATH` (or run it directly using its absolute or relative path). +2. Acquire [Python][] 3.12 or newer and have it on the `PATH` (or run it directly using its absolute or relative path). 3. Have LLVM's `bin` directory on the `PATH` (so `clang-cl.exe` is available). * We recommend selecting "C++ Clang tools for Windows" in the VS Installer. This will automatically add LLVM to the `PATH` of the x86 and x64 Native Tools Command Prompts, and will ensure that you're using a supported version. @@ -535,7 +533,10 @@ SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception [N4958]: https://wg21.link/n4958 [NOTICE.txt]: NOTICE.txt [Ninja]: https://ninja-build.org -[Pipelines]: https://dev.azure.com/vclibs/STL/_build/latest?definitionId=4&branchName=main +[STL-CI-badge]: https://dev.azure.com/vclibs/STL/_apis/build/status%2FSTL-CI?branchName=main "STL-CI" +[STL-CI-link]: https://dev.azure.com/vclibs/STL/_build/latest?definitionId=4&branchName=main +[STL-ASan-CI-badge]: https://dev.azure.com/vclibs/STL/_apis/build/status%2FSTL-ASan-CI?branchName=main "STL-ASan-CI" +[STL-ASan-CI-link]: https://dev.azure.com/vclibs/STL/_build/latest?definitionId=5&branchName=main [Python]: https://www.python.org/downloads/windows/ [Roadmap]: https://github.com/microsoft/STL/wiki/Roadmap [Status Chart]: https://microsoft.github.io/STL/ diff --git a/azure-devops/asan-pipeline.yml b/azure-devops/asan-pipeline.yml new file mode 100644 index 00000000000..4068735bad8 --- /dev/null +++ b/azure-devops/asan-pipeline.yml @@ -0,0 +1,49 @@ +# Copyright (c) Microsoft Corporation. +# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception + +# Build STL targeting x86 and x64, and run extra ASan testing + +variables: + - template: config.yml + - name: testSelection + value: '-R stlasan' # Restrict to "stlasan" test + +pr: none +trigger: none + +schedules: +- cron: '0 2 * * *' + displayName: ASan-Daily-CI + branches: + include: + - main + +stages: + - stage: Build_And_Test_x64 + displayName: 'Build and Test x64' + pool: + name: ${{ variables.poolName }} + demands: ${{ variables.poolDemands }} + jobs: + - template: native-build-test.yml + parameters: + targetPlatform: x64 + vsDevCmdArch: amd64 + buildBenchmarks: false + testSelection: ${{ variables.testSelection }} + + - stage: Build_And_Test_x86 + displayName: 'Build and Test x86' + dependsOn: [] + pool: + name: ${{ variables.poolName }} + demands: ${{ variables.poolDemands }} + jobs: + - template: native-build-test.yml + parameters: + targetPlatform: x86 + vsDevCmdArch: x86 + buildBenchmarks: false + testSelection: ${{ variables.testSelection }} + + # no coverage for ARM and ARM64 diff --git a/azure-devops/cmake-configure-build.yml b/azure-devops/cmake-configure-build.yml index 35bd8fe833f..bb58004f233 100644 --- a/azure-devops/cmake-configure-build.yml +++ b/azure-devops/cmake-configure-build.yml @@ -8,15 +8,21 @@ parameters: type: string - name: targetPlatform type: string -- name: buildOutputLocationVar - type: string - default: buildOutputLocation -- name: benchmarkBuildOutputLocationVar - type: string - default: benchmarkBuildOutputLocation +- name: buildBenchmarks + type: boolean - name: cmakeAdditionalFlags type: string default: '' +- name: litFlags + type: object + default: + - '--timeout=240' + - '-j$(testParallelism)' + - '--xunit-xml-output=$(buildOutputLocation)/test-results.xml' + - '--order=lexical' + - '--num-shards=$(System.TotalJobsInPhase)' + - '--run-shard=$(System.JobPositionInPhase)' + steps: - task: PowerShell@2 displayName: 'Get Test Parallelism' @@ -27,47 +33,47 @@ steps: $testParallelism = $env:NUMBER_OF_PROCESSORS Write-Host "##vso[task.setvariable variable=testParallelism;]$testParallelism" - script: | - if exist "$(${{ parameters.buildOutputLocationVar }})" ( - rmdir /S /Q "$(${{ parameters.buildOutputLocationVar }})" + if exist "$(buildOutputLocation)" ( + rmdir /S /Q "$(buildOutputLocation)" ) call "%ProgramFiles%\Microsoft Visual Studio\2022\Preview\Common7\Tools\VsDevCmd.bat" ^ -host_arch=${{ parameters.hostArch }} -arch=${{ parameters.targetArch }} -no_logo - cmake ${{ parameters.cmakeAdditionalFlags}} -G Ninja ^ + cmake ${{ parameters.cmakeAdditionalFlags }} -G Ninja ^ -DCMAKE_CXX_COMPILER=cl ^ -DCMAKE_BUILD_TYPE=Release ^ - -DLIT_FLAGS=$(litFlags) ^ + -DLIT_FLAGS=${{ join(';', parameters.litFlags) }} ^ -DSTL_USE_ANALYZE=ON ^ - -S $(Build.SourcesDirectory) -B $(${{ parameters.buildOutputLocationVar }}) + -S $(Build.SourcesDirectory) -B "$(buildOutputLocation)" displayName: 'Configure the STL' timeoutInMinutes: 2 env: { TMP: $(tmpDir), TEMP: $(tmpDir) } - script: | call "%ProgramFiles%\Microsoft Visual Studio\2022\Preview\Common7\Tools\VsDevCmd.bat" ^ -host_arch=${{ parameters.hostArch }} -arch=${{ parameters.targetArch }} -no_logo - cmake --build $(${{ parameters.buildOutputLocationVar }}) + cmake --build "$(buildOutputLocation)" displayName: 'Build the STL' timeoutInMinutes: 5 env: { TMP: $(tmpDir), TEMP: $(tmpDir) } - script: | - if exist "$(${{ parameters.benchmarkBuildOutputLocationVar }})" ( - rmdir /S /Q "$(${{ parameters.benchmarkBuildOutputLocationVar }})" + if exist "$(benchmarkBuildOutputLocation)" ( + rmdir /S /Q "$(benchmarkBuildOutputLocation)" ) call "%ProgramFiles%\Microsoft Visual Studio\2022\Preview\Common7\Tools\VsDevCmd.bat" ^ -host_arch=${{ parameters.hostArch }} -arch=${{ parameters.targetArch }} -no_logo - cmake ${{ parameters.cmakeAdditionalFlags}} -G Ninja ^ + cmake ${{ parameters.cmakeAdditionalFlags }} -G Ninja ^ -DCMAKE_CXX_COMPILER=cl ^ -DCMAKE_BUILD_TYPE=Release ^ - -DSTL_BINARY_DIR=$(${{ parameters.buildOutputLocationVar }}) ^ - -S $(Build.SourcesDirectory)/benchmarks -B $(${{ parameters.benchmarkBuildOutputLocationVar }}) + -DSTL_BINARY_DIR="$(buildOutputLocation)" ^ + -S $(Build.SourcesDirectory)/benchmarks -B "$(benchmarkBuildOutputLocation)" displayName: 'Configure the benchmarks' timeoutInMinutes: 2 env: { TMP: $(tmpDir), TEMP: $(tmpDir) } - condition: ne('${{ parameters.benchmarkBuildOutputLocationVar }}', '') + condition: and(succeeded(), ${{ parameters.buildBenchmarks }}) - script: | call "%ProgramFiles%\Microsoft Visual Studio\2022\Preview\Common7\Tools\VsDevCmd.bat" ^ -host_arch=${{ parameters.hostArch }} -arch=${{ parameters.targetArch }} -no_logo - cmake --build $(${{ parameters.benchmarkBuildOutputLocationVar }}) + cmake --build "$(benchmarkBuildOutputLocation)" displayName: 'Build the benchmarks' timeoutInMinutes: 2 env: { TMP: $(tmpDir), TEMP: $(tmpDir) } - condition: ne('${{ parameters.benchmarkBuildOutputLocationVar }}', '') + condition: and(succeeded(), ${{ parameters.buildBenchmarks }}) diff --git a/azure-devops/config.yml b/azure-devops/config.yml new file mode 100644 index 00000000000..0e2c41d3842 --- /dev/null +++ b/azure-devops/config.yml @@ -0,0 +1,21 @@ +# Copyright (c) Microsoft Corporation. +# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception + +# Common configuration used by both pipelines + +variables: +- name: poolName + value: 'StlBuild-2023-10-10T1443-Pool' + readonly: true +- name: poolDemands + value: 'EnableSpotVM -equals true' + readonly: true +- name: tmpDir + value: 'D:\Temp' + readonly: true +- name: buildOutputLocation + value: 'D:\build' + readonly: true +- name: benchmarkBuildOutputLocation + value: 'D:\benchmark' + readonly: true diff --git a/azure-devops/cross-build.yml b/azure-devops/cross-build.yml index 0649dd53b57..c148b2c4b33 100644 --- a/azure-devops/cross-build.yml +++ b/azure-devops/cross-build.yml @@ -9,23 +9,14 @@ parameters: type: string - name: vsDevCmdArch type: string -- name: buildOutputLocationVar - type: string - default: buildOutputLocation -- name: benchmarkBuildOutputLocationVar - type: string - default: benchmarkBuildOutputLocation +- name: buildBenchmarks + type: boolean + default: true - name: numShards type: number default: 8 jobs: - job: '${{ parameters.targetPlatform }}' - variables: - fixedFlags: '--timeout=240;--shuffle' - parallelismFlag: '-j$(testParallelism)' - xmlOutputFlag: '--xunit-xml-output=$(${{ parameters.buildOutputLocationVar }})/test-results.xml' - shardFlags: '--order=lexical;--num-shards=$(System.TotalJobsInPhase);--run-shard=$(System.JobPositionInPhase)' - litFlags: '$(fixedFlags);$(parallelismFlag);$(xmlOutputFlag);$(shardFlags)' strategy: parallel: ${{ parameters.numShards }} timeoutInMinutes: 25 @@ -42,10 +33,12 @@ jobs: hostArch: ${{ parameters.hostArch }} targetArch: ${{ parameters.vsDevCmdArch }} cmakeAdditionalFlags: '-DTESTS_BUILD_ONLY=ON' - benchmarkBuildOutputLocationVar: ${{ parameters.benchmarkBuildOutputLocationVar }} + buildBenchmarks: ${{ parameters.buildBenchmarks }} - template: run-tests.yml parameters: hostArch: ${{ parameters.hostArch }} targetPlatform: ${{ parameters.targetPlatform }} targetArch: ${{ parameters.vsDevCmdArch }} displayName: 'Build Tests' + # Exclude "stlasan" test (we don't yet support ASAN on ARM or ARM64) + testSelection: '-E stlasan' diff --git a/azure-devops/native-build-test.yml b/azure-devops/native-build-test.yml index f410386b378..b6cef2dc825 100644 --- a/azure-devops/native-build-test.yml +++ b/azure-devops/native-build-test.yml @@ -6,23 +6,19 @@ parameters: type: string - name: vsDevCmdArch type: string -- name: buildOutputLocationVar - type: string - default: buildOutputLocation -- name: benchmarkBuildOutputLocationVar - type: string - default: benchmarkBuildOutputLocation +- name: buildBenchmarks + type: boolean + default: true - name: numShards type: number default: 8 + # Parameters to pass to ctest to select the test(s) to run +- name: testSelection + type: string + # Exclude "stlasan" test by default + default: '-E stlasan' jobs: - job: '${{ parameters.targetPlatform }}' - variables: - fixedFlags: '--timeout=240;--shuffle' - parallelismFlag: '-j$(testParallelism)' - xmlOutputFlag: '--xunit-xml-output=$(${{ parameters.buildOutputLocationVar }})/test-results.xml' - shardFlags: '--order=lexical;--num-shards=$(System.TotalJobsInPhase);--run-shard=$(System.JobPositionInPhase)' - litFlags: '$(fixedFlags);$(parallelismFlag);$(xmlOutputFlag);$(shardFlags)' strategy: parallel: ${{ parameters.numShards }} timeoutInMinutes: 25 @@ -38,8 +34,10 @@ jobs: targetPlatform: ${{ parameters.targetPlatform }} targetArch: ${{ parameters.vsDevCmdArch }} hostArch: ${{ parameters.vsDevCmdArch }} + buildBenchmarks: ${{ parameters.buildBenchmarks }} - template: run-tests.yml parameters: hostArch: ${{ parameters.vsDevCmdArch }} targetPlatform: ${{ parameters.targetPlatform }} targetArch: ${{ parameters.vsDevCmdArch }} + testSelection: ${{ parameters.testSelection }} diff --git a/azure-devops/provision-image.ps1 b/azure-devops/provision-image.ps1 index 5b98c79a016..d2079664bd1 100644 --- a/azure-devops/provision-image.ps1 +++ b/azure-devops/provision-image.ps1 @@ -91,7 +91,7 @@ if ([string]::IsNullOrEmpty($AdminUserPassword)) { $PsExecPath = Join-Path $ExtractedPsToolsPath 'PsExec64.exe' # https://github.com/PowerShell/PowerShell/releases/latest - $PowerShellZipUrl = 'https://github.com/PowerShell/PowerShell/releases/download/v7.3.6/PowerShell-7.3.6-win-x64.zip' + $PowerShellZipUrl = 'https://github.com/PowerShell/PowerShell/releases/download/v7.3.8/PowerShell-7.3.8-win-x64.zip' Write-Host "Downloading: $PowerShellZipUrl" $ExtractedPowerShellPath = DownloadAndExtractZip -Url $PowerShellZipUrl $PwshPath = Join-Path $ExtractedPowerShellPath 'pwsh.exe' @@ -136,7 +136,7 @@ $Workloads = @( ) $VisualStudioBootstrapperUrl = 'https://aka.ms/vs/17/pre/vs_enterprise.exe' -$PythonUrl = 'https://www.python.org/ftp/python/3.11.5/python-3.11.5-amd64.exe' +$PythonUrl = 'https://www.python.org/ftp/python/3.12.0/python-3.12.0-amd64.exe' $CudaUrl = 'https://developer.download.nvidia.com/compute/cuda/11.6.0/local_installers/cuda_11.6.0_511.23_windows.exe' diff --git a/azure-devops/run-tests.yml b/azure-devops/run-tests.yml index 9112bfee35f..d55629a96b5 100644 --- a/azure-devops/run-tests.yml +++ b/azure-devops/run-tests.yml @@ -2,9 +2,6 @@ # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception parameters: -- name: buildOutputLocationVar - type: string - default: buildOutputLocation - name: targetPlatform type: string - name: hostArch @@ -14,28 +11,31 @@ parameters: - name: displayName type: string default: 'Run Tests' + # Parameters to pass to ctest to select the test(s) to run +- name: testSelection + type: string steps: - task: CmdLine@2 displayName: ${{ parameters.displayName }} timeoutInMinutes: 20 condition: succeeded() inputs: - workingDirectory: $(${{ parameters.buildOutputLocationVar }}) + workingDirectory: $(buildOutputLocation) script: | call "%ProgramFiles%\Microsoft Visual Studio\2022\Preview\Common7\Tools\VsDevCmd.bat" ^ -host_arch=${{ parameters.hostArch }} -arch=${{ parameters.targetArch }} -no_logo - ctest -V + ctest -V ${{ parameters.testSelection }} env: { TMP: $(tmpDir), TEMP: $(tmpDir) } - task: PublishTestResults@2 displayName: 'Publish Tests' timeoutInMinutes: 5 condition: succeededOrFailed() inputs: - searchFolder: $(${{ parameters.buildOutputLocationVar }}) + searchFolder: $(buildOutputLocation) testResultsFormat: JUnit testResultsFiles: '**/test-results.xml' testRunTitle: 'test-${{ parameters.targetPlatform }}-$(System.JobPositionInPhase)' -- publish: $(${{ parameters.buildOutputLocationVar }})/test-results.xml +- publish: $(buildOutputLocation)/test-results.xml artifact: '${{ parameters.targetPlatform }}-$(System.JobPositionInPhase)-xml-$(System.JobId)' condition: failed() displayName: 'Publish XML Artifact' diff --git a/azure-pipelines.yml b/azure-pipelines.yml index 628467f9539..1ff09dfdc66 100644 --- a/azure-pipelines.yml +++ b/azure-pipelines.yml @@ -4,13 +4,7 @@ # Build STL targeting x86, x64, arm, arm64 variables: - tmpDir: 'D:\Temp' - buildOutputLocation: 'D:\build' - benchmarkBuildOutputLocation: 'D:\benchmark' - -pool: - name: 'StlBuild-2023-09-14T1251-Pool' - demands: EnableSpotVM -equals true + - template: azure-devops/config.yml pr: drafts: false @@ -18,12 +12,18 @@ pr: stages: - stage: Code_Format displayName: 'Code Format' + pool: + name: ${{ variables.poolName }} + demands: ${{ variables.poolDemands }} jobs: - template: azure-devops/format-validation.yml - stage: Build_And_Test_x64 dependsOn: Code_Format - displayName: 'Build and Test' + displayName: 'Build and Test x64' + pool: + name: ${{ variables.poolName }} + demands: ${{ variables.poolDemands }} jobs: - template: azure-devops/native-build-test.yml parameters: @@ -32,7 +32,10 @@ stages: - stage: Build_And_Test_x86 dependsOn: Build_And_Test_x64 - displayName: 'Build and Test' + displayName: 'Build and Test x86' + pool: + name: ${{ variables.poolName }} + demands: ${{ variables.poolDemands }} jobs: - template: azure-devops/native-build-test.yml parameters: @@ -41,17 +44,23 @@ stages: - stage: Build_ARM dependsOn: Build_And_Test_x64 - displayName: 'Build' + displayName: 'Build ARM' + pool: + name: ${{ variables.poolName }} + demands: ${{ variables.poolDemands }} jobs: - template: azure-devops/cross-build.yml parameters: targetPlatform: arm vsDevCmdArch: arm - benchmarkBuildOutputLocationVar: '' + buildBenchmarks: false - stage: Build_ARM64 dependsOn: Build_And_Test_x64 - displayName: 'Build' + displayName: 'Build ARM64' + pool: + name: ${{ variables.poolName }} + demands: ${{ variables.poolDemands }} jobs: - template: azure-devops/cross-build.yml parameters: diff --git a/stl/CMakeLists.txt b/stl/CMakeLists.txt index 6f5b2022512..cc31a56e597 100644 --- a/stl/CMakeLists.txt +++ b/stl/CMakeLists.txt @@ -664,12 +664,12 @@ add_stl_dlls("d" Debug) function(add_stl_statics FLAVOR_SUFFIX REL_OR_DBG IDL_VALUE) add_library(libcpmt${FLAVOR_SUFFIX}_eha OBJECT ${EHA_SOURCES}) - target_compile_definitions(libcpmt${FLAVOR_SUFFIX}_eha PRIVATE _ANNOTATE_VECTOR _ANNOTATE_STRING "_ITERATOR_DEBUG_LEVEL=${IDL_VALUE}") + target_compile_definitions(libcpmt${FLAVOR_SUFFIX}_eha PRIVATE _ANNOTATE_STL "_ITERATOR_DEBUG_LEVEL=${IDL_VALUE}") target_compile_options(libcpmt${FLAVOR_SUFFIX}_eha PRIVATE /EHa) target_stl_compile_options(libcpmt${FLAVOR_SUFFIX}_eha ${REL_OR_DBG}) add_library(libcpmt${FLAVOR_SUFFIX} STATIC ${HEADERS} ${IMPLIB_SOURCES} ${SOURCES} ${INITIALIZER_SOURCES} ${STATIC_SOURCES}) - target_compile_definitions(libcpmt${FLAVOR_SUFFIX} PRIVATE _ANNOTATE_VECTOR _ANNOTATE_STRING "_ITERATOR_DEBUG_LEVEL=${IDL_VALUE}") + target_compile_definitions(libcpmt${FLAVOR_SUFFIX} PRIVATE _ANNOTATE_STL "_ITERATOR_DEBUG_LEVEL=${IDL_VALUE}") target_compile_options(libcpmt${FLAVOR_SUFFIX} PRIVATE "$<$:/EHsc>") target_link_libraries(libcpmt${FLAVOR_SUFFIX} PRIVATE Boost::math stl_alias_objects libcpmt${FLAVOR_SUFFIX}_eha) target_stl_compile_options(libcpmt${FLAVOR_SUFFIX} ${REL_OR_DBG}) diff --git a/stl/inc/__msvc_sanitizer_annotate_container.hpp b/stl/inc/__msvc_sanitizer_annotate_container.hpp index 3633425feb3..f0b27e06382 100644 --- a/stl/inc/__msvc_sanitizer_annotate_container.hpp +++ b/stl/inc/__msvc_sanitizer_annotate_container.hpp @@ -15,7 +15,51 @@ _STL_DISABLE_CLANG_WARNINGS #pragma push_macro("new") #undef new -#if !defined(_M_CEE_PURE) && !(defined(_DISABLE_STRING_ANNOTATION) && defined(_DISABLE_VECTOR_ANNOTATION)) +// The following macros change the behavior of this file: +// - _DISABLE_STL_ANNOTATION: Disable ASan annotations in the standard library +// (this will be auto-defined on unsupported platforms) +// + _DISABLE_STRING_ANNOTATION: same, but for only `basic_string` +// + _DISABLE_VECTOR_ANNOTATION: same, but for only `vector` +// - _ENABLE_STL_ANNOTATION_ON_UNSUPPORTED_PLATFORMS: Don't auto-disable ASan annotations +// - _ANNOTATE_STL: Even when ASan annotations are disabled, insert the code for annotating into the STL anyways; +// this is useful when building static libraries which may be linked against both ASan and non-ASan binaries. +// + _ANNOTATE_STRING: same, but only for `basic_string` +// + _ANNOTATE_VECTOR: same, but only for `vector` + +#if !defined(_DISABLE_STL_ANNOTATION) && !defined(_ENABLE_STL_ANNOTATION_ON_UNSUPPORTED_PLATFORMS) + +#if defined(_M_ARM64EC) || defined(_M_ARM64) || defined(_M_ARM) || defined(_M_CEE_PURE) +#define _DISABLE_STL_ANNOTATION +#endif // ^^^ unsupported platform ^^^ + +#endif // ^^^ !defined(_DISABLE_STL_ANNOTATION) && !defined(_ENABLE_STL_ANNOTATION_ON_UNSUPPORTED_PLATFORMS) ^^^ + +#ifdef _DISABLE_STL_ANNOTATION + +#ifdef _ENABLE_STL_ANNOTATION_ON_UNSUPPORTED_PLATFORMS +#error _ENABLE_STL_ANNOTATION_ON_UNSUPPORTED_PLATFORMS and _DISABLE_STL_ANNOTATION are mutually exclusive +#endif // ^^^ defined(_ENABLE_STL_ANNOTATION_ON_UNSUPPORTED_PLATFORMS) ^^^ + +#ifndef _DISABLE_STRING_ANNOTATION +#define _DISABLE_STRING_ANNOTATION +#endif // ^^^ !defined(_DISABLE_STRING_ANNOTATION) ^^^ +#ifndef _DISABLE_VECTOR_ANNOTATION +#define _DISABLE_VECTOR_ANNOTATION +#endif // ^^^ !defined(_DISABLE_VECTOR_ANNOTATION) ^^^ + +#endif // ^^^ defined(_DISABLE_STL_ANNOTATION) ^^^ + +#ifdef _ANNOTATE_STL + +#ifndef _ANNOTATE_STRING +#define _ANNOTATE_STRING +#endif // ^^^ !defined(_ANNOTATE_STRING) ^^^ + +#ifndef _ANNOTATE_VECTOR +#define _ANNOTATE_VECTOR +#endif // ^^^ !defined(_ANNOTATE_VECTOR) ^^^ + +#endif // ^^^ defined(_ANNOTATE_STL) ^^^ #ifdef __SANITIZE_ADDRESS__ @@ -34,41 +78,41 @@ _STL_DISABLE_CLANG_WARNINGS #pragma comment(linker, "/INFERASANLIBS") #endif // __has_feature(address_sanitizer) -#else // ^^^ defined(__clang__) / !defined(__clang__) && !defined(__SANITIZE_ADDRESS__) vvv +#endif // ^^^ defined(__clang__) ^^^ -#ifdef _ANNOTATE_STRING -#define _INSERT_STRING_ANNOTATION -#endif // defined(_ANNOTATE_STRING) -#ifdef _ANNOTATE_VECTOR -#define _INSERT_VECTOR_ANNOTATION -#endif // defined(_ANNOTATE_VECTOR) - -#endif // ^^^ !defined(__clang__) && !defined(__SANITIZE_ADDRESS__) ^^^ #ifdef _DISABLE_STRING_ANNOTATION #undef _ACTIVATE_STRING_ANNOTATION #undef _INSERT_STRING_ANNOTATION -#endif // defined(_DISABLE_STRING_ANNOTATION) +#endif // ^^^ defined(_DISABLE_STRING_ANNOTATION) ^^^ #ifdef _DISABLE_VECTOR_ANNOTATION #undef _ACTIVATE_VECTOR_ANNOTATION #undef _INSERT_VECTOR_ANNOTATION -#endif // defined(_DISABLE_VECTOR_ANNOTATION) +#endif // ^^^ defined(_DISABLE_VECTOR_ANNOTATION) ^^^ + +#ifdef _ANNOTATE_STRING +#define _INSERT_STRING_ANNOTATION +#endif // ^^^ defined(_ANNOTATE_STRING) ^^^ +#ifdef _ANNOTATE_VECTOR +#define _INSERT_VECTOR_ANNOTATION +#endif // ^^^ defined(_ANNOTATE_VECTOR) ^^^ + #ifndef _INSERT_STRING_ANNOTATION #pragma detect_mismatch("annotate_string", "0") -#endif // !defined(_INSERT_STRING_ANNOTATION) +#endif // ^^^ !defined(_INSERT_STRING_ANNOTATION) ^^^ #ifndef _INSERT_VECTOR_ANNOTATION #pragma detect_mismatch("annotate_vector", "0") -#endif // !defined(_INSERT_VECTOR_ANNOTATION) +#endif // ^^^ !defined(_INSERT_VECTOR_ANNOTATION) ^^^ #ifdef _ACTIVATE_STRING_ANNOTATION #pragma comment(lib, "stl_asan") #pragma detect_mismatch("annotate_string", "1") -#endif // defined(_ACTIVATE_STRING_ANNOTATION) +#endif // ^^^ defined(_ACTIVATE_STRING_ANNOTATION) ^^^ #ifdef _ACTIVATE_VECTOR_ANNOTATION #pragma comment(lib, "stl_asan") #pragma detect_mismatch("annotate_vector", "1") -#endif // defined(_ACTIVATE_VECTOR_ANNOTATION) +#endif // ^^^ defined(_ACTIVATE_VECTOR_ANNOTATION) ^^^ #undef _ACTIVATE_STRING_ANNOTATION #undef _ACTIVATE_VECTOR_ANNOTATION @@ -121,9 +165,7 @@ void __cdecl __sanitizer_annotate_contiguous_container( #error Unknown architecture #endif // ^^^ unknown architecture ^^^ -#endif // insert asan annotations - -#endif // !defined(_M_CEE_PURE) && asan not disabled +#endif // ^^^ insert ASan annotations ^^^ #pragma pop_macro("new") _STL_RESTORE_CLANG_WARNINGS diff --git a/stl/inc/array b/stl/inc/array index 1513b3829be..cdc0267dc79 100644 --- a/stl/inc/array +++ b/stl/inc/array @@ -433,7 +433,7 @@ public: } _CONSTEXPR20 void swap(array& _Other) noexcept(_Is_nothrow_swappable<_Ty>::value) { - _Swap_ranges_unchecked(_Elems, _Elems + _Size, _Other._Elems); + _STD _Swap_ranges_unchecked(_Elems, _Elems + _Size, _Other._Elems); } _NODISCARD _CONSTEXPR17 iterator begin() noexcept { @@ -775,7 +775,7 @@ _CONSTEXPR20 void swap(array<_Ty, _Size>& _Left, array<_Ty, _Size>& _Right) noex _EXPORT_STD template _NODISCARD _CONSTEXPR20 bool operator==(const array<_Ty, _Size>& _Left, const array<_Ty, _Size>& _Right) { - return _STD equal(_Left._Unchecked_begin(), _Left._Unchecked_end(), _Right._Unchecked_begin()); + return _STD equal(_Left.data(), _Left.data() + _Size, _Right.data()); } #if !_HAS_CXX20 @@ -789,14 +789,13 @@ _NODISCARD bool operator!=(const array<_Ty, _Size>& _Left, const array<_Ty, _Siz _EXPORT_STD template _NODISCARD constexpr _Synth_three_way_result<_Ty> operator<=>( const array<_Ty, _Size>& _Left, const array<_Ty, _Size>& _Right) { - return _STD lexicographical_compare_three_way(_Left._Unchecked_begin(), _Left._Unchecked_end(), - _Right._Unchecked_begin(), _Right._Unchecked_end(), _Synth_three_way{}); + return _STD lexicographical_compare_three_way( + _Left.data(), _Left.data() + _Size, _Right.data(), _Right.data() + _Size, _Synth_three_way{}); } #else // ^^^ defined(__cpp_lib_concepts) / !defined(__cpp_lib_concepts) vvv template _NODISCARD _CONSTEXPR20 bool operator<(const array<_Ty, _Size>& _Left, const array<_Ty, _Size>& _Right) { - return _STD lexicographical_compare( - _Left._Unchecked_begin(), _Left._Unchecked_end(), _Right._Unchecked_begin(), _Right._Unchecked_end()); + return _STD lexicographical_compare(_Left.data(), _Left.data() + _Size, _Right.data(), _Right.data() + _Size); } template @@ -834,7 +833,7 @@ _NODISCARD constexpr array, _Size> to_array(_Ty (&_Array)[_Size "to_array does not accept multidimensional arrays."); static_assert(is_constructible_v<_Ty, _Ty&>, "N4950 [array.creation]/1: " "to_array requires copy constructible elements."); - return _To_array_lvalue_impl(_Array, make_index_sequence<_Size>{}); + return _STD _To_array_lvalue_impl(_Array, make_index_sequence<_Size>{}); } _EXPORT_STD template @@ -843,32 +842,56 @@ _NODISCARD constexpr array, _Size> to_array(_Ty (&&_Array)[_Siz "to_array does not accept multidimensional arrays."); static_assert(is_move_constructible_v<_Ty>, "N4950 [array.creation]/4: " "to_array requires move constructible elements."); - return _To_array_rvalue_impl(_STD move(_Array), make_index_sequence<_Size>{}); + return _STD _To_array_rvalue_impl(_STD move(_Array), make_index_sequence<_Size>{}); } #endif // _HAS_CXX20 _EXPORT_STD template _NODISCARD constexpr _Ty& get(array<_Ty, _Size>& _Arr) noexcept { static_assert(_Idx < _Size, "array index out of bounds"); - return _Arr._Elems[_Idx]; + if constexpr (_Has_unchecked_begin_end>) { + return _Arr._Elems[_Idx]; + } else { +#if _HAS_CXX17 + return _Arr[_Idx]; +#else // ^^^ _HAS_CXX17 / !_HAS_CXX17 vvv + return const_cast<_Ty&>(_STD as_const(_Arr)[_Idx]); +#endif // ^^^ !_HAS_CXX17 ^^^ + } } _EXPORT_STD template _NODISCARD constexpr const _Ty& get(const array<_Ty, _Size>& _Arr) noexcept { static_assert(_Idx < _Size, "array index out of bounds"); - return _Arr._Elems[_Idx]; + if constexpr (_Has_unchecked_begin_end>) { + return _Arr._Elems[_Idx]; + } else { + return _Arr[_Idx]; + } } _EXPORT_STD template _NODISCARD constexpr _Ty&& get(array<_Ty, _Size>&& _Arr) noexcept { static_assert(_Idx < _Size, "array index out of bounds"); - return _STD move(_Arr._Elems[_Idx]); + if constexpr (_Has_unchecked_begin_end>) { + return _STD move(_Arr._Elems[_Idx]); + } else { +#if _HAS_CXX17 + return _STD move(_Arr[_Idx]); +#else // ^^^ _HAS_CXX17 / !_HAS_CXX17 vvv + return const_cast<_Ty&&>(_STD move(_STD as_const(_Arr)[_Idx])); +#endif // ^^^ !_HAS_CXX17 ^^^ + } } _EXPORT_STD template _NODISCARD constexpr const _Ty&& get(const array<_Ty, _Size>&& _Arr) noexcept { static_assert(_Idx < _Size, "array index out of bounds"); - return _STD move(_Arr._Elems[_Idx]); + if constexpr (_Has_unchecked_begin_end>) { + return _STD move(_Arr._Elems[_Idx]); + } else { + return _STD move(_Arr[_Idx]); + } } #if _HAS_TR1_NAMESPACE diff --git a/stl/inc/charconv b/stl/inc/charconv index 01f73e6d6e6..518841a249f 100644 --- a/stl/inc/charconv +++ b/stl/inc/charconv @@ -1026,10 +1026,7 @@ _NODISCARD inline uint64_t _Right_shift_with_rounding( constexpr uint32_t _Total_number_of_bits = 64; if (_Shift >= _Total_number_of_bits) { if (_Shift == _Total_number_of_bits) { -#pragma warning(push) -#pragma warning(disable : 26454) // TRANSITION, VSO-1826196 constexpr uint64_t _Extra_bits_mask = (1ULL << (_Total_number_of_bits - 1)) - 1; -#pragma warning(pop) constexpr uint64_t _Round_bit_mask = (1ULL << (_Total_number_of_bits - 1)); const bool _Round_bit = (_Value & _Round_bit_mask) != 0; diff --git a/stl/inc/deque b/stl/inc/deque index 964b8c4f771..56b0a708568 100644 --- a/stl/inc/deque +++ b/stl/inc/deque @@ -42,9 +42,7 @@ public: : _Mycont(static_cast(_Pdeque)), _Myoff(_Off) {} _NODISCARD reference operator*() const noexcept { - _Size_type _Block = _Mycont->_Getblock(_Myoff); - _Size_type _Off = _Myoff % _Block_size; - return _Mycont->_Map[_Block][_Off]; + return _Mycont->_Subscript(_Myoff); } _NODISCARD pointer operator->() const noexcept { @@ -74,7 +72,7 @@ public: } _Deque_unchecked_const_iterator& operator+=(const difference_type _Off) noexcept { - _Myoff += _Off; + _Myoff = static_cast<_Size_type>(_Myoff + _Off); return *this; } @@ -91,7 +89,7 @@ public: } _Deque_unchecked_const_iterator& operator-=(const difference_type _Off) noexcept { - _Myoff -= _Off; + _Myoff = static_cast<_Size_type>(_Myoff - _Off); return *this; } @@ -263,9 +261,7 @@ public: "cannot deference out of range deque iterator"); #endif // _ITERATOR_DEBUG_LEVEL != 0 - _Size_type _Block = _Mycont->_Getblock(_Myoff); - _Size_type _Off = _Myoff % _Block_size; - return _Mycont->_Map[_Block][_Off]; + return _Mycont->_Subscript(_Myoff); } _NODISCARD pointer operator->() const noexcept { @@ -317,7 +313,7 @@ public: } #endif // _ITERATOR_DEBUG_LEVEL != 0 - _Myoff += _Off; + _Myoff = static_cast<_Size_type>(_Myoff + _Off); return *this; } @@ -546,6 +542,8 @@ public: using _Mapptr = typename _Val_types::_Mapptr; private: + using _Map_difference_type = typename iterator_traits<_Mapptr>::difference_type; + static constexpr size_t _Bytes = sizeof(value_type); public: @@ -557,9 +555,27 @@ public: _Deque_val() noexcept : _Map(), _Mapsize(0), _Myoff(0), _Mysize(0) {} - size_type _Getblock(size_type _Off) const noexcept { + _Map_difference_type _Getblock(size_type _Off) const noexcept { // NB: _Mapsize and _Block_size are guaranteed to be powers of 2 - return (_Off / _Block_size) & (_Mapsize - 1); + return static_cast<_Map_difference_type>((_Off / _Block_size) & (_Mapsize - 1)); + } + + reference _Subscript(size_type _Off) noexcept { + const auto _Block = _Getblock(_Off); + const auto _Block_off = static_cast(_Off % _Block_size); + return _Map[_Block][_Block_off]; + } + + const_reference _Subscript(size_type _Off) const noexcept { + const auto _Block = _Getblock(_Off); + const auto _Block_off = static_cast(_Off % _Block_size); + return _Map[_Block][_Block_off]; + } + + value_type* _Address_subscript(size_type _Off) noexcept { + const auto _Block = _Getblock(_Off); + const auto _Block_off = static_cast(_Off % _Block_size); + return _STD _Unfancy(_Map[_Block] + _Block_off); } _Mapptr _Map; // pointer to array of pointers to blocks @@ -584,6 +600,8 @@ private: using _Mapptr = typename _Alpty_traits::pointer; using _Alproxy_ty = _Rebind_alloc_t<_Alty, _Container_proxy>; + using _Map_difference_type = typename iterator_traits<_Mapptr>::difference_type; + using _Scary_val = _Deque_val, _Deque_simple_types<_Ty>, _Deque_iter_types<_Ty, typename _Alty_traits::size_type, typename _Alty_traits::difference_type, typename _Alty_traits::pointer, typename _Alty_traits::const_pointer, _Mapptr>>>; @@ -977,7 +995,8 @@ public: if ((empty() && _Mapsize() > 0) || (!empty() && size() <= _Newcapacity && _Newcapacity < _Oldcapacity)) { // worth shrinking, do it - deque _Tmp(_STD make_move_iterator(begin()), _STD make_move_iterator(end())); + deque _Tmp( + _STD make_move_iterator(_Unchecked_begin()), _STD make_move_iterator(_Unchecked_end()), _Getal()); swap(_Tmp); } } @@ -987,7 +1006,7 @@ public: _STL_VERIFY(_Pos < _Mysize(), "deque subscript out of range"); #endif // _CONTAINER_DEBUG_LEVEL > 0 - return *(_Unchecked_begin() + static_cast(_Pos)); + return _Subscript(_Pos); } _NODISCARD reference operator[](size_type _Pos) noexcept /* strengthened */ { @@ -995,7 +1014,7 @@ public: _STL_VERIFY(_Pos < _Mysize(), "deque subscript out of range"); #endif // _CONTAINER_DEBUG_LEVEL > 0 - return *(_Unchecked_begin() + static_cast(_Pos)); + return _Subscript(_Pos); } _NODISCARD const_reference at(size_type _Pos) const { @@ -1003,7 +1022,7 @@ public: _Xran(); } - return *(begin() + static_cast(_Pos)); + return _Subscript(_Pos); } _NODISCARD reference at(size_type _Pos) { @@ -1011,7 +1030,7 @@ public: _Xran(); } - return *(begin() + static_cast(_Pos)); + return _Subscript(_Pos); } _NODISCARD reference front() noexcept /* strengthened */ { @@ -1019,7 +1038,7 @@ public: _STL_VERIFY(!empty(), "front() called on empty deque"); #endif // _CONTAINER_DEBUG_LEVEL > 0 - return *_Unchecked_begin(); + return _Subscript(0); } _NODISCARD const_reference front() const noexcept /* strengthened */ { @@ -1027,7 +1046,7 @@ public: _STL_VERIFY(!empty(), "front() called on empty deque"); #endif // _CONTAINER_DEBUG_LEVEL > 0 - return *_Unchecked_begin(); + return _Subscript(0); } _NODISCARD reference back() noexcept /* strengthened */ { @@ -1035,7 +1054,7 @@ public: _STL_VERIFY(!empty(), "back() called on empty deque"); #endif // _CONTAINER_DEBUG_LEVEL > 0 - return *_Prev_iter(_Unchecked_end()); + return _Subscript(_Mysize() - 1); } _NODISCARD const_reference back() const noexcept /* strengthened */ { @@ -1043,7 +1062,7 @@ public: _STL_VERIFY(!empty(), "back() called on empty deque"); #endif // _CONTAINER_DEBUG_LEVEL > 0 - return *_Prev_iter(_Unchecked_end()); + return _Subscript(_Mysize() - 1); } private: @@ -1053,14 +1072,13 @@ private: _Growmap(1); } _Myoff() &= _Mapsize() * _Block_size - 1; - size_type _Newoff = _Myoff() + _Mysize(); - size_type _Block = _Getblock(_Newoff); + const auto _Newoff = static_cast(_Myoff() + _Mysize()); + const auto _Block = _Getblock(_Newoff); if (_Map()[_Block] == nullptr) { _Map()[_Block] = _Getal().allocate(_Block_size); } - _Alty_traits::construct( - _Getal(), _Unfancy(_Map()[_Block] + _Newoff % _Block_size), _STD forward<_Tys>(_Vals)...); + _Alty_traits::construct(_Getal(), _Get_data()._Address_subscript(_Newoff), _STD forward<_Tys>(_Vals)...); ++_Mysize(); } @@ -1071,14 +1089,13 @@ private: _Growmap(1); } _Myoff() &= _Mapsize() * _Block_size - 1; - size_type _Newoff = _Myoff() != 0 ? _Myoff() : _Mapsize() * _Block_size; - const size_type _Block = _Getblock(--_Newoff); + const auto _Newoff = static_cast((_Myoff() != 0 ? _Myoff() : _Mapsize() * _Block_size) - 1); + const auto _Block = _Getblock(_Newoff); if (_Map()[_Block] == nullptr) { _Map()[_Block] = _Getal().allocate(_Block_size); } - _Alty_traits::construct( - _Getal(), _Unfancy(_Map()[_Block] + _Newoff % _Block_size), _STD forward<_Tys>(_Vals)...); + _Alty_traits::construct(_Getal(), _Get_data()._Address_subscript(_Newoff), _STD forward<_Tys>(_Vals)...); _Myoff() = _Newoff; ++_Mysize(); @@ -1185,7 +1202,7 @@ public: } const auto _Num = static_cast(_Mysize() - _Oldsize); - _STD reverse(begin(), begin() + _Num); + _STD reverse(_Unchecked_begin(), _Unchecked_begin() + _Num); } _Guard._Container = nullptr; } @@ -1330,7 +1347,7 @@ private: } void _Insert_n(const_iterator _Where, size_type _Count, const _Ty& _Val) { // insert _Count * _Val at _Where - iterator _Mid; + _Unchecked_iterator _Mid; size_type _Num; size_type _Off = static_cast(_Where - begin()); size_type _Oldsize = _Mysize(); @@ -1347,22 +1364,22 @@ private: push_front(_Val); // push excess values } for (_Num = _Off; _Num > 0; --_Num) { - push_front(begin()[static_cast(_Count - 1)]); // push prefix + push_front(_Subscript(_Count - 1)); // push prefix } - _Mid = begin() + static_cast(_Count); + _Mid = _Unchecked_begin() + static_cast(_Count); _STD fill_n(_Mid, _Off, _Val); // fill in rest of values } else { // insert not longer than prefix for (_Num = _Count; _Num > 0; --_Num) { - push_front(begin()[static_cast(_Count - 1)]); // push part of prefix + push_front(_Subscript(_Count - 1)); // push part of prefix } - _Mid = begin() + static_cast(_Count); + _Mid = _Unchecked_begin() + static_cast(_Count); _Alloc_temporary2<_Alty> _Tmp(_Getal(), _Val); // in case _Val is in sequence _STD move(_Mid + static_cast(_Count), _Mid + static_cast(_Off), _Mid); // copy rest of prefix - _STD fill(begin() + static_cast(_Off), _Mid + static_cast(_Off), - _Tmp._Get_value()); // fill in values + _STD fill(_Unchecked_begin() + static_cast(_Off), + _Mid + static_cast(_Off), _Tmp._Get_value()); // fill in values } _Guard._Container = nullptr; } else { // closer to back @@ -1373,18 +1390,17 @@ private: _Emplace_back_internal(_Val); // push excess values } for (_Num = 0; _Num < _Rem; ++_Num) { - _Emplace_back_internal(begin()[static_cast(_Off + _Num)]); // push suffix + _Emplace_back_internal(_Subscript(_Off + _Num)); // push suffix } - _Mid = begin() + static_cast(_Off); + _Mid = _Unchecked_begin() + static_cast(_Off); _STD fill_n(_Mid, _Rem, _Val); // fill in rest of values } else { // insert not longer than prefix for (_Num = 0; _Num < _Count; ++_Num) { - _Emplace_back_internal( - begin()[static_cast(_Off + _Rem - _Count + _Num)]); // push part of prefix + _Emplace_back_internal(_Subscript(_Off + _Rem - _Count + _Num)); // push part of prefix } - _Mid = begin() + static_cast(_Off); + _Mid = _Unchecked_begin() + static_cast(_Off); _Alloc_temporary2<_Alty> _Tmp(_Getal(), _Val); // in case _Val is in sequence _STD move_backward(_Mid, _Mid + static_cast(_Rem - _Count), _Mid + static_cast(_Rem)); // copy rest of prefix @@ -1401,8 +1417,7 @@ public: _STL_REPORT_ERROR("deque empty before pop"); } else { // something to erase, do it _Orphan_off(_Myoff()); - size_type _Block = _Getblock(_Myoff()); - _Alty_traits::destroy(_Getal(), _Unfancy(_Map()[_Block] + _Myoff() % _Block_size)); + _Alty_traits::destroy(_Getal(), _Get_data()._Address_subscript(_Myoff())); if (--_Mysize() == 0) { _Myoff() = 0; } else { @@ -1411,8 +1426,7 @@ public: } #else // ^^^ _ITERATOR_DEBUG_LEVEL == 2 / _ITERATOR_DEBUG_LEVEL < 2 vvv - size_type _Block = _Getblock(_Myoff()); - _Alty_traits::destroy(_Getal(), _Unfancy(_Map()[_Block] + _Myoff() % _Block_size)); + _Alty_traits::destroy(_Getal(), _Get_data()._Address_subscript(_Myoff())); if (--_Mysize() == 0) { _Myoff() = 0; } else { @@ -1428,8 +1442,7 @@ public: } else { // something to erase, do it size_type _Newoff = _Myoff() + _Mysize() - 1; _Orphan_off(_Newoff); - size_type _Block = _Getblock(_Newoff); - _Alty_traits::destroy(_Getal(), _Unfancy(_Map()[_Block] + _Newoff % _Block_size)); + _Alty_traits::destroy(_Getal(), _Get_data()._Address_subscript(_Newoff)); if (--_Mysize() == 0) { _Myoff() = 0; } @@ -1437,8 +1450,7 @@ public: #else // ^^^ _ITERATOR_DEBUG_LEVEL == 2 / _ITERATOR_DEBUG_LEVEL < 2 vvv size_type _Newoff = _Myoff() + _Mysize() - 1; - size_type _Block = _Getblock(_Newoff); - _Alty_traits::destroy(_Getal(), _Unfancy(_Map()[_Block] + _Newoff % _Block_size)); + _Alty_traits::destroy(_Getal(), _Get_data()._Address_subscript(_Newoff)); if (--_Mysize() == 0) { _Myoff() = 0; } @@ -1471,13 +1483,16 @@ public: return _First; } - if (_Off < static_cast(end() - _Last)) { // closer to front - _STD move_backward(begin(), _First, _Last); // copy over hole + auto _Unchecked_first = _First._Unwrapped(); + auto _Unchecked_last = _Last._Unwrapped(); + + if (_Off < static_cast(_Unchecked_end() - _Unchecked_last)) { // closer to front + _STD move_backward(_Unchecked_begin(), _Unchecked_first, _Unchecked_last); // copy over hole for (; _Count > 0; --_Count) { pop_front(); // pop copied elements } } else { // closer to back - _STD move(_Last, end(), _First); // copy over hole + _STD move(_Unchecked_last, _Unchecked_end(), _Unchecked_first); // copy over hole for (; _Count > 0; --_Count) { pop_back(); // pop copied elements } @@ -1543,9 +1558,10 @@ private: size_type _Allocsize = _Newsize; - size_type _Myboff = _Myoff() / _Block_size; - _Mapptr _Newmap = _Allocate_at_least_helper(_Almap, _Allocsize); - _Mapptr _Myptr = _Newmap + _Myboff; + const auto _Myboff = static_cast(_Myoff() / _Block_size); + const auto _Map_off = static_cast<_Map_difference_type>(_Myboff); + _Mapptr _Newmap = _Allocate_at_least_helper(_Almap, _Allocsize); + _Mapptr _Myptr = _Newmap + _Map_off; _STL_ASSERT(_Allocsize >= _Newsize, "_Allocsize >= _Newsize"); while (_Newsize <= _Allocsize / 2) { _Newsize *= 2; @@ -1553,19 +1569,21 @@ private: _Count = _Newsize - _Mapsize(); - _Myptr = _STD uninitialized_copy(_Map() + _Myboff, _Map() + _Mapsize(), _Myptr); // copy initial to end + const auto _Map_count = static_cast<_Map_difference_type>(_Count); + + _Myptr = _STD uninitialized_copy(_Map() + _Map_off, _Map() + _Map_distance(), _Myptr); // copy initial to end if (_Myboff <= _Count) { // increment greater than offset of initial block - _Myptr = _STD uninitialized_copy(_Map(), _Map() + _Myboff, _Myptr); // copy rest of old + _Myptr = _STD uninitialized_copy(_Map(), _Map() + _Map_off, _Myptr); // copy rest of old _Uninitialized_value_construct_n_unchecked1(_Myptr, _Count - _Myboff); // clear suffix of new _Uninitialized_value_construct_n_unchecked1(_Newmap, _Myboff); // clear prefix of new } else { // increment not greater than offset of initial block - _STD uninitialized_copy(_Map(), _Map() + _Count, _Myptr); // copy more old - _Myptr = _STD uninitialized_copy(_Map() + _Count, _Map() + _Myboff, _Newmap); // copy rest of old + _STD uninitialized_copy(_Map(), _Map() + _Map_count, _Myptr); // copy more old + _Myptr = _STD uninitialized_copy(_Map() + _Map_count, _Map() + _Map_off, _Newmap); // copy rest of old _Uninitialized_value_construct_n_unchecked1(_Myptr, _Count); // clear rest to initial block } if (_Map() != nullptr) { - _Destroy_range(_Map(), _Map() + _Mapsize()); + _Destroy_range(_Map(), _Map() + _Map_distance()); _Almap.deallocate(_Map(), _Mapsize()); // free storage for old } @@ -1582,7 +1600,7 @@ private: } if (_Map() != nullptr) { - for (size_type _Block = _Mapsize(); _Block > 0;) { // free storage for a block and destroy pointer + for (auto _Block = _Map_distance(); _Block > 0;) { // free storage for a block and destroy pointer if (_Map()[--_Block]) { // free block _Getal().deallocate(_Map()[_Block], _Block_size); } @@ -1617,7 +1635,7 @@ private: } #endif // _ITERATOR_DEBUG_LEVEL == 2 - size_type _Getblock(size_type _Off) const noexcept { + _Map_difference_type _Getblock(size_type _Off) const noexcept { return _Get_data()._Getblock(_Off); } @@ -1673,6 +1691,18 @@ private: return _Get_data()._Mysize; } + _Map_difference_type _Map_distance() const noexcept { + return static_cast<_Map_difference_type>(_Get_data()._Mapsize); + } + + reference _Subscript(size_type _Pos) noexcept { + return _Get_data()._Subscript(_Myoff() + _Pos); + } + + const_reference _Subscript(size_type _Pos) const noexcept { + return _Get_data()._Subscript(_Myoff() + _Pos); + } + _Compressed_pair<_Alty, _Scary_val> _Mypair; }; diff --git a/stl/inc/execution b/stl/inc/execution index dfab9661d35..a421a2f756c 100644 --- a/stl/inc/execution +++ b/stl/inc/execution @@ -1867,9 +1867,6 @@ struct _Static_partitioned_mismatch3 { } }; -#pragma warning(push) -#pragma warning(disable : 4868) // compiler may not enforce left-to-right evaluation order - // in braced initializer list (/Wall) _EXPORT_STD template /* = 0 */> _NODISCARD pair<_FwdIt1, _FwdIt2> mismatch( @@ -1911,7 +1908,6 @@ _NODISCARD pair<_FwdIt1, _FwdIt2> mismatch( _Seek_wrapped(_First1, _Result.first); return {_First1, _First2}; } -#pragma warning(pop) _EXPORT_STD template /* = 0 */> @@ -2396,9 +2392,6 @@ struct _Static_partitioned_binary_transform2 { } }; -#pragma warning(push) -#pragma warning(disable : 4868) // compiler may not enforce left-to-right evaluation order - // in braced initializer list (/Wall) _EXPORT_STD template /* = 0 */> _FwdIt3 transform(_ExPo&&, const _FwdIt1 _First1, const _FwdIt1 _Last1, const _FwdIt2 _First2, _FwdIt3 _Dest, @@ -2443,7 +2436,6 @@ _FwdIt3 transform(_ExPo&&, const _FwdIt1 _First1, const _FwdIt1 _Last1, const _F return _Dest; } } -#pragma warning(pop) _EXPORT_STD template /* = 0 */> void replace(_ExPo&& _Exec, const _FwdIt _First, const _FwdIt _Last, const _Ty& _Oldval, const _Ty& _Newval) noexcept @@ -4162,9 +4154,6 @@ struct _Static_partitioned_transform_reduce_binary2 { // transform-reduction tas } }; -#pragma warning(push) -#pragma warning(disable : 4868) // compiler may not enforce left-to-right evaluation order - // in braced initializer list (/Wall) _EXPORT_STD template /* = 0 */> _NODISCARD _Ty transform_reduce(_ExPo&&, _FwdIt1 _First1, _FwdIt1 _Last1, _FwdIt2 _First2, _Ty _Val, _BinOp1 _Reduce_op, @@ -4219,7 +4208,6 @@ _NODISCARD _Ty transform_reduce(_ExPo&&, _FwdIt1 _First1, _FwdIt1 _Last1, _FwdIt _Get_unwrapped_n(_First2, _Idl_distance<_FwdIt1>(_UFirst1, _ULast1)), _STD move(_Val), _Pass_fn(_Reduce_op), _Pass_fn(_Transform_op)); } -#pragma warning(pop) template struct _Static_partitioned_transform_reduce2 { // transformed reduction task scheduled on the system thread pool diff --git a/stl/inc/format b/stl/inc/format index 4dce53c7a23..e09d61e5f32 100644 --- a/stl/inc/format +++ b/stl/inc/format @@ -987,8 +987,11 @@ _NODISCARD constexpr bool _Is_execution_charset_self_synchronizing() { #endif // ^^^ EDG workaround ^^^ } -// Generated per N4950 [format.string.std]/13, by tools/unicode_properties_parse/format_width_estimate_intervals.cpp +// Generated per N4950 [format.string.std]/13, by tools/unicode_properties_parse/format_width_estimate_intervals.py // in the https://github.com/microsoft/stl repository. + +// EastAsianWidth-15.0.0.txt +// Date: 2022-05-24, 17:40:20 GMT [KW, LI] inline constexpr char32_t _Width_estimate_intervals_v2[] = { // 0x1100u, 0x1160u, 0x231Au, 0x231Cu, 0x2329u, 0x232Bu, 0x23E9u, 0x23EDu, 0x23F0u, 0x23F1u, 0x23F3u, 0x23F4u, 0x25FDu, 0x25FFu, 0x2614u, 0x2616u, 0x2648u, 0x2654u, 0x267Fu, 0x2680u, 0x2693u, 0x2694u, 0x26A1u, 0x26A2u, 0x26AAu, 0x26ACu, @@ -1136,12 +1139,14 @@ public: if constexpr (_Is_ordinary_literal_encoding_utf8()) { return _Decode_utf(_First, _Last, _Val); +#ifdef _MSVC_EXECUTION_CHARACTER_SET // TRANSITION, VSO-1468747 (EDG) } else if constexpr (_Is_execution_charset_self_synchronizing()) { wchar_t _Wide; const auto _Res = __std_fs_convert_narrow_to_wide(__std_code_page{_MSVC_EXECUTION_CHARACTER_SET}, _First, 1, &_Wide, 1); _Val = _Wide; return {_First + 1, _Res._Len != 0}; +#endif // defined(_MSVC_EXECUTION_CHARACTER_SET) } else { if (*_First == '\0') { _Val = U'\0'; diff --git a/stl/inc/functional b/stl/inc/functional index a0c97586e40..ea1c2e63c03 100644 --- a/stl/inc/functional +++ b/stl/inc/functional @@ -585,6 +585,23 @@ _NODISCARD _CONSTEXPR20 _Mem_fn<_Rx _Ty::*> mem_fn(_Rx _Ty::*_Pm) noexcept { } #if _HAS_CXX17 +#if _HAS_CXX20 +#ifdef __cpp_lib_concepts // TRANSITION, GH-395 +template +concept _Can_invoke_then_negate = requires( + _Callable&& _Fx, _Types&&... _Args) { !_STD invoke(_STD forward<_Callable>(_Fx), _STD forward<_Types>(_Args)...); }; +#else // ^^^ defined(__cpp_lib_concepts) / !defined(__cpp_lib_concepts) vvv +template +inline constexpr bool _Can_invoke_then_negate_impl = false; +template +inline constexpr bool _Can_invoke_then_negate_impl< + void_t(), _STD declval<_Types>()...))>, _Callable, _Types...> = true; + +template +inline constexpr bool _Can_invoke_then_negate = _Can_invoke_then_negate_impl; +#endif // ^^^ !defined(__cpp_lib_concepts) ^^^ +#endif // _HAS_CXX20 + struct _Not_fn_tag { explicit _Not_fn_tag() = default; }; @@ -603,39 +620,119 @@ public: constexpr _Not_fn(const _Not_fn&) = default; constexpr _Not_fn(_Not_fn&&) = default; +#if _HAS_CXX20 && defined(__cpp_lib_concepts) // TRANSITION, GH-395 + template + requires _Can_invoke_then_negate<_Decayed&, _Types...> + constexpr decltype(auto) operator()(_Types&&... _Args) & noexcept( + noexcept(!_STD invoke(this->_Get_val(), _STD forward<_Types>(_Args)...))) { + return !_STD invoke(this->_Get_val(), _STD forward<_Types>(_Args)...); + } + + template + requires _Can_invoke_then_negate + constexpr decltype(auto) operator()(_Types&&... _Args) const& noexcept( + noexcept(!_STD invoke(this->_Get_val(), _STD forward<_Types>(_Args)...))) { + return !_STD invoke(this->_Get_val(), _STD forward<_Types>(_Args)...); + } + template - _CONSTEXPR20 auto operator()(_Types&&... _Args) & noexcept( + requires _Can_invoke_then_negate<_Decayed, _Types...> + constexpr decltype(auto) operator()(_Types&&... _Args) && noexcept( + noexcept(!_STD invoke(_STD move(this->_Get_val()), _STD forward<_Types>(_Args)...))) { + return !_STD invoke(_STD move(this->_Get_val()), _STD forward<_Types>(_Args)...); + } + + template + requires _Can_invoke_then_negate + constexpr decltype(auto) operator()(_Types&&... _Args) const&& noexcept( + noexcept(!_STD invoke(_STD move(this->_Get_val()), _STD forward<_Types>(_Args)...))) { + return !_STD invoke(_STD move(this->_Get_val()), _STD forward<_Types>(_Args)...); + } + + template + void operator()(_Types&&...) & = delete; + + template + void operator()(_Types&&...) const& = delete; + + template + void operator()(_Types&&...) && = delete; + + template + void operator()(_Types&&...) const&& = delete; +#elif _HAS_CXX20 // ^^^ _HAS_CXX20 && defined(__cpp_lib_concepts) / _HAS_CXX20 && !defined(__cpp_lib_concepts) vvv + template , int> = 0> + constexpr decltype(auto) operator()(_Types&&... _Args) & noexcept( + noexcept(!_STD invoke(this->_Get_val(), _STD forward<_Types>(_Args)...))) { + return !_STD invoke(this->_Get_val(), _STD forward<_Types>(_Args)...); + } + + template , int> = 0> + constexpr decltype(auto) operator()(_Types&&... _Args) const& noexcept( + noexcept(!_STD invoke(this->_Get_val(), _STD forward<_Types>(_Args)...))) { + return !_STD invoke(this->_Get_val(), _STD forward<_Types>(_Args)...); + } + + template , int> = 0> + constexpr decltype(auto) operator()(_Types&&... _Args) && noexcept( + noexcept(!_STD invoke(_STD move(this->_Get_val()), _STD forward<_Types>(_Args)...))) { + return !_STD invoke(_STD move(this->_Get_val()), _STD forward<_Types>(_Args)...); + } + + template , int> = 0> + constexpr decltype(auto) operator()(_Types&&... _Args) const&& noexcept( + noexcept(!_STD invoke(_STD move(this->_Get_val()), _STD forward<_Types>(_Args)...))) { + return !_STD invoke(_STD move(this->_Get_val()), _STD forward<_Types>(_Args)...); + } + + template , int> = 0> + void operator()(_Types&&...) & = delete; + + template , int> = 0> + void operator()(_Types&&...) const& = delete; + + template , int> = 0> + void operator()(_Types&&...) && = delete; + + template , int> = 0> + void operator()(_Types&&...) const&& = delete; +#else // ^^^ _HAS_CXX20 && !defined(__cpp_lib_concepts) / !_HAS_CXX20 vvv + template + auto operator()(_Types&&... _Args) & noexcept( noexcept(!_STD invoke(this->_Get_val(), _STD forward<_Types>(_Args)...))) -> decltype(!_STD declval>()) { return !_STD invoke(this->_Get_val(), _STD forward<_Types>(_Args)...); } template - _CONSTEXPR20 auto operator()(_Types&&... _Args) const& noexcept( + auto operator()(_Types&&... _Args) const& noexcept( noexcept(!_STD invoke(this->_Get_val(), _STD forward<_Types>(_Args)...))) -> decltype(!_STD declval>()) { return !_STD invoke(this->_Get_val(), _STD forward<_Types>(_Args)...); } template - _CONSTEXPR20 auto operator()(_Types&&... _Args) && noexcept( + auto operator()(_Types&&... _Args) && noexcept( noexcept(!_STD invoke(_STD move(this->_Get_val()), _STD forward<_Types>(_Args)...))) -> decltype(!_STD declval>()) { return !_STD invoke(_STD move(this->_Get_val()), _STD forward<_Types>(_Args)...); } template - _CONSTEXPR20 auto operator()(_Types&&... _Args) const&& noexcept( + auto operator()(_Types&&... _Args) const&& noexcept( noexcept(!_STD invoke(_STD move(this->_Get_val()), _STD forward<_Types>(_Args)...))) -> decltype(!_STD declval>()) { return !_STD invoke(_STD move(this->_Get_val()), _STD forward<_Types>(_Args)...); } +#endif // ^^^ !_HAS_CXX20 ^^^ }; _EXPORT_STD template _NODISCARD _CONSTEXPR20 _Not_fn> not_fn(_Callable&& _Obj) noexcept( is_nothrow_constructible_v, _Callable>) /* strengthened */ { // wrap a callable object to be negated + static_assert(is_move_constructible_v>, + "the callable type used with std::not_fn should be move constructible."); return _Not_fn>(_STD forward<_Callable>(_Obj), _Not_fn_tag{}); } #endif // _HAS_CXX17 @@ -1139,12 +1236,37 @@ public: _NON_MEMBER_CALL(_FUNCTION_POINTER_DEDUCTION_GUIDE, X1, X2, X3) #undef _FUNCTION_POINTER_DEDUCTION_GUIDE +template +struct _Deduce_from_call_operator : _Is_memfunptr<_Call_op>::_Guide_type {}; // N4958 [func.wrap.func.con]/16.1 + +#ifdef __cpp_static_call_operator +template +struct _Inspect_static_call_operator {}; + +#define _STATIC_CALL_OPERATOR_GUIDES(CALL_OPT, CV_OPT, REF_OPT, NOEXCEPT_OPT) \ + template \ + struct _Inspect_static_call_operator<_Ret(CALL_OPT*)(_Args...) NOEXCEPT_OPT> { \ + using type = _Ret(_Args...); \ + }; + +_NON_MEMBER_CALL(_STATIC_CALL_OPERATOR_GUIDES, , , ) +#ifdef __cpp_noexcept_function_type +_NON_MEMBER_CALL(_STATIC_CALL_OPERATOR_GUIDES, , , noexcept) +#endif // ^^^ defined(__cpp_noexcept_function_type) ^^^ + +#undef _STATIC_CALL_OPERATOR_GUIDES + +template +struct _Deduce_from_call_operator<_Fx, _Call_op, void_t().operator())>> + : _Inspect_static_call_operator<_Call_op> {}; // N4958 [func.wrap.func.con]/16.2 +#endif // ^^^ defined(__cpp_static_call_operator) ^^^ + template struct _Deduce_signature {}; // can't deduce signature when &_Fx::operator() is missing, inaccessible, or ambiguous template struct _Deduce_signature<_Fx, void_t> - : _Is_memfunptr::_Guide_type {}; // N4950 [func.wrap.func.con]/16.1 + : _Deduce_from_call_operator<_Fx, decltype(&_Fx::operator())> {}; template function(_Fx) -> function::type>; diff --git a/stl/inc/memory b/stl/inc/memory index 08c513e7b1d..48ec38fa611 100644 --- a/stl/inc/memory +++ b/stl/inc/memory @@ -2693,15 +2693,16 @@ private: void _Delete_this() noexcept override { // destroy self constexpr size_t _Align = alignof(_Ref_count_unbounded_array_alloc); using _Storage = _Alignas_storage_unit<_Align>; + using _Rebound_alloc = _Rebind_alloc_t<_Alloc, _Storage>; - _Rebind_alloc_t<_Alloc, _Storage> _Al(this->_Get_val()); + _Rebound_alloc _Al(this->_Get_val()); const size_t _Bytes = _Calculate_bytes_for_flexible_array<_Ref_count_unbounded_array_alloc, _Check_overflow::_Nope>(_Size); const size_t _Storage_units = _Bytes / sizeof(_Storage); this->~_Ref_count_unbounded_array_alloc(); - _Al.deallocate(reinterpret_cast<_Storage*>(this), _Storage_units); + _Al.deallocate(_STD _Refancy<_Alloc_ptr_t<_Rebound_alloc>>(reinterpret_cast<_Storage*>(this)), _Storage_units); } }; diff --git a/stl/inc/random b/stl/inc/random index ddf08e72236..377d5cb8095 100644 --- a/stl/inc/random +++ b/stl/inc/random @@ -1437,14 +1437,100 @@ private: int _Nx; }; +template +class _Discard_block_base { // TRANSITION, ABI, should be merged into discard_block_engine +public: + using base_type = _Engine; + using result_type = typename _Engine::result_type; + + _Discard_block_base() : _Eng(), _Nx(0) {} + + explicit _Discard_block_base(const _Engine& _Ex) : _Eng(_Ex), _Nx(0) {} + + explicit _Discard_block_base(result_type _Seed) : _Eng(_Seed), _Nx(0) {} + + template = 0> + explicit _Discard_block_base(_Seed_seq& _Seq) : _Eng(_Seq), _Nx(0) {} + + void seed() { // seed engine from default value + _Eng.seed(); + _Nx = 0; + } + + void seed(result_type _Xx0) { // seed engine from specified value + _Eng.seed(_Xx0); + _Nx = 0; + } + + template = 0> + void seed(_Seed_seq& _Seq) { // seed engine from seed sequence + _Eng.seed(_Seq); + _Nx = 0; + } + + _NODISCARD const base_type& base() const noexcept { + return _Eng; + } + + _NODISCARD result_type operator()() { + if (_Rx <= _Nx) { // discard values + while (_Nx++ < _Px) { + (void) _Eng(); + } + + _Nx = 0; + } + ++_Nx; + return _Eng(); + } + + void discard(unsigned long long _Nskip) { // discard _Nskip elements + for (; 0 < _Nskip; --_Nskip) { + (void) (*this)(); + } + } + + _NODISCARD_FRIEND bool operator==(const _Discard_block_base& _Left, const _Discard_block_base& _Right) { + return _Left._Eng == _Right._Eng && _Left._Nx == _Right._Nx; + } + +#if !_HAS_CXX20 + _NODISCARD_FRIEND bool operator!=(const _Discard_block_base& _Left, const _Discard_block_base& _Right) { + return !(_Left == _Right); + } +#endif // !_HAS_CXX20 + + template + friend basic_istream<_Elem, _Traits>& operator>>( + basic_istream<_Elem, _Traits>& _Istr, _Discard_block_base& _Eng) { // read state from _Istr + return _Istr >> _Eng._Eng >> _Eng._Nx; + } + + template + friend basic_ostream<_Elem, _Traits>& operator<<( + basic_ostream<_Elem, _Traits>& _Ostr, const _Discard_block_base& _Eng) { // write state to _Ostr + return _Ostr << _Eng._Eng << ' ' << _Eng._Nx; + } + +private: + base_type _Eng; + size_t _Nx; +}; + _EXPORT_STD template -class discard_block_engine : public discard_block<_Engine, _Px, _Rx> { // discard_block_engine compound engine +class discard_block_engine // discard_block_engine compound engine + : public conditional_t<_Px <= INT_MAX, discard_block<_Engine, static_cast(_Px), static_cast(_Rx)>, + _Discard_block_base<_Engine, _Px, _Rx>> { public: static_assert(0 < _Rx && _Rx <= _Px, "invalid template argument for discard_block_engine"); - using _Mybase = discard_block<_Engine, _Px, _Rx>; + using _Mybase = conditional_t<_Px <= INT_MAX, discard_block<_Engine, static_cast(_Px), static_cast(_Rx)>, + _Discard_block_base<_Engine, _Px, _Rx>>; using result_type = typename _Engine::result_type; + static constexpr size_t block_size = _Px; + static constexpr size_t used_block = _Rx; + discard_block_engine() : _Mybase() {} explicit discard_block_engine(const _Engine& _Ex) : _Mybase(_Ex) {} diff --git a/stl/inc/source_location b/stl/inc/source_location index e4e724d6526..31d5fb34cbb 100644 --- a/stl/inc/source_location +++ b/stl/inc/source_location @@ -20,15 +20,25 @@ _STL_DISABLE_CLANG_WARNINGS #pragma push_macro("new") #undef new +#ifndef _USE_DETAILED_FUNCTION_NAME_IN_SOURCE_LOCATION +#ifdef __EDG__ // TRANSITION, DevCom-10199227 +#define _USE_DETAILED_FUNCTION_NAME_IN_SOURCE_LOCATION 0 +#elif defined(__clang__) // TRANSITION, Clang 17 has this builtin +#define _USE_DETAILED_FUNCTION_NAME_IN_SOURCE_LOCATION __has_builtin(__builtin_FUNCSIG) +#else // ^^^ Clang / MSVC vvv +#define _USE_DETAILED_FUNCTION_NAME_IN_SOURCE_LOCATION 1 +#endif // ^^^ MSVC ^^^ +#endif // ^^^ !defined(_USE_DETAILED_FUNCTION_NAME_IN_SOURCE_LOCATION) ^^^ + _STD_BEGIN _EXPORT_STD struct source_location { _NODISCARD static consteval source_location current(const uint_least32_t _Line_ = __builtin_LINE(), const uint_least32_t _Column_ = __builtin_COLUMN(), const char* const _File_ = __builtin_FILE(), -#if defined(__clang__) || defined(__EDG__) // TRANSITION, DevCom-10199227 and LLVM-58951 - const char* const _Function_ = __builtin_FUNCTION() -#else // ^^^ workaround / no workaround vvv +#if _USE_DETAILED_FUNCTION_NAME_IN_SOURCE_LOCATION const char* const _Function_ = __builtin_FUNCSIG() -#endif // TRANSITION, DevCom-10199227 and LLVM-58951 +#else // ^^^ detailed / basic vvv + const char* const _Function_ = __builtin_FUNCTION() +#endif // ^^^ basic ^^^ ) noexcept { source_location _Result{}; _Result._Line = _Line_; diff --git a/stl/inc/vector b/stl/inc/vector index 95ef86aae3b..3f86a5258d9 100644 --- a/stl/inc/vector +++ b/stl/inc/vector @@ -3748,7 +3748,7 @@ _CONSTEXPR20 _OutIt _Copy_vbool(_VbIt _First, _VbIt _Last, _OutIt _Dest) { const auto _LastDestMask = static_cast<_Vbase>(-1) << _DestEnd._Myoff; const bool _IsSingleBlockSource = _VbFirst == _VbLast; - const bool _IsSingleBlockDest = _VbDest == _DestEnd._Myptr; + const bool _IsSingleBlockDest = _VbDest == _DestEnd._Myptr - (_DestEnd._Myoff == 0 ? 1 : 0); const bool _IsRightShift = _Dest._Myoff < _First._Myoff; if (_IsSingleBlockSource) { // We already excluded _First == _Last, so here _Last._Myoff > 0 and the shift is safe @@ -3757,7 +3757,7 @@ _CONSTEXPR20 _OutIt _Copy_vbool(_VbIt _First, _VbIt _Last, _OutIt _Dest) { const auto _SourceVal = _IsRightShift ? (*_VbFirst & _SourceMask) >> _SourceShift // : (*_VbFirst & _SourceMask) << _SourceShift; if (_IsSingleBlockDest) { - const auto _DestMask = _FirstDestMask | _LastDestMask; + const auto _DestMask = _FirstDestMask | (_DestEnd._Myoff == 0 ? 0 : _LastDestMask); *_VbDest = (*_VbDest & _DestMask) | _SourceVal; } else { *_VbDest = (*_VbDest & _FirstDestMask) | _SourceVal; @@ -3774,7 +3774,7 @@ _CONSTEXPR20 _OutIt _Copy_vbool(_VbIt _First, _VbIt _Last, _OutIt _Dest) { const auto _SourceVal = _IsRightShift ? (*_VbFirst & _FirstSourceMask) >> _SourceShift // : (*_VbFirst & _FirstSourceMask) << _SourceShift; - const auto _DestMask = _FirstDestMask | _LastDestMask; + const auto _DestMask = _FirstDestMask | (_DestEnd._Myoff == 0 ? 0 : _LastDestMask); if (_Last._Myoff != 0) { const auto _LastShift = _DestEnd._Myoff - _Last._Myoff; const auto _LastSourceVal = (*_VbLast & _LastSourceMask) << _LastShift; @@ -3842,20 +3842,22 @@ _CONSTEXPR20 _OutIt _Copy_vbool(_VbIt _First, _VbIt _Last, _OutIt _Dest) { *_VbDest = (*_VbDest & _DestMask) | _SourceVal; } - const auto _CarryVal = (*_VbFirst & _LastSourceMask) << _CarryShift; - if (_Last._Myoff >= _SourceShift) { - *_VbDest = (*_VbDest & _CarryMask) | _CarryVal; - - // We have more bits remaining than the final block has left - if (_Last._Myoff != _SourceShift) { - ++_VbDest; - const auto _SourceVal = (*_VbFirst & _LastSourceMask) >> _SourceShift; - *_VbDest = (*_VbDest & _LastDestMask) | _SourceVal; + if (_Last._Myoff != 0) { + const auto _CarryVal = (*_VbFirst & _LastSourceMask) << _CarryShift; + if (_Last._Myoff >= _SourceShift) { + *_VbDest = (*_VbDest & _CarryMask) | _CarryVal; + + // We have more bits remaining than the final block has left + if (_Last._Myoff != _SourceShift) { + ++_VbDest; + const auto _SourceVal = (*_VbFirst & _LastSourceMask) >> _SourceShift; + *_VbDest = (*_VbDest & _LastDestMask) | _SourceVal; + } + } else { + // There are not enough bits to fill the final block so we need to mask both ends + const auto _FinalMask = _CarryMask | _LastDestMask; + *_VbDest = (*_VbDest & _FinalMask) | _CarryVal; } - } else if (_Last._Myoff != 0) { - // There are not enough bits to fill the final block so we need to mask both ends - const auto _FinalMask = _CarryMask | _LastDestMask; - *_VbDest = (*_VbDest & _FinalMask) | _CarryVal; } } else { const auto _SourceShift = _Dest._Myoff - _First._Myoff; diff --git a/stl/inc/xstring b/stl/inc/xstring index 8b7fc948540..ce879cf28ad 100644 --- a/stl/inc/xstring +++ b/stl/inc/xstring @@ -2287,6 +2287,19 @@ public: value_type _Buf[_BUF_SIZE]; pointer _Ptr; char _Alias[_BUF_SIZE]; // TRANSITION, ABI: _Alias is preserved for binary compatibility (especially /clr) + + _CONSTEXPR20 void _Switch_to_buf() noexcept { + _STD _Destroy_in_place(_Ptr); + +#if _HAS_CXX20 + // start the lifetime of the array elements + if (_STD is_constant_evaluated()) { + for (size_type _Idx = 0; _Idx < _BUF_SIZE; ++_Idx) { + _Buf[_Idx] = value_type(); + } + } +#endif // _HAS_CXX20 + } }; _Bxty _Bx; @@ -2484,13 +2497,11 @@ private: public: _CONSTEXPR20 basic_string() noexcept(is_nothrow_default_constructible_v<_Alty>) : _Mypair(_Zero_then_variadic_args_t{}) { - _Mypair._Myval2._Alloc_proxy(_GET_PROXY_ALLOCATOR(_Alty, _Getal())); - _Tidy_init(); + _Construct_empty(); } _CONSTEXPR20 explicit basic_string(const _Alloc& _Al) noexcept : _Mypair(_One_then_variadic_args_t{}, _Al) { - _Mypair._Myval2._Alloc_proxy(_GET_PROXY_ALLOCATOR(_Alty, _Getal())); - _Tidy_init(); + _Construct_empty(); } _CONSTEXPR20 basic_string(const basic_string& _Right) @@ -2578,8 +2589,7 @@ public: auto _UFirst = _Get_unwrapped(_First); auto _ULast = _Get_unwrapped(_Last); if (_UFirst == _ULast) { - _Mypair._Myval2._Alloc_proxy(_GET_PROXY_ALLOCATOR(_Alty, _Getal())); - _Tidy_init(); + _Construct_empty(); } else { if constexpr (_Is_elem_cptr::value) { _Construct<_Construct_strategy::_From_ptr>( @@ -2630,6 +2640,19 @@ private: _Al.deallocate(_Old_ptr, _Capacity + 1); // +1 for null terminator } + _CONSTEXPR20 void _Construct_empty() { + auto& _My_data = _Mypair._Myval2; + _My_data._Alloc_proxy(_GET_PROXY_ALLOCATOR(_Alty, _Getal())); + + // initialize basic_string data members + _My_data._Mysize = 0; + _My_data._Myres = _Small_string_capacity; + _My_data._Activate_SSO_buffer(); + + // the _Traits::assign is last so the codegen doesn't think the char write can alias this + _Traits::assign(_My_data._Bx._Buf[0], _Elem()); + } + enum class _Construct_strategy : uint8_t { _From_char, _From_ptr, _From_string }; template <_Construct_strategy _Strat, class _Char_or_ptr> @@ -2695,10 +2718,12 @@ private: template _CONSTEXPR20 void _Construct_from_iter(_Iter _First, const _Sent _Last, _Size _Count = {}) { - // Pre: _First models input_iterator or meets the Cpp17InputIterator requirements - // Pre: [_First, _Last) is a valid range + // Pre: _Iter models input_iterator or meets the Cpp17InputIterator requirements. + // Pre: [_First, _Last) is a valid range. + // Pre: if _Iter models forward_iterator or meets the Cpp17ForwardIterator requirements, + // then is_same_v<_Size, size_type> holds. // Pre: if is_same_v<_Size, size_type>, _Count is the length of [_First, _Last). - // Pre: *this is in small mode; the lifetime of the SSO elements has already begun + // Pre: *this is in small mode; the lifetime of the SSO elements has already begun. auto& _My_data = _Mypair._Myval2; auto& _Al = _Getal(); @@ -2722,35 +2747,47 @@ private: } _Tidy_deallocate_guard _Guard{this}; - for (; _First != _Last; ++_First) { - if constexpr (!is_same_v<_Size, size_type>) { - if (_My_data._Mysize == _My_data._Myres) { // Need to grow - if (_My_data._Mysize == max_size()) { - _Xlen_string(); // result too long - } - _Elem* const _Old_ptr = _My_data._Myptr(); - size_type _New_capacity = _Calculate_growth(_My_data._Mysize + 1); - const pointer _New_ptr = _Allocate_for_capacity(_Al, _New_capacity); // throws + constexpr bool _Can_construct_by_copy = + _Is_specialization_v<_Traits, char_traits> && _Is_EcharT<_Elem> && is_same_v<_Size, size_type>; - _Traits::copy(_Unfancy(_New_ptr), _Old_ptr, _My_data._Mysize); - if (_My_data._Large_mode_engaged()) { // Need to deallocate old storage - _Deallocate_for_capacity(_Al, _My_data._Bx._Ptr, _My_data._Myres); - _My_data._Bx._Ptr = _New_ptr; - } else { - _Construct_in_place(_My_data._Bx._Ptr, _New_ptr); + if constexpr (_Can_construct_by_copy) { + const auto _Data = _My_data._Myptr(); + _STD _Copy_n_unchecked4(_STD move(_First), _Count, _Data); + _My_data._Mysize = _Count; + _Data[_Count] = _Elem(); + } else { + for (; _First != _Last; ++_First) { + if constexpr (!is_same_v<_Size, size_type>) { + if (_My_data._Mysize == _My_data._Myres) { // Need to grow + if (_My_data._Mysize == max_size()) { + _Xlen_string(); // result too long + } + + _Elem* const _Old_ptr = _My_data._Myptr(); + size_type _New_capacity = _Calculate_growth(_My_data._Mysize + 1); + const pointer _New_ptr = _Allocate_for_capacity(_Al, _New_capacity); // throws + + _Traits::copy(_Unfancy(_New_ptr), _Old_ptr, _My_data._Mysize); + if (_My_data._Large_mode_engaged()) { // Need to deallocate old storage + _Deallocate_for_capacity(_Al, _My_data._Bx._Ptr, _My_data._Myres); + _My_data._Bx._Ptr = _New_ptr; + } else { + _Construct_in_place(_My_data._Bx._Ptr, _New_ptr); + } + _My_data._Myres = _New_capacity; } - _My_data._Myres = _New_capacity; } + + _Elem* const _Ptr = _My_data._Myptr(); + _Traits::assign(_Ptr[_My_data._Mysize], *_First); + ++_My_data._Mysize; } _Elem* const _Ptr = _My_data._Myptr(); - _Traits::assign(_Ptr[_My_data._Mysize], *_First); - ++_My_data._Mysize; + _Traits::assign(_Ptr[_My_data._Mysize], _Elem()); } - _Elem* const _Ptr = _My_data._Myptr(); - _Traits::assign(_Ptr[_My_data._Mysize], _Elem()); _ASAN_STRING_CREATE(*this); _Guard._Target = nullptr; _Proxy._Release(); @@ -2918,8 +2955,7 @@ public: basic_string(_String_constructor_rvalue_allocator_tag, _Alloc&& _Al) : _Mypair(_One_then_variadic_args_t{}, _STD move(_Al)) { // Used exclusively by basic_stringbuf - _Mypair._Myval2._Alloc_proxy(_GET_PROXY_ALLOCATOR(_Alty, _Getal())); - _Tidy_init(); + _Construct_empty(); } _NODISCARD bool _Move_assign_from_buffer( @@ -2958,10 +2994,13 @@ public: _Released_buffer _Result; auto& _My_data = _Mypair._Myval2; _Result._Size = _My_data._Mysize; + _My_data._Orphan_all(); _ASAN_STRING_REMOVE(*this); if (_My_data._Large_mode_engaged()) { _Result._Ptr = _My_data._Bx._Ptr; _Result._Actual_allocation_size = _My_data._Myres + 1; + + _My_data._Bx._Switch_to_buf(); } else { // use _Least_allocation_size to avoid small mode, if the buffer is assigned back size_type _Allocated = _Least_allocation_size; @@ -2969,8 +3008,9 @@ public: _Traits::copy(_Unfancy(_Result._Ptr), _My_data._Bx._Buf, _BUF_SIZE); _Result._Actual_allocation_size = _Allocated; } - _My_data._Orphan_all(); - _Tidy_init(); + _My_data._Mysize = 0; + _My_data._Myres = _Small_string_capacity; + _Traits::assign(_My_data._Bx._Buf[0], _Elem()); return _Result; } #endif // _HAS_CXX20 @@ -3038,27 +3078,34 @@ private: const auto _Right_data_mem = reinterpret_cast(_STD addressof(_Right._Mypair._Myval2)) + _Memcpy_val_offset; _CSTD memcpy(_My_data_mem, _Right_data_mem, _Memcpy_val_size); - _Right._Tidy_init(); + + _Right_data._Mysize = 0; + _Right_data._Myres = _Small_string_capacity; + _Right_data._Activate_SSO_buffer(); + _Traits::assign(_Right_data._Bx._Buf[0], _Elem()); return; } } #endif // !defined(_INSERT_STRING_ANNOTATION) if (_Right_data._Large_mode_engaged()) { // steal buffer - _Construct_in_place(_My_data._Bx._Ptr, _Right_data._Bx._Ptr); _Swap_proxy_and_iterators(_Right); - _Destroy_in_place(_Right_data._Bx._Ptr); + _Construct_in_place(_My_data._Bx._Ptr, _Right_data._Bx._Ptr); + _Right_data._Bx._Switch_to_buf(); } else { // copy small string buffer + _Right_data._Orphan_all(); + _My_data._Activate_SSO_buffer(); _Traits::copy(_My_data._Bx._Buf, _Right_data._Bx._Buf, _Right_data._Mysize + 1); - _Right_data._Orphan_all(); } _My_data._Myres = _Right_data._Myres; _My_data._Mysize = _Right_data._Mysize; - _Right._Tidy_init(); + _Right_data._Mysize = 0; + _Right_data._Myres = _Small_string_capacity; + _Traits::assign(_Right_data._Bx._Buf[0], _Elem()); } #if _HAS_CXX23 @@ -4252,9 +4299,7 @@ public: static _CONSTEXPR20 void _Swap_bx_large_with_small(_Scary_val& _Starts_large, _Scary_val& _Starts_small) noexcept { // exchange a string in large mode with one in small mode const pointer _Ptr = _Starts_large._Bx._Ptr; - _Destroy_in_place(_Starts_large._Bx._Ptr); - - _Starts_large._Activate_SSO_buffer(); + _Starts_large._Bx._Switch_to_buf(); _Traits::copy(_Starts_large._Bx._Buf, _Starts_small._Bx._Buf, _BUF_SIZE); _Construct_in_place(_Starts_small._Bx._Ptr, _Ptr); @@ -4802,10 +4847,9 @@ private: _My_data._Orphan_all(); _ASAN_STRING_REMOVE(*this); const pointer _Ptr = _My_data._Bx._Ptr; - auto& _Al = _Getal(); - _Destroy_in_place(_My_data._Bx._Ptr); - _My_data._Activate_SSO_buffer(); + _My_data._Bx._Switch_to_buf(); _Traits::copy(_My_data._Bx._Buf, _Unfancy(_Ptr), _My_data._Mysize + 1); + auto& _Al = _Getal(); _Deallocate_for_capacity(_Al, _Ptr, _My_data._Myres); _My_data._Myres = _Small_string_capacity; } @@ -4815,27 +4859,14 @@ private: _Traits::assign(_Mypair._Myval2._Myptr()[_Mypair._Myval2._Mysize = _New_size], _Elem()); } - _CONSTEXPR20 void _Tidy_init() noexcept { - // initialize basic_string data members - auto& _My_data = _Mypair._Myval2; - _My_data._Mysize = 0; - _My_data._Myres = _Small_string_capacity; - _My_data._Activate_SSO_buffer(); - - // the _Traits::assign is last so the codegen doesn't think the char write can alias this - _Traits::assign(_My_data._Bx._Buf[0], _Elem()); - } - _CONSTEXPR20 void _Tidy_deallocate() noexcept { // initialize buffer, deallocating any storage auto& _My_data = _Mypair._Myval2; _My_data._Orphan_all(); if (_My_data._Large_mode_engaged()) { _ASAN_STRING_REMOVE(*this); - const pointer _Ptr = _My_data._Bx._Ptr; - auto& _Al = _Getal(); - _Destroy_in_place(_My_data._Bx._Ptr); - _My_data._Activate_SSO_buffer(); - _Deallocate_for_capacity(_Al, _Ptr, _My_data._Myres); + auto& _Al = _Getal(); + _Deallocate_for_capacity(_Al, _My_data._Bx._Ptr, _My_data._Myres); + _My_data._Bx._Switch_to_buf(); } _My_data._Mysize = 0; diff --git a/stl/inc/xutility b/stl/inc/xutility index 351138b4716..8af5fa3de10 100644 --- a/stl/inc/xutility +++ b/stl/inc/xutility @@ -585,6 +585,13 @@ struct _Unused_parameter { // generic unused parameter struct constexpr _Unused_parameter(_Ty&&) noexcept {} }; +template // checks whether a container/view is a non-customized specialization +_INLINE_VAR constexpr bool _Has_unchecked_begin_end = false; + +template +_INLINE_VAR constexpr bool _Has_unchecked_begin_end<_Ty, + void_t()._Unchecked_begin()), decltype(_STD declval<_Ty&>()._Unchecked_end())>> = true; + template using _Algorithm_int_t = conditional_t, _Ty, ptrdiff_t>; @@ -5905,11 +5912,7 @@ namespace ranges { return _RANGES next(_STD move(_First), _Result - _First_ptr); } #else // ^^^ _USE_STD_VECTOR_ALGORITHMS / !_USE_STD_VECTOR_ALGORITHMS vvv - if constexpr (sizeof(_Iter_value_t<_It>) == 1 -#if defined(_M_ARM64) || defined(_M_ARM64EC) // TRANSITION, VSO-1538014 : memchr inspects bytes after the match - && _Is_sized -#endif // ^^^ workaround ^^^ - ) { + if constexpr (sizeof(_Iter_value_t<_It>) == 1) { size_t _Count; if constexpr (_Is_sized) { _Count = static_cast(_Last - _First); diff --git a/stl/inc/yvals_core.h b/stl/inc/yvals_core.h index 46310c21a4a..1cfe9ba2fcc 100644 --- a/stl/inc/yvals_core.h +++ b/stl/inc/yvals_core.h @@ -128,6 +128,7 @@ // P0858R0 Constexpr Iterator Requirements // P1065R2 constexpr INVOKE // (the std::invoke function only; other components like bind and reference_wrapper are C++20 only) +// P1169R4 static operator() // P1518R2 Stop Overconstraining Allocators In Container Deduction Guides // P2162R2 Inheriting From variant // P2251R1 Require span And basic_string_view To Be Trivially Copyable @@ -794,6 +795,7 @@ // warning C4702: unreachable code // warning C4793: function compiled as native // warning C4820: 'N' bytes padding added after data member 'meow' (/Wall) +// warning C4868: compiler may not enforce left-to-right evaluation order in braced initializer list (/Wall) // warning C4988: variable declared outside class/function scope (/Wall /d1WarnOnGlobals) // warning C5026: move constructor was implicitly defined as deleted (/Wall) // warning C5027: move assignment operator was implicitly defined as deleted (/Wall) @@ -806,8 +808,8 @@ // clang-format off #define _STL_DISABLED_WARNINGS \ 4180 4412 4455 4494 4514 4574 4582 4583 4587 4588 \ - 4619 4623 4625 4626 4643 4648 4702 4793 4820 4988 \ - 5026 5027 5045 5220 6294 \ + 4619 4623 4625 4626 4643 4648 4702 4793 4820 4868 \ + 4988 5026 5027 5045 5220 6294 \ _STL_DISABLED_WARNING_C4577 \ _STL_DISABLED_WARNING_C4984 \ _STL_DISABLED_WARNING_C5053 \ @@ -877,7 +879,7 @@ #define _CPPLIB_VER 650 #define _MSVC_STL_VERSION 143 -#define _MSVC_STL_UPDATE 202309L +#define _MSVC_STL_UPDATE 202310L #ifndef _ALLOW_COMPILER_AND_STL_VERSION_MISMATCH #if defined(__CUDACC__) && defined(__CUDACC_VER_MAJOR__) diff --git a/stl/msbuild/stl_1/md/msvcp_1_app/msvcp_1.nativeproj b/stl/msbuild/stl_1/md/msvcp_1_app/msvcp_1.nativeproj index 966b3699874..9a2a0eeb8ae 100644 --- a/stl/msbuild/stl_1/md/msvcp_1_app/msvcp_1.nativeproj +++ b/stl/msbuild/stl_1/md/msvcp_1_app/msvcp_1.nativeproj @@ -1,16 +1,18 @@ - - - - - md - app - true - - - - + + + + {AC581714-5C34-43F1-88AA-F239723F751F} + false + + + + md + app + true + + diff --git a/stl/msbuild/stl_1/md/msvcp_1_kernel32/msvcp_1.nativeproj b/stl/msbuild/stl_1/md/msvcp_1_kernel32/msvcp_1.nativeproj index 781acdc848d..258e418170a 100644 --- a/stl/msbuild/stl_1/md/msvcp_1_kernel32/msvcp_1.nativeproj +++ b/stl/msbuild/stl_1/md/msvcp_1_kernel32/msvcp_1.nativeproj @@ -1,16 +1,18 @@ - - - - - md - kernel32 - true - - - - + + + + {58C30DB7-35C9-432D-8490-66F6E5901B8F} + false + + + + md + kernel32 + true + + diff --git a/stl/msbuild/stl_1/md/msvcp_1_netfx/msvcp_1.nativeproj b/stl/msbuild/stl_1/md/msvcp_1_netfx/msvcp_1.nativeproj index a8148f1e68d..39c8ebc8873 100644 --- a/stl/msbuild/stl_1/md/msvcp_1_netfx/msvcp_1.nativeproj +++ b/stl/msbuild/stl_1/md/msvcp_1_netfx/msvcp_1.nativeproj @@ -1,16 +1,18 @@ - - - - - md - netfx - true - - - - + + + + {CAA5F16A-A6C1-4450-981D-E3BF0F0A7B5B} + false + + + + md + netfx + true + + diff --git a/stl/msbuild/stl_1/md/msvcp_1_onecore/msvcp_1.nativeproj b/stl/msbuild/stl_1/md/msvcp_1_onecore/msvcp_1.nativeproj index 4b1ddcbfce3..732b4404a0d 100644 --- a/stl/msbuild/stl_1/md/msvcp_1_onecore/msvcp_1.nativeproj +++ b/stl/msbuild/stl_1/md/msvcp_1_onecore/msvcp_1.nativeproj @@ -1,16 +1,18 @@ - - - - - md - onecore - true - - - - + + + + {2BD1256B-3615-4061-AD30-4F5E1E092381} + false + + + + md + onecore + true + + diff --git a/stl/msbuild/stl_1/msvcp_1.settings.targets b/stl/msbuild/stl_1/msvcp_1.settings.targets index 57849d8912b..176ccb16a5a 100644 --- a/stl/msbuild/stl_1/msvcp_1.settings.targets +++ b/stl/msbuild/stl_1/msvcp_1.settings.targets @@ -4,6 +4,9 @@ Copyright (c) Microsoft Corporation. SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception --> + + DynamicLibrary + p_1 @@ -11,8 +14,6 @@ SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception true true true - - DYNLINK diff --git a/stl/msbuild/stl_1/xmd/msvcp_1_app/msvcp_1.nativeproj b/stl/msbuild/stl_1/xmd/msvcp_1_app/msvcp_1.nativeproj index b386bc9bc49..4370ebc1e10 100644 --- a/stl/msbuild/stl_1/xmd/msvcp_1_app/msvcp_1.nativeproj +++ b/stl/msbuild/stl_1/xmd/msvcp_1_app/msvcp_1.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - app - true - - - - + + + + {E30D9740-AD72-4A90-B8A9-A1CABCC52EB9} + false + + + + xmd + app + true + + diff --git a/stl/msbuild/stl_1/xmd/msvcp_1_kernel32/msvcp_1.nativeproj b/stl/msbuild/stl_1/xmd/msvcp_1_kernel32/msvcp_1.nativeproj index d834b6edd69..8fa959f7c76 100644 --- a/stl/msbuild/stl_1/xmd/msvcp_1_kernel32/msvcp_1.nativeproj +++ b/stl/msbuild/stl_1/xmd/msvcp_1_kernel32/msvcp_1.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - kernel32 - true - - - - + + + + {A90AB3DB-494B-4ECD-AEFB-E880F9C58F74} + false + + + + xmd + kernel32 + true + + diff --git a/stl/msbuild/stl_1/xmd/msvcp_1_netfx/msvcp_1.nativeproj b/stl/msbuild/stl_1/xmd/msvcp_1_netfx/msvcp_1.nativeproj index 378adb8e009..bed9439872c 100644 --- a/stl/msbuild/stl_1/xmd/msvcp_1_netfx/msvcp_1.nativeproj +++ b/stl/msbuild/stl_1/xmd/msvcp_1_netfx/msvcp_1.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - netfx - true - - - - + + + + {B37B087A-D591-472E-8E73-396CD32F5E77} + false + + + + xmd + netfx + true + + diff --git a/stl/msbuild/stl_1/xmd/msvcp_1_onecore/msvcp_1.nativeproj b/stl/msbuild/stl_1/xmd/msvcp_1_onecore/msvcp_1.nativeproj index 3eeaf9b1d62..24ba1f0c656 100644 --- a/stl/msbuild/stl_1/xmd/msvcp_1_onecore/msvcp_1.nativeproj +++ b/stl/msbuild/stl_1/xmd/msvcp_1_onecore/msvcp_1.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - onecore - true - - - - + + + + {6E55B52D-472B-4A51-AC94-B1E391ECAAD7} + false + + + + xmd + onecore + true + + diff --git a/stl/msbuild/stl_2/md/msvcp_2_app/msvcp_2.nativeproj b/stl/msbuild/stl_2/md/msvcp_2_app/msvcp_2.nativeproj index 9747790c304..fb8bc40c850 100644 --- a/stl/msbuild/stl_2/md/msvcp_2_app/msvcp_2.nativeproj +++ b/stl/msbuild/stl_2/md/msvcp_2_app/msvcp_2.nativeproj @@ -1,16 +1,18 @@ - - - - - md - app - true - - - - + + + + {451BB540-FBE3-4BFC-B3FC-1D118E6D44ED} + false + + + + md + app + true + + diff --git a/stl/msbuild/stl_2/md/msvcp_2_kernel32/msvcp_2.nativeproj b/stl/msbuild/stl_2/md/msvcp_2_kernel32/msvcp_2.nativeproj index bcff4e94ca8..bdce81e61b9 100644 --- a/stl/msbuild/stl_2/md/msvcp_2_kernel32/msvcp_2.nativeproj +++ b/stl/msbuild/stl_2/md/msvcp_2_kernel32/msvcp_2.nativeproj @@ -1,16 +1,18 @@ - - - - - md - kernel32 - true - - - - + + + + {219EFF3E-A40D-46E4-86DC-887AF90330CA} + false + + + + md + kernel32 + true + + diff --git a/stl/msbuild/stl_2/md/msvcp_2_netfx/msvcp_2.nativeproj b/stl/msbuild/stl_2/md/msvcp_2_netfx/msvcp_2.nativeproj index 840069c3b6a..7dcac8b0f07 100644 --- a/stl/msbuild/stl_2/md/msvcp_2_netfx/msvcp_2.nativeproj +++ b/stl/msbuild/stl_2/md/msvcp_2_netfx/msvcp_2.nativeproj @@ -1,16 +1,18 @@ - - - - - md - netfx - true - - - - + + + + {DEC67AC5-1EF2-4745-BAFF-28484A23477E} + false + + + + md + netfx + true + + diff --git a/stl/msbuild/stl_2/md/msvcp_2_onecore/msvcp_2.nativeproj b/stl/msbuild/stl_2/md/msvcp_2_onecore/msvcp_2.nativeproj index 38e5772cb39..a1063717ef8 100644 --- a/stl/msbuild/stl_2/md/msvcp_2_onecore/msvcp_2.nativeproj +++ b/stl/msbuild/stl_2/md/msvcp_2_onecore/msvcp_2.nativeproj @@ -1,16 +1,18 @@ - - - - - md - onecore - true - - - - + + + + {24C78BD7-AED7-4090-BE81-8E3247ECC5A3} + false + + + + md + onecore + true + + diff --git a/stl/msbuild/stl_2/msvcp_2.settings.targets b/stl/msbuild/stl_2/msvcp_2.settings.targets index eab44b6af00..b11b1a4c331 100644 --- a/stl/msbuild/stl_2/msvcp_2.settings.targets +++ b/stl/msbuild/stl_2/msvcp_2.settings.targets @@ -4,6 +4,9 @@ Copyright (c) Microsoft Corporation. SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception --> + + DynamicLibrary + p_2 @@ -11,8 +14,6 @@ SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception true true true - - DYNLINK diff --git a/stl/msbuild/stl_2/xmd/msvcp_2_app/msvcp_2.nativeproj b/stl/msbuild/stl_2/xmd/msvcp_2_app/msvcp_2.nativeproj index 5751496f0f4..1c1a9414c70 100644 --- a/stl/msbuild/stl_2/xmd/msvcp_2_app/msvcp_2.nativeproj +++ b/stl/msbuild/stl_2/xmd/msvcp_2_app/msvcp_2.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - app - true - - - - + + + + {EFC70BD7-F82E-4951-8F60-468B164BF419} + false + + + + xmd + app + true + + diff --git a/stl/msbuild/stl_2/xmd/msvcp_2_kernel32/msvcp_2.nativeproj b/stl/msbuild/stl_2/xmd/msvcp_2_kernel32/msvcp_2.nativeproj index 0c78314cdc8..071b5877006 100644 --- a/stl/msbuild/stl_2/xmd/msvcp_2_kernel32/msvcp_2.nativeproj +++ b/stl/msbuild/stl_2/xmd/msvcp_2_kernel32/msvcp_2.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - kernel32 - true - - - - + + + + {3CFB766B-CCA6-4078-9A03-CAE24FF65373} + false + + + + xmd + kernel32 + true + + diff --git a/stl/msbuild/stl_2/xmd/msvcp_2_netfx/msvcp_2.nativeproj b/stl/msbuild/stl_2/xmd/msvcp_2_netfx/msvcp_2.nativeproj index a9b4b51afc2..73d7b05cd57 100644 --- a/stl/msbuild/stl_2/xmd/msvcp_2_netfx/msvcp_2.nativeproj +++ b/stl/msbuild/stl_2/xmd/msvcp_2_netfx/msvcp_2.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - netfx - true - - - - + + + + {4A10E59B-BC11-478F-A911-4985F503B489} + false + + + + xmd + netfx + true + + diff --git a/stl/msbuild/stl_2/xmd/msvcp_2_onecore/msvcp_2.nativeproj b/stl/msbuild/stl_2/xmd/msvcp_2_onecore/msvcp_2.nativeproj index 96281b17219..b59f49bb03d 100644 --- a/stl/msbuild/stl_2/xmd/msvcp_2_onecore/msvcp_2.nativeproj +++ b/stl/msbuild/stl_2/xmd/msvcp_2_onecore/msvcp_2.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - onecore - true - - - - + + + + {4897703D-D42F-4CF6-B4C1-B7CFD3D9F054} + false + + + + xmd + onecore + true + + diff --git a/stl/msbuild/stl_asan/stl_asan.nativeproj b/stl/msbuild/stl_asan/stl_asan.nativeproj index cdb216a23ea..048d94c520b 100644 --- a/stl/msbuild/stl_asan/stl_asan.nativeproj +++ b/stl/msbuild/stl_asan/stl_asan.nativeproj @@ -1,14 +1,16 @@ - - - - - true - - - - + + + + {B8236181-0F0C-465B-8729-36944CBF324A} + false + + + + true + + diff --git a/stl/msbuild/stl_asan/stl_asan.settings.targets b/stl/msbuild/stl_asan/stl_asan.settings.targets index 766ed8b6612..eef8af472ad 100644 --- a/stl/msbuild/stl_asan/stl_asan.settings.targets +++ b/stl/msbuild/stl_asan/stl_asan.settings.targets @@ -4,10 +4,12 @@ Copyright (c) Microsoft Corporation. SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception --> + + StaticLibrary + p_stl_asan - LIBRARY true diff --git a/stl/msbuild/stl_atomic_wait/md/msvcp_atomic_wait_app/msvcp_atomic_wait.nativeproj b/stl/msbuild/stl_atomic_wait/md/msvcp_atomic_wait_app/msvcp_atomic_wait.nativeproj index 25ee294c299..4404468a37c 100644 --- a/stl/msbuild/stl_atomic_wait/md/msvcp_atomic_wait_app/msvcp_atomic_wait.nativeproj +++ b/stl/msbuild/stl_atomic_wait/md/msvcp_atomic_wait_app/msvcp_atomic_wait.nativeproj @@ -1,16 +1,18 @@ - - - - - md - app - true - - - - + + + + {99C61FE5-793F-4D49-82F6-27938575B058} + false + + + + md + app + true + + diff --git a/stl/msbuild/stl_atomic_wait/md/msvcp_atomic_wait_kernel32/msvcp_atomic_wait.nativeproj b/stl/msbuild/stl_atomic_wait/md/msvcp_atomic_wait_kernel32/msvcp_atomic_wait.nativeproj index fa3b0cb07d1..29819eaaa3b 100644 --- a/stl/msbuild/stl_atomic_wait/md/msvcp_atomic_wait_kernel32/msvcp_atomic_wait.nativeproj +++ b/stl/msbuild/stl_atomic_wait/md/msvcp_atomic_wait_kernel32/msvcp_atomic_wait.nativeproj @@ -1,16 +1,18 @@ - - - - - md - kernel32 - true - - - - + + + + {2C785D3F-9961-46E9-A202-D410DAD6269D} + false + + + + md + kernel32 + true + + diff --git a/stl/msbuild/stl_atomic_wait/md/msvcp_atomic_wait_netfx/msvcp_atomic_wait.nativeproj b/stl/msbuild/stl_atomic_wait/md/msvcp_atomic_wait_netfx/msvcp_atomic_wait.nativeproj index b3d49531cde..f81dae4d668 100644 --- a/stl/msbuild/stl_atomic_wait/md/msvcp_atomic_wait_netfx/msvcp_atomic_wait.nativeproj +++ b/stl/msbuild/stl_atomic_wait/md/msvcp_atomic_wait_netfx/msvcp_atomic_wait.nativeproj @@ -1,16 +1,18 @@ - - - - - md - netfx - true - - - - + + + + {B0D8709C-8649-43DF-AB53-AA05134A9B83} + false + + + + md + netfx + true + + diff --git a/stl/msbuild/stl_atomic_wait/md/msvcp_atomic_wait_onecore/msvcp_atomic_wait.nativeproj b/stl/msbuild/stl_atomic_wait/md/msvcp_atomic_wait_onecore/msvcp_atomic_wait.nativeproj index 5ecec8dcfc2..76c7329c1b0 100644 --- a/stl/msbuild/stl_atomic_wait/md/msvcp_atomic_wait_onecore/msvcp_atomic_wait.nativeproj +++ b/stl/msbuild/stl_atomic_wait/md/msvcp_atomic_wait_onecore/msvcp_atomic_wait.nativeproj @@ -1,16 +1,18 @@ - - - - - md - onecore - true - - - - + + + + {22F86914-609E-4BF5-A1DA-2804C1251044} + false + + + + md + onecore + true + + diff --git a/stl/msbuild/stl_atomic_wait/msvcp_atomic_wait.settings.targets b/stl/msbuild/stl_atomic_wait/msvcp_atomic_wait.settings.targets index 43eb0ad9e78..2f778a88276 100644 --- a/stl/msbuild/stl_atomic_wait/msvcp_atomic_wait.settings.targets +++ b/stl/msbuild/stl_atomic_wait/msvcp_atomic_wait.settings.targets @@ -4,6 +4,9 @@ Copyright (c) Microsoft Corporation. SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception --> + + DynamicLibrary + p_atomic_wait @@ -11,8 +14,6 @@ SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception true true true - - DYNLINK diff --git a/stl/msbuild/stl_atomic_wait/xmd/msvcp_atomic_wait_app/msvcp_atomic_wait.nativeproj b/stl/msbuild/stl_atomic_wait/xmd/msvcp_atomic_wait_app/msvcp_atomic_wait.nativeproj index 3cf18558d38..719161c308a 100644 --- a/stl/msbuild/stl_atomic_wait/xmd/msvcp_atomic_wait_app/msvcp_atomic_wait.nativeproj +++ b/stl/msbuild/stl_atomic_wait/xmd/msvcp_atomic_wait_app/msvcp_atomic_wait.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - app - true - - - - + + + + {3AEA1ADF-5AA1-4BAB-B0AA-104B622C75B5} + false + + + + xmd + app + true + + diff --git a/stl/msbuild/stl_atomic_wait/xmd/msvcp_atomic_wait_kernel32/msvcp_atomic_wait.nativeproj b/stl/msbuild/stl_atomic_wait/xmd/msvcp_atomic_wait_kernel32/msvcp_atomic_wait.nativeproj index 1226365ae6b..96aff15ad9a 100644 --- a/stl/msbuild/stl_atomic_wait/xmd/msvcp_atomic_wait_kernel32/msvcp_atomic_wait.nativeproj +++ b/stl/msbuild/stl_atomic_wait/xmd/msvcp_atomic_wait_kernel32/msvcp_atomic_wait.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - kernel32 - true - - - - + + + + {D771D7D3-3021-4CBE-A966-68CD817D0C04} + false + + + + xmd + kernel32 + true + + diff --git a/stl/msbuild/stl_atomic_wait/xmd/msvcp_atomic_wait_netfx/msvcp_atomic_wait.nativeproj b/stl/msbuild/stl_atomic_wait/xmd/msvcp_atomic_wait_netfx/msvcp_atomic_wait.nativeproj index aa9cdc5716a..9d566dadb5f 100644 --- a/stl/msbuild/stl_atomic_wait/xmd/msvcp_atomic_wait_netfx/msvcp_atomic_wait.nativeproj +++ b/stl/msbuild/stl_atomic_wait/xmd/msvcp_atomic_wait_netfx/msvcp_atomic_wait.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - netfx - true - - - - + + + + {31EE7F7B-CF43-489D-8419-EDB8F2C152EE} + false + + + + xmd + netfx + true + + diff --git a/stl/msbuild/stl_atomic_wait/xmd/msvcp_atomic_wait_onecore/msvcp_atomic_wait.nativeproj b/stl/msbuild/stl_atomic_wait/xmd/msvcp_atomic_wait_onecore/msvcp_atomic_wait.nativeproj index 6b512a2847c..1f9168ca537 100644 --- a/stl/msbuild/stl_atomic_wait/xmd/msvcp_atomic_wait_onecore/msvcp_atomic_wait.nativeproj +++ b/stl/msbuild/stl_atomic_wait/xmd/msvcp_atomic_wait_onecore/msvcp_atomic_wait.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - onecore - true - - - - + + + + {57A6A807-C9DC-4ADF-8128-3589FCDAA2E4} + false + + + + xmd + onecore + true + + diff --git a/stl/msbuild/stl_base/libcp.settings.targets b/stl/msbuild/stl_base/libcp.settings.targets index fcd73927832..0e03b8a714e 100644 --- a/stl/msbuild/stl_base/libcp.settings.targets +++ b/stl/msbuild/stl_base/libcp.settings.targets @@ -4,10 +4,12 @@ Copyright (c) Microsoft Corporation. SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception --> + + StaticLibrary + p - LIBRARY true true true @@ -25,7 +27,7 @@ SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception $(OutputLibPdbPath)$(OutputName)$(PdbVerName).pdb - $(ClDefines);_VCRT_ALLOW_INTERNALS;_ANNOTATE_VECTOR;_ANNOTATE_STRING + $(ClDefines);_VCRT_ALLOW_INTERNALS;_ANNOTATE_STL diff --git a/stl/msbuild/stl_base/md/msvcp_app/msvcp.nativeproj b/stl/msbuild/stl_base/md/msvcp_app/msvcp.nativeproj index acddd63ea73..38fa814f722 100644 --- a/stl/msbuild/stl_base/md/msvcp_app/msvcp.nativeproj +++ b/stl/msbuild/stl_base/md/msvcp_app/msvcp.nativeproj @@ -1,16 +1,18 @@ - - - - - md - app - true - - - - + + + + {26CFD97A-BD12-4347-ACEA-3B13904E59DA} + false + + + + md + app + true + + diff --git a/stl/msbuild/stl_base/md/msvcp_kernel32/msvcp.nativeproj b/stl/msbuild/stl_base/md/msvcp_kernel32/msvcp.nativeproj index 1a605f5a8c5..760912837d7 100644 --- a/stl/msbuild/stl_base/md/msvcp_kernel32/msvcp.nativeproj +++ b/stl/msbuild/stl_base/md/msvcp_kernel32/msvcp.nativeproj @@ -1,16 +1,18 @@ - - - - - md - kernel32 - true - - - - + + + + {00EE32E2-A705-4D07-A967-60092E13F497} + false + + + + md + kernel32 + true + + diff --git a/stl/msbuild/stl_base/md/msvcp_netfx/msvcp.nativeproj b/stl/msbuild/stl_base/md/msvcp_netfx/msvcp.nativeproj index 7a455dc627b..7d3ec0cc88a 100644 --- a/stl/msbuild/stl_base/md/msvcp_netfx/msvcp.nativeproj +++ b/stl/msbuild/stl_base/md/msvcp_netfx/msvcp.nativeproj @@ -1,16 +1,18 @@ - - - - - md - netfx - true - - - - + + + + {98CE2EB2-F428-4C28-9186-8D614658A1BE} + false + + + + md + netfx + true + + diff --git a/stl/msbuild/stl_base/md/msvcp_onecore/msvcp.nativeproj b/stl/msbuild/stl_base/md/msvcp_onecore/msvcp.nativeproj index 991f19e2f12..084241b2d2e 100644 --- a/stl/msbuild/stl_base/md/msvcp_onecore/msvcp.nativeproj +++ b/stl/msbuild/stl_base/md/msvcp_onecore/msvcp.nativeproj @@ -1,16 +1,18 @@ - - - - - md - onecore - true - - - - + + + + {3318F9FE-FD4A-4D16-82F6-7DBC8007D1B6} + false + + + + md + onecore + true + + diff --git a/stl/msbuild/stl_base/msvcp.settings.targets b/stl/msbuild/stl_base/msvcp.settings.targets index 2d48b09ad3e..dd0140ac104 100644 --- a/stl/msbuild/stl_base/msvcp.settings.targets +++ b/stl/msbuild/stl_base/msvcp.settings.targets @@ -4,6 +4,9 @@ Copyright (c) Microsoft Corporation. SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception --> + + DynamicLibrary + p @@ -14,8 +17,6 @@ SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception true true true - - DYNLINK diff --git a/stl/msbuild/stl_base/mt/libcpmt_kernel32/libcpmt.nativeproj b/stl/msbuild/stl_base/mt/libcpmt_kernel32/libcpmt.nativeproj index e5fda7b500b..6a95c5dead9 100644 --- a/stl/msbuild/stl_base/mt/libcpmt_kernel32/libcpmt.nativeproj +++ b/stl/msbuild/stl_base/mt/libcpmt_kernel32/libcpmt.nativeproj @@ -1,16 +1,18 @@ - - - - - mt - kernel32 - true - - - - + + + + {B56C39F9-89BF-486F-9C5E-B88FD82E2AA7} + false + + + + mt + kernel32 + true + + diff --git a/stl/msbuild/stl_base/mt/libcpmt_onecore/libcpmt.nativeproj b/stl/msbuild/stl_base/mt/libcpmt_onecore/libcpmt.nativeproj index f6f1144b9af..3c418307ea6 100644 --- a/stl/msbuild/stl_base/mt/libcpmt_onecore/libcpmt.nativeproj +++ b/stl/msbuild/stl_base/mt/libcpmt_onecore/libcpmt.nativeproj @@ -1,16 +1,18 @@ - - - - - mt - onecore - true - - - - + + + + {5F515BBF-E680-4553-B38E-0C125D2A6455} + false + + + + mt + onecore + true + + diff --git a/stl/msbuild/stl_base/mt1/libcpmt_kernel32/libcpmt.nativeproj b/stl/msbuild/stl_base/mt1/libcpmt_kernel32/libcpmt.nativeproj index 1ef7535fc2b..5176f8fef9d 100644 --- a/stl/msbuild/stl_base/mt1/libcpmt_kernel32/libcpmt.nativeproj +++ b/stl/msbuild/stl_base/mt1/libcpmt_kernel32/libcpmt.nativeproj @@ -1,16 +1,18 @@ - - - - - mt1 - kernel32 - true - - - - + + + + {027B5024-5996-4645-BC46-8FEF2E2A4E71} + false + + + + mt1 + kernel32 + true + + diff --git a/stl/msbuild/stl_base/mt1/libcpmt_onecore/libcpmt.nativeproj b/stl/msbuild/stl_base/mt1/libcpmt_onecore/libcpmt.nativeproj index 889fbe794cb..bd6ba4d81be 100644 --- a/stl/msbuild/stl_base/mt1/libcpmt_onecore/libcpmt.nativeproj +++ b/stl/msbuild/stl_base/mt1/libcpmt_onecore/libcpmt.nativeproj @@ -1,16 +1,18 @@ - - - - - mt1 - onecore - true - - - - + + + + {0824A200-D996-41C0-87D8-62CF1D7483C6} + false + + + + mt1 + onecore + true + + diff --git a/stl/msbuild/stl_base/xmd/msvcp_app/msvcp.nativeproj b/stl/msbuild/stl_base/xmd/msvcp_app/msvcp.nativeproj index e3b55c5e3dc..d34cc038e06 100644 --- a/stl/msbuild/stl_base/xmd/msvcp_app/msvcp.nativeproj +++ b/stl/msbuild/stl_base/xmd/msvcp_app/msvcp.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - app - true - - - - + + + + {3DFFE995-1592-4D71-A088-65B5E90829E3} + false + + + + xmd + app + true + + diff --git a/stl/msbuild/stl_base/xmd/msvcp_kernel32/msvcp.nativeproj b/stl/msbuild/stl_base/xmd/msvcp_kernel32/msvcp.nativeproj index 6a31bf3a079..241b0db2c9a 100644 --- a/stl/msbuild/stl_base/xmd/msvcp_kernel32/msvcp.nativeproj +++ b/stl/msbuild/stl_base/xmd/msvcp_kernel32/msvcp.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - kernel32 - true - - - - + + + + {19B72B03-37A8-4ED7-85D9-26031335269E} + false + + + + xmd + kernel32 + true + + diff --git a/stl/msbuild/stl_base/xmd/msvcp_netfx/msvcp.nativeproj b/stl/msbuild/stl_base/xmd/msvcp_netfx/msvcp.nativeproj index 7aaf345b3ea..5dd0b9923b7 100644 --- a/stl/msbuild/stl_base/xmd/msvcp_netfx/msvcp.nativeproj +++ b/stl/msbuild/stl_base/xmd/msvcp_netfx/msvcp.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - netfx - true - - - - + + + + {9E0C069E-C345-4977-9753-16CEE50029D8} + false + + + + xmd + netfx + true + + diff --git a/stl/msbuild/stl_base/xmd/msvcp_onecore/msvcp.nativeproj b/stl/msbuild/stl_base/xmd/msvcp_onecore/msvcp.nativeproj index d166a3f4b9d..a4e38d88190 100644 --- a/stl/msbuild/stl_base/xmd/msvcp_onecore/msvcp.nativeproj +++ b/stl/msbuild/stl_base/xmd/msvcp_onecore/msvcp.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - onecore - true - - - - + + + + {617D60ED-BAB2-45FA-8FAF-B0E7F9304403} + false + + + + xmd + onecore + true + + diff --git a/stl/msbuild/stl_base/xmt/libcpmt_kernel32/libcpmt.nativeproj b/stl/msbuild/stl_base/xmt/libcpmt_kernel32/libcpmt.nativeproj index f7b8117cbeb..35587a51410 100644 --- a/stl/msbuild/stl_base/xmt/libcpmt_kernel32/libcpmt.nativeproj +++ b/stl/msbuild/stl_base/xmt/libcpmt_kernel32/libcpmt.nativeproj @@ -1,16 +1,18 @@ - - - - - xmt - kernel32 - true - - - - + + + + {ECA62467-8F67-4F70-953D-0916472878AA} + false + + + + xmt + kernel32 + true + + diff --git a/stl/msbuild/stl_base/xmt/libcpmt_onecore/libcpmt.nativeproj b/stl/msbuild/stl_base/xmt/libcpmt_onecore/libcpmt.nativeproj index 86c82dff9c2..b0d0e7da211 100644 --- a/stl/msbuild/stl_base/xmt/libcpmt_onecore/libcpmt.nativeproj +++ b/stl/msbuild/stl_base/xmt/libcpmt_onecore/libcpmt.nativeproj @@ -1,16 +1,18 @@ - - - - - xmt - onecore - true - - - - + + + + {02DA6861-AC66-4EA6-B558-9D0E0F1073A8} + false + + + + xmt + onecore + true + + diff --git a/stl/msbuild/stl_base/xmt0/libcpmt_kernel32/libcpmt.nativeproj b/stl/msbuild/stl_base/xmt0/libcpmt_kernel32/libcpmt.nativeproj index d76d2b7cab9..ca4a6a907d5 100644 --- a/stl/msbuild/stl_base/xmt0/libcpmt_kernel32/libcpmt.nativeproj +++ b/stl/msbuild/stl_base/xmt0/libcpmt_kernel32/libcpmt.nativeproj @@ -1,16 +1,18 @@ - - - - - xmt0 - kernel32 - true - - - - + + + + {C9715C5F-41D3-472B-AC8D-4E374105FD6B} + false + + + + xmt0 + kernel32 + true + + diff --git a/stl/msbuild/stl_base/xmt0/libcpmt_onecore/libcpmt.nativeproj b/stl/msbuild/stl_base/xmt0/libcpmt_onecore/libcpmt.nativeproj index d1945603266..8d4a6f2ae9b 100644 --- a/stl/msbuild/stl_base/xmt0/libcpmt_onecore/libcpmt.nativeproj +++ b/stl/msbuild/stl_base/xmt0/libcpmt_onecore/libcpmt.nativeproj @@ -1,16 +1,18 @@ - - - - - xmt0 - onecore - true - - - - + + + + {5B4429AE-5436-4C16-A6D6-998D76182CF1} + false + + + + xmt0 + onecore + true + + diff --git a/stl/msbuild/stl_base/xmt1/libcpmt_kernel32/libcpmt.nativeproj b/stl/msbuild/stl_base/xmt1/libcpmt_kernel32/libcpmt.nativeproj index 6266c565a18..c66f2134d67 100644 --- a/stl/msbuild/stl_base/xmt1/libcpmt_kernel32/libcpmt.nativeproj +++ b/stl/msbuild/stl_base/xmt1/libcpmt_kernel32/libcpmt.nativeproj @@ -1,16 +1,18 @@ - - - - - xmt1 - kernel32 - true - - - - + + + + {C5C4581F-36C6-4327-BB54-6C1DFF52A60F} + false + + + + xmt1 + kernel32 + true + + diff --git a/stl/msbuild/stl_base/xmt1/libcpmt_onecore/libcpmt.nativeproj b/stl/msbuild/stl_base/xmt1/libcpmt_onecore/libcpmt.nativeproj index db93f3f15a1..d806c728cde 100644 --- a/stl/msbuild/stl_base/xmt1/libcpmt_onecore/libcpmt.nativeproj +++ b/stl/msbuild/stl_base/xmt1/libcpmt_onecore/libcpmt.nativeproj @@ -1,16 +1,18 @@ - - - - - xmt1 - onecore - true - - - - + + + + {4B156573-7D78-4FDA-B365-320A91AE8916} + false + + + + xmt1 + onecore + true + + diff --git a/stl/msbuild/stl_codecvt_ids/md/msvcp_codecvt_ids_app/msvcp_codecvt_ids.nativeproj b/stl/msbuild/stl_codecvt_ids/md/msvcp_codecvt_ids_app/msvcp_codecvt_ids.nativeproj index 317f7eff453..a38414ef804 100644 --- a/stl/msbuild/stl_codecvt_ids/md/msvcp_codecvt_ids_app/msvcp_codecvt_ids.nativeproj +++ b/stl/msbuild/stl_codecvt_ids/md/msvcp_codecvt_ids_app/msvcp_codecvt_ids.nativeproj @@ -1,16 +1,18 @@ - - - - - md - app - true - - - - + + + + {CD1E3105-704A-4D91-B49A-4D6E96546ED5} + false + + + + md + app + true + + diff --git a/stl/msbuild/stl_codecvt_ids/md/msvcp_codecvt_ids_kernel32/msvcp_codecvt_ids.nativeproj b/stl/msbuild/stl_codecvt_ids/md/msvcp_codecvt_ids_kernel32/msvcp_codecvt_ids.nativeproj index 7abf5d633e4..7445371ae5e 100644 --- a/stl/msbuild/stl_codecvt_ids/md/msvcp_codecvt_ids_kernel32/msvcp_codecvt_ids.nativeproj +++ b/stl/msbuild/stl_codecvt_ids/md/msvcp_codecvt_ids_kernel32/msvcp_codecvt_ids.nativeproj @@ -1,16 +1,18 @@ - - - - - md - kernel32 - true - - - - + + + + {ED7C0741-B3D2-4EAD-AA7E-BDF1B0948ECC} + false + + + + md + kernel32 + true + + diff --git a/stl/msbuild/stl_codecvt_ids/md/msvcp_codecvt_ids_netfx/msvcp_codecvt_ids.nativeproj b/stl/msbuild/stl_codecvt_ids/md/msvcp_codecvt_ids_netfx/msvcp_codecvt_ids.nativeproj index 5354be3a0c6..6250a475250 100644 --- a/stl/msbuild/stl_codecvt_ids/md/msvcp_codecvt_ids_netfx/msvcp_codecvt_ids.nativeproj +++ b/stl/msbuild/stl_codecvt_ids/md/msvcp_codecvt_ids_netfx/msvcp_codecvt_ids.nativeproj @@ -1,16 +1,18 @@ - - - - - md - netfx - true - - - - + + + + {5F6F2FF5-EFED-4CF7-8F44-810DB15F32CD} + false + + + + md + netfx + true + + diff --git a/stl/msbuild/stl_codecvt_ids/md/msvcp_codecvt_ids_onecore/msvcp_codecvt_ids.nativeproj b/stl/msbuild/stl_codecvt_ids/md/msvcp_codecvt_ids_onecore/msvcp_codecvt_ids.nativeproj index 71825718ba0..1d04a54326f 100644 --- a/stl/msbuild/stl_codecvt_ids/md/msvcp_codecvt_ids_onecore/msvcp_codecvt_ids.nativeproj +++ b/stl/msbuild/stl_codecvt_ids/md/msvcp_codecvt_ids_onecore/msvcp_codecvt_ids.nativeproj @@ -1,16 +1,18 @@ - - - - - md - onecore - true - - - - + + + + {32352E48-0D6E-4BCA-935A-76DAFDD4239D} + false + + + + md + onecore + true + + diff --git a/stl/msbuild/stl_codecvt_ids/msvcp_codecvt_ids.settings.targets b/stl/msbuild/stl_codecvt_ids/msvcp_codecvt_ids.settings.targets index 6c1bf19ce64..eaf3de6fd1a 100644 --- a/stl/msbuild/stl_codecvt_ids/msvcp_codecvt_ids.settings.targets +++ b/stl/msbuild/stl_codecvt_ids/msvcp_codecvt_ids.settings.targets @@ -4,6 +4,9 @@ Copyright (c) Microsoft Corporation. SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception --> + + DynamicLibrary + p_codecvt_ids @@ -11,8 +14,6 @@ SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception true true true - - DYNLINK diff --git a/stl/msbuild/stl_codecvt_ids/xmd/msvcp_codecvt_ids_app/msvcp_codecvt_ids.nativeproj b/stl/msbuild/stl_codecvt_ids/xmd/msvcp_codecvt_ids_app/msvcp_codecvt_ids.nativeproj index a07d3c95ef5..cc570ae8270 100644 --- a/stl/msbuild/stl_codecvt_ids/xmd/msvcp_codecvt_ids_app/msvcp_codecvt_ids.nativeproj +++ b/stl/msbuild/stl_codecvt_ids/xmd/msvcp_codecvt_ids_app/msvcp_codecvt_ids.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - app - true - - - - + + + + {53AB0179-49FF-4620-9D42-45BD8ED71EA8} + false + + + + xmd + app + true + + diff --git a/stl/msbuild/stl_codecvt_ids/xmd/msvcp_codecvt_ids_kernel32/msvcp_codecvt_ids.nativeproj b/stl/msbuild/stl_codecvt_ids/xmd/msvcp_codecvt_ids_kernel32/msvcp_codecvt_ids.nativeproj index 58411828c0d..fcad6e03f57 100644 --- a/stl/msbuild/stl_codecvt_ids/xmd/msvcp_codecvt_ids_kernel32/msvcp_codecvt_ids.nativeproj +++ b/stl/msbuild/stl_codecvt_ids/xmd/msvcp_codecvt_ids_kernel32/msvcp_codecvt_ids.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - kernel32 - true - - - - + + + + {9D9D5B21-5342-4726-AA4F-ACDF4D028F28} + false + + + + xmd + kernel32 + true + + diff --git a/stl/msbuild/stl_codecvt_ids/xmd/msvcp_codecvt_ids_netfx/msvcp_codecvt_ids.nativeproj b/stl/msbuild/stl_codecvt_ids/xmd/msvcp_codecvt_ids_netfx/msvcp_codecvt_ids.nativeproj index 055e45710b7..90ee84d6455 100644 --- a/stl/msbuild/stl_codecvt_ids/xmd/msvcp_codecvt_ids_netfx/msvcp_codecvt_ids.nativeproj +++ b/stl/msbuild/stl_codecvt_ids/xmd/msvcp_codecvt_ids_netfx/msvcp_codecvt_ids.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - netfx - true - - - - + + + + {D561DC89-A909-478B-8566-41640F9F5B53} + false + + + + xmd + netfx + true + + diff --git a/stl/msbuild/stl_codecvt_ids/xmd/msvcp_codecvt_ids_onecore/msvcp_codecvt_ids.nativeproj b/stl/msbuild/stl_codecvt_ids/xmd/msvcp_codecvt_ids_onecore/msvcp_codecvt_ids.nativeproj index e603fe84374..6c98dc33517 100644 --- a/stl/msbuild/stl_codecvt_ids/xmd/msvcp_codecvt_ids_onecore/msvcp_codecvt_ids.nativeproj +++ b/stl/msbuild/stl_codecvt_ids/xmd/msvcp_codecvt_ids_onecore/msvcp_codecvt_ids.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - onecore - true - - - - + + + + {10C04DBD-4EB2-4590-BC8D-25DBA780905C} + false + + + + xmd + onecore + true + + diff --git a/stl/msbuild/stl_post/md/msvcp_post_app/msvcp_post.nativeproj b/stl/msbuild/stl_post/md/msvcp_post_app/msvcp_post.nativeproj index e5422b71165..343ac0feb7f 100644 --- a/stl/msbuild/stl_post/md/msvcp_post_app/msvcp_post.nativeproj +++ b/stl/msbuild/stl_post/md/msvcp_post_app/msvcp_post.nativeproj @@ -1,16 +1,18 @@ - - - - - md - app - true - - - - + + + + {0E89DF6E-E7BA-44A1-841E-E6310F470211} + false + + + + md + app + true + + diff --git a/stl/msbuild/stl_post/md/msvcp_post_kernel32/msvcp_post.nativeproj b/stl/msbuild/stl_post/md/msvcp_post_kernel32/msvcp_post.nativeproj index 25cd54fef6f..7c1f17a2029 100644 --- a/stl/msbuild/stl_post/md/msvcp_post_kernel32/msvcp_post.nativeproj +++ b/stl/msbuild/stl_post/md/msvcp_post_kernel32/msvcp_post.nativeproj @@ -1,16 +1,18 @@ - - - - - md - kernel32 - true - - - - + + + + {4BC58285-8BF8-4362-BE62-38CCBB34EA57} + false + + + + md + kernel32 + true + + diff --git a/stl/msbuild/stl_post/md/msvcp_post_netcore/msvcp_post.nativeproj b/stl/msbuild/stl_post/md/msvcp_post_netcore/msvcp_post.nativeproj index 25cd54fef6f..b2c42ef1d6c 100644 --- a/stl/msbuild/stl_post/md/msvcp_post_netcore/msvcp_post.nativeproj +++ b/stl/msbuild/stl_post/md/msvcp_post_netcore/msvcp_post.nativeproj @@ -1,16 +1,18 @@ - - - - - md - kernel32 - true - - - - + + + + {F6BF440E-AA43-48D1-A7BF-53ED43ED2C6F} + false + + + + md + kernel32 + true + + diff --git a/stl/msbuild/stl_post/md/msvcp_post_netfx/msvcp_post.nativeproj b/stl/msbuild/stl_post/md/msvcp_post_netfx/msvcp_post.nativeproj index 1f893b27dac..fbc0fe20069 100644 --- a/stl/msbuild/stl_post/md/msvcp_post_netfx/msvcp_post.nativeproj +++ b/stl/msbuild/stl_post/md/msvcp_post_netfx/msvcp_post.nativeproj @@ -1,16 +1,18 @@ - - - - - md - netfx - true - - - - + + + + {9EAC2409-0DE5-465D-BEB2-08DD9221CDC7} + false + + + + md + netfx + true + + diff --git a/stl/msbuild/stl_post/md/msvcp_post_onecore/msvcp_post.nativeproj b/stl/msbuild/stl_post/md/msvcp_post_onecore/msvcp_post.nativeproj index b9413c6e44c..b75e4cb3a1b 100644 --- a/stl/msbuild/stl_post/md/msvcp_post_onecore/msvcp_post.nativeproj +++ b/stl/msbuild/stl_post/md/msvcp_post_onecore/msvcp_post.nativeproj @@ -1,16 +1,18 @@ - - - - - md - onecore - true - - - - + + + + {8A1D8A23-DBBA-4356-816E-344F7956D497} + false + + + + md + onecore + true + + diff --git a/stl/msbuild/stl_post/msvcp_post.settings.targets b/stl/msbuild/stl_post/msvcp_post.settings.targets index 4c1b2e3b27c..8ed7816451d 100644 --- a/stl/msbuild/stl_post/msvcp_post.settings.targets +++ b/stl/msbuild/stl_post/msvcp_post.settings.targets @@ -4,6 +4,9 @@ Copyright (c) Microsoft Corporation. SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception --> + + StaticLibrary + p_post @@ -11,8 +14,6 @@ SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception true true true - - LIBRARY diff --git a/stl/msbuild/stl_post/xmd/msvcp_post_app/msvcp_post.nativeproj b/stl/msbuild/stl_post/xmd/msvcp_post_app/msvcp_post.nativeproj index c0359f2f7e5..41a6d6a5a54 100644 --- a/stl/msbuild/stl_post/xmd/msvcp_post_app/msvcp_post.nativeproj +++ b/stl/msbuild/stl_post/xmd/msvcp_post_app/msvcp_post.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - app - true - - - - + + + + {687A5106-D6CE-4BC4-8BA1-27D84F895FF5} + false + + + + xmd + app + true + + diff --git a/stl/msbuild/stl_post/xmd/msvcp_post_kernel32/msvcp_post.nativeproj b/stl/msbuild/stl_post/xmd/msvcp_post_kernel32/msvcp_post.nativeproj index 3656ba523f4..16c5436d376 100644 --- a/stl/msbuild/stl_post/xmd/msvcp_post_kernel32/msvcp_post.nativeproj +++ b/stl/msbuild/stl_post/xmd/msvcp_post_kernel32/msvcp_post.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - kernel32 - true - - - - + + + + {13998FA0-CBA7-4303-9212-879E17F69D53} + false + + + + xmd + kernel32 + true + + diff --git a/stl/msbuild/stl_post/xmd/msvcp_post_netcore/msvcp_post.nativeproj b/stl/msbuild/stl_post/xmd/msvcp_post_netcore/msvcp_post.nativeproj index 3656ba523f4..27de5bc5f5e 100644 --- a/stl/msbuild/stl_post/xmd/msvcp_post_netcore/msvcp_post.nativeproj +++ b/stl/msbuild/stl_post/xmd/msvcp_post_netcore/msvcp_post.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - kernel32 - true - - - - + + + + {EC379541-9453-4884-9250-3CDBA73E2C10} + false + + + + xmd + kernel32 + true + + diff --git a/stl/msbuild/stl_post/xmd/msvcp_post_netfx/msvcp_post.nativeproj b/stl/msbuild/stl_post/xmd/msvcp_post_netfx/msvcp_post.nativeproj index c19d65f192c..2c0a3cc65ff 100644 --- a/stl/msbuild/stl_post/xmd/msvcp_post_netfx/msvcp_post.nativeproj +++ b/stl/msbuild/stl_post/xmd/msvcp_post_netfx/msvcp_post.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - netfx - true - - - - + + + + {9FAAE4A7-D6CE-48C8-8B80-6EA96F508545} + false + + + + xmd + netfx + true + + diff --git a/stl/msbuild/stl_post/xmd/msvcp_post_onecore/msvcp_post.nativeproj b/stl/msbuild/stl_post/xmd/msvcp_post_onecore/msvcp_post.nativeproj index 472a8e1f63a..fd55615865a 100644 --- a/stl/msbuild/stl_post/xmd/msvcp_post_onecore/msvcp_post.nativeproj +++ b/stl/msbuild/stl_post/xmd/msvcp_post_onecore/msvcp_post.nativeproj @@ -1,16 +1,18 @@ - - - - - xmd - onecore - true - - - - + + + + {8DA22F7E-CE13-4885-AD01-D97B180E815C} + false + + + + xmd + onecore + true + + diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt index 6a0b6858af1..2cb6e24e969 100644 --- a/tests/CMakeLists.txt +++ b/tests/CMakeLists.txt @@ -23,7 +23,7 @@ add_subdirectory(tr1) # chance to add to the config map and test directory global properties. add_subdirectory(utils/stl-lit) -find_package(Python "3.9" REQUIRED COMPONENTS Interpreter) +find_package(Python "3.12" REQUIRED COMPONENTS Interpreter) if(NOT DEFINED LIT_FLAGS) list(APPEND LIT_FLAGS "-o" "${CMAKE_CURRENT_BINARY_DIR}/test_results.json") @@ -32,6 +32,12 @@ endif() get_property(STL_LIT_TEST_DIRS GLOBAL PROPERTY STL_LIT_TEST_DIRS) list(APPEND STL_LIT_COMMAND "${STL_LIT_OUTPUT}" "${LIT_FLAGS}" + "-D" "notags=ASAN" "${STL_LIT_TEST_DIRS}") +list(APPEND STLASAN_LIT_COMMAND "${STL_LIT_OUTPUT}" + "${LIT_FLAGS}" + "-D" "tags=ASAN" + "${STL_LIT_TEST_DIRS}") add_test(NAME stl COMMAND ${Python_EXECUTABLE} ${STL_LIT_COMMAND} COMMAND_EXPAND_LISTS) +add_test(NAME stlasan COMMAND ${Python_EXECUTABLE} ${STLASAN_LIT_COMMAND} COMMAND_EXPAND_LISTS) diff --git a/tests/libcxx/expected_results.txt b/tests/libcxx/expected_results.txt index 5efce3bf46a..0276f5cd9cc 100644 --- a/tests/libcxx/expected_results.txt +++ b/tests/libcxx/expected_results.txt @@ -322,14 +322,30 @@ std/utilities/tuple/tuple.tuple/tuple.apply/apply_large_arity.pass.cpp SKIPPED std/utilities/tuple/tuple.tuple/tuple.cnstr/recursion_depth.pass.cpp SKIPPED +# *** ASAN FAILURES *** +# ASAN runtime warns about an overlarge allocation and panics when it should throw bad_alloc instead +# (VSO-1854252, VSO-1854240, VSO-1854255, VSO-1854247, VSO-1854256) +std/language.support/support.dynamic/new.delete/new.delete.array/new_align_val_t.pass.cpp:1 FAIL +std/language.support/support.dynamic/new.delete/new.delete.array/new_array.pass.cpp:1 FAIL +std/language.support/support.dynamic/new.delete/new.delete.single/new.pass.cpp:1 FAIL +std/language.support/support.dynamic/new.delete/new.delete.single/new_align_val_t.pass.cpp:1 FAIL +std/strings/basic.string/string.capacity/max_size.pass.cpp:1 FAIL + +# ASAN runtime warns about an overlarge allocation and doesn't call new_handler (VSO-1854235, VSO-1854568, VSO-1854400, VSO-1854248) +std/language.support/support.dynamic/new.delete/new.delete.array/new_align_val_t_nothrow.pass.cpp:1 FAIL +std/language.support/support.dynamic/new.delete/new.delete.array/new_array_nothrow.pass.cpp:1 FAIL +std/language.support/support.dynamic/new.delete/new.delete.single/new_nothrow.pass.cpp:1 FAIL +std/language.support/support.dynamic/new.delete/new.delete.single/new_align_val_t_nothrow.pass.cpp:1 FAIL + +# ASAN runtime intercepts `strtol` and breaks LWG-2009 (VSO-1875597) +std/strings/string.conversions/stol.pass.cpp:1 FAIL + + # *** MISSING STL FEATURES *** # Missing mbrtoc8 and c8rtomb std/depr/depr.c.headers/uchar_h.compile.pass.cpp FAIL std/strings/c.strings/cuchar.compile.pass.cpp FAIL -# P1169R4 static operator() -std/thread/futures/futures.task/futures.task.members/ctad.static.compile.pass.cpp FAIL - # P2255R2 "Type Traits To Detect References Binding To Temporaries" std/language.support/support.limits/support.limits.general/type_traits.version.compile.pass.cpp FAIL @@ -349,6 +365,12 @@ std/utilities/format/format.tuple/set_separator.pass.cpp FAIL # MSVC doesn't properly support [[no_unique_address]] std/algorithms/algorithms.results/no_unique_address.compile.pass.cpp SKIPPED +# P1169R4 static operator() +std/thread/futures/futures.task/futures.task.members/ctad.static.compile.pass.cpp:0 FAIL +std/thread/futures/futures.task/futures.task.members/ctad.static.compile.pass.cpp:1 FAIL +std/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/ctad.static.compile.pass.cpp:0 FAIL +std/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/ctad.static.compile.pass.cpp:1 FAIL + # *** MISSING LWG ISSUE RESOLUTIONS *** # LWG-2192 "Validity and return type of std::abs(0u) is unclear" (resolution is missing in UCRT, DevCom-10331466) @@ -376,6 +398,7 @@ std/atomics/atomics.types.generic/copy_semantics_traits.pass.cpp FAIL # *** C1XX COMPILER BUGS *** # DevCom-409222 "Constructing rvalue reference from non-reference-related lvalue reference" std/utilities/meta/meta.unary/meta.unary.prop/is_constructible.pass.cpp:0 FAIL +std/utilities/meta/meta.unary/meta.unary.prop/is_constructible.pass.cpp:1 FAIL # VSO-1271673 "static analyzer doesn't know about short-circuiting" std/algorithms/alg.sorting/alg.sort/partial.sort/partial_sort.pass.cpp:0 FAIL @@ -383,32 +406,46 @@ std/algorithms/alg.sorting/alg.sort/partial.sort/partial_sort_comp.pass.cpp:0 FA # DevCom-1436243 constexpr new initialized array std/utilities/smartptr/unique.ptr/unique.ptr.class/unique.ptr.modifiers/reset_self.pass.cpp:0 FAIL +std/utilities/smartptr/unique.ptr/unique.ptr.class/unique.ptr.modifiers/reset_self.pass.cpp:1 FAIL std/utilities/smartptr/unique.ptr/unique.ptr.create/make_unique.array.pass.cpp:0 FAIL +std/utilities/smartptr/unique.ptr/unique.ptr.create/make_unique.array.pass.cpp:1 FAIL # DevCom-10138792: C4455 'operator ""s': literal suffix identifiers that do not start with an underscore are reserved std/strings/basic.string.literals/noexcept.compile.pass.cpp:0 FAIL +std/strings/basic.string.literals/noexcept.compile.pass.cpp:1 FAIL # DevCom-1626139 "compile-time NaN comparison" std/iterators/predef.iterators/reverse.iterators/reverse.iter.cmp/three-way.pass.cpp:0 FAIL +std/iterators/predef.iterators/reverse.iterators/reverse.iter.cmp/three-way.pass.cpp:1 FAIL std/library/description/conventions/expos.only.func/synth_three_way.pass.cpp:0 FAIL +std/library/description/conventions/expos.only.func/synth_three_way.pass.cpp:1 FAIL std/utilities/function.objects/comparisons/compare_three_way.pass.cpp:0 FAIL +std/utilities/function.objects/comparisons/compare_three_way.pass.cpp:1 FAIL std/utilities/tuple/tuple.tuple/tuple.rel/three_way.pass.cpp:0 FAIL +std/utilities/tuple/tuple.tuple/tuple.rel/three_way.pass.cpp:1 FAIL std/utilities/utility/pairs/pairs.spec/three_way_comparison.pass.cpp:0 FAIL +std/utilities/utility/pairs/pairs.spec/three_way_comparison.pass.cpp:1 FAIL std/utilities/variant/variant.relops/three_way.pass.cpp:0 FAIL +std/utilities/variant/variant.relops/three_way.pass.cpp:1 FAIL # DevCom-1626727: bogus "failure was caused by a conversion from void* to a pointer-to-object type" for conversion to void std/algorithms/robust_re_difference_type.compile.pass.cpp:0 FAIL +std/algorithms/robust_re_difference_type.compile.pass.cpp:1 FAIL # DevCom-1638496: C1XX doesn't properly reject int <=> unsigned std/language.support/cmp/cmp.concept/three_way_comparable_with.compile.pass.cpp:0 FAIL +std/language.support/cmp/cmp.concept/three_way_comparable_with.compile.pass.cpp:1 FAIL std/language.support/cmp/cmp.result/compare_three_way_result.compile.pass.cpp:0 FAIL +std/language.support/cmp/cmp.result/compare_three_way_result.compile.pass.cpp:1 FAIL std/utilities/tuple/tuple.tuple/tuple.rel/three_way.pass.cpp:0 FAIL +std/utilities/tuple/tuple.tuple/tuple.rel/three_way.pass.cpp:1 FAIL # DevCom-1638563: icky static analysis false positive std/language.support/support.coroutines/end.to.end/go.pass.cpp:0 FAIL # DevCom-10026599: conditional expression has two different types std/concepts/concepts.compare/concept.equalitycomparable/equality_comparable_with.compile.pass.cpp:0 FAIL +std/concepts/concepts.compare/concept.equalitycomparable/equality_comparable_with.compile.pass.cpp:1 FAIL # DevCom-10284753: Overload resolution is sometimes wrong for templated classes whose template argument are cv void std/utilities/function.objects/func.wrap/func.wrap.func/noncopyable_return_type.pass.cpp SKIPPED @@ -416,22 +453,22 @@ std/utilities/function.objects/func.wrap/func.wrap.func/noncopyable_return_type. # *** CLANG COMPILER BUGS *** # LLVM-46207 Clang's tgmath.h interferes with the UCRT's tgmath.h -std/depr/depr.c.headers/tgmath_h.pass.cpp:1 FAIL +std/depr/depr.c.headers/tgmath_h.pass.cpp:2 FAIL # *** CLANG ISSUES, NOT YET ANALYZED *** # Clang doesn't enable sized deallocation by default. Should we add -fsized-deallocation or do something else? -std/language.support/support.dynamic/new.delete/new.delete.array/sized_delete_array_fsizeddeallocation.pass.cpp:1 SKIPPED -std/language.support/support.dynamic/new.delete/new.delete.array/sized_delete_array14.pass.cpp:1 SKIPPED -std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete_fsizeddeallocation.pass.cpp:1 SKIPPED -std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete14.pass.cpp:1 SKIPPED +std/language.support/support.dynamic/new.delete/new.delete.array/sized_delete_array_fsizeddeallocation.pass.cpp:2 SKIPPED +std/language.support/support.dynamic/new.delete/new.delete.array/sized_delete_array14.pass.cpp:2 SKIPPED +std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete_fsizeddeallocation.pass.cpp:2 SKIPPED +std/language.support/support.dynamic/new.delete/new.delete.single/sized_delete14.pass.cpp:2 SKIPPED # Not analyzed. Clang apparently defines platform macros differently from C1XX. -std/language.support/support.limits/limits/numeric.limits.members/traps.pass.cpp:1 FAIL +std/language.support/support.limits/limits/numeric.limits.members/traps.pass.cpp:2 FAIL # Not analyzed. Possibly C++20 equality operator rewrite issues. -std/utilities/expected/expected.expected/equality/equality.other_expected.pass.cpp:1 FAIL -std/utilities/expected/expected.void/equality/equality.other_expected.pass.cpp:1 FAIL +std/utilities/expected/expected.expected/equality/equality.other_expected.pass.cpp:2 FAIL +std/utilities/expected/expected.void/equality/equality.other_expected.pass.cpp:2 FAIL # *** STL BUGS *** @@ -513,7 +550,9 @@ std/thread/thread.threads/thread.thread.class/thread.thread.member/join.pass.cpp # OS-29877133 "LDBL_DECIMAL_DIG missing from " std/depr/depr.c.headers/float_h.pass.cpp:0 FAIL +std/depr/depr.c.headers/float_h.pass.cpp:1 FAIL std/language.support/support.limits/c.limits/cfloat.pass.cpp:0 FAIL +std/language.support/support.limits/c.limits/cfloat.pass.cpp:1 FAIL # *** LIKELY BOGUS TESTS *** @@ -606,8 +645,11 @@ std/containers/container.requirements/container.requirements.general/allocator_m # Tests emit warning C4244: 'argument': conversion from 'T' to 'const std::complex::_Ty', possible loss of data std/numerics/complex.number/cmplx.over/conj.pass.cpp:0 FAIL +std/numerics/complex.number/cmplx.over/conj.pass.cpp:1 FAIL std/numerics/complex.number/cmplx.over/pow.pass.cpp:0 FAIL +std/numerics/complex.number/cmplx.over/pow.pass.cpp:1 FAIL std/numerics/complex.number/cmplx.over/proj.pass.cpp:0 FAIL +std/numerics/complex.number/cmplx.over/proj.pass.cpp:1 FAIL # Assertion failed: c == NaN || c == non_zero_nan # Testing input values outside the range of [complex.value.ops]/9 @@ -683,6 +725,7 @@ std/containers/sequences/vector/vector.cons/assign_copy.pass.cpp FAIL # LIT's ADDITIONAL_COMPILE_FLAGS is problematic std/concepts/concepts.lang/concept.default.init/default_initializable.compile.pass.cpp:0 FAIL +std/concepts/concepts.lang/concept.default.init/default_initializable.compile.pass.cpp:1 FAIL std/utilities/format/format.functions/escaped_output.ascii.pass.cpp SKIPPED std/utilities/meta/meta.unary/dependent_return_type.compile.pass.cpp SKIPPED std/utilities/variant/variant.variant/implicit_ctad.pass.cpp SKIPPED @@ -702,23 +745,28 @@ std/algorithms/alg.modifying.operations/alg.partitions/ranges_partition_copy.pas std/algorithms/alg.modifying.operations/alg.remove/ranges.remove.pass.cpp FAIL std/algorithms/alg.modifying.operations/alg.remove/ranges.remove_if.pass.cpp FAIL std/algorithms/alg.modifying.operations/alg.replace/ranges.replace.pass.cpp:0 FAIL +std/algorithms/alg.modifying.operations/alg.replace/ranges.replace.pass.cpp:1 FAIL std/algorithms/alg.modifying.operations/alg.rotate/ranges.rotate_copy.pass.cpp FAIL std/algorithms/alg.modifying.operations/alg.swap/ranges.swap_ranges.pass.cpp FAIL std/algorithms/alg.modifying.operations/alg.transform/ranges.transform.pass.cpp:0 FAIL +std/algorithms/alg.modifying.operations/alg.transform/ranges.transform.pass.cpp:1 FAIL std/algorithms/alg.modifying.operations/alg.unique/ranges_unique_copy.pass.cpp FAIL # warning C5101: use of preprocessor directive in function-like macro argument list is undefined behavior std/time/time.syn/formatter.year_month.pass.cpp:0 FAIL +std/time/time.syn/formatter.year_month.pass.cpp:1 FAIL std/time/time.syn/formatter.year_month_day_last.pass.cpp:0 FAIL +std/time/time.syn/formatter.year_month_day_last.pass.cpp:1 FAIL std/time/time.syn/formatter.year_month_weekday.pass.cpp:0 FAIL +std/time/time.syn/formatter.year_month_weekday.pass.cpp:1 FAIL # unused-variable warning std/numerics/rand/rand.device/ctor.pass.cpp FAIL std/thread/thread.mutex/thread.lock/thread.lock.scoped/mutex.pass.cpp FAIL -std/thread/thread.mutex/thread.mutex.requirements/thread.shared_mutex.requirements/thread.shared_mutex.class/default.pass.cpp:1 FAIL +std/thread/thread.mutex/thread.mutex.requirements/thread.shared_mutex.requirements/thread.shared_mutex.class/default.pass.cpp:2 FAIL # This test assumes that array is not const-default-constructible. -std/concepts/concepts.lang/concept.default.init/default_initializable.compile.pass.cpp:1 FAIL +std/concepts/concepts.lang/concept.default.init/default_initializable.compile.pass.cpp:2 FAIL # *** LIKELY STL BUGS *** @@ -812,7 +860,9 @@ std/thread/futures/futures.promise/set_rvalue.pass.cpp FAIL # Possible STL bugs in pair and tuple. std/utilities/tuple/tuple.tuple/tuple.cnstr/PR23256_constrain_UTypes_ctor.pass.cpp:0 FAIL +std/utilities/tuple/tuple.tuple/tuple.cnstr/PR23256_constrain_UTypes_ctor.pass.cpp:1 FAIL std/utilities/tuple/tuple.tuple/tuple.cnstr/PR31384.pass.cpp:0 FAIL +std/utilities/tuple/tuple.tuple/tuple.cnstr/PR31384.pass.cpp:1 FAIL # Bugs/questionable choices in codecvt, which we probably will not fix since # (1) they are deprecated, and (2) we don't want to break existing users. @@ -826,13 +876,17 @@ std/utilities/format/format.formatter/format.parse.ctx/next_arg_id.pass.cpp FAIL std/time/time.syn/formatter.month_day_last.pass.cpp FAIL # Likely STL bug in `join_view::_Iterator`: constexpr weirdness -std/ranges/range.adaptors/range.join.view/end.pass.cpp:1 FAIL +std/ranges/range.adaptors/range.join.view/end.pass.cpp:2 FAIL std/ranges/range.adaptors/range.join.view/iterator/decrement.pass.cpp:0 FAIL +std/ranges/range.adaptors/range.join.view/iterator/decrement.pass.cpp:1 FAIL std/ranges/range.adaptors/range.join.view/iterator/increment.pass.cpp:0 FAIL +std/ranges/range.adaptors/range.join.view/iterator/increment.pass.cpp:1 FAIL std/ranges/range.adaptors/range.join.view/iterator/iter.swap.pass.cpp:0 FAIL +std/ranges/range.adaptors/range.join.view/iterator/iter.swap.pass.cpp:1 FAIL std/ranges/range.adaptors/range.join.view/iterator/star.pass.cpp:0 FAIL -std/ranges/range.adaptors/range.join.view/sentinel/ctor.parent.pass.cpp:1 FAIL -std/ranges/range.adaptors/range.join.view/sentinel/eq.pass.cpp:1 FAIL +std/ranges/range.adaptors/range.join.view/iterator/star.pass.cpp:1 FAIL +std/ranges/range.adaptors/range.join.view/sentinel/ctor.parent.pass.cpp:2 FAIL +std/ranges/range.adaptors/range.join.view/sentinel/eq.pass.cpp:2 FAIL # Our monotonic_buffer_resource takes "user" space for metadata, which it probably should not do. std/utilities/utility/mem.res/mem.res.monotonic.buffer/mem.res.monotonic.buffer.mem/allocate_with_initial_size.pass.cpp FAIL @@ -863,6 +917,7 @@ std/containers/unord/unord.map/unord.map.cnstr/deduct_const.pass.cpp FAIL std/containers/unord/unord.multimap/unord.multimap.cnstr/deduct.pass.cpp FAIL std/containers/unord/unord.multimap/unord.multimap.cnstr/deduct_const.pass.cpp FAIL std/utilities/tuple/tuple.tuple/tuple.cnstr/deduct.pass.cpp:0 FAIL +std/utilities/tuple/tuple.tuple/tuple.cnstr/deduct.pass.cpp:1 FAIL # Not analyzed. Frequent timeouts std/containers/sequences/deque/deque.modifiers/insert_iter_iter.pass.cpp SKIPPED @@ -875,6 +930,7 @@ std/input.output/filesystems/class.path/path.member/path.charconv.pass.cpp FAIL # Not analyzed. Possibly C1XX constexpr bug. std/utilities/function.objects/func.invoke/invoke_constexpr.pass.cpp:0 FAIL +std/utilities/function.objects/func.invoke/invoke_constexpr.pass.cpp:1 FAIL # Not analyzed. Failing for "[a[.ch.]z]". std/re/re.alg/re.alg.match/awk.locale.pass.cpp FAIL @@ -902,7 +958,7 @@ std/containers/sequences/vector/vector.cons/deduct.pass.cpp FAIL std/iterators/iterator.primitives/iterator.operations/advance.pass.cpp SKIPPED # Not analyzed. Maybe Clang over-eagerly instantiating noexcept-specifier? -std/utilities/memory/unique.ptr/iterator_concept_conformance.compile.pass.cpp:1 SKIPPED +std/utilities/memory/unique.ptr/iterator_concept_conformance.compile.pass.cpp:2 SKIPPED # Not analyzed. Assertion failed: std::abs((kurtosis - x_kurtosis) / x_kurtosis) < VARIOUS_VALUES std/numerics/rand/rand.dist/rand.dist.bern/rand.dist.bern.bin/eval.PR44847.pass.cpp FAIL @@ -933,12 +989,17 @@ std/language.support/support.limits/limits/numeric.limits.members/tinyness_befor # Not analyzed. the test fails on x64 but passes on x86 std/containers/associative/map/map.access/iterator.pass.cpp:0 SKIPPED +std/containers/associative/map/map.access/iterator.pass.cpp:1 SKIPPED std/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.-/sentinel.pass.cpp:0 SKIPPED +std/iterators/predef.iterators/move.iterators/move.iter.ops/move.iter.op.-/sentinel.pass.cpp:1 SKIPPED std/algorithms/alg.modifying.operations/alg.random.shuffle/ranges_shuffle.pass.cpp:0 SKIPPED +std/algorithms/alg.modifying.operations/alg.random.shuffle/ranges_shuffle.pass.cpp:1 SKIPPED # Not analyzed. the test fails on x86 but passes on x64 std/algorithms/alg.sorting/alg.set.operations/includes/ranges_includes.pass.cpp:0 SKIPPED +std/algorithms/alg.sorting/alg.set.operations/includes/ranges_includes.pass.cpp:1 SKIPPED std/algorithms/alg.modifying.operations/alg.unique/ranges_unique.pass.cpp:0 SKIPPED +std/algorithms/alg.modifying.operations/alg.unique/ranges_unique.pass.cpp:1 SKIPPED # Not analyzed. These tests are marked `XFAIL: msvc`, citing DevCom-1660844. std/localization/locale.categories/category.numeric/locale.nm.put/facet.num.put.members/put_long_double.hex.pass.cpp SKIPPED @@ -953,12 +1014,18 @@ std/algorithms/alg.modifying.operations/alg.rotate/ranges_rotate.pass.cpp FAIL std/algorithms/alg.nonmodifying/alg.all_of/ranges.all_of.pass.cpp FAIL std/algorithms/alg.nonmodifying/alg.any_of/ranges.any_of.pass.cpp FAIL std/algorithms/alg.nonmodifying/alg.equal/ranges.equal.pass.cpp:0 FAIL +std/algorithms/alg.nonmodifying/alg.equal/ranges.equal.pass.cpp:1 FAIL std/algorithms/alg.nonmodifying/alg.find.end/ranges.find_end.pass.cpp:0 FAIL +std/algorithms/alg.nonmodifying/alg.find.end/ranges.find_end.pass.cpp:1 FAIL std/algorithms/alg.nonmodifying/alg.foreach/ranges.for_each.pass.cpp:0 FAIL +std/algorithms/alg.nonmodifying/alg.foreach/ranges.for_each.pass.cpp:1 FAIL std/algorithms/alg.nonmodifying/alg.foreach/ranges.for_each_n.pass.cpp:0 FAIL +std/algorithms/alg.nonmodifying/alg.foreach/ranges.for_each_n.pass.cpp:1 FAIL std/algorithms/alg.nonmodifying/alg.none_of/ranges.none_of.pass.cpp FAIL std/algorithms/alg.nonmodifying/alg.search/ranges.search.pass.cpp:0 FAIL +std/algorithms/alg.nonmodifying/alg.search/ranges.search.pass.cpp:1 FAIL std/algorithms/alg.nonmodifying/alg.search/ranges.search_n.pass.cpp:0 FAIL +std/algorithms/alg.nonmodifying/alg.search/ranges.search_n.pass.cpp:1 FAIL std/algorithms/alg.nonmodifying/mismatch/ranges_mismatch.pass.cpp FAIL std/algorithms/alg.sorting/alg.clamp/ranges.clamp.pass.cpp FAIL std/algorithms/alg.sorting/alg.heap.operations/make.heap/ranges_make_heap.pass.cpp FAIL @@ -970,36 +1037,56 @@ std/algorithms/alg.sorting/alg.merge/ranges_merge.pass.cpp FAIL std/algorithms/alg.sorting/alg.min.max/requires_forward_iterator.fail.cpp FAIL std/algorithms/alg.sorting/alg.nth.element/ranges_nth_element.pass.cpp FAIL std/algorithms/alg.sorting/alg.partitions/ranges.is_partitioned.pass.cpp:0 FAIL +std/algorithms/alg.sorting/alg.partitions/ranges.is_partitioned.pass.cpp:1 FAIL std/algorithms/alg.sorting/alg.set.operations/set.difference/ranges_set_difference.pass.cpp FAIL std/algorithms/alg.sorting/alg.set.operations/set.intersection/ranges_set_intersection.pass.cpp FAIL std/algorithms/alg.sorting/alg.set.operations/set.symmetric.difference/ranges_set_symmetric_difference.pass.cpp FAIL std/algorithms/alg.sorting/alg.set.operations/set.union/ranges_set_union.pass.cpp FAIL std/algorithms/alg.sorting/alg.sort/is.sorted/ranges.is_sorted.pass.cpp:0 FAIL +std/algorithms/alg.sorting/alg.sort/is.sorted/ranges.is_sorted.pass.cpp:1 FAIL std/algorithms/alg.sorting/alg.sort/is.sorted/ranges.is_sorted_until.pass.cpp:0 FAIL -std/algorithms/alg.sorting/alg.sort/partial.sort.copy/ranges_partial_sort_copy.pass.cpp:1 FAIL +std/algorithms/alg.sorting/alg.sort/is.sorted/ranges.is_sorted_until.pass.cpp:1 FAIL +std/algorithms/alg.sorting/alg.sort/partial.sort.copy/ranges_partial_sort_copy.pass.cpp:2 FAIL std/algorithms/algorithms.results/in_found_result.pass.cpp:0 FAIL +std/algorithms/algorithms.results/in_found_result.pass.cpp:1 FAIL std/algorithms/algorithms.results/min_max_result.pass.cpp:0 FAIL +std/algorithms/algorithms.results/min_max_result.pass.cpp:1 FAIL std/algorithms/ranges_robust_against_dangling.pass.cpp FAIL std/algorithms/robust_against_proxy_iterators_lifetime_bugs.pass.cpp FAIL std/containers/sequences/deque/abi.compile.pass.cpp FAIL std/containers/sequences/vector.bool/construct_iter_iter.pass.cpp:0 FAIL +std/containers/sequences/vector.bool/construct_iter_iter.pass.cpp:1 FAIL std/containers/sequences/vector.bool/construct_iter_iter_alloc.pass.cpp:0 FAIL +std/containers/sequences/vector.bool/construct_iter_iter_alloc.pass.cpp:1 FAIL std/containers/sequences/vector.bool/construct_size.pass.cpp:0 FAIL +std/containers/sequences/vector.bool/construct_size.pass.cpp:1 FAIL std/containers/sequences/vector.bool/construct_size_value.pass.cpp:0 FAIL +std/containers/sequences/vector.bool/construct_size_value.pass.cpp:1 FAIL std/containers/sequences/vector.bool/construct_size_value_alloc.pass.cpp:0 FAIL +std/containers/sequences/vector.bool/construct_size_value_alloc.pass.cpp:1 FAIL std/containers/sequences/vector.bool/emplace_back.pass.cpp FAIL std/containers/sequences/vector.bool/enabled_hash.pass.cpp FAIL std/containers/sequences/vector.bool/move.pass.cpp:0 FAIL +std/containers/sequences/vector.bool/move.pass.cpp:1 FAIL std/containers/sequences/vector.bool/vector_bool.pass.cpp FAIL std/containers/sequences/vector/iterators.pass.cpp:0 FAIL +std/containers/sequences/vector/iterators.pass.cpp:1 FAIL std/containers/sequences/vector/reverse_iterators.pass.cpp:0 FAIL +std/containers/sequences/vector/reverse_iterators.pass.cpp:1 FAIL std/containers/sequences/vector/vector.cons/construct_iter_iter.pass.cpp:0 FAIL +std/containers/sequences/vector/vector.cons/construct_iter_iter.pass.cpp:1 FAIL std/containers/sequences/vector/vector.cons/construct_iter_iter_alloc.pass.cpp:0 FAIL +std/containers/sequences/vector/vector.cons/construct_iter_iter_alloc.pass.cpp:1 FAIL std/containers/sequences/vector/vector.cons/construct_size.pass.cpp:0 FAIL +std/containers/sequences/vector/vector.cons/construct_size.pass.cpp:1 FAIL std/containers/sequences/vector/vector.cons/construct_size_value.pass.cpp:0 FAIL +std/containers/sequences/vector/vector.cons/construct_size_value.pass.cpp:1 FAIL std/containers/sequences/vector/vector.cons/construct_size_value_alloc.pass.cpp:0 FAIL +std/containers/sequences/vector/vector.cons/construct_size_value_alloc.pass.cpp:1 FAIL std/containers/sequences/vector/vector.erasure/erase.pass.cpp:0 FAIL +std/containers/sequences/vector/vector.erasure/erase.pass.cpp:1 FAIL std/containers/sequences/vector/vector.erasure/erase_if.pass.cpp:0 FAIL +std/containers/sequences/vector/vector.erasure/erase_if.pass.cpp:1 FAIL std/input.output/filesystems/fs.op.funcs/fs.op.remove_all/toctou.pass.cpp FAIL std/input.output/iostream.format/quoted.manip/quoted_traits.compile.pass.cpp FAIL std/iterators/iterator.requirements/iterator.concepts/iterator.concept.random.access/contiguous_iterator.compile.pass.cpp FAIL @@ -1026,6 +1113,7 @@ std/ranges/range.adaptors/range.filter/sentinel/base.pass.cpp FAIL std/ranges/range.adaptors/range.filter/sentinel/compare.pass.cpp FAIL std/ranges/range.adaptors/range.filter/sentinel/ctor.parent.pass.cpp FAIL std/ranges/range.adaptors/range.join.view/adaptor.pass.cpp:0 FAIL +std/ranges/range.adaptors/range.join.view/adaptor.pass.cpp:1 FAIL std/ranges/range.adaptors/range.lazy.split/adaptor.pass.cpp FAIL std/ranges/range.adaptors/range.lazy.split/base.pass.cpp FAIL std/ranges/range.adaptors/range.lazy.split/begin.pass.cpp FAIL @@ -1065,27 +1153,39 @@ std/ranges/range.factories/range.single.view/cpo.pass.cpp FAIL std/thread/futures/futures.task/futures.task.members/ctor2.compile.pass.cpp FAIL std/utilities/format/format.functions/escaped_output.ascii.pass.cpp FAIL std/utilities/format/format.functions/locale-specific_form.pass.cpp FAIL -std/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.con/ctad.static.compile.pass.cpp FAIL std/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.inv/invoke.pass.cpp:0 FAIL +std/utilities/function.objects/func.wrap/func.wrap.func/func.wrap.func.inv/invoke.pass.cpp:1 FAIL std/utilities/function.objects/refwrap/refwrap.const/type_conv_ctor.pass.cpp:0 FAIL -std/utilities/memory/util.smartptr/util.smartptr.shared/util.smartptr.shared.create/allocate_shared.array.unbounded.pass.cpp FAIL +std/utilities/function.objects/refwrap/refwrap.const/type_conv_ctor.pass.cpp:1 FAIL std/utilities/meta/meta.logical/conjunction.compile.pass.cpp FAIL std/utilities/meta/meta.logical/disjunction.compile.pass.cpp FAIL std/utilities/meta/meta.unary/meta.unary.prop/is_nothrow_copy_assignable.pass.cpp:0 FAIL +std/utilities/meta/meta.unary/meta.unary.prop/is_nothrow_copy_assignable.pass.cpp:1 FAIL std/utilities/meta/meta.unary/meta.unary.prop/is_nothrow_move_assignable.pass.cpp:0 FAIL +std/utilities/meta/meta.unary/meta.unary.prop/is_nothrow_move_assignable.pass.cpp:1 FAIL std/utilities/tuple/tuple.tuple/tuple.cnstr/convert_const_move.pass.cpp FAIL # Not analyzed, probably MSVC constexpr issue(s) std/strings/basic.string/string.modifiers/string_erase/iter.pass.cpp:0 FAIL +std/strings/basic.string/string.modifiers/string_erase/iter.pass.cpp:1 FAIL std/strings/basic.string/string.modifiers/string_erase/iter_iter.pass.cpp:0 FAIL +std/strings/basic.string/string.modifiers/string_erase/iter_iter.pass.cpp:1 FAIL std/strings/basic.string/string.modifiers/string_insert/iter_iter_iter.pass.cpp:0 FAIL +std/strings/basic.string/string.modifiers/string_insert/iter_iter_iter.pass.cpp:1 FAIL std/strings/basic.string/string.modifiers/string_insert/iter_size_char.pass.cpp:0 FAIL +std/strings/basic.string/string.modifiers/string_insert/iter_size_char.pass.cpp:1 FAIL std/strings/basic.string/string.modifiers/string_replace/iter_iter_iter_iter.pass.cpp:0 FAIL +std/strings/basic.string/string.modifiers/string_replace/iter_iter_iter_iter.pass.cpp:1 FAIL std/strings/basic.string/string.modifiers/string_replace/iter_iter_pointer.pass.cpp:0 FAIL +std/strings/basic.string/string.modifiers/string_replace/iter_iter_pointer.pass.cpp:1 FAIL std/strings/basic.string/string.modifiers/string_replace/iter_iter_pointer_size.pass.cpp:0 FAIL +std/strings/basic.string/string.modifiers/string_replace/iter_iter_pointer_size.pass.cpp:1 FAIL std/strings/basic.string/string.modifiers/string_replace/iter_iter_size_char.pass.cpp:0 FAIL +std/strings/basic.string/string.modifiers/string_replace/iter_iter_size_char.pass.cpp:1 FAIL std/strings/basic.string/string.modifiers/string_replace/iter_iter_string.pass.cpp:0 FAIL +std/strings/basic.string/string.modifiers/string_replace/iter_iter_string.pass.cpp:1 FAIL std/strings/basic.string/string.modifiers/string_replace/iter_iter_string_view.pass.cpp:0 FAIL +std/strings/basic.string/string.modifiers/string_replace/iter_iter_string_view.pass.cpp:1 FAIL # Not analyzed, possible path length issue. With a repo root of D:\GitHub\STL (13 characters), fails with: # "error RC2136 : missing '=' in EXSTYLE=" followed by "LINK : fatal error LNK1327: failure during running rc.exe" diff --git a/tests/libcxx/usual_matrix.lst b/tests/libcxx/usual_matrix.lst index 5604d27fed6..ea6aeb7e3ab 100644 --- a/tests/libcxx/usual_matrix.lst +++ b/tests/libcxx/usual_matrix.lst @@ -3,7 +3,8 @@ RUNALL_INCLUDE ..\universal_prefix.lst RUNALL_CROSSLIST -PM_CL="/EHsc /MTd /std:c++latest /permissive- /utf-8 /FImsvc_stdlib_force_include.h /wd4643 /D_STL_CALL_ABORT_INSTEAD_OF_INVALID_PARAMETER" +* PM_CL="/EHsc /MTd /std:c++latest /permissive- /utf-8 /FImsvc_stdlib_force_include.h /wd4643 /D_STL_CALL_ABORT_INSTEAD_OF_INVALID_PARAMETER" RUNALL_CROSSLIST -PM_CL="/analyze:autolog- /Zc:preprocessor /wd6262" -PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call" +* PM_CL="/analyze:autolog- /Zc:preprocessor /wd6262" +ASAN PM_CL="-fsanitize=address /Zi" PM_LINK="/debug" +* PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call" diff --git a/tests/std/include/test_header_units_and_modules.hpp b/tests/std/include/test_header_units_and_modules.hpp index 1fc40727b13..f6d35c37694 100644 --- a/tests/std/include/test_header_units_and_modules.hpp +++ b/tests/std/include/test_header_units_and_modules.hpp @@ -688,11 +688,21 @@ constexpr bool impl_test_source_location() { const auto sl = source_location::current(); assert(sl.line() == __LINE__ - 1); assert(sl.column() == 38); -#if defined(__clang__) || defined(__EDG__) // TRANSITION, DevCom-10199227 and LLVM-58951 - assert(sl.function_name() == "impl_test_source_location"sv); -#else // ^^^ workaround / no workaround vvv + +#ifdef __EDG__ // TRANSITION, DevCom-10199227 +#define TEST_DETAILED_FUNCTION_NAME 0 +#elif defined(__clang__) // TRANSITION, Clang 17 has this builtin +#define TEST_DETAILED_FUNCTION_NAME __has_builtin(__builtin_FUNCSIG) +#else // ^^^ Clang / MSVC vvv +#define TEST_DETAILED_FUNCTION_NAME 1 +#endif // ^^^ MSVC ^^^ + +#if TEST_DETAILED_FUNCTION_NAME assert(sl.function_name() == "bool __cdecl impl_test_source_location(void)"sv); -#endif // TRANSITION, DevCom-10199227 and LLVM-58951 +#else // ^^^ detailed / basic vvv + assert(sl.function_name() == "impl_test_source_location"sv); +#endif // ^^^ basic ^^^ + assert(string_view{sl.file_name()}.ends_with("test_header_units_and_modules.hpp"sv)); return true; } diff --git a/tests/std/test.lst b/tests/std/test.lst index b0783f0730a..55e0953ec64 100644 --- a/tests/std/test.lst +++ b/tests/std/test.lst @@ -232,6 +232,7 @@ tests\GH_003735_char_traits_signatures tests\GH_003840_tellg_when_reading_lf_file_in_text_mode tests\GH_003867_output_nan tests\GH_004023_mdspan_fwd_prod_overflow +tests\GH_004040_container_nonmember_functions tests\LWG2381_num_get_floating_point tests\LWG2597_complex_branch_cut tests\LWG3018_shared_ptr_function @@ -241,6 +242,7 @@ tests\LWG3234_math_special_overloads tests\LWG3422_seed_seq_ctors tests\LWG3480_directory_iterator_range tests\LWG3545_pointer_traits_sfinae +tests\LWG3561_discard_block_engine_counter tests\LWG3610_iota_view_size_and_integer_class tests\P0009R18_mdspan_default_accessor tests\P0009R18_mdspan_extents @@ -508,6 +510,7 @@ tests\P1135R6_latch tests\P1135R6_semaphore tests\P1147R1_printing_volatile_pointers tests\P1165R1_consistently_propagating_stateful_allocators +tests\P1169R4_static_call_operator tests\P1206R7_deque_append_range tests\P1206R7_deque_assign_range tests\P1206R7_deque_from_range diff --git a/tests/std/tests/Dev08_527068_scl_no_exceptions/env.lst b/tests/std/tests/Dev08_527068_scl_no_exceptions/env.lst index 6777856e825..ecb02a99c36 100644 --- a/tests/std/tests/Dev08_527068_scl_no_exceptions/env.lst +++ b/tests/std/tests/Dev08_527068_scl_no_exceptions/env.lst @@ -3,5 +3,5 @@ RUNALL_INCLUDE ..\impure_matrix.lst RUNALL_CROSSLIST -PM_CL="/D_HAS_EXCEPTIONS=0" -PM_CL="/D_HAS_EXCEPTIONS=1" +* PM_CL="/D_HAS_EXCEPTIONS=0" +* PM_CL="/D_HAS_EXCEPTIONS=1" diff --git a/tests/std/tests/Dev10_814245_regex_character_class_crash/env.lst b/tests/std/tests/Dev10_814245_regex_character_class_crash/env.lst index 288bc01fbe0..a5100294a4a 100644 --- a/tests/std/tests/Dev10_814245_regex_character_class_crash/env.lst +++ b/tests/std/tests/Dev10_814245_regex_character_class_crash/env.lst @@ -1,4 +1,4 @@ # Copyright (c) Microsoft Corporation. # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception -RUNALL_INCLUDE ..\fast_matrix.lst +RUNALL_INCLUDE ..\fast_no_asan_matrix.lst # TRANSITION, VSO-1886547 diff --git a/tests/std/tests/Dev10_909646_stringstream_vd2/env.lst b/tests/std/tests/Dev10_909646_stringstream_vd2/env.lst index 521f4db0cbb..d88b4f77907 100644 --- a/tests/std/tests/Dev10_909646_stringstream_vd2/env.lst +++ b/tests/std/tests/Dev10_909646_stringstream_vd2/env.lst @@ -3,4 +3,4 @@ RUNALL_INCLUDE ..\usual_matrix.lst RUNALL_CROSSLIST -PM_CL="/vd2" +* PM_CL="/vd2" diff --git a/tests/std/tests/Dev11_0493504_error_category_lifetime/env.lst b/tests/std/tests/Dev11_0493504_error_category_lifetime/env.lst index b31baf1dbb3..fc44e4dcd11 100644 --- a/tests/std/tests/Dev11_0493504_error_category_lifetime/env.lst +++ b/tests/std/tests/Dev11_0493504_error_category_lifetime/env.lst @@ -3,5 +3,5 @@ RUNALL_INCLUDE ..\usual_matrix.lst RUNALL_CROSSLIST -PM_CL="/D_STL_OPTIMIZE_SYSTEM_ERROR_OPERATORS=0" -PM_CL="/D_STL_OPTIMIZE_SYSTEM_ERROR_OPERATORS=1" +* PM_CL="/D_STL_OPTIMIZE_SYSTEM_ERROR_OPERATORS=0" +* PM_CL="/D_STL_OPTIMIZE_SYSTEM_ERROR_OPERATORS=1" diff --git a/tests/std/tests/Dev11_0535636_functional_overhaul/test.cpp b/tests/std/tests/Dev11_0535636_functional_overhaul/test.cpp index c81667641e3..f89a8b3a2bc 100644 --- a/tests/std/tests/Dev11_0535636_functional_overhaul/test.cpp +++ b/tests/std/tests/Dev11_0535636_functional_overhaul/test.cpp @@ -2356,6 +2356,62 @@ _CONSTEXPR20 bool test_not_fn() { return true; } +// Also test the invocability of the return type of std::not_fn before and after the changes in P0356R5. +#if _HAS_CXX17 +struct ConstOnlyFunctor { + bool operator()() = delete; + bool operator()() const { + return true; + } +}; + +struct ConstOnlyBooleanTester { + void operator()() {} + bool operator()() const { + return true; + } +}; + +struct GetPinnedNegatable { + struct PinnedNegatable { + PinnedNegatable() = default; + + PinnedNegatable(const PinnedNegatable&) = delete; + PinnedNegatable& operator=(const PinnedNegatable&) = delete; + + friend bool operator!(PinnedNegatable) { + return false; + } + }; + + PinnedNegatable operator()() const { + return {}; + } +}; + +using NegatedConstOnlyFunctor = decltype(not_fn(ConstOnlyFunctor{})); +using NegatedConstOnlyBooleanTester = decltype(not_fn(ConstOnlyBooleanTester{})); +using NegatedGetPinnedNegatable = decltype(not_fn(GetPinnedNegatable{})); + +#if _HAS_CXX20 +constexpr bool not_fn_is_perfect_forwarding = true; +#else // ^^^ _HAS_CXX20 / !_HAS_CXX20 vvv +constexpr bool not_fn_is_perfect_forwarding = false; +#endif // ^^^ !_HAS_CXX20 ^^^ + +static_assert(is_invocable_v); +static_assert(is_invocable_v); +static_assert(is_invocable_v); +static_assert(is_invocable_v); + +static_assert(is_invocable_v == !not_fn_is_perfect_forwarding); +static_assert(is_invocable_v == !not_fn_is_perfect_forwarding); +static_assert(is_invocable_v == !not_fn_is_perfect_forwarding); +static_assert(is_invocable_v == !not_fn_is_perfect_forwarding); + +static_assert(is_invocable_v == not_fn_is_perfect_forwarding); +#endif // _HAS_CXX17 + int main() { // Test addressof() with functions. assert(addressof(triple) == &triple); diff --git a/tests/std/tests/Dev11_1127004_future_has_exceptions_0/env.lst b/tests/std/tests/Dev11_1127004_future_has_exceptions_0/env.lst index 6777856e825..ecb02a99c36 100644 --- a/tests/std/tests/Dev11_1127004_future_has_exceptions_0/env.lst +++ b/tests/std/tests/Dev11_1127004_future_has_exceptions_0/env.lst @@ -3,5 +3,5 @@ RUNALL_INCLUDE ..\impure_matrix.lst RUNALL_CROSSLIST -PM_CL="/D_HAS_EXCEPTIONS=0" -PM_CL="/D_HAS_EXCEPTIONS=1" +* PM_CL="/D_HAS_EXCEPTIONS=0" +* PM_CL="/D_HAS_EXCEPTIONS=1" diff --git a/tests/std/tests/Dev11_1158803_regex_thread_safety/env.lst b/tests/std/tests/Dev11_1158803_regex_thread_safety/env.lst index 288bc01fbe0..a5100294a4a 100644 --- a/tests/std/tests/Dev11_1158803_regex_thread_safety/env.lst +++ b/tests/std/tests/Dev11_1158803_regex_thread_safety/env.lst @@ -1,4 +1,4 @@ # Copyright (c) Microsoft Corporation. # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception -RUNALL_INCLUDE ..\fast_matrix.lst +RUNALL_INCLUDE ..\fast_no_asan_matrix.lst # TRANSITION, VSO-1886547 diff --git a/tests/std/tests/GH_000639_nvcc_include_all/env.lst b/tests/std/tests/GH_000639_nvcc_include_all/env.lst index 633ab107731..56940befa07 100644 --- a/tests/std/tests/GH_000639_nvcc_include_all/env.lst +++ b/tests/std/tests/GH_000639_nvcc_include_all/env.lst @@ -1,7 +1,7 @@ # Copyright (c) Microsoft Corporation. # SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception -PM_COMPILER="nvcc" PM_CL="--x cu -Xcompiler -Od,-EHsc,-nologo,-W4,-WX,-openmp" +* PM_COMPILER="nvcc" PM_CL="--x cu -Xcompiler -Od,-EHsc,-nologo,-W4,-WX,-openmp" RUNALL_CROSSLIST -PM_CL="-Xcompiler -MT" -PM_CL="--debug -Xcompiler -MTd" +* PM_CL="-Xcompiler -MT" +* PM_CL="--debug -Xcompiler -MTd" diff --git a/tests/std/tests/GH_000990_any_link_without_exceptions/env.lst b/tests/std/tests/GH_000990_any_link_without_exceptions/env.lst index a0e43315459..10ff82a4f2c 100644 --- a/tests/std/tests/GH_000990_any_link_without_exceptions/env.lst +++ b/tests/std/tests/GH_000990_any_link_without_exceptions/env.lst @@ -3,5 +3,5 @@ RUNALL_INCLUDE ..\usual_17_matrix.lst RUNALL_CROSSLIST -PM_CL="/D_HAS_EXCEPTIONS=0" -PM_CL="/D_HAS_EXCEPTIONS=1" +* PM_CL="/D_HAS_EXCEPTIONS=0" +* PM_CL="/D_HAS_EXCEPTIONS=1" diff --git a/tests/std/tests/GH_002030_asan_annotate_string/env.lst b/tests/std/tests/GH_002030_asan_annotate_string/env.lst index f51270fc94c..c7838e075f5 100644 --- a/tests/std/tests/GH_002030_asan_annotate_string/env.lst +++ b/tests/std/tests/GH_002030_asan_annotate_string/env.lst @@ -6,52 +6,52 @@ # TRANSITION, google/sanitizers#328 - clang-cl does not currently support targeting /MDd or /MTd. RUNALL_INCLUDE ..\prefix.lst RUNALL_CROSSLIST -PM_CL="/Zi /wd4611 /w14640 /Zc:threadSafeInit-" PM_LINK="/debug" +* PM_CL="/Zi /wd4611 /w14640 /Zc:threadSafeInit-" PM_LINK="/debug" RUNALL_CROSSLIST -PM_CL="-fsanitize=address /BE /c /EHsc /MD /std:c++14" -PM_CL="-fsanitize=address /BE /c /EHsc /MDd /std:c++17 /permissive-" -PM_CL="-fsanitize=address /BE /c /EHsc /MT /std:c++20 /permissive-" -PM_CL="-fsanitize=address /BE /c /EHsc /MTd /std:c++latest /permissive-" -PM_CL="-fsanitize=address /EHsc /MD /std:c++14" -PM_CL="-fsanitize=address /EHsc /MD /std:c++17" -PM_CL="-fsanitize=address /EHsc /MD /std:c++20" -PM_CL="-fsanitize=address /EHsc /MD /std:c++latest /permissive- /Zc:char8_t- /Zc:preprocessor" -PM_CL="-fsanitize=address /EHsc /MD /std:c++latest /permissive- /Zc:noexceptTypes-" -PM_CL="-fsanitize=address /EHsc /MDd /std:c++14 /fp:except /Zc:preprocessor" -PM_CL="-fsanitize=address /EHsc /MDd /std:c++17 /permissive-" -PM_CL="-fsanitize=address /EHsc /MDd /std:c++20 /permissive-" -PM_CL="-fsanitize=address /EHsc /MDd /std:c++latest /permissive- /Zc:wchar_t-" -PM_CL="-fsanitize=address /EHsc /MDd /std:c++latest /permissive-" -PM_CL="-fsanitize=address /EHsc /MT /std:c++latest /permissive- /analyze:only /analyze:autolog-" -PM_CL="-fsanitize=address /EHsc /MT /std:c++latest /permissive-" -PM_CL="-fsanitize=address /EHsc /MTd /std:c++latest /permissive" -PM_CL="-fsanitize=address /EHsc /MTd /std:c++latest /permissive- /analyze:only /analyze:autolog-" -PM_CL="-fsanitize=address /EHsc /MTd /std:c++latest /permissive- /fp:strict" -PM_CL="-fsanitize=address /EHsc /MTd /std:c++latest /permissive-" -PM_CL="/D_ANNOTATE_STRING /BE /c /EHsc /MD /std:c++14" -PM_CL="/D_ANNOTATE_STRING /BE /c /EHsc /MDd /std:c++17 /permissive-" -PM_CL="/D_ANNOTATE_STRING /BE /c /EHsc /MT /std:c++20 /permissive-" -PM_CL="/D_ANNOTATE_STRING /BE /c /EHsc /MTd /std:c++latest /permissive-" -PM_CL="/D_ANNOTATE_STRING /EHsc /MD /std:c++14" -PM_CL="/D_ANNOTATE_STRING /EHsc /MD /std:c++14 /Zc:char8_t" -PM_CL="/D_ANNOTATE_STRING /EHsc /MD /std:c++17" -PM_CL="/D_ANNOTATE_STRING /EHsc /MD /std:c++17 /Zc:char8_t" -PM_CL="/D_ANNOTATE_STRING /EHsc /MD /std:c++20" -PM_CL="/D_ANNOTATE_STRING /EHsc /MD /std:c++latest /permissive- /Zc:char8_t- /Zc:preprocessor" -PM_CL="/D_ANNOTATE_STRING /EHsc /MD /std:c++latest /permissive- /Zc:noexceptTypes-" -PM_CL="/D_ANNOTATE_STRING /EHsc /MDd /std:c++14 /fp:except /Zc:preprocessor" -PM_CL="/D_ANNOTATE_STRING /EHsc /MDd /std:c++17 /permissive-" -PM_CL="/D_ANNOTATE_STRING /EHsc /MDd /std:c++20 /permissive-" -PM_CL="/D_ANNOTATE_STRING /EHsc /MDd /std:c++latest /permissive- /Zc:wchar_t-" -PM_CL="/D_ANNOTATE_STRING /EHsc /MDd /std:c++latest /permissive-" -PM_CL="/D_ANNOTATE_STRING /EHsc /MT /std:c++latest /permissive- /analyze:only /analyze:autolog-" -PM_CL="/D_ANNOTATE_STRING /EHsc /MT /std:c++latest /permissive-" -PM_CL="/D_ANNOTATE_STRING /EHsc /MTd /std:c++latest /permissive" -PM_CL="/D_ANNOTATE_STRING /EHsc /MTd /std:c++latest /permissive- /analyze:only /analyze:autolog-" -PM_CL="/D_ANNOTATE_STRING /EHsc /MTd /std:c++latest /permissive- /fp:strict" -PM_CL="/D_ANNOTATE_STRING /EHsc /MTd /std:c++latest /permissive-" +* PM_CL="-fsanitize=address /BE /c /EHsc /MD /std:c++14" +* PM_CL="-fsanitize=address /BE /c /EHsc /MDd /std:c++17 /permissive-" +* PM_CL="-fsanitize=address /BE /c /EHsc /MT /std:c++20 /permissive-" +* PM_CL="-fsanitize=address /BE /c /EHsc /MTd /std:c++latest /permissive-" +* PM_CL="-fsanitize=address /EHsc /MD /std:c++14" +* PM_CL="-fsanitize=address /EHsc /MD /std:c++17" +* PM_CL="-fsanitize=address /EHsc /MD /std:c++20" +* PM_CL="-fsanitize=address /EHsc /MD /std:c++latest /permissive- /Zc:char8_t- /Zc:preprocessor" +* PM_CL="-fsanitize=address /EHsc /MD /std:c++latest /permissive- /Zc:noexceptTypes-" +* PM_CL="-fsanitize=address /EHsc /MDd /std:c++14 /fp:except /Zc:preprocessor" +* PM_CL="-fsanitize=address /EHsc /MDd /std:c++17 /permissive-" +* PM_CL="-fsanitize=address /EHsc /MDd /std:c++20 /permissive-" +* PM_CL="-fsanitize=address /EHsc /MDd /std:c++latest /permissive- /Zc:wchar_t-" +* PM_CL="-fsanitize=address /EHsc /MDd /std:c++latest /permissive-" +* PM_CL="-fsanitize=address /EHsc /MT /std:c++latest /permissive- /analyze:only /analyze:autolog-" +* PM_CL="-fsanitize=address /EHsc /MT /std:c++latest /permissive-" +* PM_CL="-fsanitize=address /EHsc /MTd /std:c++latest /permissive" +* PM_CL="-fsanitize=address /EHsc /MTd /std:c++latest /permissive- /analyze:only /analyze:autolog-" +* PM_CL="-fsanitize=address /EHsc /MTd /std:c++latest /permissive- /fp:strict" +* PM_CL="-fsanitize=address /EHsc /MTd /std:c++latest /permissive-" +* PM_CL="/D_ANNOTATE_STRING /BE /c /EHsc /MD /std:c++14" +* PM_CL="/D_ANNOTATE_STRING /BE /c /EHsc /MDd /std:c++17 /permissive-" +* PM_CL="/D_ANNOTATE_STRING /BE /c /EHsc /MT /std:c++20 /permissive-" +* PM_CL="/D_ANNOTATE_STRING /BE /c /EHsc /MTd /std:c++latest /permissive-" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MD /std:c++14" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MD /std:c++14 /Zc:char8_t" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MD /std:c++17" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MD /std:c++17 /Zc:char8_t" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MD /std:c++20" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MD /std:c++latest /permissive- /Zc:char8_t- /Zc:preprocessor" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MD /std:c++latest /permissive- /Zc:noexceptTypes-" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MDd /std:c++14 /fp:except /Zc:preprocessor" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MDd /std:c++17 /permissive-" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MDd /std:c++20 /permissive-" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MDd /std:c++latest /permissive- /Zc:wchar_t-" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MDd /std:c++latest /permissive-" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MT /std:c++latest /permissive- /analyze:only /analyze:autolog-" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MT /std:c++latest /permissive-" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MTd /std:c++latest /permissive" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MTd /std:c++latest /permissive- /analyze:only /analyze:autolog-" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MTd /std:c++latest /permissive- /fp:strict" +* PM_CL="/D_ANNOTATE_STRING /EHsc /MTd /std:c++latest /permissive-" # TRANSITION, clang-cl does not support /alternatename so we cannot test /D_ANNOTATE_STRING without -fsanitize=address -PM_COMPILER="clang-cl" PM_CL="-fsanitize=address -fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MD /std:c++14" -PM_COMPILER="clang-cl" PM_CL="-fsanitize=address -fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MD /std:c++17" -PM_COMPILER="clang-cl" PM_CL="-fsanitize=address -fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MT /std:c++20 /permissive-" -PM_COMPILER="clang-cl" PM_CL="-fsanitize=address -fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MT /std:c++latest /permissive- /fp:strict" +* PM_COMPILER="clang-cl" PM_CL="-fsanitize=address -fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MD /std:c++14" +* PM_COMPILER="clang-cl" PM_CL="-fsanitize=address -fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MD /std:c++17" +* PM_COMPILER="clang-cl" PM_CL="-fsanitize=address -fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MT /std:c++20 /permissive-" +* PM_COMPILER="clang-cl" PM_CL="-fsanitize=address -fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MT /std:c++latest /permissive- /fp:strict" diff --git a/tests/std/tests/GH_002030_asan_annotate_vector/env.lst b/tests/std/tests/GH_002030_asan_annotate_vector/env.lst index 5e9703a1c29..3af7152aca2 100644 --- a/tests/std/tests/GH_002030_asan_annotate_vector/env.lst +++ b/tests/std/tests/GH_002030_asan_annotate_vector/env.lst @@ -6,50 +6,50 @@ # TRANSITION, google/sanitizers#328 - clang-cl does not currently support targeting /MDd or /MTd. RUNALL_INCLUDE ..\prefix.lst RUNALL_CROSSLIST -PM_CL="/Zi /wd4611 /w14640 /Zc:threadSafeInit-" PM_LINK="/debug" +* PM_CL="/Zi /wd4611 /w14640 /Zc:threadSafeInit-" PM_LINK="/debug" RUNALL_CROSSLIST -PM_CL="-fsanitize=address /BE /c /EHsc /MD /std:c++14" -PM_CL="-fsanitize=address /BE /c /EHsc /MDd /std:c++17 /permissive-" -PM_CL="-fsanitize=address /BE /c /EHsc /MT /std:c++20 /permissive-" -PM_CL="-fsanitize=address /BE /c /EHsc /MTd /std:c++latest /permissive-" -PM_CL="-fsanitize=address /EHsc /MD /std:c++14" -PM_CL="-fsanitize=address /EHsc /MD /std:c++17" -PM_CL="-fsanitize=address /EHsc /MD /std:c++20" -PM_CL="-fsanitize=address /EHsc /MD /std:c++latest /permissive- /Zc:char8_t- /Zc:preprocessor" -PM_CL="-fsanitize=address /EHsc /MD /std:c++latest /permissive- /Zc:noexceptTypes-" -PM_CL="-fsanitize=address /EHsc /MDd /std:c++14 /fp:except /Zc:preprocessor" -PM_CL="-fsanitize=address /EHsc /MDd /std:c++17 /permissive-" -PM_CL="-fsanitize=address /EHsc /MDd /std:c++20 /permissive-" -PM_CL="-fsanitize=address /EHsc /MDd /std:c++latest /permissive- /Zc:wchar_t-" -PM_CL="-fsanitize=address /EHsc /MDd /std:c++latest /permissive-" -PM_CL="-fsanitize=address /EHsc /MT /std:c++latest /permissive- /analyze:only /analyze:autolog-" -PM_CL="-fsanitize=address /EHsc /MT /std:c++latest /permissive-" -PM_CL="-fsanitize=address /EHsc /MTd /std:c++latest /permissive" -PM_CL="-fsanitize=address /EHsc /MTd /std:c++latest /permissive- /analyze:only /analyze:autolog-" -PM_CL="-fsanitize=address /EHsc /MTd /std:c++latest /permissive- /fp:strict" -PM_CL="-fsanitize=address /EHsc /MTd /std:c++latest /permissive-" -PM_CL="/D_ANNOTATE_VECTOR /BE /c /EHsc /MD /std:c++14" -PM_CL="/D_ANNOTATE_VECTOR /BE /c /EHsc /MDd /std:c++17 /permissive-" -PM_CL="/D_ANNOTATE_VECTOR /BE /c /EHsc /MT /std:c++20 /permissive-" -PM_CL="/D_ANNOTATE_VECTOR /BE /c /EHsc /MTd /std:c++latest /permissive-" -PM_CL="/D_ANNOTATE_VECTOR /EHsc /MD /std:c++14" -PM_CL="/D_ANNOTATE_VECTOR /EHsc /MD /std:c++17" -PM_CL="/D_ANNOTATE_VECTOR /EHsc /MD /std:c++20" -PM_CL="/D_ANNOTATE_VECTOR /EHsc /MD /std:c++latest /permissive- /Zc:char8_t- /Zc:preprocessor" -PM_CL="/D_ANNOTATE_VECTOR /EHsc /MD /std:c++latest /permissive- /Zc:noexceptTypes-" -PM_CL="/D_ANNOTATE_VECTOR /EHsc /MDd /std:c++14 /fp:except /Zc:preprocessor" -PM_CL="/D_ANNOTATE_VECTOR /EHsc /MDd /std:c++17 /permissive-" -PM_CL="/D_ANNOTATE_VECTOR /EHsc /MDd /std:c++20 /permissive-" -PM_CL="/D_ANNOTATE_VECTOR /EHsc /MDd /std:c++latest /permissive- /Zc:wchar_t-" -PM_CL="/D_ANNOTATE_VECTOR /EHsc /MDd /std:c++latest /permissive-" -PM_CL="/D_ANNOTATE_VECTOR /EHsc /MT /std:c++latest /permissive- /analyze:only /analyze:autolog-" -PM_CL="/D_ANNOTATE_VECTOR /EHsc /MT /std:c++latest /permissive-" -PM_CL="/D_ANNOTATE_VECTOR /EHsc /MTd /std:c++latest /permissive" -PM_CL="/D_ANNOTATE_VECTOR /EHsc /MTd /std:c++latest /permissive- /analyze:only /analyze:autolog-" -PM_CL="/D_ANNOTATE_VECTOR /EHsc /MTd /std:c++latest /permissive- /fp:strict" -PM_CL="/D_ANNOTATE_VECTOR /EHsc /MTd /std:c++latest /permissive-" +* PM_CL="-fsanitize=address /BE /c /EHsc /MD /std:c++14" +* PM_CL="-fsanitize=address /BE /c /EHsc /MDd /std:c++17 /permissive-" +* PM_CL="-fsanitize=address /BE /c /EHsc /MT /std:c++20 /permissive-" +* PM_CL="-fsanitize=address /BE /c /EHsc /MTd /std:c++latest /permissive-" +* PM_CL="-fsanitize=address /EHsc /MD /std:c++14" +* PM_CL="-fsanitize=address /EHsc /MD /std:c++17" +* PM_CL="-fsanitize=address /EHsc /MD /std:c++20" +* PM_CL="-fsanitize=address /EHsc /MD /std:c++latest /permissive- /Zc:char8_t- /Zc:preprocessor" +* PM_CL="-fsanitize=address /EHsc /MD /std:c++latest /permissive- /Zc:noexceptTypes-" +* PM_CL="-fsanitize=address /EHsc /MDd /std:c++14 /fp:except /Zc:preprocessor" +* PM_CL="-fsanitize=address /EHsc /MDd /std:c++17 /permissive-" +* PM_CL="-fsanitize=address /EHsc /MDd /std:c++20 /permissive-" +* PM_CL="-fsanitize=address /EHsc /MDd /std:c++latest /permissive- /Zc:wchar_t-" +* PM_CL="-fsanitize=address /EHsc /MDd /std:c++latest /permissive-" +* PM_CL="-fsanitize=address /EHsc /MT /std:c++latest /permissive- /analyze:only /analyze:autolog-" +* PM_CL="-fsanitize=address /EHsc /MT /std:c++latest /permissive-" +* PM_CL="-fsanitize=address /EHsc /MTd /std:c++latest /permissive" +* PM_CL="-fsanitize=address /EHsc /MTd /std:c++latest /permissive- /analyze:only /analyze:autolog-" +* PM_CL="-fsanitize=address /EHsc /MTd /std:c++latest /permissive- /fp:strict" +* PM_CL="-fsanitize=address /EHsc /MTd /std:c++latest /permissive-" +* PM_CL="/D_ANNOTATE_VECTOR /BE /c /EHsc /MD /std:c++14" +* PM_CL="/D_ANNOTATE_VECTOR /BE /c /EHsc /MDd /std:c++17 /permissive-" +* PM_CL="/D_ANNOTATE_VECTOR /BE /c /EHsc /MT /std:c++20 /permissive-" +* PM_CL="/D_ANNOTATE_VECTOR /BE /c /EHsc /MTd /std:c++latest /permissive-" +* PM_CL="/D_ANNOTATE_VECTOR /EHsc /MD /std:c++14" +* PM_CL="/D_ANNOTATE_VECTOR /EHsc /MD /std:c++17" +* PM_CL="/D_ANNOTATE_VECTOR /EHsc /MD /std:c++20" +* PM_CL="/D_ANNOTATE_VECTOR /EHsc /MD /std:c++latest /permissive- /Zc:char8_t- /Zc:preprocessor" +* PM_CL="/D_ANNOTATE_VECTOR /EHsc /MD /std:c++latest /permissive- /Zc:noexceptTypes-" +* PM_CL="/D_ANNOTATE_VECTOR /EHsc /MDd /std:c++14 /fp:except /Zc:preprocessor" +* PM_CL="/D_ANNOTATE_VECTOR /EHsc /MDd /std:c++17 /permissive-" +* PM_CL="/D_ANNOTATE_VECTOR /EHsc /MDd /std:c++20 /permissive-" +* PM_CL="/D_ANNOTATE_VECTOR /EHsc /MDd /std:c++latest /permissive- /Zc:wchar_t-" +* PM_CL="/D_ANNOTATE_VECTOR /EHsc /MDd /std:c++latest /permissive-" +* PM_CL="/D_ANNOTATE_VECTOR /EHsc /MT /std:c++latest /permissive- /analyze:only /analyze:autolog-" +* PM_CL="/D_ANNOTATE_VECTOR /EHsc /MT /std:c++latest /permissive-" +* PM_CL="/D_ANNOTATE_VECTOR /EHsc /MTd /std:c++latest /permissive" +* PM_CL="/D_ANNOTATE_VECTOR /EHsc /MTd /std:c++latest /permissive- /analyze:only /analyze:autolog-" +* PM_CL="/D_ANNOTATE_VECTOR /EHsc /MTd /std:c++latest /permissive- /fp:strict" +* PM_CL="/D_ANNOTATE_VECTOR /EHsc /MTd /std:c++latest /permissive-" # TRANSITION, clang-cl does not support /alternatename so we cannot test /D_ANNOTATE_VECTOR without -fsanitize=address -PM_COMPILER="clang-cl" PM_CL="-fsanitize=address -fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MD /std:c++14" -PM_COMPILER="clang-cl" PM_CL="-fsanitize=address -fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MD /std:c++17" -PM_COMPILER="clang-cl" PM_CL="-fsanitize=address -fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MT /std:c++20 /permissive-" -PM_COMPILER="clang-cl" PM_CL="-fsanitize=address -fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MT /std:c++latest /permissive- /fp:strict" +* PM_COMPILER="clang-cl" PM_CL="-fsanitize=address -fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MD /std:c++14" +* PM_COMPILER="clang-cl" PM_CL="-fsanitize=address -fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MD /std:c++17" +* PM_COMPILER="clang-cl" PM_CL="-fsanitize=address -fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MT /std:c++20 /permissive-" +* PM_COMPILER="clang-cl" PM_CL="-fsanitize=address -fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MT /std:c++latest /permissive- /fp:strict" diff --git a/tests/std/tests/GH_002094_cpp_core_guidelines/env.lst b/tests/std/tests/GH_002094_cpp_core_guidelines/env.lst index 56a4f87e0b0..8eeee159a0d 100644 --- a/tests/std/tests/GH_002094_cpp_core_guidelines/env.lst +++ b/tests/std/tests/GH_002094_cpp_core_guidelines/env.lst @@ -3,14 +3,14 @@ RUNALL_INCLUDE ..\prefix.lst RUNALL_CROSSLIST -PM_CL="/EHsc /w14640 /Zc:threadSafeInit-" +* PM_CL="/EHsc /w14640 /Zc:threadSafeInit-" RUNALL_CROSSLIST -PM_CL="/MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++14 /analyze:only /analyze:autolog- /analyze:plugin EspXEngine.dll /analyze:ruleset stl.ruleset" -PM_CL="/MDd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++17 /permissive- /analyze:only /analyze:autolog- /analyze:plugin EspXEngine.dll /analyze:ruleset stl.ruleset" -PM_CL="/MDd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++20 /permissive- /analyze:only /analyze:autolog- /analyze:plugin EspXEngine.dll /analyze:ruleset stl.ruleset" -PM_CL="/MT /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /analyze:only /analyze:autolog- /analyze:plugin EspXEngine.dll /analyze:ruleset stl.ruleset" -PM_CL="/MTd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++latest /permissive- /analyze:only /analyze:autolog- /analyze:plugin EspXEngine.dll /analyze:ruleset stl.ruleset" -PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /MD /std:c++14" -PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /MDd /std:c++17" -PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /MT /std:c++20 /permissive-" -PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /MTd /std:c++latest /permissive-" +* PM_CL="/MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++14 /analyze:only /analyze:autolog- /analyze:plugin EspXEngine.dll /analyze:ruleset stl.ruleset" +* PM_CL="/MDd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++17 /permissive- /analyze:only /analyze:autolog- /analyze:plugin EspXEngine.dll /analyze:ruleset stl.ruleset" +* PM_CL="/MDd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++20 /permissive- /analyze:only /analyze:autolog- /analyze:plugin EspXEngine.dll /analyze:ruleset stl.ruleset" +* PM_CL="/MT /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /analyze:only /analyze:autolog- /analyze:plugin EspXEngine.dll /analyze:ruleset stl.ruleset" +* PM_CL="/MTd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++latest /permissive- /analyze:only /analyze:autolog- /analyze:plugin EspXEngine.dll /analyze:ruleset stl.ruleset" +* PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /MD /std:c++14" +* PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /MDd /std:c++17" +* PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /MT /std:c++20 /permissive-" +* PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /MTd /std:c++latest /permissive-" diff --git a/tests/std/tests/GH_002431_byte_range_find_with_unreachable_sentinel/env.lst b/tests/std/tests/GH_002431_byte_range_find_with_unreachable_sentinel/env.lst index eab6d7b23e7..269bb574bcf 100644 --- a/tests/std/tests/GH_002431_byte_range_find_with_unreachable_sentinel/env.lst +++ b/tests/std/tests/GH_002431_byte_range_find_with_unreachable_sentinel/env.lst @@ -3,5 +3,5 @@ RUNALL_INCLUDE ..\concepts_20_matrix.lst RUNALL_CROSSLIST -PM_CL="" -PM_CL="/D_USE_STD_VECTOR_ALGORITHMS=0" +* PM_CL="" +* PM_CL="/D_USE_STD_VECTOR_ALGORITHMS=0" diff --git a/tests/std/tests/GH_002558_format_presetPadding/env.lst b/tests/std/tests/GH_002558_format_presetPadding/env.lst index f02e9c02448..449518a8f4e 100644 --- a/tests/std/tests/GH_002558_format_presetPadding/env.lst +++ b/tests/std/tests/GH_002558_format_presetPadding/env.lst @@ -4,24 +4,37 @@ # This is concepts_20_matrix.lst + /presetPadding with clang configs disabled (clang-cl doesn't support /presetPadding) RUNALL_INCLUDE ..\prefix.lst RUNALL_CROSSLIST -PM_CL="/w14640 /Zc:threadSafeInit- /presetPadding" +* PM_CL="/w14640 /Zc:threadSafeInit- /presetPadding" RUNALL_CROSSLIST -PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++20 /permissive- /Zc:noexceptTypes-" -PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" -PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /Zc:char8_t- /Zc:preprocessor" -PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /Zc:wchar_t-" -PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" -PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++20 /permissive- /fp:except /Zc:preprocessor" -PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive-" -PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /analyze:only /analyze:autolog-" -PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" -PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /fp:strict" -PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" -PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++latest /permissive" -PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++latest /permissive- /analyze:only /analyze:autolog-" -PM_CL="/clr /MD /std:c++20" -PM_CL="/clr /MDd /std:c++20" -# PM_CL="/std:c++20 /permissive- /BE /c /EHsc /MD" -# PM_CL="/std:c++latest /permissive- /BE /c /EHsc /MTd" -# PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /std:c++20 /permissive- /MD" -# PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /std:c++latest /permissive- /MTd /fp:strict" +* PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++20 /permissive- /Zc:noexceptTypes-" +ASAN PM_CL="/EHsc /MD /std:c++20 /permissive- /Zc:noexceptTypes- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" +ASAN PM_CL="/EHsc /MD /std:c++latest /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /Zc:char8_t- /Zc:preprocessor" +ASAN PM_CL="/EHsc /MD /std:c++latest /permissive- /Zc:char8_t- /Zc:preprocessor -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /Zc:wchar_t-" +ASAN PM_CL="/EHsc /MDd /std:c++latest /permissive- /Zc:wchar_t- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" +ASAN PM_CL="/EHsc /MDd /std:c++latest /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++20 /permissive- /fp:except /Zc:preprocessor" +ASAN PM_CL="/EHsc /MDd /std:c++20 /permissive- /fp:except /Zc:preprocessor -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive-" +ASAN PM_CL="/EHsc /MT /std:c++latest /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /analyze:only /analyze:autolog-" +ASAN PM_CL="/EHsc /MT /std:c++latest /permissive- /analyze:only /analyze:autolog- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" +# No corresponding ASAN config, since the above differs from another config only in IDL +* PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /fp:strict" +ASAN PM_CL="/EHsc /MTd /std:c++latest /permissive- /fp:strict -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" +ASAN PM_CL="/EHsc /MTd /std:c++latest /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++latest /permissive" +ASAN PM_CL="/EHsc /MTd /std:c++latest /permissive -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++latest /permissive- /analyze:only /analyze:autolog-" +ASAN PM_CL="/EHsc /MTd /std:c++latest /permissive- /analyze:only /analyze:autolog- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/clr /MD /std:c++20" +* PM_CL="/clr /MDd /std:c++20" +# * PM_CL="/std:c++20 /permissive- /BE /c /EHsc /MD" +# * PM_CL="/std:c++latest /permissive- /BE /c /EHsc /MTd" +# * PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /std:c++20 /permissive- /MD" +# * PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /std:c++latest /permissive- /MTd /fp:strict" diff --git a/tests/std/tests/GH_002655_alternate_name_broke_linker/env.lst b/tests/std/tests/GH_002655_alternate_name_broke_linker/env.lst index 01590223746..8c96a40cd21 100644 --- a/tests/std/tests/GH_002655_alternate_name_broke_linker/env.lst +++ b/tests/std/tests/GH_002655_alternate_name_broke_linker/env.lst @@ -3,7 +3,7 @@ RUNALL_INCLUDE ..\prefix.lst RUNALL_CROSSLIST -PM_CL="/MD" -PM_CL="/MDd" -PM_CL="/MT" -PM_CL="/MTd" +* PM_CL="/MD" +* PM_CL="/MDd" +* PM_CL="/MT" +* PM_CL="/MTd" diff --git a/tests/std/tests/GH_002711_Zc_alignedNew-/env.lst b/tests/std/tests/GH_002711_Zc_alignedNew-/env.lst index 1efced5bcfb..0d9c89bf17a 100644 --- a/tests/std/tests/GH_002711_Zc_alignedNew-/env.lst +++ b/tests/std/tests/GH_002711_Zc_alignedNew-/env.lst @@ -3,5 +3,5 @@ RUNALL_INCLUDE ..\impure_matrix.lst RUNALL_CROSSLIST -PM_CL="/Zc:alignedNew-" -PM_CL="/J" +* PM_CL="/Zc:alignedNew-" +* PM_CL="/J" diff --git a/tests/std/tests/GH_002769_handle_deque_block_pointers/test.cpp b/tests/std/tests/GH_002769_handle_deque_block_pointers/test.cpp index 28d2d7abf24..34fde2bafc5 100644 --- a/tests/std/tests/GH_002769_handle_deque_block_pointers/test.cpp +++ b/tests/std/tests/GH_002769_handle_deque_block_pointers/test.cpp @@ -3,6 +3,7 @@ #include #include +#include #include #include #include @@ -12,7 +13,7 @@ using namespace std; size_t counter = 0; -template +template class counting_ptr { private: T* p_; @@ -24,13 +25,16 @@ class counting_ptr { template friend struct ptr_counting_allocator; + template + friend struct inconsistent_difference_allocator; + public: #ifdef __cpp_lib_concepts using iterator_concept = contiguous_iterator_tag; #endif // __cpp_lib_concepts using iterator_category = random_access_iterator_tag; using value_type = T; - using difference_type = ptrdiff_t; + using difference_type = Diff; using pointer = T*; using reference = add_lvalue_reference_t; @@ -90,46 +94,46 @@ class counting_ptr { return tmp; } - template , int> = 0> + template , int> = 0> T& operator[](I n) const noexcept { return p_[n]; } - template , int> = 0> + template , int> = 0> counting_ptr& operator+=(I n) noexcept { p_ += n; return *this; } - template , int> = 0> + template , int> = 0> counting_ptr& operator-=(I n) noexcept { p_ -= n; return *this; } - template , int> = 0> + template , int> = 0> friend counting_ptr operator+(const counting_ptr& p, I n) noexcept { auto tmp = p; tmp += n; return tmp; } - template , int> = 0> + template , int> = 0> friend counting_ptr operator+(I n, const counting_ptr& p) noexcept { auto tmp = p; tmp += n; return tmp; } - template , int> = 0> + template , int> = 0> friend counting_ptr operator-(const counting_ptr& p, I n) noexcept { auto tmp = p; tmp -= n; return tmp; } - friend ptrdiff_t operator-(const counting_ptr& lhs, const counting_ptr& rhs) noexcept { - return lhs.p_ - rhs.p_; + friend Diff operator-(const counting_ptr& lhs, const counting_ptr& rhs) noexcept { + return static_cast(lhs.p_ - rhs.p_); } friend bool operator==(const counting_ptr& p, nullptr_t) noexcept { @@ -211,6 +215,22 @@ struct ptr_counting_allocator { #endif // !_HAS_CXX20 }; +// GH-2769 : For allocators where allocator_traits::pointer is an object, destructors aren't always called +void test_gh_2769() { + { + deque> dq{3, 1, 4, 1, 5, 9}; + dq.insert(dq.end(), {2, 6, 5, 3, 5, 8}); + } + assert(counter == 0); + + { + deque> dq(979, 323); + dq.insert(dq.begin(), 84, 62); + dq.erase(dq.begin() + 64, dq.begin() + 338); + } + assert(counter == 0); +} + size_t count_limit = 0; struct live_counter { @@ -261,19 +281,55 @@ void test_gh_3717() { } } -int main() { +template +struct inconsistent_difference_allocator { + using value_type = T; + using size_type = size_t; + using difference_type = conditional_t, int64_t, int32_t>; + using pointer = counting_ptr; + + inconsistent_difference_allocator() = default; + + template + constexpr inconsistent_difference_allocator(inconsistent_difference_allocator) noexcept {} + + pointer allocate(size_type n) { + return pointer{allocator{}.allocate(n)}; + } + + void deallocate(pointer p, size_type n) { + allocator{}.deallocate(p.operator->(), n); + } + + template + friend constexpr bool operator==(inconsistent_difference_allocator, inconsistent_difference_allocator) noexcept { + return true; + } +#if !_HAS_CXX20 + template + friend constexpr bool operator!=(inconsistent_difference_allocator, inconsistent_difference_allocator) noexcept { + return false; + } +#endif // !_HAS_CXX20 +}; + +void test_inconsistent_difference_types() { { - deque> dq{3, 1, 4, 1, 5, 9}; + deque> dq{3, 1, 4, 1, 5, 9}; dq.insert(dq.end(), {2, 6, 5, 3, 5, 8}); } assert(counter == 0); { - deque> dq(979, 323); + deque> dq(979, 323); dq.insert(dq.begin(), 84, 62); dq.erase(dq.begin() + 64, dq.begin() + 338); } assert(counter == 0); +} +int main() { + test_gh_2769(); test_gh_3717(); + test_inconsistent_difference_types(); } diff --git a/tests/std/tests/GH_004040_container_nonmember_functions/env.lst b/tests/std/tests/GH_004040_container_nonmember_functions/env.lst new file mode 100644 index 00000000000..19f025bd0e6 --- /dev/null +++ b/tests/std/tests/GH_004040_container_nonmember_functions/env.lst @@ -0,0 +1,4 @@ +# Copyright (c) Microsoft Corporation. +# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception + +RUNALL_INCLUDE ..\usual_matrix.lst diff --git a/tests/std/tests/GH_004040_container_nonmember_functions/test.cpp b/tests/std/tests/GH_004040_container_nonmember_functions/test.cpp new file mode 100644 index 00000000000..25c53023fa0 --- /dev/null +++ b/tests/std/tests/GH_004040_container_nonmember_functions/test.cpp @@ -0,0 +1,314 @@ +// Copyright (c) Microsoft Corporation. +// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception + +#include +#include +#include +#include +#include +#include +#include +#include + +#define STATIC_ASSERT(...) static_assert(__VA_ARGS__, #__VA_ARGS__) + +#if _HAS_CXX20 +#define CONSTEXPR20 constexpr +#define CONSTEXPR17 constexpr +#define NODISCARD20 [[nodiscard]] +#elif _HAS_CXX17 // ^^^ _HAS_CXX20 / !_HAS_CXX20 && _HAS_CXX17 vvv +#define CONSTEXPR20 inline +#define CONSTEXPR17 constexpr +#define NODISCARD20 +#else // ^^^ !_HAS_CXX20 && _HAS_CXX17 / !_HAS_CXX17 vvv +#define CONSTEXPR20 inline +#define CONSTEXPR17 inline +#define NODISCARD20 +#endif // ^^^ !_HAS_CXX17 ^^^ + +using namespace std; + +struct Meow { +#if _HAS_CXX20 + friend constexpr auto operator<=>(Meow, Meow) = default; +#else // ^^^ _HAS_CXX20 / !_HAS_CXX20 vvv + friend constexpr bool operator==(Meow, Meow) noexcept { + return true; + } + + friend constexpr bool operator!=(Meow, Meow) noexcept { + return false; + } + + friend constexpr bool operator<(Meow, Meow) noexcept { + return false; + } + + friend constexpr bool operator>(Meow, Meow) noexcept { + return false; + } + + friend constexpr bool operator<=(Meow, Meow) noexcept { + return true; + } + + friend constexpr bool operator>=(Meow, Meow) noexcept { + return true; + } +#endif // ^^^ !_HAS_CXX20 ^^^ +}; + +template +struct std::array { + using value_type = Meow; + using pointer = Meow*; + using const_pointer = const Meow*; + using reference = Meow&; + using const_reference = const Meow&; + using size_type = size_t; + using difference_type = ptrdiff_t; + using iterator = Meow*; + using const_iterator = const Meow*; + using reverse_iterator = std::reverse_iterator; + using const_reverse_iterator = std::reverse_iterator; + + CONSTEXPR20 void fill(const Meow&) {} // Meow is no-op assignable. + CONSTEXPR20 void swap(array&) noexcept {} // Meow is no-op swappable. + + CONSTEXPR17 iterator begin() noexcept { + return elems_; + } + CONSTEXPR17 const_iterator begin() const noexcept { + return elems_; + } + CONSTEXPR17 iterator end() noexcept { + return elems_ + N; + } + CONSTEXPR17 const_iterator end() const noexcept { + return elems_ + N; + } + + CONSTEXPR17 reverse_iterator rbegin() noexcept { + return reverse_iterator{elems_ + N}; + } + CONSTEXPR17 const_reverse_iterator rbegin() const noexcept { + return const_reverse_iterator{elems_ + N}; + } + CONSTEXPR17 reverse_iterator rend() noexcept { + return reverse_iterator{elems_}; + } + CONSTEXPR17 const_reverse_iterator rend() const noexcept { + return const_reverse_iterator{elems_}; + } + + CONSTEXPR17 const_iterator cbegin() const noexcept { + return elems_; + } + CONSTEXPR17 const_iterator cend() const noexcept { + return elems_ + N; + } + CONSTEXPR17 const_reverse_iterator crbegin() const noexcept { + return const_reverse_iterator{elems_ + N}; + } + CONSTEXPR17 const_reverse_iterator crend() const noexcept { + return const_reverse_iterator{elems_}; + } + + NODISCARD20 constexpr bool empty() const noexcept { + return false; + } + constexpr size_type size() const noexcept { + return N; + } + constexpr size_type max_size() const noexcept { + return N; + } + + CONSTEXPR17 reference operator[](size_type n) { + return elems_[n]; + } + constexpr const_reference operator[](size_type n) const { + return elems_[n]; + } + CONSTEXPR17 reference at(size_type n) { + return n < N ? elems_[n] : throw out_of_range{"bad array access"}; + } + constexpr const_reference at(size_type n) const { + return n < N ? elems_[n] : throw out_of_range{"bad array access"}; + } + CONSTEXPR17 reference front() { + return elems_[0]; + } + constexpr const_reference front() const { + return elems_[0]; + } + CONSTEXPR17 reference back() { + return elems_[N - 1]; + } + constexpr const_reference back() const { + return elems_[N - 1]; + } + + CONSTEXPR17 pointer data() noexcept { + return elems_; + } + CONSTEXPR17 const_pointer data() const noexcept { + return elems_; + } + + Meow elems_[N]; +}; + +template <> +struct std::array { + using value_type = Meow; + using pointer = Meow*; + using const_pointer = const Meow*; + using reference = Meow&; + using const_reference = const Meow&; + using size_type = size_t; + using difference_type = ptrdiff_t; + using iterator = Meow*; + using const_iterator = const Meow*; + using reverse_iterator = std::reverse_iterator; + using const_reverse_iterator = std::reverse_iterator; + + CONSTEXPR20 void fill(const Meow&) {} // Meow is no-op assignable. + CONSTEXPR20 void swap(array&) noexcept {} // Meow is no-op swappable. + + CONSTEXPR17 iterator begin() noexcept { + return nullptr; + } + CONSTEXPR17 const_iterator begin() const noexcept { + return nullptr; + } + CONSTEXPR17 iterator end() noexcept { + return nullptr; + } + CONSTEXPR17 const_iterator end() const noexcept { + return nullptr; + } + + CONSTEXPR17 reverse_iterator rbegin() noexcept { + return reverse_iterator{end()}; + } + CONSTEXPR17 const_reverse_iterator rbegin() const noexcept { + return const_reverse_iterator{end()}; + } + CONSTEXPR17 reverse_iterator rend() noexcept { + return reverse_iterator{begin()}; + } + CONSTEXPR17 const_reverse_iterator rend() const noexcept { + return const_reverse_iterator{begin()}; + } + + CONSTEXPR17 const_iterator cbegin() const noexcept { + return nullptr; + } + CONSTEXPR17 const_iterator cend() const noexcept { + return nullptr; + } + CONSTEXPR17 const_reverse_iterator crbegin() const noexcept { + return const_reverse_iterator{end()}; + } + CONSTEXPR17 const_reverse_iterator crend() const noexcept { + return const_reverse_iterator{begin()}; + } + + NODISCARD20 constexpr bool empty() const noexcept { + return true; + } + constexpr size_type size() const noexcept { + return 0; + } + constexpr size_type max_size() const noexcept { + return 0; + } + + // Perhaps these functions of array shouldn't be constexpr as an invocation is always throwing or UB. + reference operator[](size_type) { + abort(); // UB + } + const_reference operator[](size_type) const { + abort(); // UB + } + reference at(size_type) { + throw out_of_range{"bad array access"}; + } + const_reference at(size_type) const { + throw out_of_range{"bad array access"}; + } + reference front() { + abort(); // UB + } + const_reference front() const { + abort(); // UB + } + reference back() { + abort(); // UB + } + const_reference back() const { + abort(); // UB + } + + CONSTEXPR17 pointer data() noexcept { + return nullptr; + } + CONSTEXPR17 const_pointer data() const noexcept { + return nullptr; + } + + unsigned char dummy_[1]; +}; + +constexpr bool test_array_get() { + array a{}; + const auto& c = a; + + STATIC_ASSERT(is_same_v(a)), Meow&>); + STATIC_ASSERT(is_same_v(c)), const Meow&>); + STATIC_ASSERT(is_same_v(move(a))), Meow&&>); + STATIC_ASSERT(is_same_v(move(c))), const Meow&&>); + + assert(get<0>(a) == Meow{}); + assert(get<0>(c) == Meow{}); + assert(get<0>(move(a)) == Meow{}); + assert(get<0>(move(c)) == Meow{}); + + return true; +} + +CONSTEXPR20 bool test_array_comparison() { + using A0 = array; + assert(A0{} == A0{}); + assert(!(A0{} != A0{})); + assert(!(A0{} < A0{})); + assert(!(A0{} > A0{})); + assert(A0{} <= A0{}); + assert(A0{} >= A0{}); +#if _HAS_CXX20 && defined(__cpp_lib_concepts) // TRANSITION, GH-395 + assert(A0{} <=> A0{} == strong_ordering::equal); +#endif // _HAS_CXX20 && defined(__cpp_lib_concepts) + + using A1 = array; + assert(A1{} == A1{}); + assert(!(A1{} != A1{})); + assert(!(A1{} < A1{})); + assert(!(A1{} > A1{})); + assert(A1{} <= A1{}); + assert(A1{} >= A1{}); +#if _HAS_CXX20 && defined(__cpp_lib_concepts) // TRANSITION, GH-395 + assert(A1{} <=> A1{} == strong_ordering::equal); +#endif // _HAS_CXX20 && defined(__cpp_lib_concepts) + + return true; +} + +int main() { + test_array_get(); + STATIC_ASSERT(test_array_get()); + test_array_comparison(); +#if _HAS_CXX20 + static_assert(test_array_comparison()); +#endif // _HAS_CXX20 +} diff --git a/tests/std/tests/LWG3561_discard_block_engine_counter/env.lst b/tests/std/tests/LWG3561_discard_block_engine_counter/env.lst new file mode 100644 index 00000000000..19f025bd0e6 --- /dev/null +++ b/tests/std/tests/LWG3561_discard_block_engine_counter/env.lst @@ -0,0 +1,4 @@ +# Copyright (c) Microsoft Corporation. +# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception + +RUNALL_INCLUDE ..\usual_matrix.lst diff --git a/tests/std/tests/LWG3561_discard_block_engine_counter/test.cpp b/tests/std/tests/LWG3561_discard_block_engine_counter/test.cpp new file mode 100644 index 00000000000..9e98e4a971c --- /dev/null +++ b/tests/std/tests/LWG3561_discard_block_engine_counter/test.cpp @@ -0,0 +1,83 @@ +// Copyright (c) Microsoft Corporation. +// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception + +#include +#include +#include +#include +#include +#include +#include +#include + +#define STATIC_ASSERT(...) static_assert(__VA_ARGS__, #__VA_ARGS__) + +using namespace std; + +constexpr size_t large_block_size = UINT_MAX - 16; +constexpr size_t large_used_block = UINT_MAX - 20; + +struct trivial_engine { + using result_type = size_t; + + static constexpr size_t min() { + return 0; + } + static constexpr size_t max() { + return SIZE_MAX; + } + + size_t operator()() noexcept { + return counter_++; + } + +#if _HAS_CXX20 + friend bool operator==(const trivial_engine&, const trivial_engine&) = default; +#else // ^^^ _HAS_CXX20 / !_HAS_CXX20 vvv + friend bool operator==(const trivial_engine& lhs, const trivial_engine& rhs) noexcept { + return lhs.counter_ == rhs.counter_; + } + friend bool operator!=(const trivial_engine& lhs, const trivial_engine& rhs) noexcept { + return lhs.counter_ != rhs.counter_; + } +#endif // ^^^ !_HAS_CXX20 ^^^ + + template + friend basic_istream& operator>>(basic_istream& is, trivial_engine& eng) { + return is >> eng.counter_; + } + + template + friend basic_ostream& operator<<(basic_ostream& os, const trivial_engine& eng) { + return os << eng.counter_; + } + + size_t counter_ = 0; +}; + +using trivial_discard_block = discard_block_engine; + +void test_lwg_3561() { + trivial_discard_block e{}; + e.discard(168); + auto rep = (ostringstream{} << e).str(); + + assert(e == e); + assert(!(e != e)); + assert(rep == "168 168"); // relies on the implementation-specific details of operator<< +} + +// Also tests the type correctness of discard_block_engine::block_size/used_block + +STATIC_ASSERT(is_same_v); +STATIC_ASSERT(is_same_v); + +STATIC_ASSERT(is_same_v); +STATIC_ASSERT(is_same_v); + +STATIC_ASSERT(is_same_v); +STATIC_ASSERT(is_same_v); + +int main() { + test_lwg_3561(); +} diff --git a/tests/std/tests/P0067R5_charconv/env.lst b/tests/std/tests/P0067R5_charconv/env.lst index 7194073a8e2..cebd06596b5 100644 --- a/tests/std/tests/P0067R5_charconv/env.lst +++ b/tests/std/tests/P0067R5_charconv/env.lst @@ -3,4 +3,4 @@ RUNALL_INCLUDE ..\usual_17_matrix.lst RUNALL_CROSSLIST -PM_CL="/O2 /wd4793" +* PM_CL="/O2 /wd4793" diff --git a/tests/std/tests/P0088R3_variant/env.lst b/tests/std/tests/P0088R3_variant/env.lst index b2afc414f0e..7b996d4035d 100644 --- a/tests/std/tests/P0088R3_variant/env.lst +++ b/tests/std/tests/P0088R3_variant/env.lst @@ -7,33 +7,50 @@ RUNALL_INCLUDE ..\prefix.lst RUNALL_CROSSLIST -PM_CL="/w14640 /Zc:threadSafeInit-" +* PM_CL="/w14640 /Zc:threadSafeInit-" RUNALL_CROSSLIST -PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /Zc:noexceptTypes-" -PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++17 /DCONSTEXPR_NOTHROW /DTEST_PERMISSIVE" -PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++20" -PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" -PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /Zc:char8_t- /Zc:preprocessor" -PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /Zc:wchar_t-" -PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" -PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++latest /permissive- /fp:except /Zc:preprocessor" -PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++17 /permissive-" -PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++20 /permissive-" -PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive-" -PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /analyze:only /analyze:autolog-" -PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" -PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /fp:strict" -PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" -PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++latest /permissive /DCONSTEXPR_NOTHROW /DTEST_PERMISSIVE" -PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++latest /permissive- /analyze:only /analyze:autolog-" +* PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /Zc:noexceptTypes-" +ASAN PM_CL="/EHsc /MD /std:c++latest /permissive- /Zc:noexceptTypes- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++17 /DCONSTEXPR_NOTHROW /DTEST_PERMISSIVE" +ASAN PM_CL="/EHsc /MD /std:c++17 /DCONSTEXPR_NOTHROW /DTEST_PERMISSIVE -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++20" +ASAN PM_CL="/EHsc /MD /std:c++20 -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" +ASAN PM_CL="/EHsc /MD /std:c++latest /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /Zc:char8_t- /Zc:preprocessor" +ASAN PM_CL="/EHsc /MD /std:c++latest /permissive- /Zc:char8_t- /Zc:preprocessor -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /Zc:wchar_t-" +ASAN PM_CL="/EHsc /MDd /std:c++latest /permissive- /Zc:wchar_t- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" +ASAN PM_CL="/EHsc /MDd /std:c++latest /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++latest /permissive- /fp:except /Zc:preprocessor" +ASAN PM_CL="/EHsc /MDd /std:c++latest /permissive- /fp:except /Zc:preprocessor -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++17 /permissive-" +ASAN PM_CL="/EHsc /MDd /std:c++17 /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++20 /permissive-" +ASAN PM_CL="/EHsc /MDd /std:c++20 /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive-" +ASAN PM_CL="/EHsc /MT /std:c++latest /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /analyze:only /analyze:autolog-" +ASAN PM_CL="/EHsc /MT /std:c++latest /permissive- /analyze:only /analyze:autolog- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" +# No corresponding ASAN config, since the above differs from another config only in IDL +* PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /fp:strict" +ASAN PM_CL="/EHsc /MTd /std:c++latest /permissive- /fp:strict -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" +ASAN PM_CL="/EHsc /MTd /std:c++latest /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++latest /permissive /DCONSTEXPR_NOTHROW /DTEST_PERMISSIVE" +ASAN PM_CL="/EHsc /MTd /std:c++latest /permissive /DCONSTEXPR_NOTHROW /DTEST_PERMISSIVE -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++latest /permissive- /analyze:only /analyze:autolog-" +ASAN PM_CL="/EHsc /MTd /std:c++latest /permissive- /analyze:only /analyze:autolog- -fsanitize=address /Zi" PM_LINK="/debug" # With /clr /std:c++20, extreme compiler memory consumption causes test timeouts. -PM_CL="/clr /MD /std:c++17 /DCONSTEXPR_NOTHROW /DTEST_PERMISSIVE" -PM_CL="/clr /MDd /std:c++17 /DCONSTEXPR_NOTHROW /DTEST_PERMISSIVE" -PM_CL="/BE /c /EHsc /MD /std:c++latest /permissive-" -PM_CL="/BE /c /EHsc /MDd /std:c++17 /permissive-" -PM_CL="/BE /c /EHsc /MT /std:c++20 /permissive-" -PM_CL="/BE /c /EHsc /MTd /std:c++latest /permissive-" -PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MD /std:c++latest /permissive-" -PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MDd /std:c++17 /DTEST_PERMISSIVE" -PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MT /std:c++20 /permissive-" -PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MTd /std:c++latest /permissive- /fp:strict" +* PM_CL="/clr /MD /std:c++17 /DCONSTEXPR_NOTHROW /DTEST_PERMISSIVE" +* PM_CL="/clr /MDd /std:c++17 /DCONSTEXPR_NOTHROW /DTEST_PERMISSIVE" +* PM_CL="/BE /c /EHsc /MD /std:c++latest /permissive-" +* PM_CL="/BE /c /EHsc /MDd /std:c++17 /permissive-" +* PM_CL="/BE /c /EHsc /MT /std:c++20 /permissive-" +* PM_CL="/BE /c /EHsc /MTd /std:c++latest /permissive-" +* PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MD /std:c++latest /permissive-" +* PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MDd /std:c++17 /DTEST_PERMISSIVE" +* PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MT /std:c++20 /permissive-" +* PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MTd /std:c++latest /permissive- /fp:strict" diff --git a/tests/std/tests/P0288R9_move_only_function/env.lst b/tests/std/tests/P0288R9_move_only_function/env.lst index 6b203c24288..5b8d3c50c12 100644 --- a/tests/std/tests/P0288R9_move_only_function/env.lst +++ b/tests/std/tests/P0288R9_move_only_function/env.lst @@ -3,5 +3,5 @@ RUNALL_INCLUDE ..\usual_latest_matrix.lst RUNALL_CROSSLIST -PM_CL="/Zc:alignedNew-" -PM_CL="" +* PM_CL="/Zc:alignedNew-" +* PM_CL="" diff --git a/tests/std/tests/P0325R4_to_array/test.cpp b/tests/std/tests/P0325R4_to_array/test.cpp index ccdbbdcecb1..adf4c3ae531 100644 --- a/tests/std/tests/P0325R4_to_array/test.cpp +++ b/tests/std/tests/P0325R4_to_array/test.cpp @@ -53,6 +53,21 @@ void assert_not_constexpr() { assert_equal(to_array({"cats"s, "go"s, "meow"s}), array{"cats", "go", "meow"}); } +#ifndef _M_CEE // TRANSITION, VSO-1659496 +struct incomplete; + +template +struct holder { + T t; +}; + +void test_adl_proof() { // COMPILE-ONLY + holder* a[1]{}; + (void) std::to_array(a); // intentionally qualified to avoid ADL + (void) std::to_array(std::move(a)); // intentionally qualified to avoid ADL +} +#endif // _M_CEE + int main() { assert(assert_constexpr()); static_assert(assert_constexpr()); diff --git a/tests/std/tests/P0355R7_calendars_and_time_zones_formatting/env.lst b/tests/std/tests/P0355R7_calendars_and_time_zones_formatting/env.lst index 1f537b16e72..223468e5254 100644 --- a/tests/std/tests/P0355R7_calendars_and_time_zones_formatting/env.lst +++ b/tests/std/tests/P0355R7_calendars_and_time_zones_formatting/env.lst @@ -3,4 +3,4 @@ RUNALL_INCLUDE ..\concepts_20_matrix.lst RUNALL_CROSSLIST -PM_CL="/utf-8" +* PM_CL="/utf-8" diff --git a/tests/std/tests/P0553R4_bit_rotating_and_counting_functions/env.lst b/tests/std/tests/P0553R4_bit_rotating_and_counting_functions/env.lst index ff4a6cc8f27..6d45b1c2a26 100644 --- a/tests/std/tests/P0553R4_bit_rotating_and_counting_functions/env.lst +++ b/tests/std/tests/P0553R4_bit_rotating_and_counting_functions/env.lst @@ -3,5 +3,5 @@ RUNALL_INCLUDE ..\usual_20_matrix.lst RUNALL_CROSSLIST -PM_CL="" -PM_CL="/arch:AVX2" +* PM_CL="" +* PM_CL="/arch:AVX2" diff --git a/tests/std/tests/P0556R3_bit_integral_power_of_two_operations/env.lst b/tests/std/tests/P0556R3_bit_integral_power_of_two_operations/env.lst index ff4a6cc8f27..6d45b1c2a26 100644 --- a/tests/std/tests/P0556R3_bit_integral_power_of_two_operations/env.lst +++ b/tests/std/tests/P0556R3_bit_integral_power_of_two_operations/env.lst @@ -3,5 +3,5 @@ RUNALL_INCLUDE ..\usual_20_matrix.lst RUNALL_CROSSLIST -PM_CL="" -PM_CL="/arch:AVX2" +* PM_CL="" +* PM_CL="/arch:AVX2" diff --git a/tests/std/tests/P0645R10_text_formatting_legacy_text_encoding/env.lst b/tests/std/tests/P0645R10_text_formatting_legacy_text_encoding/env.lst index adb6a326162..54a8abf4e09 100644 --- a/tests/std/tests/P0645R10_text_formatting_legacy_text_encoding/env.lst +++ b/tests/std/tests/P0645R10_text_formatting_legacy_text_encoding/env.lst @@ -6,24 +6,38 @@ RUNALL_INCLUDE ..\prefix.lst RUNALL_CROSSLIST -PM_CL="/w14640 /Zc:threadSafeInit- /execution-charset:.932" +* PM_CL="/w14640 /Zc:threadSafeInit- /execution-charset:.932" RUNALL_CROSSLIST -PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++20 /permissive- /Zc:noexceptTypes-" -PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" -PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /Zc:char8_t- /Zc:preprocessor" -PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /Zc:wchar_t-" -PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" -PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++20 /permissive- /fp:except /Zc:preprocessor" -PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive-" -PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /analyze:only /analyze:autolog-" -PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" -PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /fp:strict" -PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" -PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++latest /permissive" -PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++latest /permissive- /analyze:only /analyze:autolog-" -PM_CL="/clr /MD /std:c++20" -PM_CL="/clr /MDd /std:c++20" -# PM_CL="/std:c++20 /permissive- /BE /c /EHsc /MD" -# PM_CL="/std:c++latest /permissive- /BE /c /EHsc /MTd" -# PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /std:c++20 /permissive- /MD" -# PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /std:c++latest /permissive- /MTd /fp:strict" +* PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++20 /permissive- /Zc:noexceptTypes-" +ASAN PM_CL="/EHsc /MD /std:c++20 /permissive- /Zc:noexceptTypes- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" +ASAN PM_CL="/EHsc /MD /std:c++latest /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /Zc:char8_t- /Zc:preprocessor" +ASAN PM_CL="/EHsc /MD /std:c++latest /permissive- /Zc:char8_t- /Zc:preprocessor -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /Zc:wchar_t-" +ASAN PM_CL="/EHsc /MDd /std:c++latest /permissive- /Zc:wchar_t- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" +ASAN PM_CL="/EHsc /MDd /std:c++latest /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MDd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++20 /permissive- /fp:except /Zc:preprocessor" +ASAN PM_CL="/EHsc /MDd /std:c++20 /permissive- /fp:except /Zc:preprocessor -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive-" +ASAN PM_CL="/EHsc /MT /std:c++latest /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /analyze:only /analyze:autolog-" +ASAN PM_CL="/EHsc /MT /std:c++latest /permissive- /analyze:only /analyze:autolog- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MT /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" +# No corresponding ASAN config, since the above differs from another config only in IDL +* PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=0 /std:c++latest /permissive- /fp:strict" +ASAN PM_CL="/EHsc /MTd /std:c++latest /permissive- /fp:strict -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=1 /std:c++latest /permissive-" +ASAN PM_CL="/EHsc /MTd /std:c++latest /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++latest /permissive" +ASAN PM_CL="/EHsc /MTd /std:c++latest /permissive -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MTd /D_ITERATOR_DEBUG_LEVEL=2 /std:c++latest /permissive- /analyze:only /analyze:autolog-" +ASAN PM_CL="/EHsc /MTd /std:c++latest /permissive- /analyze:only /analyze:autolog- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/clr /MD /std:c++20" +* PM_CL="/clr /MDd /std:c++20" +# * PM_CL="/std:c++20 /permissive- /BE /c /EHsc /MD" +# * PM_CL="/std:c++latest /permissive- /BE /c /EHsc /MTd" +# * PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /std:c++20 /permissive- /MD" +# * PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /std:c++latest /permissive- /MTd /fp:strict" +# * PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /std:c++latest /permissive- /MT /fp:strict -fsanitize=undefined -fno-sanitize-recover=undefined" diff --git a/tests/std/tests/P0645R10_text_formatting_utf8/env.lst b/tests/std/tests/P0645R10_text_formatting_utf8/env.lst index 1f537b16e72..223468e5254 100644 --- a/tests/std/tests/P0645R10_text_formatting_utf8/env.lst +++ b/tests/std/tests/P0645R10_text_formatting_utf8/env.lst @@ -3,4 +3,4 @@ RUNALL_INCLUDE ..\concepts_20_matrix.lst RUNALL_CROSSLIST -PM_CL="/utf-8" +* PM_CL="/utf-8" diff --git a/tests/std/tests/P0811R3_midpoint_lerp/env.lst b/tests/std/tests/P0811R3_midpoint_lerp/env.lst index 5d2c55ad304..d707906cdd2 100644 --- a/tests/std/tests/P0811R3_midpoint_lerp/env.lst +++ b/tests/std/tests/P0811R3_midpoint_lerp/env.lst @@ -3,5 +3,5 @@ RUNALL_INCLUDE ..\usual_20_matrix.lst RUNALL_CROSSLIST -PM_CL="/Od" -PM_CL="/O2" +* PM_CL="/Od" +* PM_CL="/O2" diff --git a/tests/std/tests/P0881R7_stacktrace/env.lst b/tests/std/tests/P0881R7_stacktrace/env.lst index 1349aaccb51..c6bc6d6453a 100644 --- a/tests/std/tests/P0881R7_stacktrace/env.lst +++ b/tests/std/tests/P0881R7_stacktrace/env.lst @@ -3,6 +3,6 @@ RUNALL_INCLUDE ..\usual_latest_matrix.lst RUNALL_CROSSLIST -PM_CL="/Zi /DHAS_DEBUG_INFO" PM_LINK="/debug" -PM_CL="/DHAS_EXPORT" -PM_CL="" +* PM_CL="/Zi /DHAS_DEBUG_INFO" PM_LINK="/debug" +* PM_CL="/DHAS_EXPORT" +* PM_CL="" diff --git a/tests/std/tests/P0881R7_stacktrace/test.cpp b/tests/std/tests/P0881R7_stacktrace/test.cpp index 879d6bdcb82..17cf3864e2d 100644 --- a/tests/std/tests/P0881R7_stacktrace/test.cpp +++ b/tests/std/tests/P0881R7_stacktrace/test.cpp @@ -156,6 +156,11 @@ string to_string_using_to_string(const stacktrace& st) { return to_string(st) + "\n"; } +#if !defined(HAS_DEBUG_INFO) && defined(__SANITIZE_ADDRESS__) +// We always use /Zi with -fsanitize=address +#define HAS_DEBUG_INFO +#endif // ^^^ !defined(HAS_DEBUG_INFO) && defined(__SANITIZE_ADDRESS__) ^^^ + #if defined(HAS_DEBUG_INFO) || defined(HAS_EXPORT) #define HAS_NAMES #endif // ^^^ defined(HAS_DEBUG_INFO) || defined(HAS_EXPORT) ^^^ diff --git a/tests/std/tests/P0912R5_coroutine/env.lst b/tests/std/tests/P0912R5_coroutine/env.lst index 753a686fb03..c1ae7ea8ca2 100644 --- a/tests/std/tests/P0912R5_coroutine/env.lst +++ b/tests/std/tests/P0912R5_coroutine/env.lst @@ -3,25 +3,41 @@ RUNALL_INCLUDE ..\prefix.lst RUNALL_CROSSLIST -PM_CL="/EHsc /MD /await:strict /std:c++14" -PM_CL="/EHsc /MD /await:strict /std:c++14 /permissive-" -PM_CL="/EHsc /MTd /await:strict /std:c++14 /permissive- /Zc:preprocessor" -PM_CL="/EHsc /MD /await:strict /std:c++14 /permissive- /analyze:only /analyze:autolog-" -PM_CL="/EHsc /MD /await:strict /std:c++17" -PM_CL="/EHsc /MD /await:strict /std:c++17 /permissive-" -PM_CL="/EHsc /MTd /await:strict /std:c++17 /permissive- /Zc:preprocessor" -PM_CL="/EHsc /MD /await:strict /std:c++17 /permissive- /analyze:only /analyze:autolog-" -PM_CL="/EHsc /MD /std:c++20 /permissive" -PM_CL="/EHsc /MD /std:c++20 /permissive-" -PM_CL="/EHsc /MTd /std:c++20 /permissive- /Zc:preprocessor" -PM_CL="/EHsc /MD /std:c++20 /permissive- /analyze:only /analyze:autolog-" -PM_CL="/EHsc /MD /std:c++latest /permissive" -PM_CL="/EHsc /MD /std:c++latest /permissive-" -PM_CL="/EHsc /MTd /std:c++latest /permissive- /Zc:preprocessor" -PM_CL="/EHsc /MD /std:c++latest /permissive- /analyze:only /analyze:autolog-" -PM_CL="/clr /MD /std:c++20" -PM_CL="/clr /MDd /std:c++20" -PM_CL="/BE /c /EHsc /MD /std:c++20 /permissive-" -PM_CL="/BE /c /EHsc /MTd /std:c++latest /permissive-" -PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MD /std:c++20 /permissive-" -PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MTd /std:c++latest /permissive-" +* PM_CL="/EHsc /MD /await:strict /std:c++14" +ASAN PM_CL="/EHsc /MD /await:strict /std:c++14 -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /await:strict /std:c++14 /permissive-" +ASAN PM_CL="/EHsc /MD /await:strict /std:c++14 /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MTd /await:strict /std:c++14 /permissive- /Zc:preprocessor" +ASAN PM_CL="/EHsc /MTd /await:strict /std:c++14 /permissive- /Zc:preprocessor -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /await:strict /std:c++14 /permissive- /analyze:only /analyze:autolog-" +ASAN PM_CL="/EHsc /MD /await:strict /std:c++14 /permissive- /analyze:only /analyze:autolog- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /await:strict /std:c++17" +ASAN PM_CL="/EHsc /MD /await:strict /std:c++17 -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /await:strict /std:c++17 /permissive-" +ASAN PM_CL="/EHsc /MD /await:strict /std:c++17 /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MTd /await:strict /std:c++17 /permissive- /Zc:preprocessor" +ASAN PM_CL="/EHsc /MTd /await:strict /std:c++17 /permissive- /Zc:preprocessor -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /await:strict /std:c++17 /permissive- /analyze:only /analyze:autolog-" +ASAN PM_CL="/EHsc /MD /await:strict /std:c++17 /permissive- /analyze:only /analyze:autolog- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /std:c++20 /permissive" +ASAN PM_CL="/EHsc /MD /std:c++20 /permissive -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /std:c++20 /permissive-" +ASAN PM_CL="/EHsc /MD /std:c++20 /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MTd /std:c++20 /permissive- /Zc:preprocessor" +ASAN PM_CL="/EHsc /MTd /std:c++20 /permissive- /Zc:preprocessor -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /std:c++20 /permissive- /analyze:only /analyze:autolog-" +ASAN PM_CL="/EHsc /MD /std:c++20 /permissive- /analyze:only /analyze:autolog- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /std:c++latest /permissive" +ASAN PM_CL="/EHsc /MD /std:c++latest /permissive -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /std:c++latest /permissive-" +ASAN PM_CL="/EHsc /MD /std:c++latest /permissive- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MTd /std:c++latest /permissive- /Zc:preprocessor" +ASAN PM_CL="/EHsc /MTd /std:c++latest /permissive- /Zc:preprocessor -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/EHsc /MD /std:c++latest /permissive- /analyze:only /analyze:autolog-" +ASAN PM_CL="/EHsc /MD /std:c++latest /permissive- /analyze:only /analyze:autolog- -fsanitize=address /Zi" PM_LINK="/debug" +* PM_CL="/clr /MD /std:c++20" +* PM_CL="/clr /MDd /std:c++20" +* PM_CL="/BE /c /EHsc /MD /std:c++20 /permissive-" +* PM_CL="/BE /c /EHsc /MTd /std:c++latest /permissive-" +* PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MD /std:c++20 /permissive-" +* PM_COMPILER="clang-cl" PM_CL="-fno-ms-compatibility -fno-delayed-template-parsing -Wno-unqualified-std-cast-call /EHsc /MTd /std:c++latest /permissive-" diff --git a/tests/std/tests/P1169R4_static_call_operator/env.lst b/tests/std/tests/P1169R4_static_call_operator/env.lst new file mode 100644 index 00000000000..642f530ffad --- /dev/null +++ b/tests/std/tests/P1169R4_static_call_operator/env.lst @@ -0,0 +1,4 @@ +# Copyright (c) Microsoft Corporation. +# SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception + +RUNALL_INCLUDE ..\usual_latest_matrix.lst diff --git a/tests/std/tests/P1169R4_static_call_operator/test.compile.pass.cpp b/tests/std/tests/P1169R4_static_call_operator/test.compile.pass.cpp new file mode 100644 index 00000000000..47b6bcd6374 --- /dev/null +++ b/tests/std/tests/P1169R4_static_call_operator/test.compile.pass.cpp @@ -0,0 +1,57 @@ +// Copyright (c) Microsoft Corporation. +// SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception + +#ifdef __cpp_static_call_operator + +#include +#include +#include +using namespace std; + +struct F0 { + static char operator()(); +}; + +struct F1 { + static short operator()(float); +}; + +struct F2 { + static int operator()(double*, double&); +}; + +struct F3 { + static void operator()(const long&, long&&, const long&&); +}; + +struct Base { + static bool operator()(unsigned int); +}; + +struct Derived : Base {}; + +struct Nothrow { + static char16_t operator()(char32_t) noexcept; +}; + +template