Closed
Description
Top level declarations seem a bit hit and miss.
implied RunNNFExpr[B] for RunDSL[NNF[B], B] = _.terminal
implied RunNNFImpl[B] for RunDSL[NNF[B], B] {
override def runDSL(b: NNF[B]): B = b.terminal
}
The top declaration RunNNFExpr
works fine. The bottom declaration RunNNFImpl
fails to compile with:
[error] 93 |implied RunNNF[B] for RunDSL[NNF[B], B] {
[error] |^
[error] |An implicit class may not be top-level
[error] 94 | override def runDSL(b: NNF[B]): B = b.terminal
[error] 95 |}
This seems like a strange inconsistency.
Metadata
Metadata
Assignees
Labels
No labels