···11+# ChangeLog
22+33+## 2.1.0 - 2025-08-03
44+55+### Changed
66+77+- when fields are CHOICEs now both the field name and the choice name are shown (fixes GitHub #102)
88+- upgrade minimum NodeJS version supported from 12.20.0 to 14.6.0 due to usage of ?. and ?? operators in defs.js (ECMAScript 2020); older code is still linted against ECMAScript 2015 for now
99+1010+### Added
1111+1212+- add tests to check expected decoding
1313+1414+## 2.0.6 - 2025-07-29
1515+1616+### Added
1717+1818+- add proper support for standard Base64 (we previously only supported Base64url) (fixes GitHub #99)
1919+- improve test harness
2020+2121+## 2.0.5 - 2025-04-12
2222+2323+### Added
2424+2525+- add `index-local.html` for local `file://` usage without needing a web server
2626+- add definitions support for `LDAPMessage`
2727+- #TODO continue producing old ChangeLog entries
···1313// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
1414// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
15151616-let max = 10000000000000; // biggest 10^n integer that can still fit 2^53 when multiplied by 256
1616+/** Biggest 10^n integer that can still fit 2^53 when multiplied by 256. */
1717+const max = 10000000000000;
17181819export class Int10 {
1920 /**
···26272728 /**
2829 * Multiply value by m and add c.
2929- * @param {number} m - multiplier, must be < =256
3030- * @param {number} c - value to add
3030+ * @param {number} m - multiplier, must be 0<m<=256
3131+ * @param {number} c - value to add, must be c>=0
3132 */
3233 mulAdd(m, c) {
3434+ // assert(m > 0)
3335 // assert(m <= 256)
3636+ // assert(c >= 0)
3437 let b = this.buf,
3538 l = b.length,
3639 i, t;
···71747275 /**
7376 * Convert to decimal string representation.
7474- * @param {*} base - optional value, only value accepted is 10
7777+ * @param {number} [base=10] - optional value, only value accepted is 10
7878+ * @returns {string} The decimal string representation.
7579 */
7676- toString(base) {
7777- if ((base || 10) != 10)
7878- throw 'only base 10 is supported';
8080+ toString(base = 10) {
8181+ if (base != 10)
8282+ throw new Error('only base 10 is supported');
7983 let b = this.buf,
8084 s = b[b.length - 1].toString();
8185 for (let i = b.length - 2; i >= 0; --i)
···8690 /**
8791 * Convert to Number value representation.
8892 * Will probably overflow 2^53 and thus become approximate.
9393+ * @returns {number} The numeric value.
8994 */
9095 valueOf() {
9196 let b = this.buf,
···9710298103 /**
99104 * Return value as a simple Number (if it is <= 10000000000000), or return this.
105105+ * @returns {number | Int10} The simplified value.
100106 */
101107 simplify() {
102108 let b = this.buf;