f94b972d |
1 | /* -*-c-*- |
2 | * |
3 | * $Id$ |
4 | * |
5 | * Internal structures for built-in fields |
6 | * |
7 | * (c) 2004 Straylight/Edgeware |
8 | */ |
9 | |
10 | /*----- Licensing notice --------------------------------------------------* |
11 | * |
12 | * This file is part of Catacomb. |
13 | * |
14 | * Catacomb is free software; you can redistribute it and/or modify |
15 | * it under the terms of the GNU Library General Public License as |
16 | * published by the Free Software Foundation; either version 2 of the |
17 | * License, or (at your option) any later version. |
18 | * |
19 | * Catacomb is distributed in the hope that it will be useful, |
20 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
21 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
22 | * GNU Library General Public License for more details. |
23 | * |
24 | * You should have received a copy of the GNU Library General Public |
25 | * License along with Catacomb; if not, write to the Free |
26 | * Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, |
27 | * MA 02111-1307, USA. |
28 | */ |
29 | |
30 | #ifndef CATACOMB_FIELD_GUTS_H |
31 | #define CATACOMB_FIELD_GUTS_H |
32 | |
33 | #ifdef __cplusplus |
34 | extern "C" { |
35 | #endif |
36 | |
37 | /*----- Header files ------------------------------------------------------*/ |
38 | |
39 | #ifndef CATACOMB_MP_H |
40 | # include "mp.h" |
41 | #endif |
42 | |
43 | #ifndef CATACOMB_EC_H |
44 | # include "ec.h" |
45 | #endif |
46 | |
47 | #ifndef CATACOMB_MPMONT_H |
48 | # include "mpmont.h" |
49 | #endif |
50 | |
51 | #ifndef CATACOMB_MPREDUCE_H |
52 | # include "mpreduce.h" |
53 | #endif |
54 | |
55 | #ifndef CATACOMB_GF_H |
56 | # include "gf.h" |
57 | #endif |
58 | |
59 | #ifndef CATACOMB_GFN_H |
60 | # include "gfn.h" |
61 | #endif |
62 | |
63 | #ifndef CATACOMB_GFREDUCE_H |
64 | # include "gfreduce.h" |
65 | #endif |
66 | |
67 | #ifndef CATACOMB_FIELD_H |
68 | # include "field.h" |
69 | #endif |
70 | |
71 | /*----- Data structures ---------------------------------------------------*/ |
72 | |
73 | typedef struct fctx_prime { |
74 | field f; |
75 | mpmont mm; |
76 | } fctx_prime; |
77 | |
78 | typedef struct fctx_niceprime { |
79 | field f; |
80 | mpreduce r; |
81 | } fctx_niceprime; |
82 | |
83 | typedef struct fctx_binpoly { |
84 | field f; |
85 | gfreduce r; |
86 | } fctx_binpoly; |
87 | |
88 | typedef struct fctx_binnorm { |
89 | fctx_binpoly f; |
90 | gfn ntop, pton; |
91 | } fctx_binnorm; |
92 | |
93 | /*----- That's all, folks -------------------------------------------------*/ |
94 | |
95 | #ifdef __cplusplus |
96 | } |
97 | #endif |
98 | |
99 | #endif |