title: Invalid option '7' for /langversion; must be ISO-1, ISO-2, Default or an integer in range 1 to 6
body: <p>I have a project in Visual Studio that won't compile.
  It is throwing lots of errors like these ones:</p>
  
  <blockquote>
    <p>error CS1001: Identifier expected<br>
    ; expected<br>
        error CS1022: Type or namespace definition, or end-of-file expected<br>
        error CS0116: A namespace cannot directly contain members such as fields or methods</p>
  </blockquote>
  
  <p>It is complaining about modern C# constructs such as Tuples.
  Whenever I navigate to these files, Visual Studio won't mark any error, or mark them for a second before they go away.</p>
  
  <p>If I go to the project properties (in Build -> Advanced...), the language version is set to "C# latest major version (default)".
  If I set it to 7.0 or higher to try to gain support for these constructs, when compiling the project it will throw the following error:</p>
  
  <blockquote>
    <p>Invalid option '7' for /langversion; must be ISO-1, ISO-2, Default or an integer in range 1 to 6.</p>
  </blockquote>
  
  <p>So it seems to not be accepting a version of C# higher than 6.</p>
  
  <p>It is worth noting that this project is shared in a repository, and none of the other members of the team have problems compiling it.
  Therefore it all points to a problem with the local setup of my machine or my Visual Studio, and not to the configuration of the project.</p>
  
  <p>Some things to consider:</p>
  
  <ul>
  <li>The package "System.ValueTuple" is correctly referenced in the project and set to version 4.3.1.</li>
  <li>The package "Microsoft.Net.Compilers" is at version 2.2.0.</li>
  <li>The target framework for the project is set to .NET Framework 4.6.2.</li>
  <li>My Visual Studio is on its most recent version, 15.8.7.</li>
  </ul>
  
  <p>These are some of the things that I have tried:</p>
  
  <ul>
  <li>Upgrading the packages "System.ValueTuple" and "Microsoft.Net.Compilers" to their latest versions.</li>
  <li>I've built, rebuilt and cleaned the project.</li>
  <li>I tried upgrading all the other projects in my solution to the same version of Microsoft.Net.Compilers.</li>
  <li>I repaired my installation of Visual Studio.</li>
  </ul>
  
  <p>And yet nothing seems to work.</p>
  
  <p>Any help is appreciated!</p>