mirror of
https://github.com/rdkit/rdkit.git
synced 2026-06-03 21:44:30 +08:00
Switches to URANGE_CHECK when appropriate
This commit is contained in:
@@ -338,8 +338,8 @@ namespace RDCatalog {
|
||||
*/
|
||||
void addEdge(unsigned int id1, unsigned int id2) {
|
||||
unsigned int nents = getNumEntries();
|
||||
RANGE_CHECK(0, id1, nents-1);
|
||||
RANGE_CHECK(0, id2, nents-1);
|
||||
URANGE_CHECK(id1, nents-1);
|
||||
URANGE_CHECK(id2, nents-1);
|
||||
// FIX: if we boost::setS for the edgeList BGL will
|
||||
// do the checking for duplicity (parallel edges)
|
||||
// But for reasons unknown setS results in compile
|
||||
@@ -357,7 +357,7 @@ namespace RDCatalog {
|
||||
//------------------------------------
|
||||
//! returns a pointer to our entry with a particular index
|
||||
const entryType *getEntryWithIdx(unsigned int idx) const {
|
||||
RANGE_CHECK(0,idx,getNumEntries()-1);
|
||||
URANGE_CHECK(idx,getNumEntries()-1);
|
||||
int vd = boost::vertex(idx, d_graph);
|
||||
typename boost::property_map < CatalogGraph, vertex_entry_t>::const_type
|
||||
pMap = boost::get(vertex_entry_t(), d_graph);
|
||||
@@ -367,7 +367,7 @@ namespace RDCatalog {
|
||||
//------------------------------------
|
||||
//! returns a pointer to our entry with a particular bit ID
|
||||
const entryType *getEntryWithBitId(unsigned int idx) const {
|
||||
RANGE_CHECK(0,idx,this->getFPLength()-1);
|
||||
URANGE_CHECK(idx,this->getFPLength()-1);
|
||||
typename boost::property_map < CatalogGraph, vertex_entry_t>::const_type
|
||||
pMap = boost::get(vertex_entry_t(), d_graph);
|
||||
const entryType *res=NULL;
|
||||
@@ -384,7 +384,7 @@ namespace RDCatalog {
|
||||
//------------------------------------
|
||||
//! returns the index of the entry with a particular bit ID
|
||||
int getIdOfEntryWithBitId(unsigned int idx) const {
|
||||
RANGE_CHECK(0,idx,this->getFPLength()-1);
|
||||
URANGE_CHECK(idx,this->getFPLength()-1);
|
||||
typename boost::property_map < CatalogGraph, vertex_entry_t>::const_type
|
||||
pMap = boost::get(vertex_entry_t(), d_graph);
|
||||
int res=-1;
|
||||
|
||||
Reference in New Issue
Block a user