langtools/src/share/classes/com/sun/tools/javac/code/Lint.java
changeset 13689 4d519199a6aa
parent 7681 1f0819a3341f
child 14369 3d660d08d1f7
equal deleted inserted replaced
13636:bee2d435e11f 13689:4d519199a6aa
     1 /*
     1 /*
     2  * Copyright (c) 2005, 2010, Oracle and/or its affiliates. All rights reserved.
     2  * Copyright (c) 2005, 2012, Oracle and/or its affiliates. All rights reserved.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     3  * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
     4  *
     4  *
     5  * This code is free software; you can redistribute it and/or modify it
     5  * This code is free software; you can redistribute it and/or modify it
     6  * under the terms of the GNU General Public License version 2 only, as
     6  * under the terms of the GNU General Public License version 2 only, as
     7  * published by the Free Software Foundation.  Oracle designates this
     7  * published by the Free Software Foundation.  Oracle designates this
    68 
    68 
    69     /**
    69     /**
    70      * Returns the result of combining the values in this object with
    70      * Returns the result of combining the values in this object with
    71      * the given annotations.
    71      * the given annotations.
    72      */
    72      */
    73     public Lint augment(List<Attribute.Compound> attrs) {
    73     public Lint augment(Annotations annots) {
    74         return augmentor.augment(this, attrs);
    74         return augmentor.augment(this, annots.getAttributes());
    75     }
    75     }
    76 
    76 
    77     /**
    77     /**
    78      * Returns the result of combining the values in this object with
    78      * Returns the result of combining the values in this object with
    79      * the given annotations and flags.
    79      * the given annotations and flags.
    80      */
    80      */
    81     public Lint augment(List<Attribute.Compound> attrs, long flags) {
    81     public Lint augment(Annotations annots, long flags) {
    82         Lint l = augmentor.augment(this, attrs);
    82         Lint l = augmentor.augment(this, annots.getAttributes());
    83         if ((flags & DEPRECATED) != 0) {
    83         if ((flags & DEPRECATED) != 0) {
    84             if (l == this)
    84             if (l == this)
    85                 l = new Lint(this);
    85                 l = new Lint(this);
    86             l.values.remove(LintCategory.DEPRECATION);
    86             l.values.remove(LintCategory.DEPRECATION);
    87             l.suppressedValues.add(LintCategory.DEPRECATION);
    87             l.suppressedValues.add(LintCategory.DEPRECATION);