prettyEncodedValue :: DexFile -> EncodedValue -> PP.Doc
prettyEncodedValue dex ev =
  case ev of
    EncodedByte i -> "(int8)" <> PP.int (fromIntegral i)
    EncodedShort i -> "(int16)" <> PP.int (fromIntegral i)
    EncodedChar c -> PP.quotes (PP.char c)
    EncodedInt i -> "(int32)" <> PP.int (fromIntegral i)
    EncodedLong i -> "(int64)" <> PP.integer (fromIntegral i)
    EncodedFloat f -> "(float)" <> PP.float f
    EncodedDouble d -> "(double)" <> PP.double d
    EncodedStringRef sid -> PP.doubleQuotes (getStr' dex sid)
    EncodedTypeRef tid -> getTypeName' dex tid
    EncodedFieldRef fid -> fieldStr dex fid
    EncodedMethodRef mid -> methodStr dex mid
    EncodedEnumRef fid -> fieldStr dex fid
    EncodedArray vs -> PP.brackets $ PP.hcat (PP.punctuate ", " (map (prettyEncodedValue dex) vs))
    EncodedAnnotation a -> prettyAnnotation dex a
    EncodedNull -> "(null)"
    EncodedBool b -> PP.text (show b)
prettyEncodedValue :: DexFile -> EncodedValue -> PP.Doc
prettyEncodedValue dex ev =
  case ev of
    EncodedByte i -> "(int8)" <> PP.int (fromIntegral i)
    EncodedShort i -> "(int16)" <> PP.int (fromIntegral i)
    EncodedChar c -> PP.quotes (PP.char c)
    EncodedInt i -> "(int32)" <> PP.int (fromIntegral i)
    EncodedLong i -> "(int64)" <> PP.integer (fromIntegral i)
    EncodedFloat f -> "(float)" <> PP.float f
    EncodedDouble d -> "(double)" <> PP.double d
    EncodedStringRef sid -> PP.doubleQuotes (getStr' dex sid)
    EncodedTypeRef tid -> getTypeName' dex tid
    EncodedFieldRef fid -> fieldStr dex fid
    EncodedMethodRef mid -> methodStr dex mid
    EncodedEnumRef fid -> fieldStr dex fid
    EncodedArray vs -> PP.brackets $ PP.hcat (PP.punctuate ", " (map (prettyEncodedValue dex) vs))
    EncodedAnnotation a -> prettyAnnotation dex a
    EncodedNull -> "(null)"
    EncodedBool b -> PP.text (show b)
prettyEncodedValue dex ev =
  case ev of
    EncodedByte i -> "(int8)" <> PP.int (fromIntegral i)
    EncodedShort i -> "(int16)" <> PP.int (fromIntegral i)
    EncodedChar c -> PP.quotes (PP.char c)
    EncodedInt i -> "(int32)" <> PP.int (fromIntegral i)
    EncodedLong i -> "(int64)" <> PP.integer (fromIntegral i)
    EncodedFloat f -> "(float)" <> PP.float f
    EncodedDouble d -> "(double)" <> PP.double d
    EncodedStringRef sid -> PP.doubleQuotes (getStr' dex sid)
    EncodedTypeRef tid -> getTypeName' dex tid
    EncodedFieldRef fid -> fieldStr dex fid
    EncodedMethodRef mid -> methodStr dex mid
    EncodedEnumRef fid -> fieldStr dex fid
    EncodedArray vs -> PP.brackets $ PP.hcat (PP.punctuate ", " (map (prettyEncodedValue dex) vs))
    EncodedAnnotation a -> prettyAnnotation dex a
    EncodedNull -> "(null)"
    EncodedBool b -> PP.text (show b)