angular/angular.js — pull request #10502 by caitp (2014-12-17 15:08:28+00:00)
Title: fix($compile): respect return value from controller constructor

The return value of the controller constructor is now respected in all cases.

If controllerAs is used, the controller will be re-bound to scope. If bindToController is used, the previous binding $watches (if any) will be unwatched, and bindings re-installed on the new controller.

Blocked on #10467 --- This potentially results in leaks and performance regressions, good review is needed here.