3 Copyright (C) 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003
4 Institut f. Computersprachen, TU Wien
5 R. Grafl, A. Krall, C. Kruegel, C. Oates, R. Obermaisser, M. Probst,
6 S. Ring, E. Steiner, C. Thalinger, D. Thuernbeck, P. Tomsich,
9 This file is part of CACAO.
11 This program is free software; you can redistribute it and/or
12 modify it under the terms of the GNU General Public License as
13 published by the Free Software Foundation; either version 2, or (at
14 your option) any later version.
16 This program is distributed in the hope that it will be useful, but
17 WITHOUT ANY WARRANTY; without even the implied warranty of
18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
19 General Public License for more details.
21 You should have received a copy of the GNU General Public License
22 along with this program; if not, write to the Free Software
23 Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
26 Contact: cacao@complang.tuwien.ac.at
28 Authors: Carolyn Oates
30 $Id: sets.h 665 2003-11-21 18:36:43Z jowenn $
40 typedef struct methSet methSet;
41 typedef struct methSetNode methSetNode;
42 typedef struct fldSet fldSet;
43 typedef struct fldSetNode fldSetNode;
44 typedef struct classSet classSet;
45 typedef struct classSetNode classSetNode;
51 /*------------ Method /Class Used Markers -------------------------------*/
54 USED all methods and fields are available;
55 PARTUSED = specific methods (static, <init>, <clinit>, inherited def used, special) used,
57 NOTUSED = nothing used in class - not needed
61 USED = method definition is used
62 PARTUSED = method definition will be used if class instanciated
63 NOTUSED = method defintion never used
72 #define MONO1 1 /* potential poly that is really mono */
76 /*------------------------------------------------------------*/
77 /*-- flds used by a method set fns */
78 /*------------------------------------------------------------*/
89 fldSetNode *nextfldRef;
92 classSetNode *lastptrPUT;
93 classSetNode *lastptrGET;
98 fldSetNode *inFldSet (fldSetNode *, fieldinfo *);
99 fldSetNode *addFldRef(fldSetNode *, fieldinfo *);
100 fldSet *add2FldSet(fldSet *, fieldinfo *, bool, bool);
101 fldSet *createFldSet();
102 int printFldSet(fldSetNode *);
103 int printFieldSet(fldSet *);
106 /*------------------------------------------------------------*/
107 /*-- methodinfo call set fns */
108 /*------------------------------------------------------------*/
119 methSetNode *nextmethRef;
120 classSetNode *lastptrIntoClassSet2;
126 int inMethSet (methSetNode *, methodinfo *);
127 methSetNode *addMethRef(methSetNode *, methodinfo *);
128 methSet *add2MethSet(methSet *, methodinfo *);
129 methSet *createMethSet();
130 int printMethSet (methSetNode *);
131 int printMethodSet (methSet *);
134 /*------------------------------------------------------------*/
135 /*-- classinfo XTA set fns */
136 /*------------------------------------------------------------*/
146 struct classSetNode {
147 classinfo *classType;
148 classSetNode *nextClass;
153 int inSet(classSetNode *, classinfo *);
154 classSetNode *addElement(classSetNode *, classinfo *);
155 classSet *add2ClassSet(classSet *, classinfo *);
156 classSet *createClassSet();
157 int inRange(classSetNode *, classinfo *);
158 classSetNode *addClassCone(classSetNode *, classinfo *);
159 classSetNode *intersectSubtypesWithSet(classinfo *, classSetNode *);
160 int sizeOfSet(classSetNode *s);
161 int setSize(classSetNode *);
162 int printSet(classSetNode *);
163 int printClassSet(classSet *);
169 * These are local overrides for various environment variables in Emacs.
170 * Please do not remove this and leave it at the end of the file, where
171 * Emacs will automagically detect them.
172 * ---------------------------------------------------------------------
175 * indent-tabs-mode: t