Return err on failure instead of using panic.

Based recommendation from Effective Go (http://golang.org/doc/effective_go.html#errors) libraries should not panic but should return an error value on failure.

I've now left the FromString function alone and have added a New function that returns `*Version, err`