summaryrefslogtreecommitdiff
path: root/testsuite/dc.tests
AgeCommit message (Collapse)Author
2021-02-26bc/dc: fix length(0) and length(0.000nnn) resultDenys Vlasenko
function old new delta zxc_vm_process 6464 6498 +34 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2019-09-05dc: Parse error & fix out of bounds read in xc_program_printStringBrian Foley
function old new delta xc_program_print 712 735 +23 Signed-off-by: Brian Foley <bpfoley@google.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2019-09-05dc: Fix segfault when executing strings generated using asciifyBrian Foley
function old new delta zxc_vm_process 6884 6891 +7 Signed-off-by: Brian Foley <bpfoley@google.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2019-09-05dc: execute shouldn't pop if stack head is not a stringBrian Foley
This matches the behaviour of both GNU dc (as specified in its man page), and BSD dc (where stack_popstring() pops only if the head is a string.) Add a couple of tests to verify this behavior. function old new delta zxc_vm_process 6882 6884 +2 Signed-off-by: Brian Foley <bpfoley@google.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2019-04-19dc.tests: fix two test case to also depend on DC_BIGChen Qi
Signed-off-by: Chen Qi <Qi.Chen@windriver.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2019-01-04dc: fit returning of stringDenys Vlasenko
function old new delta zxc_program_exec 4087 4098 +11 Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2019-01-04dc: fix '?'Denys Vlasenko
function old new delta zdc_parse_expr 470 479 +9 zxc_vm_process 839 814 -25 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 1/1 up/down: 9/-25) Total: -16 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2018-12-28bc: rename config optionsDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2018-12-25dc: add two testsDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2018-12-22dc: unbreak interactive mode - was trying to get next tokens instead of ↵Denys Vlasenko
executing function old new delta zbc_program_read - 268 +268 zdc_program_printStream - 146 +146 zbc_program_exec 4046 4182 +136 zdc_program_execStr 472 512 +40 zdc_parse_exprs_until_eof - 26 +26 zbc_vm_process 740 765 +25 zbc_lex_next 2225 2240 +15 zdc_parse_expr 569 535 -34 zbc_program_pushArray 147 - -147 zdc_program_asciify 370 - -370 ------------------------------------------------------------------------------ (add/remove: 3/2 grow/shrink: 4/1 up/down: 656/-551) Total: 105 bytes Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2018-12-12testsuite: add bc and dc testsDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2018-12-06dc: fix testsuiteDenys Vlasenko
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
2015-02-16dc: tweak parsingBernhard Reutner-Fischer
https://bugs.debian.org/538685 dc requires whitespace between language elements. We were requiring 1 2 + p instead of the abbreviated 1 2+p (for example). function old new delta stack_machine 97 126 +29 dc_main 117 79 -38 ------------------------------------------------------------------------------ (add/remove: 0/0 grow/shrink: 1/1 up/down: 29/-38) Total: -9 bytes Signed-off-by: Bernhard Reutner-Fischer <rep.dot.nop@gmail.com> Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>