-
Notifications
You must be signed in to change notification settings - Fork 2
/
Type_table.h
41 lines (35 loc) · 1.24 KB
/
Type_table.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
#ifndef _TYPE_TABLE_H_
#define _TYPE_TABLE_H_
/*******************************************************************/
/*** FILE : Type_table.h ***/
/*** AUTHOR: Sekhar Muddana ***/
/*** DATE WRITTEN: May 1990 ***/
/*******************************************************************/
#include "Build_defs.h"
typedef struct tt_node {
Basis begin_basis;
Basis end_basis; /* indices into Base table. */
Type type;
} TT_node;
int CreateTypeTable(Type Cur_type);
int GetTargetLen();
Type GetNewType();
void NameToType(Name N, Type T);
void SubtractTypeName(Name n1, Name n2, Name *res_name);
int GetDegree(Type Pntr);
int GetDegreeName(Name n);
Name TypeToName(Type T);
bool IsSubtype(Name n1, Name n2);
void EnterEndBasis(int TTindex, Basis basis);
void UpdateTypeTable(Name n, Basis Begin_basis, Basis End_basis);
void DestroyTypeTable();
void PrintTypeName(Name n, FILE *filePtr);
Name FirstTypeDegree(Degree D);
Name NextTypeSameDegree(Name n);
Basis FirstBasis(Name N);
Basis NextBasisSameType(Basis B);
Basis BeginBasis(Name n);
Basis EndBasis(Name n);
bool save_type_table(FILE *f);
bool restore_type_table(FILE *f);
#endif