From 273ba03041ee4cac93385f180d1397b49f8094ca Mon Sep 17 00:00:00 2001 From: Alan Mishchenko Date: Tue, 9 Aug 2005 08:01:00 -0700 Subject: Version abc50809 --- src/misc/vec/vecInt.h | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) (limited to 'src/misc/vec/vecInt.h') diff --git a/src/misc/vec/vecInt.h b/src/misc/vec/vecInt.h index 975b61cf..76fce02e 100644 --- a/src/misc/vec/vecInt.h +++ b/src/misc/vec/vecInt.h @@ -428,6 +428,29 @@ static inline int Vec_IntPop( Vec_Int_t * p ) return p->pArray[--p->nSize]; } +/**Function************************************************************* + + Synopsis [] + + Description [] + + SideEffects [] + + SeeAlso [] + +***********************************************************************/ +static inline void Vec_IntRemove( Vec_Int_t * p, int Entry ) +{ + int i; + for ( i = 0; i < p->nSize; i++ ) + if ( p->pArray[i] == Entry ) + break; + assert( i < p->nSize ); + for ( i++; i < p->nSize; i++ ) + p->pArray[i-1] = p->pArray[i]; + p->nSize--; +} + /**Function************************************************************* Synopsis [Comparison procedure for two integers.] -- cgit v1.2.3