-
-
Notifications
You must be signed in to change notification settings - Fork 528
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Error out on nil returns from MarshalTOML/MarshalText
encoding/json encodes it as "", but IMHO that's confusing, and since it would generate invalid TOML before (`keyname =`) it's okay to change this to an error. Another alternative might be to skip the field if the return value is nil, but that's probably also a bit confusing in some cases, and we can change error to skip in the future and remain compatible, but we can't do the reverse.
- Loading branch information
Showing
2 changed files
with
44 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters