anchor.diff:  #if FX_RESHAPED_REFLECTION
   open ReflectionAdapters
   #endif
  +
  +// Create one global interactive checker instance 
  +let checker = FSharpChecker.Create()
  +
  +type TempFile(ext, contents) = 
  +    let tmpFile =  Path.ChangeExtension(System.IO.Path.GetTempFileName() , ext)
  +    do File.WriteAllText(tmpFile, contents)
  +    interface System.IDisposable with 
  +        member x.Dispose() = try File.Delete tmpFile with _ -> ()
  +    member x.Name = tmpFile
  +
  +#nowarn "57"
  +
  +let getBackgroundParseResultsForScriptText (input) = 
  +    use file =  new TempFile("fsx", input)
  +    let checkOptions = checker.GetProjectOptionsFromScript(file.Name, input) |> Async.RunSynchronously
  +    checker.GetBackgroundParseResultsForFileInProject(file.Name, checkOptions)  |> Async.RunSynchronously
  +
  +
  +let getBackgroundCheckResultsForScriptText (input) = 
  +    use file =  new TempFile("fsx", input)
  +    let checkOptions = checker.GetProjectOptionsFromScript(file.Name, input) |> Async.RunSynchronously
  +    checker.GetBackgroundCheckResultsForFileInProject(file.Name, checkOptions) |> Async.RunSynchronously
  +
  +
  +let sysLib nm = 
  +#if !FX_ATLEAST_PORTABLE
  +    if System.Environment.OSVersion.Platform = System.PlatformID.Win32NT then // file references only valid on Windows 
  +        @"C:\Program Files (x86)\Reference Assemblies\Microsoft\Framework\.NETFramework\v4.5\" + nm + ".dll"
  +    else
  +#endif
  +#if FX_NO_RUNTIMEENVIRONMENT
  +        let sysDir = System.AppContext.BaseDirectory
  +#else
  +        let sysDir = System.Runtime.InteropServices.RuntimeEnvironment.GetRuntimeDirectory()
  +#endif
  +        let (++) a b = System.IO.Path.Combine(a,b)
  +        sysDir ++ nm + ".dll" 
  +
  +[<AutoOpen>]
  +module Helpers = 
  +    open System
  +    type DummyType = A | B
  +    let PathRelativeToTestAssembly p = Path.Combine(Path.GetDirectoryName(Uri(typeof<DummyType>.Assembly.CodeBase).LocalPath), p)
  +
  +let fsCoreDefaultReference() = 
  +#if !FX_ATLEAST_PORTABLE
  +    if System.Environment.OSVersion.Platform = System.PlatformID.Win32NT then // file references only valid on Windows 
  +        @"C:\Program Files (x86)\Reference Assemblies\Microsoft\FSharp\.NETFramework\v4.0\4.4.0.0\FSharp.Core.dll"  
  +    else 
  +#endif
  +        sysLib "FSharp.Core"
   
   let mkProjectCommandLineArgs (dllName, fileNames) = 
       [|  yield "--simpleresolution" 
  
positive.code:             yield "-r:" + r
       |]
  
  // Create one global interactive checker instance 
  let checker = FSharpChecker.Create()
  
  let parseAndCheckScript (file, input) = 
  
  #if TODO_REWORK_ASSEMBLY_LOAD
  
negative.code:     match typedRes with
      | FSharpCheckFileAnswer.Succeeded(res) -> parseResult, res
      | res -> failwithf "Parsing did not finish... (%A)" res
  
  /// Extract range info 
  let tups (m:Range.range) = (m.StartLine, m.StartColumn), (m.EndLine, m.EndColumn)
  