summaryrefslogtreecommitdiff
path: root/pkg
diff options
context:
space:
mode:
authorMichael Forney <mforney@mforney.org>2019-03-19 01:07:28 -0700
committerMichael Forney <mforney@mforney.org>2019-03-19 01:07:28 -0700
commitf9a9ca97042e50b283f940cdad73f1edd9344957 (patch)
treedfdc0b7886a3e00eece1f7885b714603299f3cb1 /pkg
parent10a498f912d67a62c960035c005f3cd6990e8ac6 (diff)
bc: Update to 1.2.0
Diffstat (limited to 'pkg')
-rw-r--r--pkg/bc/config.h4
-rw-r--r--pkg/bc/patch/0001-Fix-a-bug.patch25
-rw-r--r--pkg/bc/patch/0002-Fix-EOF-behavior-in-interactive-mode-with-history.patch34
m---------pkg/bc/src0
-rw-r--r--pkg/bc/ver2
5 files changed, 3 insertions, 62 deletions
diff --git a/pkg/bc/config.h b/pkg/bc/config.h
index 1c37fdff..1c408e19 100644
--- a/pkg/bc/config.h
+++ b/pkg/bc/config.h
@@ -3,6 +3,6 @@
#define BC_ENABLE_EXTRA_MATH 1
#define BC_ENABLE_HISTORY 1
-#define BC_ENABLE_REFERENCES 1
+#define BC_ENABLE_NLS 0
#define BC_ENABLE_SIGNALS 1
-#define BC_NUM_KARATSUBA_LEN 32
+#define BC_NUM_KARATSUBA_LEN 64
diff --git a/pkg/bc/patch/0001-Fix-a-bug.patch b/pkg/bc/patch/0001-Fix-a-bug.patch
deleted file mode 100644
index 4fa20bef..00000000
--- a/pkg/bc/patch/0001-Fix-a-bug.patch
+++ /dev/null
@@ -1,25 +0,0 @@
-From b8e4f427c41a66b272a04ef2506020e64504b443 Mon Sep 17 00:00:00 2001
-From: Gavin Howard <yzena.tech@gmail.com>
-Date: Wed, 20 Feb 2019 09:27:30 -0700
-Subject: [PATCH] Fix a bug
-
----
- src/read.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/read.c b/src/read.c
-index 43fa8e12..45237397 100644
---- a/src/read.c
-+++ b/src/read.c
-@@ -118,7 +118,7 @@ BcStatus bc_read_line(BcVec *vec, const char *prompt) {
- if (bc_read_binary(vec->v, vec->len - 1))
- return bc_vm_verr(BC_ERROR_VM_BIN_FILE, bc_program_stdin_name);
-
-- return BC_STATUS_SUCCESS;
-+ return s;
- }
-
- BcStatus bc_read_file(const char *path, char **buf) {
---
-2.21.0
-
diff --git a/pkg/bc/patch/0002-Fix-EOF-behavior-in-interactive-mode-with-history.patch b/pkg/bc/patch/0002-Fix-EOF-behavior-in-interactive-mode-with-history.patch
deleted file mode 100644
index e7fdefa7..00000000
--- a/pkg/bc/patch/0002-Fix-EOF-behavior-in-interactive-mode-with-history.patch
+++ /dev/null
@@ -1,34 +0,0 @@
-From bbaac8ed0fc40acc4349df837abed2af72276f52 Mon Sep 17 00:00:00 2001
-From: Michael Forney <mforney@mforney.org>
-Date: Wed, 6 Mar 2019 00:52:01 -0800
-Subject: [PATCH] Fix EOF behavior in interactive mode with history
-
-Previously, Ctrl-D would re-process the previous line, read one
-more line, then exit. This is because bc_history_line left the
-buffer untouched in case of EOF, and the bc_vm_stdin loop reads the
-next line before checking the `done` condition of the previous
-iteration.
-
-This fix also prevents reading passed the end of the buffer in case
-the first user input is EOF, since in that case, vec->len is still
-0, so (size_t)-1 is passed to bc_read_binary.
----
- src/history/history.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/src/history/history.c b/src/history/history.c
-index e9953ed5..d575256d 100644
---- a/src/history/history.c
-+++ b/src/history/history.c
-@@ -1229,7 +1229,7 @@ BcStatus bc_history_line(BcHistory *h, BcVec *vec, const char *prompt) {
- if (BC_TTYIN && !vm->history.badTerm) {
-
- s = bc_history_raw(h, prompt);
-- if (s) return s;
-+ if (s && s != BC_STATUS_EOF) return s;
-
- bc_vec_string(vec, BC_HISTORY_BUF_LEN(h), h->buf.v);
-
---
-2.21.0
-
diff --git a/pkg/bc/src b/pkg/bc/src
-Subproject 6fe912a279b71d6591a0cad1d3d8a2ce1613815
+Subproject 04a2b152d3b788641d4cfe69f186d11c1f03f4c
diff --git a/pkg/bc/ver b/pkg/bc/ver
index 1c0625aa..f9221692 100644
--- a/pkg/bc/ver
+++ b/pkg/bc/ver
@@ -1 +1 @@
-1.1.4 r0
+1.2.0 r0