Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-6416721

(spec thread) Fix Thread.yield() javadoc

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: P3 P3
    • 7
    • 6
    • core-libs
    • b19
    • generic
    • generic
    • Not verified

        The current spec for Thread.yield

        "Causes the currently executing thread object to temporarily pause and allow other threads to execute."

        is inadequate because
        - there is no guarantee that the thread will or will not pause.
        - if there are idle processors it is unlikely to pause.
        - it should be clearer that this is a hint to the implementation, almost a "no-op".
        - it should be made clear that ordinary application developers should not use this
          method. It is only appropriate in unusual circumstances. That is, it should be
          denigrated.

              chegar Chris Hegarty
              martin Martin Buchholz
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

                Created:
                Updated:
                Resolved:
                Imported:
                Indexed: