Pragma disable for CS8802 is ignored
- Dominant language
- TypeScript
- Stars
- 3.1k
- Forks
- 737
- Avg merge
- 18h 40m
- Merged PRs (30d)
- 31
Description
## Issue Description ##
`#pragma warning disable CS8802` being ignored by analyzer
## Steps to Reproduce ##
1. Create C# project with TLS
2. Make 2 translation units utilizing TLS
3. Add `#pragma warning disable CS8802` to the unit with CS8802 reported
## Expected Behavior ##
Warning goes away
## Actual Behavior ##
It stays.
## Additional info ##

## Environment information ##
**VSCode version**: 1.67.1
**C# Extension**: 1.25.0
Dotnet Information
.NET SDK:
Version: 7.0.100
Commit: e12b7af219
Runtime Environment:
OS Name: Windows
OS Version: 10.0.19044
OS Platform: Windows
RID: win10-x64
Base Path: C:\Program Files\dotnet\sdk\7.0.100\
Host:
Version: 7.0.0
Architecture: x64
Commit: d099f075e4
.NET SDKs installed:
7.0.100 [C:\Program Files\dotnet\sdk]
.NET runtimes installed:
Microsoft.AspNetCore.App 3.1.31 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 6.0.11 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.AspNetCore.App 7.0.0 [C:\Program Files\dotnet\shared\Microsoft.AspNetCore.App]
Microsoft.NETCore.App 3.1.25 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 3.1.31 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 6.0.11 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.NETCore.App 7.0.0 [C:\Program Files\dotnet\shared\Microsoft.NETCore.App]
Microsoft.WindowsDesktop.App 3.1.25 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 3.1.31 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 6.0.11 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Microsoft.WindowsDesktop.App 7.0.0 [C:\Program Files\dotnet\shared\Microsoft.WindowsDesktop.App]
Other architectures found:
x86 [C:\Program Files (x86)\dotnet]
registered at [HKLM\SOFTWARE\dotnet\Setup\InstalledVersions\x86\InstallLocation]
Environment variables:
Not set
global.json file:
Not found
Learn more:
https://aka.ms/dotnet/info
Download .NET:
https://aka.ms/dotnet/download
Visual Studio Code Extensions
|Extension|Author|Version|
|---|---|---|
|code-spell-checker|streetsidesoftware|2.7.3|
|cpptools|ms-vscode|1.11.5|
|csharp|ms-dotnettools|1.25.0|
|extension-path|actboy168|0.0.4|
|gitlens|eamodio|12.1.2|
|go|golang|0.35.2|
|java|redhat|1.10.0|
|jupyter|ms-toolsai|2022.4.1021342353|
|jupyter-keymap|ms-toolsai|1.0.0|
|jupyter-renderers|ms-toolsai|1.0.9|
|lua|sumneko|3.5.3|
|nugetpackagemanagergui|aliasadidev|2.0.3|
|python|ms-python|2022.6.3|
|theme-bluloco-light|uloco|3.6.1|
|unity-debug|Unity|3.0.2|
|unreal-angelscript|Hazelight|1.4.2|
|vscode-eslint|dbaeumer|2.2.2|
|vscode-gradle|vscjava|3.12.4|
|vscode-java-debug|vscjava|0.44.0|
|vscode-java-dependency|vscjava|0.20.0|
|vscode-lua|trixnz|0.12.4|
|vscode-maven|vscjava|0.38.0|
|vscode-pylance|ms-python|2022.6.0|;
Contributor guide
Assessment
This issue has not been assessed yet.