haskell / haskell/stylish-haskell

Failure to parse lines without indentation in `do` block.

Open
#442 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
Haskell
Stars
1k
Forks
153
PR merge metrics
No merged PRs in 30d

Description

It's common to write SQL queries with Esqueleto without indent lines under a `do`, like this:

```haskell
getJohns =
select $ do
people <- from $ table @Person
where_ (people ^. PersonName ==. val "John")
pure people
```

This style more closely resembles what you might write in plain SQL.

Running stylish-haskell on this fails however, with something like the following error message:

```
:22:9: error:
parse error on input `<-'
Perhaps this statement should be within a 'do' block?
```

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.