decodePackedBCD overloads

Synopses

Declared in <llvm/Support/BCD.h>

Decode a packed BCD value stored in an integer object.

template<
    typename ResultT,
    typename ValT>
ResultT
decodePackedBCD(
    ValT const Val,
    bool IsSigned = true);

Decode a packed BCD value from a byte buffer.

int64_t
decodePackedBCD(
    uint8_t const* Ptr,
    size_t ByteLen,
    bool IsSigned = true);

Return Value

  • The decoded value converted to ResultT.

  • The decoded signed integer value.

Template Parameters

Name

Description

ResultT

Integer type of the decoded result.

ValT

Type whose object representation holds the packed BCD bytes.

Parameters

Name

Description

Val

Object whose bytes are interpreted as packed BCD.

IsSigned

Whether the last nibble of the last byte is a sign nibble.

Ptr

Packed BCD bytes to decode.

ByteLen

Number of bytes at Ptr. Must be between 1 and 9.

Created with MrDocs