2 * This file is part of cparser.
3 * Copyright (C) 2007-2008 Matthias Braun <matze@braunis.de>
5 * This program is free software; you can redistribute it and/or
6 * modify it under the terms of the GNU General Public License
7 * as published by the Free Software Foundation; either version 2
8 * of the License, or (at your option) any later version.
10 * This program is distributed in the hope that it will be useful,
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 * GNU General Public License for more details.
15 * You should have received a copy of the GNU General Public License
16 * along with this program; if not, write to the Free Software
17 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
23 #include <libfirm/firm_types.h>
26 typedef struct entitymap_entry_t {
31 #define HashSet entitymap_t
32 #define HashSetIterator entitymap_iterator_t
33 #define ValueType entitymap_entry_t
35 #include "adt/hashset.h"
38 #undef HashSetIterator
41 typedef struct entitymap_iterator_t entitymap_iterator_t;
42 typedef struct entitymap_t entitymap_t;
44 void entitymap_init(entitymap_t *map);
46 void entitymap_destroy(entitymap_t *map);
48 void entitymap_insert(entitymap_t *map, symbol_t *symbol, ir_entity *entity);
50 ir_entity *entitymap_get(const entitymap_t *map, symbol_t *symbol);