thepowersgang / mrustc

Alternative rust compiler (re-implementation)
MIT License
2.18k stars 109 forks source link

Windows build - fix compilation errors on VS2022 #290

Closed arlosi closed 2 years ago

arlosi commented 2 years ago

A few minor changes necessary to make mrustc build with VS2022.

Does not actually change any of the projects to build with VS2022.

thepowersgang commented 2 years ago

Appveyor build errored with ..\..\src\mir\mir_builder.cpp(741): error C2280: 'SplitArm::SplitArm(void) noexcept': attempting to reference a deleted function [C:\projects\mrustc\vsproject\mrustc_lib\mrustc_lib.vcxproj]

arlosi commented 2 years ago

Trying a fix. If it doesn't work I'll install VS2015 locally to get it passing.

arlosi commented 2 years ago

I couldn't find a way to make it work on both 2015 and 2022, so I had to make it conditional on _MSC_VER

thepowersgang commented 2 years ago

Hmm... I'm slightly hesitant to add guarded changes like that. What's the goal of targetting VS2022? (Laziness will keep me on 2015 until there's a good reason to upgrade)

arlosi commented 2 years ago

No specific reason other than VS2015 ended mainstream support on Oct 13, 2020

I've removed the conditional compilation parts of this PR. Let's at least get those parts in.