[nomaster] SI-7733 reflective packages now more consistent with scalac

Previously PackageScopes from scala.reflect ignored all classes that
had $'s in non-rightmost positions in their names.

Unfortunately this behaviour is inconsistent with how scalac does things,
and I reconciled this as usual, by pulling corresponding logic into
scala-reflect.jar and sharing it between runtime reflection and compiler.

This change has seprate pull requests for 2.10.x and 2.11.0. The latter
deprecates `scala.tools.nsc.util.ClassPath.isTraitImplementation`
whereas the former (which you're looking at right now) does not, because
we can't deprecated members in minor releases.
Merge pull request #2809 from xeno-by/ticket/7733

SI-7733 reflective packages now more consistent with scalac
SI-7694 @uncheckedBounds, an opt-out from type bounds checking

Synthetic defs introduced by transforms like named/default arguments,
ANF (in scala-async) often introduce a type tree (the tpt of the temporary)
that are based on the types of expressions. These types are scrutinized in
RefChecks to check that type parameter bounds are satisfied.

However, the type of the expression might be based on slack a LUB that
fails to capture constraints between type parameters.

This slackness is noted in `mergePrefixAndArgs`:

    // Martin: I removed this, because incomplete. Not sure there is a
    // good way to fix it. For the moment we just err on the conservative
    // side, i.e. with a bound that is too high.

The synthesizer can now opt out of bounds by annotating the type as follows:

   val temp: (<expr.tpe> @uncheckedBounds) = expr

This facility is now used in named/default arguments for the temporaries
used for the reciever and arguments.

The annotation is hidden under scala.reflect.internal, rather than in
the more prominent scala.annotation.unchecked, to reflect the intention
that it should only be used in tree transformers.

The library component of this change and test case will be included in the
next commit. Why split like this? It shows that the 2.10.3 compiler will
work with 2.10.2 scala-reflect.jar.
SI-7694 Add @uncheckedBounds to the library

Followup to the previous commit that added the compiler support
for opting out of bounds checking.

With both pieces, we can test that the temporaries introduced
by the named/default arguments transform don't trigger bounds
violations.
Merge pull request #2826 from retronym/ticket/7020-2.10.x

SI-7020 Determinism for pattern matcher warnings
Merge pull request #2828 from adriaanm/rebase-2771

[Rebase #2771] SI-7694 @uncheckedBounds, an opt-out from type bounds checking
SI-7014 Annot arg may refer to annotated class's member

This only reduces the crasher to a warning.
Merge pull request #2829 from adriaanm/ticket-7014

SI-7014 Annot arg may refer to annotated class's member
SI-7752 Don't disambiguate type parameters of overloaded alts

These are passed through from `InferencerContextErrors#applyErrorMsg`
to `withDisambiguation` as the `locals` parameter, which is promptly
ignored. This looks to be an unintended change in 39938bcc299.

Without this patch, the enclosed test case enters a pathalogical
disambiguation session, that not only flirts with unpleasant big-O
complexities, but also flails about appending "(in method foo)"
only to find that *all* occurences of the same-named type parameter
come from some method named "foo".

    [snipping error message 40 seconds in the making]
    method foo), O(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo), P(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo), Q(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo), R(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo), S(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo), T, U(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo)(in method foo), V)
     cannot be applied to (Int)
      foo((1))