Skip to content

Conversation

@hdgarrood
Copy link
Contributor

This additional instance prevents "unit" from being printed after
evaluating an action of the type Effect Unit. This is what ghci does,
and it is usually what you want. For example:

Before:

> log "hello, world"
hello, world
unit

After:

> log "hello, world"
hello, world

(Just thought I'd go straight to opening a PR rather than first opening an issue to discuss because this is so easy to do implementation-wise)

This additional instance prevents "unit" from being printed after
evaluating an action of the type `Effect Unit`. This is what ghci does,
and it is usually what you want. For example:

Before:
```
> log "hello, world"
hello, world
unit
```

After:
```
> log "hello, world"
hello, world
```
@hdgarrood
Copy link
Contributor Author

@JordanMartinez what do you think about this?

@JordanMartinez
Copy link
Contributor

I've always been annoyed by the unit part being printed afterwards. It can be confusing for new learners when that appears but they didn't write any code that said to do that.

@JordanMartinez JordanMartinez merged commit f44e5d3 into master Oct 15, 2020
@JordanMartinez JordanMartinez deleted the eval-effect-unit branch October 15, 2020 01:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants