-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support GHCi style multiline input in the repl
- Loading branch information
1 parent
8658ae7
commit 80785d5
Showing
7 changed files
with
70 additions
and
23 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,16 @@ | ||
:set +core-eval | ||
:set +c-eval | ||
|
||
from injury ~> fold x = map_create then case map_lookup (Some location) x of None then map_insert (Some location) (Some severity) x; Some _ then map_delete (Some location) x ~> x | ||
-- fold x = map_create : | ||
-- case map_lookup location x | ||
-- | None -> map_insert location severity x | ||
-- | Some _ -> map_delete location x | ||
-- end | ||
|
||
:{ | ||
from injury in | ||
fold x = | ||
map_create | ||
then | ||
case map_lookup (Some location) x of | ||
None then | ||
map_insert (Some location) (Some severity) x | ||
Some _ then | ||
map_delete (Some location) x | ||
in | ||
x | ||
:} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters