aboutsummaryrefslogtreecommitdiffstats
path: root/tests/gpgscm/scheme.c
diff options
context:
space:
mode:
authorJustus Winter <[email protected]>2017-03-29 12:11:58 +0000
committerJustus Winter <[email protected]>2017-04-10 12:57:22 +0000
commite7ed9822e20ee4bbb4cdd9eca8121b4ade87e5ce (patch)
treede38638c8d453ea3862b187286a598e86c528926 /tests/gpgscm/scheme.c
parentgpgscm: Merge 'opexe_6'. (diff)
downloadgnupg-e7ed9822e20ee4bbb4cdd9eca8121b4ade87e5ce.tar.gz
gnupg-e7ed9822e20ee4bbb4cdd9eca8121b4ade87e5ce.zip
gpgscm: Remove now obsolete dispatcher function from the opcodes.
* tests/gpgscm/opdefines.h: Remove now obsolete dispatcher function from the opcodes. * tests/gpgscm/scheme-private.h (_OP_DEF): Adapt. * tests/gpgscm/scheme.c (dispatch_func): Remove type declaration. (op_code_info): Remove 'func'. (_OP_DEF): Adapt. (Eval_Cycle): Always call 'opexe_0'. Signed-off-by: Justus Winter <[email protected]>
Diffstat (limited to '')
-rw-r--r--tests/gpgscm/scheme.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/tests/gpgscm/scheme.c b/tests/gpgscm/scheme.c
index f90ac3f5e..07f56edc1 100644
--- a/tests/gpgscm/scheme.c
+++ b/tests/gpgscm/scheme.c
@@ -5213,8 +5213,6 @@ static pointer opexe_0(scheme *sc, enum scheme_opcodes op) {
return sc->T; /* NOTREACHED */
}
-typedef pointer (*dispatch_func)(scheme *, enum scheme_opcodes);
-
typedef int (*test_predicate)(pointer);
static int is_any(pointer p) {
@@ -5265,7 +5263,6 @@ static const struct {
#define TST_NATURAL "\016"
typedef struct {
- dispatch_func func;
const char *name;
int min_arity;
int max_arity;
@@ -5275,7 +5272,7 @@ typedef struct {
#define INF_ARG 0xffff
static const op_code_info dispatch_table[]= {
-#define _OP_DEF(A,B,C,D,E,OP) {A,B,C,D,E},
+#define _OP_DEF(A,B,C,D,OP) {A,B,C,D},
#include "opdefines.h"
#undef _OP_DEF
{ 0 }
@@ -5354,7 +5351,7 @@ static void Eval_Cycle(scheme *sc, enum scheme_opcodes op) {
}
}
ok_to_freely_gc(sc);
- if (pcd->func(sc, (enum scheme_opcodes)sc->op) == sc->NIL) {
+ if (opexe_0(sc, (enum scheme_opcodes)sc->op) == sc->NIL) {
return;
}
if(sc->no_memory) {