Skip to content
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

ClassfileAnnotation: confusing error when argument is implicitly converted #6083

Closed
scabug opened this issue Jul 14, 2012 · 3 comments
Closed

Comments

@scabug
Copy link

scabug commented Jul 14, 2012

classfile annot arg, confusing error message when implicitly converted argument. says "need constant, found X" where X is a constant

object conv {
  implicit def i2s(i: Int): String = ""
}
import conv._
class annot(value: String) extends annotation.ClassfileAnnotation
@annot(101) class C

gives

t5892.scala:6: error: annotation argument needs to be a constant; found: 101
@annot(101) class C
       ^
@scabug
Copy link
Author

scabug commented Jul 14, 2012

Imported From: https://issues.scala-lang.org/browse/SI-6083?orig=1
Reporter: @lrytz

@scabug
Copy link
Author

scabug commented Jan 31, 2013

@paulp said:
76bb23df5e2 in master, will look at 2.10.x

@scabug
Copy link
Author

scabug commented May 17, 2013

@paulp said:
Looks like 2.11 has the exclusive.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants