Unable to cast transparent proxy to type 'Roslyn.Utilities.SerializableDataStorage'

Got this strange error today while using Roslyn via NuGet.
To fix it check this:

  1. The is not outdated version of the "Roslyn.Services.dll" process running (check task manager)
  2. The platform target of your DLL or application is "Any CPU"
  3. Visual Studio 2012: Disable "Prefer 32-bit" under the "Platform target" drop-down menu for your startup project.
    This was the reason why it was not working for me.