anchor.diff:              | Some newCode -> newCode
               | None -> null
   
  -    let formatText (doc : Gui.Document) (policyParent : PolicyContainer) (mimeTypeInheritanceChain : string seq) input formattingOption = 
  +    let formatText (doc : Gui.Document option) (policyParent : PolicyContainer) (mimeTypeInheritanceChain : string seq) input formattingOption = 
           let textStylePolicy = policyParent.Get<TextStylePolicy>(mimeTypeInheritanceChain)
           let formattingPolicy = policyParent.Get<FSharpFormattingPolicy>(mimeTypeInheritanceChain)
           format doc textStylePolicy formattingPolicy input formattingOption
  
positive.code:     let trimIfNeeded (input:string) (output:string) =
          let trimLinefeed = not <|  input.EndsWith("\n")
          if trimLinefeed then output.TrimEnd('\n') 
          else input
                      
      let format (doc : Gui.Document) style formatting input options onTheFly =
          let isFsiFile = 
              if doc = null then false
              else doc.FileName.Extension.Equals(".fsi", StringComparison.OrdinalIgnoreCase)
  
          let config = getConfig style formatting
          LoggingService.LogInfo("**Fantomas**: Read config - \n{0}", sprintf "%A" config)
  
negative.code:     override x.CorrectIndenting(policyParent, mimeTypeChain, data, line) = raise (NotSupportedException())
  
      override x.OnTheFlyFormat(doc, fromOffset, toOffset) =
          let policyParent : PolicyContainer =
              match doc.Project with
              | null -> PolicyService.DefaultPolicies
  