]> andersk Git - splint.git/blame - src/Headers/lsymbolSet.h
Updated copyrights
[splint.git] / src / Headers / lsymbolSet.h
CommitLineData
885824d3 1/*
c0de361f 2** Copyright (C) University of Virginia, Massachusetts Institue of Technology 1994-2003.
885824d3 3** See ../LICENSE for license information.
4**
5*/
6/*
7** lsymbolSet.h
8**
9** based on set_template.h
10*/
11
12# ifndef LSYMBOLSET_H
13# define LSYMBOLSET_H
14
28bf4b0b 15abst_typedef /*@null@*/ struct
885824d3 16{
17 int entries;
18 int nspace;
19 /*@reldef@*/ /*@relnull@*/ lsymbol *elements;
20} *lsymbolSet ;
21
22/*@constant null lsymbolSet lsymbolSet_undefined; @*/
23# define lsymbolSet_undefined (NULL)
24
0e41eb0e 25extern /*@falsewhennull@*/ bool lsymbolSet_isDefined (lsymbolSet p_l) /*@*/ ;
885824d3 26# define lsymbolSet_isDefined(l) ((l) != lsymbolSet_undefined)
27
28/*@iter lsymbolSet_elements (sef lsymbolSet s, yield lsymbol el); @*/
29# define lsymbolSet_elements(x, m_el) \
30 if (lsymbolSet_isDefined (x)) \
31 { int m_ind; \
32 for (m_ind = 0 ; m_ind < (x)->entries; m_ind++) \
33 { lsymbol m_el = (x)->elements[m_ind];
34
35# define end_lsymbolSet_elements }}
36
37extern /*@only@*/ lsymbolSet lsymbolSet_new(void) /*@*/ ;
38extern bool lsymbolSet_insert (lsymbolSet p_s, lsymbol p_el) /*@modifies p_s@*/ ;
39extern bool lsymbolSet_member (lsymbolSet p_s, lsymbol p_el) /*@*/ ;
40extern /*@unused@*/ /*@only@*/ cstring lsymbolSet_unparse (lsymbolSet p_s) /*@*/ ;
41extern void lsymbolSet_free (/*@only@*/ lsymbolSet p_s);
42
43/*@constant int lsymbolSetBASESIZE;@*/
44# define lsymbolSetBASESIZE MIDBASESIZE
45
46# else
47# error "Multiple include"
48# endif
This page took 0.071971 seconds and 5 git commands to generate.