h&]L*      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXY Z [ \ ] ^ _ ` a b c d e f g h i j k l m n o p q r s t u v w x y z { | } ~                                                                                                                                                                                                                                                                      ! Safe-Inferred%()/0145789:;<=>?<binrep?The length in bytes of any value of the given type is constant.Many binary representation primitives are constant, or store their size in their type. This is a stronger statement about their length than BLen. Safe-Inferred%()/0145789:;<=>?binrep"A hex bytestring looks like this: 00 01 89 8a FEff. You can mix and match capitalization and spacing, but I prefer to space each byte, full caps.binrepParse a byte formatted as two hex digits e.g. EF. You _must_ provide both nibbles e.g. 0F, not F. They cannot be spaced e.g. E F is invalid.Returns a value 0-255, so can fit in any Num type that can store that.binrepPretty print to default format  00 12 AB FF': space between each byte, all caps.This format I consider most human readable. I prefer caps to draw attention to this being data instead of text (you don't see that many capital letters packed together in prose). binrep!Pretty print to "compact" format 0012abff (often output by hashers).    Safe-Inferred&()/0145789:;<=>?KbinrepCommon type error string for when GHC attempts to derive an binrep instance for a (the?) void datatype V1.binrep/How to turn a constructor name into a byte tag.binrep? without the value (only used as a proxy). Lets us push our s into one place. Safe-Inferred&()/0145789:;<=>? binrepI don't know how to pattern match in types without writing type families. Safe-Inferred&()/0145789:;<=>?]binrep=A type that can be parsed from binary given some environment.Making this levity polymorphic makes things pretty strange, but is useful. See Binrep.Example.FileTable. binrep-Parse from binary with the given environment."binrepParse from binary.+binrepParse heterogeneous lists in order. No length indicator, so either fails or succeeds by reaching EOF. Probably not what you usually want, but sometimes used at the "top" of binary formats. !"#$%&#!"$% & Safe-Inferred&()/0145789:;<=>?1binrep$Any datatype, constructor or record.2binrep,Refuse to derive instance for void datatype.3binrep$Product type fields are consecutive.4binrepField.5binrepEmpty constructor.6binrep3Bad. Need to wrap this like SumFromString in Aeson.8binrep4Constructor sums are differentiated by a prefix tag.,-./00./,- Safe-Inferred%()/0145789:;<=>?9binrep+Put with inlined checks via an environment.:binrep:Attempt to serialize to binary with the given environment.<binrepSerialize to binary.>binrepRun the serializer.@binrepHelper for wrapping a BinRep into a  BinRepWith (for encoding).Abinrep.Run the serializer with the given environment.DbinrepSerialize the bytestring as-is.Careful -- the only way you're going to be able to parse this is to read until EOF.FbinrepSerialize each element in order. No length indicator, so parse until either error or EOF. Usually not what you want, but sometimes used at the "top" of binary formats. 9:;<=>?@A =;<>?9:@A Safe-Inferred&()/0145789:;<=>?Hbinrep2Get the name of the constructor of a sum datatype.Obinrep$Any datatype, constructor or record.Pbinrep,Refuse to derive instance for void datatype.Qbinrep$Product type fields are consecutive.RbinrepField.SbinrepEmpty constructor.Xbinrep4Constructor sums are differentiated by a prefix tag.HIJKLMNNLMJKHI  Safe-Inferred%()/0145789:;<=>?Ybinrep Byte order.Zbinrep2big endian, MSB first. e.g. most network protocols[binrep;little endian, MSB last. e.g. most processor architecturesY[ZY[Z  Safe-Inferred&()/0145789:;<=>? abinrep Convert some  i where i >= 0 to a .,This is intended for wrapping the output of  functions.*underflows if you call it with a negative  :)`ab`ab  Safe-Inferred'()/0145789:;<=>?!ebinrep'Efficiently reify a list of type-level Bytes to a bytestring builder.This is about as far as one should go for pointless performance here, I should think.cdefghihigefcd  Safe-Inferred%()/0145789:;<=>?&binrepHelper definitions for using the given type to store byte lengths.Byte lengths must be non-negative. Thus, the ideal representation is a .. However, most underlying types that we use ( ! , lists) store their length in s. By similarly storing an 6 ourselves, we could potentially improve performance.I like both options, and don't want to give up either. So we provide helpers via a typeclass so that the user doesn't ever have to think about the underlying type.+For simplicity, documentation may consider a to be an "unsigned" type. For example, underflow refers to a negative a result.binrep!Safe blen subtraction, returning  for negative results.Regular subtraction should only be used when you have a guarantee that it won't underflow.binrep Convert some  i where i >= 0 to a blen.,This is intended for wrapping the output of  functions.binrep Convert some  w where w <= maxBound  a@ to a blen.binrep Convert some  n where n <= maxBound  a@ to a blen.  Safe-Inferred&()/0145789:;<=>?*binrepThe length in bytes of a value of the given type can be known on the cheap e.g. by reading a length field, or using compile time information.Concepts such as null padding require the notion of length in bytes in order to handle. In a hand-rolled parser, you may keep count of the current length as you go. Here, the individual types keep track, and expose it via this typeclass..Obtaining the length of a value is usually an O(1) operation like reading a field or returning a constant. When it's not, it's often an indicator of a problematic type e.g. plain Haskell lists.We derive a default instance for constant-size types by throwing away the value and reifying the type level natural. Note that one can derive a free  instance for any type with a Put instance via serializing it and checking the length. _Do not do this._ If you find you can't write a decent  instance for a type, it may be that you need to rethink the representation.binrep6Reify a type's constant byte length to the term level.binrep O(n)  Safe-Inferred&()/0145789:;<=>?,Pbinrep$Any datatype, constructor or record.binrep,Refuse to derive instance for void datatype.binrep$Product type fields are consecutive.binrepField.binrepEmpty constructor.binrep4Constructor sums are differentiated by a prefix tag." Safe-Inferred%()/0145789:;<=>?, !"#$%&9:;<=>?@A Safe-Inferred&()/0145789:;<=>?-C Safe-Inferred&!()/0145789:;<=>?- Safe-Inferred&!()/0145789:;<=>?/binrepSafety: we assert actual length is within expected length (in order to calculate how much padding to parse).Note that the consumer probably doesn't care about the content of the padding, just that the data is chunked correctly. I figure we care about correctness here, so it'd be nice to know about the padding well-formedness (i.e. that it's all nulls).(TODO maybe better definition via isolatebinrep=The size of some null-padded data is known - at compile time! Safe-Inferred&()/0145789:;<=>?0e Safe-Inferred&()/0145789:;<=>?1binrep+Forces magic values to be individual bytes.6TODO improve show - maybe hexbytestring goes here? lolbinrep+Forces magic values to be individual bytes.binrep*Assumes magic values are individual bytes.binrep*Assumes magic values are individual bytes. Safe-Inferred&()/0145789:;<=>?5 binrep Restricted reflected version of maxBound.binrep Shortcut.binrepGrouping for matching a signedness and size to a Haskell integer data type.binrep(Machine integer size in number of bytes.binrepMachine integer sign.binrepsignedbinrepunsignedbinrepWrapper type grouping machine integers (sign, size) along with an explicit endianness.The internal representation is selected via a type family to correspond to the relevant Haskell data type, so common overflow behaviour should match. We derive lots of handy instances, so you may perform regular arithmetic on pairs of these types. For example:255 + 1 :: I 'U 'I1 e0255 + 1 :: I 'U 'I2 e256binrep5Signed machine integers can be idealized as integers.binrep7Unsigned machine integers can be idealized as naturals.None'()/0145789:;<=>?6binrepHoly shit - no need to do a smart constructor, it's simply impossible to instantiate invalid values of this type! Safe-Inferred'!()/0145789:;<=>?9binrep;A bytestring using the given representation, stored in the Text type.binrepBytestring representation.binrepC-style bytestring. Arbitrary length, terminated with a null byte. Permits no null bytes inside the bytestring.binrepPascal-style bytestring. Length defined in a prefixing integer of given size and endianness.binrep5A C-style bytestring must not contain any null bytes. Safe-Inferred(!()/0145789:;<=>?AUbinrep Decode a  ByteString to  with an explicit encoding.;This is intended to be used with visible type applications.binrep?DQbinrepObtain the tag for a sum type value by applying a function to the constructor name, and reading the result as a hexadecimal number.binrep8Successfully parse exactly one result, or runtime error.binrepObtain the tag for a sum type value using the constructor name directly (with a null terminator).This is probably not what you want in a binary representation, but it's safe and may be useful for debugging.The refine force is safe under the assumption that Haskell constructor names are UTF-8 with no null bytes allowed. I haven't confirmed that, but I'm fairly certain. 0N N0 Safe-Inferred&()/0145789:;<=>?FbinrepA  represented in binary as an ASCII string, where each character a is a digit in the given base (> 1). instances display the stored number in the given base. If the base has a common prefix (e.g. 0x for hex), it is used.binrep Compare two s with arbitrary bases.binrepThe bytelength of an  is the number of digits in the number in the given base. We can calculate this generically with great efficiency using GHC primitives. Safe-Inferred%()/0145789:;<=>?GA   Safe-Inferred'()/0145789:;<=>?G   Safe-Inferred%()/0145789:;<=>?IbinrepThe naturals in tars are sized octal ASCII digit strings that end with a null byte (and may start with leading ASCII zeroes). The size includes the terminating null, so you get n-1 digits. What a farce.Don't use this constructor directly! The size must be checked to ensure it fits.binrepNo need to check for underflow etc. as TarNat guarantees good sizing.   Safe-Inferred%()/0145789:;<=>?Jw Safe-Inferred&()/0145789:;<=>?K  Safe-Inferred%()/0145789:;<=>?K# Safe-Inferred&()/0145789:;<=>?L$%&&'()*+,-./01234567789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz { | } ~                                                                                                                                                                                                                                                                                                       ########binrep-0.2.0-inplace Binrep.CBLenBinrep.Extra.HexByteStringBinrep.Generic.InternalBinrep.Generic.CBLen Binrep.GetBinrep.Generic.Get Binrep.PutBinrep.Generic.PutBinrep.Type.Common Binrep.UtilBinrep.Type.ByteBinrep.BLen.Internal.AsBLen Binrep.BLenBinrep.Generic.BLenBinrep.Type.VectorBinrep.Type.SizedBinrep.Type.NullPaddedBinrep.Type.Magic.UTF8Binrep.Type.MagicBinrep.Type.IntBinrep.Type.LenPfxBinrep.Type.ByteStringBinrep.Type.TextBinrep.GenericBinrep.Type.AsciiNatBinrep.Example.WavBinrep.Example.TiffBinrep.Example.TarBinrep.Example.FileTableBinrep.ExampleData.Aeson.Extra.SizedVectorB ByteStringBinrep Paths_binrepCBLen HexByteStringHexunHexparseHexByteString parseHexByteprettyHexByteString prettyHexByteprettyHexByteStringCompact $fToJSONHex $fFromJSONHex $fShowHex $fToJSONHex0$fFromJSONHex0 $fShowHex0 $fGenericHex $fDataHex$fEqHexGErrRefuseVoidCfgcSumTagconName'NothingXJustXGCBLenCaseMaybeMaybeEq GCBLenSumGCBLen CBLenGenericGetWithgetWithGetgetGetterrunGet runGetter runGetWith $fGetInt8 $fGetWord8$fGetByteString$fGet(,)$fGet[]GGetSumggetsumGGetgget getGeneric $fGGetkM1 $fGGetkV1 $fGGetk:*: $fGGetkK1 $fGGetkU1 $fGGetSumkM1 $fGGetSumk:+: $fGGetk:+:PutWithputWithPutputBuilderrunPut runBuilder putWithout runPutWith $fPutInt8 $fPutWord8$fPutByteString$fPut(,)$fPut[] $fPutWithr[] GetConName getConNameGPutSumgputsumGPutgput putGeneric $fGPutkM1 $fGPutkV1 $fGPutk:*: $fGPutkK1 $fGPutkU1 $fGPutSumkM1 $fGPutSumk:+:$fGetConNamekM1$fGetConNamek:+: $fGPutk:+: EndiannessBELE$fGenericEndianness$fDataEndianness$fShowEndianness$fEqEndiannesstshow posIntToNatnatVal'' WriteByteVals writeByteValsByteValsbyteValsLengthByteValbyteVal $fByteVal255 $fByteVal254 $fByteVal253 $fByteVal252 $fByteVal251 $fByteVal250 $fByteVal249 $fByteVal248 $fByteVal247 $fByteVal246 $fByteVal245 $fByteVal244 $fByteVal243 $fByteVal242 $fByteVal241 $fByteVal240 $fByteVal239 $fByteVal238 $fByteVal237 $fByteVal236 $fByteVal235 $fByteVal234 $fByteVal233 $fByteVal232 $fByteVal231 $fByteVal230 $fByteVal229 $fByteVal228 $fByteVal227 $fByteVal226 $fByteVal225 $fByteVal224 $fByteVal223 $fByteVal222 $fByteVal221 $fByteVal220 $fByteVal219 $fByteVal218 $fByteVal217 $fByteVal216 $fByteVal215 $fByteVal214 $fByteVal213 $fByteVal212 $fByteVal211 $fByteVal210 $fByteVal209 $fByteVal208 $fByteVal207 $fByteVal206 $fByteVal205 $fByteVal204 $fByteVal203 $fByteVal202 $fByteVal201 $fByteVal200 $fByteVal199 $fByteVal198 $fByteVal197 $fByteVal196 $fByteVal195 $fByteVal194 $fByteVal193 $fByteVal192 $fByteVal191 $fByteVal190 $fByteVal189 $fByteVal188 $fByteVal187 $fByteVal186 $fByteVal185 $fByteVal184 $fByteVal183 $fByteVal182 $fByteVal181 $fByteVal180 $fByteVal179 $fByteVal178 $fByteVal177 $fByteVal176 $fByteVal175 $fByteVal174 $fByteVal173 $fByteVal172 $fByteVal171 $fByteVal170 $fByteVal169 $fByteVal168 $fByteVal167 $fByteVal166 $fByteVal165 $fByteVal164 $fByteVal163 $fByteVal162 $fByteVal161 $fByteVal160 $fByteVal159 $fByteVal158 $fByteVal157 $fByteVal156 $fByteVal155 $fByteVal154 $fByteVal153 $fByteVal152 $fByteVal151 $fByteVal150 $fByteVal149 $fByteVal148 $fByteVal147 $fByteVal146 $fByteVal145 $fByteVal144 $fByteVal143 $fByteVal142 $fByteVal141 $fByteVal140 $fByteVal139 $fByteVal138 $fByteVal137 $fByteVal136 $fByteVal135 $fByteVal134 $fByteVal133 $fByteVal132 $fByteVal131 $fByteVal130 $fByteVal129 $fByteVal128 $fByteVal127 $fByteVal126 $fByteVal125 $fByteVal124 $fByteVal123 $fByteVal122 $fByteVal121 $fByteVal120 $fByteVal119 $fByteVal118 $fByteVal117 $fByteVal116 $fByteVal115 $fByteVal114 $fByteVal113 $fByteVal112 $fByteVal111 $fByteVal110 $fByteVal109 $fByteVal108 $fByteVal107 $fByteVal106 $fByteVal105 $fByteVal104 $fByteVal103 $fByteVal102 $fByteVal101 $fByteVal100 $fByteVal99 $fByteVal98 $fByteVal97 $fByteVal96 $fByteVal95 $fByteVal94 $fByteVal93 $fByteVal92 $fByteVal91 $fByteVal90 $fByteVal89 $fByteVal88 $fByteVal87 $fByteVal86 $fByteVal85 $fByteVal84 $fByteVal83 $fByteVal82 $fByteVal81 $fByteVal80 $fByteVal79 $fByteVal78 $fByteVal77 $fByteVal76 $fByteVal75 $fByteVal74 $fByteVal73 $fByteVal72 $fByteVal71 $fByteVal70 $fByteVal69 $fByteVal68 $fByteVal67 $fByteVal66 $fByteVal65 $fByteVal64 $fByteVal63 $fByteVal62 $fByteVal61 $fByteVal60 $fByteVal59 $fByteVal58 $fByteVal57 $fByteVal56 $fByteVal55 $fByteVal54 $fByteVal53 $fByteVal52 $fByteVal51 $fByteVal50 $fByteVal49 $fByteVal48 $fByteVal47 $fByteVal46 $fByteVal45 $fByteVal44 $fByteVal43 $fByteVal42 $fByteVal41 $fByteVal40 $fByteVal39 $fByteVal38 $fByteVal37 $fByteVal36 $fByteVal35 $fByteVal34 $fByteVal33 $fByteVal32 $fByteVal31 $fByteVal30 $fByteVal29 $fByteVal28 $fByteVal27 $fByteVal26 $fByteVal25 $fByteVal24 $fByteVal23 $fByteVal22 $fByteVal21 $fByteVal20 $fByteVal19 $fByteVal18 $fByteVal17 $fByteVal16 $fByteVal15 $fByteVal14 $fByteVal13 $fByteVal12 $fByteVal11 $fByteVal10 $fByteVal9 $fByteVal8 $fByteVal7 $fByteVal6 $fByteVal5 $fByteVal4 $fByteVal3 $fByteVal2 $fByteVal1 $fByteVal0$fWriteByteVals:$fWriteByteVals[] $fByteValsnsAsBLen safeBLenSub posIntToBLen wordToBLen# natToBLen$fAsBLenNatural $fAsBLenIntBLenblenBLenT typeNatToBLencblen$fBLenByteString $fBLen(,)$fBLen[] $fBLenInt64 $fBLenWord64 $fBLenInt32 $fBLenWord32 $fBLenInt16 $fBLenWord16 $fBLenInt8 $fBLenWord8GBLenSumgblensumGBLengblen blenGeneric $fGBLenkM1 $fGBLenkV1 $fGBLenk:*: $fGBLenkK1 $fGBLenkU1 $fGBLenSumkM1$fGBLenSumk:+: $fGBLenk:+: getVector $fGetVector $fPutVector $fBLenVectorSizedSize$fPredicateTYPESizea $fGetRefined $fPutRefined $fBLenRefined NullPaddedNullPad getNNulls$fPredicateTYPENullPada MagicUTF8symValencodeStringUtf8$fGetMagicUTF8$fPutMagicUTF8$fBLenMagicUTF8$fShowMagicUTF8SymbolAsCharList'SymbolAsCharListCharListUnicodeCodepointsSymbolUnicodeCodepoints MagicValsMagic $fGetMagic $fPutMagic$fGenericMagic $fDataMagic $fShowMagic $fEqMagic $fBLenMagicMaxBoundIMaxIRepISizeI1I2I4I8ISignSUIgetI$fGetI$fPutI$fGetI0$fPutI0$fGetI1$fPutI1$fGetI2$fPutI2$fGetI3$fPutI3$fGetI4$fPutI4$fGetI5$fPutI5$fGetI6$fPutI6$fGetI7$fPutI7$fGetI8$fPutI8$fGetI9$fPutI9$fGetI10$fPutI10$fGetI11$fPutI11$fGetI12$fPutI12 $fStrengthenI $fWeakenI$fStrengthenI0 $fWeakenI0 $fGenericI$fGenericISize $fDataISize $fShowISize $fEqISize$fGenericISign $fDataISign $fShowISign $fEqISign$fBLenI $fFromJSONI $fToJSONI $fIntegralI$fEnumI$fRealI$fNumI $fBoundedI$fOrdI$fEqI$fShowI$fDataILenPfxunLenPfxvsEqasLenPfxlenPfxFromList lenPfxSize getLenPfx $fGetLenPfx $fPutLenPfx $fBLenLenPfx$fStrengthenLenPfx$fWeakenLenPfx $fShowLenPfx $fEqLenPfx$fGenericLenPfx AsByteStringRepCPascal getCString putCString$fPredicateRepPascalByteString$fPredicateRepCByteString $fGetRefined0 $fPutRefined0$fBLenRefined0 $fGenericRep $fDataRep $fShowRep$fEqRepDecodedecodeEncodeAsTextEncodingUTF8UTF16UTF32ASCIISJISencode encodeToRepdecodeViaTextICU$fPredicateEncodingSJISText$fPredicateEncodingASCIIText$fPredicateEncodingUTF32Text$fPredicateEncodingUTF16Text$fPredicateEncodingUTF8Text $fEncodeSJIS $fEncodeUTF32$fEncodeUTF320 $fEncodeUTF16$fEncodeUTF160 $fEncodeASCII $fEncodeUTF8 $fDecodeSJIS $fDecodeUTF32$fDecodeUTF320 $fDecodeUTF16$fDecodeUTF160 $fDecodeUTF8$fGenericEncoding$fDataEncoding$fShowEncoding $fEqEncoding cSumTagHexcSumTagNullTermcDefAsciiNat getAsciiNatasciiNatCompareoctalFromAsciiDigitnatToAsciiBytesasciiBytesToNatdigits $fGetAsciiNat $fPutAsciiNat$fBLenAsciiNat$fShowAsciiNat$fShowAsciiNat0$fShowAsciiNat1$fShowAsciiNat2$fGenericAsciiNat$fDataAsciiNat $fEqAsciiNat $fOrdAsciiNat WavHeaderwavHeaderMagicwavHeaderChunkSize wavHeaderFmtwavHeaderFmtChunkMarkerwavHeaderFmtTypewavHeaderChannelsW16W32E brCfgNoSum$fGetWavHeader$fPutWavHeader$fBLenWavHeader$fGenericWavHeader$fDataWavHeader$fShowWavHeader $fEqWavHeader TiffMagicTiffBody tiffBodyMagic tiffBodyExIntTiffW8tiffLEbstiffBEbs $fGetTiffBody $fPutTiffBody$fBLenTiffBody $fGetTiff $fPutTiff $fBLenTiff $fShowTiff$fGenericTiffBody$fShowTiffBody $fEqTiffBody$fDataTiffBodyTar tarFileName tarFileModetarFileUIDOwnertarFileUIDGrouptarFileFileSizetarFileLastModTarNat getTarNatBS $fGetTarNat $fPutTarNat $fBLenTarNat$fGetTar$fPutTar $fBLenTar $fGenericTar $fShowTar$fEqTar$fGenericTarNat $fShowTarNat $fEqTarNatEntry entryName entryDataTableunTable putFileTable prepEntry getFileTablegetEntryw8i#exBs$fGetWithAddrRepAddr#Entry$fStrengthenEntry $fWeakenEntry $fGetTable $fPutTable$fGenericEntry $fEqEntry $fShowEntry $fEqEntry0 $fShowEntry0DXDCSDCS1DCS2DCS3DCS4DCS5DSSdss1dss2dss3dss4dss5DUDVbrCfgDCS$fGetDU$fPutDU$fBLenDU$fGetDSS$fPutDSS $fBLenDSS$fGetDCS$fPutDCS $fGenericDX$fDataDX$fShowDX$fEqDX $fGenericDCS $fDataDCS $fShowDCS$fEqDCS $fGenericDSS $fDataDSS $fShowDSS$fEqDSS $fGenericDU$fDataDU$fShowDU$fEqDU $fGenericDV$fDataDV$fBLenDX $fBLenDCS$fFromJSONVector$fToJSONVectorbase GHC.GenericsconNameGHC.Err undefinedghc-prim GHC.TypesInt ghc-bignumGHC.Num.NaturalNatural Data.Foldablelength GHC.MaybeNothingGHC.PrimWord#D:R:CBLenRefinedD:R:CBLenMagic text-1.2.5.0Data.Text.InternalTextencode' decodeTextByteswrapUnsafeDecoderencodeViaTextICU forceReadGHC.ShowShowversiongetDataFileName getBinDir getLibDir getDynLibDir getDataDir getLibexecDir getSysconfDir