fix opt4 build

This commit is contained in:
David Rose 2005-08-17 01:06:10 +00:00
parent bb63ebad79
commit 2af4a15df2
3 changed files with 2 additions and 32 deletions

View File

@ -17,23 +17,6 @@
//////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////
#ifdef NDEBUG
// This function is only inline if NDEBUG is defined. Otherwise, it
// is non-inline and its definition appears in typeRegistry.cxx.
////////////////////////////////////////////////////////////////////
// Function: TypeRegistry::look_up
// Access: Private
// Description: Returns the TypeRegistryNode associated with the
// indicated TypeHandle.
////////////////////////////////////////////////////////////////////
INLINE TypeRegistryNode *TypeRegistry::
look_up(TypeHandle handle, TypedObject *) const {
return _handle_registry[handle._index];
}
#endif // NDEBUG
//////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////
// Function: TypeRegistry::freshen_derivations // Function: TypeRegistry::freshen_derivations
// Access: Private // Access: Private

View File

@ -584,11 +584,6 @@ write_node(ostream &out, int indent_level, const TypeRegistryNode *node) const {
} }
} }
#ifndef NDEBUG
// This function is only non-inline if NDEBUG is not defined.
// Otherwise, it is inline and its definition appears in
// typeRegistry.I.
//////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////
// Function: TypeRegistry::look_up // Function: TypeRegistry::look_up
// Access: Private // Access: Private
@ -604,6 +599,7 @@ write_node(ostream &out, int indent_level, const TypeRegistryNode *node) const {
//////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////
TypeRegistryNode *TypeRegistry:: TypeRegistryNode *TypeRegistry::
look_up(TypeHandle handle, TypedObject *object) const { look_up(TypeHandle handle, TypedObject *object) const {
#ifndef NDEBUG
if (handle._index == 0) { if (handle._index == 0) {
// The TypeHandle is unregistered. This is an error condition. // The TypeHandle is unregistered. This is an error condition.
@ -650,6 +646,7 @@ look_up(TypeHandle handle, TypedObject *object) const {
<< "! Is memory corrupt?\n"; << "! Is memory corrupt?\n";
nassertr(false, NULL); nassertr(false, NULL);
} }
#endif // NDEBUG
return _handle_registry[handle._index]; return _handle_registry[handle._index];
} }
@ -689,6 +686,3 @@ extern "C" int get_best_parent_from_Set(int id, const std::set<int> &set)
return th.get_best_parent_from_Set(set); return th.get_best_parent_from_Set(set);
} }
#endif // NDEBUG

View File

@ -88,14 +88,7 @@ private:
TypeRegistry(); TypeRegistry();
static void init_global_pointer(); static void init_global_pointer();
// In NDEBUG mode, this is an inline function; otherwise, it's
// out-of-line.
#ifdef NDEBUG
INLINE TypeRegistryNode *look_up(TypeHandle type, TypedObject *object) const;
#else
TypeRegistryNode *look_up(TypeHandle type, TypedObject *object) const; TypeRegistryNode *look_up(TypeHandle type, TypedObject *object) const;
#endif
INLINE void freshen_derivations(); INLINE void freshen_derivations();
void rebuild_derivations(); void rebuild_derivations();