From 920a530385bb1d3980306641b4d9a6347fe9447b Mon Sep 17 00:00:00 2001 From: Florian Stecker Date: Thu, 16 Jun 2022 15:43:19 +0200 Subject: [PATCH] remove unnecessary function qext_newtype() --- qext.c | 10 ---------- qext.h | 1 - 2 files changed, 11 deletions(-) diff --git a/qext.c b/qext.c index 0864aa2..5b13071 100644 --- a/qext.c +++ b/qext.c @@ -37,16 +37,6 @@ static void qext_init_type(struct qext_type *type) } } -struct qext_type *qext_newtype(int rank, const int *coeffs) -{ - struct qext_type *type = malloc(sizeof(struct qext_type)); - type->rank = rank; - type->integer_coeffs = coeffs; - qext_init_type(type); - - return type; -} - void qext_init(qext_number x, struct qext_type *type) { if(type->coeffs == NULL) // uninitialized default type diff --git a/qext.h b/qext.h index 7181353..fd35a67 100644 --- a/qext.h +++ b/qext.h @@ -20,7 +20,6 @@ extern struct qext_type *QT_TRIVIAL; extern struct qext_type *QT_SQRT5; extern struct qext_type *QT_GAUSS_SQRT5; -struct qext_type *qext_newtype(int rank, const int *coeffs); void qext_init(qext_number x, struct qext_type *type); void qext_clear(qext_number x); void qext_set(qext_number x, qext_number y);