@@ -189,11 +189,13 @@ processNetCmd orig i h fn cmd
189189 where
190190 processNet fn Reload = processNet fn (Load fn Nothing)
191191 processNet fn (Load f toline) =
192− do let ist = orig { idris_options = idris_options i
193− , idris_colourTheme = idris_colourTheme i
194− , idris_colourRepl = False
195− }
196− putIState ist
192+ -- The $!! here prevents a space leak on reloading.
193+ -- This isn't a solution - but it's a temporary stopgap.
194+ -- See issue #2386
195+ do putIState $!! orig { idris_options = idris_options i
196+ , idris_colourTheme = idris_colourTheme i
197+ , idris_colourRepl = False
198+ }
197199 setErrContext True
198200 setOutH h
199201 setQuiet True
@@ -755,6 +757,9 @@ edit f orig
755757 let args = line ++ [fixName f]
756758 runIO $ rawSystem editor args
757759 clearErr
760+ -- The $!! here prevents a space leak on reloading.
761+ -- This isn't a solution - but it's a temporary stopgap.
762+ -- See issue #2386
758763 putIState $!! orig { idris_options = idris_options i
759764 , idris_colourTheme = idris_colourTheme i
760765 }
@@ -1704,6 +1709,7 @@ idrisMain opts =
17041709 iputStrLn banner
17051710
17061711 orig <- getIState
1712+
17071713 mods <- if idesl then return [] else loadInputs inputs Nothing
17081714 let efile = case inputs of
17091715 [] -> ""