SI-8862 Fix treatment of inherited implicits in package objects

Two spots in implicit search fell prey to a trap with package
objects. Members of a package object are entered into the scope
of the enclosing package, but that doesn't form a suitable prefix
for determing the member type.

A REPL transcript paints a picture that speaks a 1000 words:

```
scala> :paste -raw
// Entering paste mode (ctrl-D to finish)

package p { class C[A] { def foo: A = ??? }; object `package` extends C[String] }

// Exiting paste mode, now interpreting.

scala> val p = rootMirror.getPackageIfDefined("p")
warning: there was one deprecation warning; re-run with -deprecation for details
p: $r.intp.global.Symbol = package p

scala> p.info.decls
res0: $r.intp.global.Scope = Scopes(class C, package object p, method foo)

scala> val foo = p.info.decl(TermName("foo"))
foo: $r.intp.global.Symbol = method foo

scala> p.typeOfThis memberType foo
res1: $r.intp.global.Type = => A

scala> val fooOwner = foo.owner
fooOwner: $r.intp.global.Symbol = class C

scala> p.info.decl(nme.PACKAGE).typeOfThis memberType foo
res3: $r.intp.global.Type = => String
```

This commit detects if we find an implicit in a package module,
and then uses the self type of the corresponding package object
as the prefix for the `ImplicitInfo`. This is done in both
`Context.implicitss` (which collects in-scope implicits), and
in `companionImplicitMap` (which harvests them from the implicit
scope.) In addition, it was necessary / possible to remove a special
case that excluded package object implicits, the referenced tests for
SI-3999 now pass without this.
While in the vicinity of `insertApply`

```scala
def insertApply(): Tree = {
        assert(!context.inTypeConstructorAllowed, mode) //@M
        val adapted = adaptToName(tree, nme.apply)
        def stabilize0(pre: Type): Tree = stabilize(adapted, pre, MonoQualifierModes, WildcardType)

        // TODO reconcile the overlap between Typers#stablize and TreeGen.stabilize
        val qual = adapted match {
          case This(_) =>
            gen.stabilize(adapted)
          case Ident(_) =>
            val owner = adapted.symbol.owner
            val pre =
              if (owner.isPackageClass) owner.thisType
              else if (owner.isClass) context.enclosingSubClassContext(owner).prefix
              else NoPrefix
            stabilize0(pre)
          case Select(qualqual, _) =>
            stabilize0(qualqual.tpe)
          case other =>
            other
        }
        typedPos(tree.pos, mode, pt) {
          Select(qual setPos tree.pos.makeTransparent, nme.apply)
        }
      }
```

I found the use of `enclosingSubClassContext` suspicious. It was added in ac49199ed. Looking at the old-timey issue it fixed:

http://lrytz.github.io/scala-aladdin-bugtracker/displayItem.do%3Fid=763.html

And then expanding the test case:

```scala
// Test from http://lrytz.github.io/scala-aladdin-bugtracker/displayItem.do%3Fid=763.html


trait Foo { type T; def apply() : T }
object Test {

  val f : Foo = new Foo { type T = Int; def apply() = 42 }

  def main(args: Array[String]): Unit = {
    val g : Foo = new Foo { type T = Int; def apply() = 42 }
    f()
    g()
  }
}
```

The branch that calls `enclosingSubClassContext` is never executed. If the adapted type is class-owned, we'll always end up with a `Select`. Perhaps this wasn't the case back in the halcyon days of Scala 2.2.