diff options
-rw-r--r-- | src/Data/BEncode/Types.hs | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/Data/BEncode/Types.hs b/src/Data/BEncode/Types.hs index e505249..fae90fe 100644 --- a/src/Data/BEncode/Types.hs +++ b/src/Data/BEncode/Types.hs | |||
@@ -20,13 +20,19 @@ import Data.ByteString | |||
20 | 20 | ||
21 | import Data.BEncode.BDict | 21 | import Data.BEncode.BDict |
22 | 22 | ||
23 | 23 | -- | A bencode "integer". | |
24 | type BInteger = Integer | 24 | type BInteger = Integer |
25 | |||
26 | -- | A raw bencode string. | ||
25 | type BString = ByteString | 27 | type BString = ByteString |
28 | |||
29 | -- | A plain bencode list. | ||
26 | type BList = [BValue] | 30 | type BList = [BValue] |
31 | |||
32 | -- | A bencode dictionary. | ||
27 | type BDict = BDictMap BValue | 33 | type BDict = BDictMap BValue |
28 | 34 | ||
29 | -- | 'BEncode' is straightforward ADT for b-encoded values. Please | 35 | -- | 'BValue' is straightforward ADT for b-encoded values. Please |
30 | -- note that since dictionaries are sorted, in most cases we can | 36 | -- note that since dictionaries are sorted, in most cases we can |
31 | -- compare BEncoded values without serialization and vice versa. | 37 | -- compare BEncoded values without serialization and vice versa. |
32 | -- Lists is not required to be sorted through. | 38 | -- Lists is not required to be sorted through. |