You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Given the following foo.jaif (attached):
---------------------------------------
package java.lang:
annotation @SuppressWarnings:
String[] value
package pkg:
class foo:
field a: @SuppressWarnings({"bar"})
field b: @SuppressWarnings({"bar"})
---------------------------------------
and the following pkg/foo.java (attached):
---------------------------------------
package pkg;
public class foo
{
volatile int a, b;
}
---------------------------------------
I would expect the call to
insert-annotations-to-source -i foo.jaif pkg/foo.java
(synced on April 2, 2014 and run on Fedora 19 64-bit)
to produce
----------------------------------
package pkg;
import java.lang.SuppressWarnings;
public class foo
{
@SuppressWarnings({"bar"})
volatile int a, b;
}
----------------------------------
Instead, the following output is produced, which results in the following
compilation error:
"foo.java:6: error: duplicate annotation"
------------------------------------------------------------------------
package pkg;
import java.lang.SuppressWarnings;
public class foo
{
volatile @SuppressWarnings({"bar"}) @SuppressWarnings({"bar"}) int a, b;
}
------------------------------------------------------------------------
Original issue reported on code.google.com by jtha...@cs.washington.edu on 10 Apr 2014 at 5:21
Original issue reported on code.google.com by
jtha...@cs.washington.edu
on 10 Apr 2014 at 5:21Attachments:
The text was updated successfully, but these errors were encountered: