@@ -2053,7 +2053,7 @@ type internal FsiInteractionProcessor
20532053 f istate
20542054 with e ->
20552055 stopProcessingRecovery e range0
2056- istate, CompletedWithReportedError e
2056+ istate, CompletedWithReportedError e
20572057
20582058 let isFeatureSupported featureId = tcConfigB.langVersion.SupportsFeature featureId
20592059
@@ -2099,19 +2099,19 @@ type internal FsiInteractionProcessor
20992099 let ExecInteraction ( ctok , tcConfig : TcConfig , istate , action : ParsedFsiInteraction , errorLogger : ErrorLogger ) =
21002100 istate |> InteractiveCatch errorLogger ( fun istate ->
21012101 match action with
2102- | IDefns ([ ], _) ->
2102+ | IDefns ([], _) ->
21032103 let istate = fsiDynamicCompiler.CommitDependencyManagerText( ctok, istate, lexResourceManager, errorLogger)
21042104 istate, Completed None
21052105
2106- | IDefns ([ SynModuleDecl.DoExpr(_, expr,_)],_) ->
2106+ | IDefns ([ SynModuleDecl.DoExpr(_, expr, _)], _) ->
21072107 let istate = fsiDynamicCompiler.CommitDependencyManagerText( ctok, istate, lexResourceManager, errorLogger)
21082108 fsiDynamicCompiler.EvalParsedExpression( ctok, errorLogger, istate, expr)
21092109
21102110 | IDefns ( defs,_) ->
21112111 let istate = fsiDynamicCompiler.CommitDependencyManagerText( ctok, istate, lexResourceManager, errorLogger)
21122112 fsiDynamicCompiler.EvalParsedDefinitions ( ctok, errorLogger, istate, true , false , defs)
21132113
2114- | IHash ( ParsedHashDirective( " load" , sourceFiles, m),_) ->
2114+ | IHash ( ParsedHashDirective( " load" , sourceFiles, m), _) ->
21152115 let istate = fsiDynamicCompiler.CommitDependencyManagerText( ctok, istate, lexResourceManager, errorLogger)
21162116 fsiDynamicCompiler.EvalSourceFiles ( ctok, istate, m, sourceFiles, lexResourceManager, errorLogger), Completed None
21172117
@@ -2161,69 +2161,69 @@ type internal FsiInteractionProcessor
21612161 fsiConsoleOutput.uprintnfnn " %s " format)
21622162 istate, Completed None
21632163
2164- | IHash ( ParsedHashDirective( " I" ,[ path], m),_) ->
2165- tcConfigB.AddIncludePath ( m, path, tcConfig.implicitIncludeDir)
2164+ | IHash ( ParsedHashDirective( " I" , [ path], m), _) ->
2165+ tcConfigB.AddIncludePath ( m, path, tcConfig.implicitIncludeDir)
21662166 fsiConsoleOutput.uprintnfnn " %s " ( FSIstrings.SR.fsiDidAHashI( tcConfig.MakePathAbsolute path))
2167- istate, Completed None
2167+ istate, Completed None
21682168
2169- | IHash ( ParsedHashDirective( " cd" ,[ path], m),_) ->
2169+ | IHash ( ParsedHashDirective( " cd" , [ path], m), _) ->
21702170 ChangeDirectory path m
2171- istate, Completed None
2171+ istate, Completed None
21722172
2173- | IHash ( ParsedHashDirective( " silentCd" ,[ path], m),_) ->
2173+ | IHash ( ParsedHashDirective( " silentCd" , [ path], m), _) ->
21742174 ChangeDirectory path m
21752175 fsiConsolePrompt.SkipNext() (* "silent" directive *)
2176- istate, Completed None
2176+ istate, Completed None
21772177
2178- | IHash ( ParsedHashDirective( " dbgbreak" ,[],_),_) ->
2179- { istate with debugBreak = true }, Completed None
2178+ | IHash ( ParsedHashDirective( " dbgbreak" , [], _), _) ->
2179+ { istate with debugBreak = true }, Completed None
21802180
2181- | IHash ( ParsedHashDirective( " time" ,[],_),_) ->
2181+ | IHash ( ParsedHashDirective( " time" , [], _), _) ->
21822182 if istate.timing then
21832183 fsiConsoleOutput.uprintnfnn " %s " ( FSIstrings.SR.fsiTurnedTimingOff())
21842184 else
21852185 fsiConsoleOutput.uprintnfnn " %s " ( FSIstrings.SR.fsiTurnedTimingOn())
2186- { istate with timing = not istate.timing}, Completed None
2186+ { istate with timing = not istate.timing}, Completed None
21872187
2188- | IHash ( ParsedHashDirective( " time" ,[( " on" | " off" ) as v],_),_) ->
2188+ | IHash ( ParsedHashDirective( " time" , [( " on" | " off" ) as v], _), _) ->
21892189 if v <> " on" then
21902190 fsiConsoleOutput.uprintnfnn " %s " ( FSIstrings.SR.fsiTurnedTimingOff())
21912191 else
21922192 fsiConsoleOutput.uprintnfnn " %s " ( FSIstrings.SR.fsiTurnedTimingOn())
2193- { istate with timing = ( v = " on" )}, Completed None
2193+ { istate with timing = ( v = " on" )}, Completed None
21942194
2195- | IHash ( ParsedHashDirective( " nowarn" , numbers, m),_) ->
2196- List.iter ( fun ( d : string ) -> tcConfigB.TurnWarningOff( m, d)) numbers
2197- istate, Completed None
2195+ | IHash ( ParsedHashDirective( " nowarn" , numbers, m), _) ->
2196+ List.iter ( fun ( d : string ) -> tcConfigB.TurnWarningOff( m, d)) numbers
2197+ istate, Completed None
21982198
2199- | IHash ( ParsedHashDirective( " terms" ,[],_),_) ->
2199+ | IHash ( ParsedHashDirective( " terms" , [], _), _) ->
22002200 tcConfigB.showTerms <- not tcConfig.showTerms
2201- istate, Completed None
2201+ istate, Completed None
22022202
2203- | IHash ( ParsedHashDirective( " types" ,[],_),_) ->
2203+ | IHash ( ParsedHashDirective( " types" , [], _), _) ->
22042204 fsiOptions.ShowTypes <- not fsiOptions.ShowTypes
2205- istate, Completed None
2205+ istate, Completed None
22062206
22072207 #if DEBUG
2208- | IHash ( ParsedHashDirective( " ilcode" ,[],_ m),_) ->
2208+ | IHash ( ParsedHashDirective( " ilcode" , [], _ m), _) ->
22092209 fsiOptions.ShowILCode <- not fsiOptions.ShowILCode;
2210- istate, Completed None
2210+ istate, Completed None
22112211
2212- | IHash ( ParsedHashDirective( " info" ,[],_ m),_) ->
2212+ | IHash ( ParsedHashDirective( " info" , [], _ m), _) ->
22132213 PrintOptionInfo tcConfigB
2214- istate, Completed None
2214+ istate, Completed None
22152215 #endif
22162216
2217- | IHash ( ParsedHashDirective(( " q" | " quit" ),[],_),_) ->
2217+ | IHash ( ParsedHashDirective(( " q" | " quit" ), [], _), _) ->
22182218 fsiInterruptController.Exit()
22192219
2220- | IHash ( ParsedHashDirective( " help" ,[],_),_) ->
2220+ | IHash ( ParsedHashDirective( " help" , [], _), _) ->
22212221 fsiOptions.ShowHelp()
2222- istate, Completed None
2222+ istate, Completed None
22232223
2224- | IHash ( ParsedHashDirective( c, arg,_), _) ->
2225- fsiConsoleOutput.uprintfn " %s " ( FSIstrings .SR.fsiInvalidDirective( c, String.concat " " arg)) // REVIEW: uprintnfnn - like other directives above
2226- istate, Completed None (* REVIEW: cont = CompletedWithReportedError *)
2224+ | IHash ( ParsedHashDirective( c, arg, m ), _) ->
2225+ warning ( Error (( FSComp .SR.fsiInvalidDirective( c, String.concat " " arg)), m ))
2226+ istate, Completed None
22272227 )
22282228
22292229 /// Execute a single parsed interaction which may contain multiple items to be executed
0 commit comments