johnwahba / go-tour

Automatically exported from code.google.com/p/go-tour
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

step #49 - should Abs() not return a MyFloat? #54

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
On step 49 of the tour, would it not make more sense for Abs() to return a 
MyFloat instead of a float64?

This is a super-minor issue and is arguably down to personal taste, but it 
would make the example simpler since the cast to float64 would not be required.

Original issue reported on code.google.com by sean.mcl...@gmail.com on 14 Jan 2013 at 10:06

Attachments:

GoogleCodeExporter commented 9 years ago
No. Then it wouldn't satisfy the Abser interface.

Original comment by a...@golang.org on 30 May 2013 at 12:44