go-yaml/yaml — pull request #58 by ghodss (2014-11-25 10:37:35+00:00)
Title: Don't call MarshalText() if MarshalYAML() has been called

I found a really nasty bug where, if you have an object that implements both yaml.Unmarshaler and encoding.TextMarshaler, both are called back-to-back, creating incorrect output. This patch fixes it, with tests, and without breaking any existing tests.