public static string Format(string text) { var result = ParseScript( text, flags: Flags.EnableExpressionChaining); // Can't pretty print a script with errors. if (result.HasError) { return(text); } return(PrettyPrintVisitor.Format(result.Root, result.Before, result.After, text)); }