Buildalyzer icon indicating copy to clipboard operation
Buildalyzer copied to clipboard

Updates MSBuild references

Open REscobar opened this issue 1 year ago • 4 comments

Fixes #281

🚀 Pull Request Template

Description

This PR updates MSbuild references to support C# 12 features which are not buildable using latest public version of Buildalyzer

A test case was added which would fail withouth this commit

REscobar avatar Jul 24 '24 01:07 REscobar

This does not work when you just update these dependencies yourself in your own project?

Corniel avatar Jul 28 '24 09:07 Corniel

Setting up a project, referencig Buildalyzer and updating those references locally does allow Buildalyzer to build projects with C# 12 features.

But I'm not using Buildalyzer directly, I'm using https://github.com/eNeRGy164/LivingDocumentation, which is a dotnet command line tool, to analyze my projects but I'm unable to do so beacuse the referenced and the latest version of Buildalyzer can't build them.

REscobar avatar Jul 29 '24 13:07 REscobar

@REscobar Thank you very much for contributing, I intend to evaluate your PR this week, I need to understand if we really won't have a backwards compatibility problem, there are some situations that are not possible to simulate in unit tests.

@Corniel do you see any problem? I appreciate your opinion.

phmonte avatar Jul 31 '24 18:07 phmonte

If we take a look at: Roslyn's release notes, we can conclude that v4.4.0 (our current version) is almost 2 years old, which supports .NET 7.0 and C# 11. Although I would argue by explicitly including v4.10.0 it should work for .NET 8.0 and C# 12 too, sticking to a version that supports up to a framework version that Microsoft does not support anymore, makes no sense.

We have no paying customers (as far as I know) that would have issues with old systems relying on this older version that can not update. So, I think we should do it.

That being said: I think we should define a strategy on how to deal with this dependencies: Should we always aim to go for the latest stable version out there?

Corniel avatar Jul 31 '24 21:07 Corniel