diff options
author | Alan Mishchenko <alanmi@berkeley.edu> | 2007-04-08 08:01:00 -0700 |
---|---|---|
committer | Alan Mishchenko <alanmi@berkeley.edu> | 2007-04-08 08:01:00 -0700 |
commit | c09d4d499cee70f02e3e9a18226554b8d1d34488 (patch) | |
tree | 89ac20b1029dc8407f655224f6ef2b5f431fa453 /src/misc/nm/nmApi.c | |
parent | 94112fd22fc6f09ccc488cfc577d43aebeff9c5f (diff) | |
download | abc-c09d4d499cee70f02e3e9a18226554b8d1d34488.tar.gz abc-c09d4d499cee70f02e3e9a18226554b8d1d34488.tar.bz2 abc-c09d4d499cee70f02e3e9a18226554b8d1d34488.zip |
Version abc70408
Diffstat (limited to 'src/misc/nm/nmApi.c')
-rw-r--r-- | src/misc/nm/nmApi.c | 23 |
1 files changed, 23 insertions, 0 deletions
diff --git a/src/misc/nm/nmApi.c b/src/misc/nm/nmApi.c index c46866d5..9165922f 100644 --- a/src/misc/nm/nmApi.c +++ b/src/misc/nm/nmApi.c @@ -222,6 +222,29 @@ int Nm_ManFindIdByName( Nm_Man_t * p, char * pName, int Type ) /**Function************************************************************* + Synopsis [Returns ID of the object if its name is known.] + + Description [This procedure may return two IDs because POs and latches + may have the same name (the only allowed case of name duplication).] + + SideEffects [] + + SeeAlso [] + +***********************************************************************/ +int Nm_ManFindIdByNameTwoTypes( Nm_Man_t * p, char * pName, int Type1, int Type2 ) +{ + int iNodeId; + iNodeId = Nm_ManFindIdByName( p, pName, Type1 ); + if ( iNodeId == -1 ) + iNodeId = Nm_ManFindIdByName( p, pName, Type2 ); + if ( iNodeId == -1 ) + return -1; + return iNodeId; +} + +/**Function************************************************************* + Synopsis [Return the IDs of objects with names.] Description [] |