I'm about to start working on a C# project. I'd like to buy VS 2010, but the only other member of the programming team is already using VS 2008. I'm concerned that having two different versions of VS in use will cause code compatibility issues. Is this a valid concern?
views:
96answers:
4Yes. You can't (natively) open a VS2010 solution in Vs2008. Also, if you start writing code aimed at .net 4.0, the guy with VS2008 won't be able to maintain/work on the code.
It shouldn't produce code compatibility issues since you choose the framework version for development. One thing that will break is the solution (.sln) files, unless they decided that one version of the file covers many VS's :)
The code compatibility can be managed by being consistent with the framework version you compile against (e.g. v2 or v3.5).
Project file compatibility will be more of an issue, as VS2008 won't be able to load the project files from VS2010, which in turn would keep wanting to update it to the later format. This could be solved by duplicating the project files in the same directory, but you will run into issues when classes are added/removed from one project or the other, as they won't be kept in sync automatically
There'll be code compatibilities if you target .NET 4 while your colleague targets .NET 3.5, but more importantly there'll be compatibility problems with the project files themselves.
If you open any projects/solutions they'll upgrade and your colleague won't be able to open them.