angular/angular.js — pull request #7846 by myitcv (2014-06-16 11:12:36+00:00)
Title: Use source object prototype in object copy

Whilst not strictly necessary for the likes of `$watch` to behave as expected, given that `angular.copy` is exposed it should honour the prototype of the source object such that, as the test ensures:

```javascript
function A() {}
var a = new A();
var a_copy = angular.copy(a);
expect(a_copy instanceof A).toBe(true);
```

Otherwise users of `angular.copy` (read: at least me) end up having to create their own version of `angular.copy` to make this one change.