Fixing annotations

Two fixes:

1) Annotation#symbol now returns the correct annotations for classes as well as traits.
2) Typer copies annotations from Modifiers to Symbols
Fix lazy vals tests broken by previous commit.
Port LazyVals to use hasAnnotation.

Instead of by-hand testing of modifier type.
Merge pull request #118 from dotty-staging/fix/annotations

Fixing annotations
Allow phases to give restrictions on pipeline position.

Phases can now specify which phases should it follow.
Tree transforms can additionally specify which TreeTransforms
should have finished their processing of compilation units entirely.
SymDenotation.isEffectivelyFinal

Helper method that tests weather this particular
SymDenotation cant have overrides: eg if it's defined in module class,
if it is inner method, if it is method of anonymous class, etc.
Allow closures to take type parameters.

This shouldn't require any changes to backend,
as all type parameters will be erased in erasure

Conflicts:
	src/dotty/tools/dotc/core/Symbols.scala
Sbt: simplify debugging and tracing
TailRec phase and tests for it.

Ported tailcall phase from scalac with such changes:
  - all transformation is done in the phase itself
     (previously half of the work was done in backend)
  - it is now able to run before uncurry
  - it is now a treeTransform
  - renamed to tailrec to make it more obvious that
     this phase transforms only recursive calls.

For now this is a single phase which speculatively
transforms DefDefs.
Speculation can be potentially removed by
splitting into 2 phases:
  one detecting which methods should be transformed
  second performing transformation.

But, as transformation requires as same amount of work
as detection, I believe it will be simpler to maintain
it as a single phase.

Conflicts:
	tests/pos/typers.scala
Merge pull request #117 from DarkDimius/tailrec

TailRec phase and tests for it.
Merge pull request #111 from DarkDimius/phase-req

Allow phases to give restrictions on pipeline position.
Make mkArityArray work for classes outside "scala" package
Fix error in bridges.

Do not discard non-bridge methods
Fix mkArityArray not producing last arity
Merge pull request #120 from DarkDimius/backend-backport

Backend backport
Fixing prefix of implicit members

Implicit members are TermRefs that should have a prefix corresponding to the object of which they are a member. They used to have the ThisType of their owner before.

`implicits2` provides a way to verify that the change works. It would be good to turn this
into a more robust test at some point.  But it's not high preiority, so I prefer no test to a fragile test.
Members of stable methods

Stable methods are introduced from getters by inserting () parameters.
This change makes sure that adding () does not lose the members of an
ExprType.

Also, avoid spurious stale symbol errors in loadDenot. When something is not
a SymDenotation, no use retrying in first phase; current would fail immediately.
InfoTransformers as specific DenotTransformers

Factored out denot transformer behavior where the we transform types
in a uniform way into InfoTransformers.
ByNameTypeTree is a TypTree.

Was an oversight before.
Fix to Select(Tree, Symbol)

As a denotation need to take the symbol's info *as seen from
the qualifier type*.