Skip to content

Type Lambdas not accepted in F-Bound expression #8752

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
rssh opened this issue Apr 20, 2020 · 0 comments · Fixed by #11013
Closed

Type Lambdas not accepted in F-Bound expression #8752

rssh opened this issue Apr 20, 2020 · 0 comments · Fixed by #11013

Comments

@rssh
Copy link
Contributor

rssh commented Apr 20, 2020

Minimized code

import scala.collection.IterableOps

trait Arround1[C <:[X]=>>IterableOps[X,C,C[X]] ]

Output

[error] -- [E053] Type Error: /Users/rssh/work/oss/dotty-cps/dotty-cps/src/test/scala/cps/X.scala:3:41 
[error] 3 |trait Arround1[C <:[X]=>>IterableOps[X,C,C[X]] ]
[error]   |                                         ^^^^
[error]   |                                         C/T does not take type parameters
[error] -- Error: /Users/rssh/work/oss/dotty-cps/dotty-cps/src/test/scala/cps/X.scala:3:39 
[error] 3 |trait Arround1[C <:[X]=>>IterableOps[X,C,C[X]] ]
[error]   |                                       ^
[error]   |                  Type argument C/T has not the same kind as its bound [_]
[error] two errors found
[error] (Test / compileIncremental) Compilation failed

Expectation

Compiles. the same as

trait Arround2[C[X] <: IterableOps[X,C,C[X]] ]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants