Sol2: Internal compiler error with VS 2019 16.8.2

Created on 2 Dec 2020  路  10Comments  路  Source: ThePhD/sol2

Hi,

With Visual Studio 2019 16.8.2 and sol v3.2.3 (revision 62804667), I get an internal compiler error:

C:\PROGRA~2\MICROS~1\2019\COMMUN~1\VC\Tools\MSVC\1428~1.293\bin\Hostx64\x64\cl.exe  /nologo /TP -DDEBUG -I..\..\..\extlibs\stb -I..\..\..\include -I..\..\..\ -I..\..\..\extlibs\imgui -I..\..\..\extlibs -I..\..\..\demos\LuaSample\. -I..\..\..\demos\LuaSample\lua-5.4.1\src -I..\..\..\demos\LuaSample\ImGuiColorTextEdit -IC:\Users\scemino\source\repos\vcpkg\installed\x64-windows\include -IC:\Users\scemino\source\repos\vcpkg\installed\x64-windows\include\SDL2 /DWIN32 /D_WINDOWS /GR /EHsc /Zi /Ob0 /Od /RTC1 -MDd /W4 /Zc:twoPhase- -std:c++17 /showIncludes /Fodemos\LuaSample\CMakeFiles\LuaSample.dir\Graphics.cpp.obj /Fddemos\LuaSample\CMakeFiles\LuaSample.dir\ /FS -c ..\..\..\demos\LuaSample\Graphics.cpp
C:\Users\scemino\source\repos\EnggeFramework\demos\LuaSample\sol\sol.hpp(15611): fatal error C1001: Internal compiler error.
  (compiler file 'msc1.cpp', line 1584)
   To work around this problem, try simplifying or changing the program near the locations listed above.
  If possible please provide a repro here: https://developercommunity.visualstudio.com 
  Please choose the Technical Support command on the Visual C++ 
   Help menu, or open the Technical Support help file for more information
  C:\Users\scemino\source\repos\EnggeFramework\demos\LuaSample\sol/sol.hpp(15754): note: see reference to class template instantiation 'sol::proxy_base<sol::stack_proxy_base>' being compiled
  INTERNAL COMPILER ERROR in 'C:\PROGRA~2\MICROS~1\2019\COMMUN~1\VC\Tools\MSVC\1428~1.293\bin\Hostx64\x64\cl.exe'
      Please choose the Technical Support command on the Visual C++
      Help menu, or open the Technical Support help file for more information

I tried with this switch /Zc:twoPhase- as explained in an issue, but I still get the error.

To reproduce you can try my repo here: https://github.com/scemino/EnggeFramework
I'm using Github actions to compile on Windows.

I'm open to any suggestions or workaround, thank you.

Help.Desk

All 10 comments

Try to pass -Thost=x64 to cmake generator

Thank you @halx99 your solution works, I can close the issue.

Ooops sorry, I made a mistake, I disabled LuaSample project, so it was compiling correctly, but I have still the same issue 馃槩

That's glad, so may needs wait visual studio team to fix the bug

Apologies, I haven't gotten to this yet.

I made some changes and I don't quite get the error in my tests, but I still need to pull the framework and test. Sorry for the pain here.

It looks like I need to get GLEW and a bunch of other stuff to "try" this error out.

It looks like I need to get GLEW and a bunch of other stuff to "try" this error out.

I'm lucky 馃榿, tell me if I can help.

VS 2019 Preview and VS 2019 Release, latest version, do not Internal Compiler Error, either with the latest sol2 or the version you reported here.

I am assuming this is a solved problem. Please upgrade your Visual Studio.

OK I use now the stable version v3.2.2 and it works.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

TheMaverickProgrammer picture TheMaverickProgrammer  路  6Comments

spin-scenario picture spin-scenario  路  5Comments

morsisko picture morsisko  路  3Comments

cgloeckner picture cgloeckner  路  3Comments

squeek502 picture squeek502  路  4Comments