ここに私のコードの例外があります
poly.h
#include "gf.h"
typedef struct polynome {
int deg, size;
gf_t * coeff;
} * poly_t; /* polynomial has coefficients in the finite field */
class Polinomio{
public:
int poly_degppf(poly_t g);
poly.cpp
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include "gf.h"
#include "poly.h"
Polinomio::Polinomio(int n){
printf("Hola como estas");
}
int Polinomio::poly_degppf(poly_t g) {
int i, d, res;
poly_t *u;
d = poly_deg(g);
u = malloc(d * sizeof (poly_t*));
なぜこのエラーが発生するのですか?
poly.cpp: In member function ‘int Polinomio::poly_degppf(polynome*)’:
poly.cpp:261: error: invalid conversion from ‘void*’ to ‘polynome**’