Updated comment for multiply()/finiteFieldMultiply() in C++ and C code.
This commit is contained in:
parent
1a2b0065fe
commit
84dd6f4e07
|
@ -462,7 +462,8 @@ testable void calcReedSolomonRemainder(const uint8_t data[], int dataLen, const
|
|||
}
|
||||
|
||||
|
||||
// Returns the product of the two given field elements modulo GF(2^8/0x11D). All argument values are valid.
|
||||
// Returns the product of the two given field elements modulo GF(2^8/0x11D).
|
||||
// All inputs are valid. This could be implemented as a 256*256 lookup table.
|
||||
testable uint8_t finiteFieldMultiply(uint8_t x, uint8_t y) {
|
||||
// Russian peasant multiplication
|
||||
uint8_t z = 0;
|
||||
|
|
|
@ -283,8 +283,8 @@ class QrCode final {
|
|||
|
||||
/*-- Static function --*/
|
||||
|
||||
// Returns the product of the two given field elements modulo GF(2^8/0x11D). The arguments and result
|
||||
// are unsigned 8-bit integers. This could be implemented as a lookup table of 256*256 entries of uint8.
|
||||
// Returns the product of the two given field elements modulo GF(2^8/0x11D).
|
||||
// All inputs are valid. This could be implemented as a 256*256 lookup table.
|
||||
private: static std::uint8_t multiply(std::uint8_t x, std::uint8_t y);
|
||||
|
||||
};
|
||||
|
|
Loading…
Reference in New Issue