eteq/astropy — pull request #6 by taldcroft (2012-12-04 02:50:01+00:00)
Title: Modified approach for time init additions

Good idea to allow for initializing the Time object with an existing Time object.

There is an existing method `Time.replicate(self, format, copy)` that makes a reference copy or deep copy (copy=True) of a Time object. I used this method within a new `Time.__new__` method to take care of the copying bit when `val` is a `Time` object. The main benefit of this approach is that all the other `Time` initialization keywords will now function as expected, i.e. `format`, `scale`, `precision`, and so on.

Also added code to do the same in `TimeDelta`.