ADTaaron-thesisarm-ehast-experimentalcleanup-dtorsctordeferred_resndemanglerenumforall-pointer-decaygc_noraiijacob/cs343-translationjenkins-sandboxmemorynew-astnew-ast-unique-exprnew-envno_listpersistent-indexerpthread-emulationqualifiedEnumresolv-newstringwith_gc
Last change
on this file since 91b216b4 was
51b7345,
checked in by Peter A. Buhr <pabuhr@…>, 10 years ago
|
initial commit
|
-
Property mode set to
100644
|
File size:
487 bytes
|
Rev | Line | |
---|
[51b7345] | 1 | #ifndef VECTOR_INT_H |
---|
| 2 | #define VECTOR_INT_H |
---|
| 3 | |
---|
| 4 | typedef struct vector_int |
---|
| 5 | { |
---|
| 6 | int last; |
---|
| 7 | int capacity; |
---|
| 8 | int *data; |
---|
| 9 | } vector_int; |
---|
| 10 | |
---|
| 11 | |
---|
| 12 | vector_int vector_int_allocate(); |
---|
| 13 | vector_int vector_int_allocate( int reserve ); |
---|
| 14 | void vector_int_deallocate( vector_int ); |
---|
| 15 | |
---|
| 16 | void reserve( vector_int *vec, int reserve ); |
---|
| 17 | void append( vector_int *vec, int element ); |
---|
| 18 | |
---|
| 19 | // implement bounded_array |
---|
| 20 | |
---|
| 21 | lvalue int ?[?]( vector_int vec, int index ); |
---|
| 22 | int array_last( vector_int vec ); |
---|
| 23 | |
---|
| 24 | #endif /* #ifndef VECTOR_INT_H */ |
---|
Note: See
TracBrowser
for help on using the repository browser.