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

Subclassing ClassfileAnnotation emits non-sensical warning message #6991

Closed
scabug opened this issue Jan 18, 2013 · 3 comments
Closed

Subclassing ClassfileAnnotation emits non-sensical warning message #6991

scabug opened this issue Jan 18, 2013 · 3 comments
Assignees
Milestone

Comments

@scabug
Copy link

scabug commented Jan 18, 2013

Subclassing annotation.ClassfileAnnotation ...

class Foo extends annotation.ClassfileAnnotation

... emits the following, misleading warning:

Implementation restriction: subclassing Classfile does not make your
annotation visible at runtime. If that is what you want,
you must write the annotation class in Java.

A) Um yes? ... That's exactly as intended. That's why the class is called ClassfileAnnotation and not RuntimeAnnotation.
B) The class is called ClassfileAnnotation, not Classfile.

If we had a non-functional RuntimeAnnotation somewhere in the library, the warning would make sense, but like this, it doesn't.

@scabug
Copy link
Author

scabug commented Jan 18, 2013

Imported From: https://issues.scala-lang.org/browse/SI-6991?orig=1
Reporter: @soc
Affected Versions: 2.10.0, 2.11.0-M1

@scabug
Copy link
Author

scabug commented Jan 18, 2013

@soc said:
scala/scala#1924

@scabug
Copy link
Author

scabug commented Oct 25, 2014

@soc said:
Merged in scala/scala@382b33e

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

No branches or pull requests

2 participants