Signed-off-by: Niklas Hambuechen <[email protected]>
---
 src/Ganeti/JSON.hs | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/src/Ganeti/JSON.hs b/src/Ganeti/JSON.hs
index 5f58682..111d994 100644
--- a/src/Ganeti/JSON.hs
+++ b/src/Ganeti/JSON.hs
@@ -424,6 +424,10 @@ class ArrayObject a where
 -- | A Maybe newtype that allows for serialization more appropriate to the
 -- semantics of Maybe and JSON in our calls. Does not produce needless
 -- and confusing dictionaries.
+--
+-- In particular, `J.JSNull` corresponds to `Nothing`.
+-- This also means that this `Maybe a` newtype should not be used with `a`
+-- values that themselves can serialize to `null`.
 newtype MaybeForJSON a = MaybeForJSON { unMaybeForJSON :: Maybe a }
   deriving (Show, Eq, Ord)
 instance (J.JSON a) => J.JSON (MaybeForJSON a) where
-- 
2.1.0.rc2.206.gedb03e5

Reply via email to