Search Unity

  1. Unity support for visionOS is now available. Learn more in our blog post.
    Dismiss Notice

Unmanaged constructed types and Visual Studio (possible bug?)

Discussion in '2020.2 Beta' started by Imakhiil, Sep 3, 2020.

  1. Imakhiil

    Imakhiil

    Joined:
    Oct 11, 2013
    Posts:
    96
    I downloaded the beta today to check if unmanaged constructed types are supported already (I read in another thread that they should be) but I'm getting this error in Visual Studio:
    upload_2020-9-3_7-47-24.png

    The code compiles and executes just fine in Unity. Both in Editor and in release.

    I regenerated project files but it doesn't seem to have had any effect. I believe I have the latest version of the Visual Editor Plugin (2.0.2).

    Is this a bug or is there something else I could try to get rid of that error notification in VS?
     
  2. TheZombieKiller

    TheZombieKiller

    Joined:
    Feb 8, 2013
    Posts:
    263
    The VS IDE support plugin (as of version 2.0.1) has functionality that forces generated .csproj files to use C# 7.3 when C# 8 support is detected. Until this is removed (or tweaked to only affect the appropriate versions of Unity), the simplest solution available is to downgrade to version 2.0.0.