@@ -2099,8 +2099,16 @@ type BackgroundCompiler(referenceResolver, projectCacheSize, keepAssemblyContent
20992099 cancellable{
21002100
21012101let projectReferences =
2102- [ for ( nm, opts) in options.ReferencedProjects->
2103- { new IProjectReferencewith
2102+ [ for ( nm, opts) in options.ReferencedProjectsdo
2103+
2104+ // Don't use cross-project references for FSharp.Core, since various bits of code require a concrete FSharp.Core to exist on-disk.
2105+ // The only solutions that have these cross-project references to FSharp.Core are VisualFSharp.sln and FSharp.sln. The only ramification
2106+ // of this is that you need to build FSharp.Core to get intellisense in those projects.
2107+
2108+ if ( try Path.GetFileNameWithoutExtension( nm) with _ -> " " ) <> GetFSharpCoreLibraryName() then
2109+
2110+ yield
2111+ { new IProjectReferencewith
21042112member x.EvaluateRawContents ( ctok ) =
21052113 cancellable{
21062114let! r = self.ParseAndCheckProjectImpl( opts, ctok, userOpName+ " .CheckReferencedProject(" + nm+ " )" )