Details

    • Type: Task Task
    • Status: Closed
    • Priority: Trivial Trivial
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.0-ALPHA
    • Component/s: None
    • Labels:
      None
    • Lucene Fields:
      New, Patch Available

      Description

      as discussed on LUCENE-2084, I think we should be consistent about use of @Deprecated annotations if we are to use it.

      This patch adds the missing annotations... unfortunately i cannot commit this for some time, because my internet connection does not support heavy committing (it is difficult to even upload a large patch).

      So if someone wants to take it, have fun, otherwise in a week or so I will commit it if nobody objects.

      1. LUCENE-2185.patch
        54 kB
        Chris Male
      2. LUCENE-2185_flex.patch
        14 kB
        Robert Muir

        Activity

        Hide
        Chris Male added a comment -

        Attaching patch for Robert.

        Show
        Chris Male added a comment - Attaching patch for Robert.
        Hide
        Steve Rowe added a comment -

        The justification for using @Deprecated, AFAICT, is that conforming compilers are required to issue warnings for each so-annotated class/method, where compilers are not required to issue warnings for javadoc @deprecated tags, and although Sun compilers do this, other vendors' compilers might not.

        Another (similarly theoretical) argument in favor of using @Deprecated annotations is that, unlike @deprecated javadoc tags, this annotation is available via runtime reflection.

        A random information point: MYFACES-2135 removed all @Deprecated annotations from MyFaces code because an apparent bug in the Sun TCK flags methods bearing this annotation as changing method signatures.

        Show
        Steve Rowe added a comment - The justification for using @Deprecated, AFAICT, is that conforming compilers are required to issue warnings for each so-annotated class/method, where compilers are not required to issue warnings for javadoc @deprecated tags, and although Sun compilers do this, other vendors' compilers might not. Another (similarly theoretical) argument in favor of using @Deprecated annotations is that, unlike @deprecated javadoc tags, this annotation is available via runtime reflection. A random information point: MYFACES-2135 removed all @Deprecated annotations from MyFaces code because an apparent bug in the Sun TCK flags methods bearing this annotation as changing method signatures.
        Hide
        Robert Muir added a comment -

        Steven, yeah i know theoretically why this is here, but it is completely stupid.

        @Deprecated is a gigantic mistake, requiring me to write it twice, once lowercase in the javadocs, once uppercase as an annotation. This is the only way to properly deprecate something with a message as to why.

        and so this additional work buys me nothing, except some theoretical workaround to sun's piss-poor broken language design.

        this being said, i still think we should be consistent: either remove all these annotations or add them all, and not just use them 'sometime'.

        Show
        Robert Muir added a comment - Steven, yeah i know theoretically why this is here, but it is completely stupid. @Deprecated is a gigantic mistake, requiring me to write it twice, once lowercase in the javadocs, once uppercase as an annotation. This is the only way to properly deprecate something with a message as to why. and so this additional work buys me nothing, except some theoretical workaround to sun's piss-poor broken language design. this being said, i still think we should be consistent: either remove all these annotations or add them all, and not just use them 'sometime'.
        Hide
        Robert Muir added a comment -

        Committed revision 895342 to trunk.

        I added flex branch here, after the next time trunk is merged to it we should do the same there.

        Show
        Robert Muir added a comment - Committed revision 895342 to trunk. I added flex branch here, after the next time trunk is merged to it we should do the same there.
        Hide
        Robert Muir added a comment -

        patch for flex, also RegexTermsEnum is undeprecated as it was accidentally deprecated in favor of itself.

        Show
        Robert Muir added a comment - patch for flex, also RegexTermsEnum is undeprecated as it was accidentally deprecated in favor of itself.
        Hide
        Robert Muir added a comment -

        Committed revision 899831 to flex

        Show
        Robert Muir added a comment - Committed revision 899831 to flex

          People

          • Assignee:
            Robert Muir
            Reporter:
            Robert Muir
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development