Search Issue Tracker
Fixed
Fixed in 2.0.18
Votes
4
Found in [Package]
2.0.11
Issue ID
VS-43
Regression
Yes
Unity VS package generates csproj with the wrong language version
How to reproduce:
1. Open project "Empty Unity Project.zip"
2. Go to Unity>Preferences>External Tools and click the "Regenerate project files" button
3. Open the project folder in your file explorer
4. Open "Assembly-CSharp.csproj" with a text editor but not a VS
5. Look at the "<LangVersion>8.0</LangVersion>" version
6. Close the text editor
7. In the Unity Project window create a new C# Script (Right click>Create>C# Script)
8. Again open "Assembly-CSharp.csproj" with a text editor but not VS
9. Look at the "<LangVersion>latest</LangVersion>" version
10. If the version didn't change go to the 7th step
11. Again go to Unity>Preferences>External Tools and click the "Regenerate project files" button
12. Again open "Assembly-CSharp.csproj" with a text editor but not VS
13. Look at the "<LangVersion>8.0</LangVersion>" version
Expected result: Lang version should be 8.0 (or different in other versions)
Actual result: Lang version is "latest"
Reproducible with: 2.0.11 (2020.1.0a21, 2020.3.20f1, 2021.1.25f1, 2021.2.0b16, 2022.1.0a12)
Not reproducible with: 2.0.11 (2019.4.31f1)
Could not test with: 2020.1.0a20 ("Regenerate project files" button wasn't appearing)
Add comment
All about bugs
View bugs we have successfully reproduced, and vote for the bugs you want to see fixed most urgently.
Latest issues
- Crash on ScriptableRenderLoopDraw when rendering a specific VFX in Play Mode
- The script is not renamed in the Project window when renaming and a compilation Error is present
- Average FPS in Play Mode degradation on a newly created BiRP project when it's upgraded from 2020.3.48f1 to a newer Editor version
- DecoratorDrawer indentation is incorrect when it is called with EditorGUI
- "Unable to get the list of approved APIs." is thrown when testing the App Packages with Windows App Certification Kit
dsenn
Mar 02, 2022 15:58
fixing this should be a minor amount of work and would improve the ux a lot.
stavroskaskuras
Nov 05, 2021 19:27
Please fix it as imo get suggestions for things that belong in c# 9 like the new() constructor...
Also it is very disturbing seeing start and update being continuously underlined because visual studio thinks they are not used....