1 |
ben.allan |
33 |
/**< |
2 |
aw0a |
1 |
* Ascend Instance Tree Killing |
3 |
|
|
* by Tom Epperly |
4 |
|
|
* 8/16/89 |
5 |
|
|
* Version: $Revision: 1.6 $ |
6 |
|
|
* Version control file: $RCSfile: destroyinst.h,v $ |
7 |
|
|
* Date last modified: $Date: 1997/07/18 12:28:54 $ |
8 |
|
|
* Last modified by: $Author: mthomas $ |
9 |
|
|
* |
10 |
|
|
* This file is part of the Ascend Language Interpreter. |
11 |
|
|
* |
12 |
|
|
* Copyright (C) 1996 Ben Allan |
13 |
|
|
* based on instance.c |
14 |
|
|
* Copyright (C) 1990, 1993, 1994 Thomas Guthrie Epperly |
15 |
|
|
* |
16 |
|
|
* The Ascend Language Interpreter is free software; you can redistribute |
17 |
|
|
* it and/or modify it under the terms of the GNU General Public License as |
18 |
|
|
* published by the Free Software Foundation; either version 2 of the |
19 |
|
|
* License, or (at your option) any later version. |
20 |
|
|
* |
21 |
|
|
* The Ascend Language Interpreter is distributed in hope that it will be |
22 |
|
|
* useful, but WITHOUT ANY WARRANTY; without even the implied warranty of |
23 |
|
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU |
24 |
|
|
* General Public License for more details. |
25 |
|
|
* |
26 |
|
|
* You should have received a copy of the GNU General Public License |
27 |
|
|
* along with the program; if not, write to the Free Software Foundation, |
28 |
|
|
* Inc., 675 Mass Ave, Cambridge, MA 02139 USA. Check the file named |
29 |
|
|
* COPYING. |
30 |
|
|
*/ |
31 |
|
|
#ifndef __DESTROYINST_H_SEEN__ |
32 |
|
|
#define __DESTROYINST_H_SEEN__ |
33 |
|
|
|
34 |
|
|
|
35 |
ben.allan |
33 |
/**< |
36 |
aw0a |
1 |
* When #including destroyinst.h, make sure these files are #included first: |
37 |
|
|
* #include "instance_enum.h" |
38 |
|
|
*/ |
39 |
|
|
|
40 |
|
|
|
41 |
|
|
extern void DestroyInstance(struct Instance *,struct Instance *); |
42 |
ben.allan |
33 |
/**< |
43 |
aw0a |
1 |
* void DestroyInstance(inst,parent) |
44 |
|
|
* struct Instance *inst,*parent; |
45 |
|
|
* If parent is NULL, this will destroy all references to inst and deallocate |
46 |
|
|
* the memory associated with inst. It will delete inst's reference to its |
47 |
|
|
* children. If parent is not NULL, this will destroy parent's reference |
48 |
|
|
* to inst. If this is the only reference to inst, it will deallocate the |
49 |
|
|
* memory associated with inst. |
50 |
|
|
* |
51 |
|
|
* DestroyInstance will modify the parent's of inst to remove the reference. |
52 |
|
|
*/ |
53 |
|
|
|
54 |
|
|
|
55 |
|
|
#endif |
56 |
ben.allan |
33 |
/**< __DESTROYINST_H_SEEN__ */ |