Minor unspecified bool refactoring (removed redundant CW workaround)
git-svn-id: http://pugixml.googlecode.com/svn/trunk@685 99668b35-9821-0410-8761-19e4c4f06640
This commit is contained in:
parent
e7b0e52068
commit
f3795e55dd
@ -3071,11 +3071,7 @@ namespace pugi
|
|||||||
|
|
||||||
xml_attribute::operator xml_attribute::unspecified_bool_type() const
|
xml_attribute::operator xml_attribute::unspecified_bool_type() const
|
||||||
{
|
{
|
||||||
#ifdef __MWERKS__
|
|
||||||
return _attr ? &xml_attribute::empty : 0;
|
|
||||||
#else
|
|
||||||
return _attr ? &xml_attribute::_attr : 0;
|
return _attr ? &xml_attribute::_attr : 0;
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bool xml_attribute::operator!() const
|
bool xml_attribute::operator!() const
|
||||||
@ -3319,11 +3315,7 @@ namespace pugi
|
|||||||
|
|
||||||
xml_node::operator xml_node::unspecified_bool_type() const
|
xml_node::operator xml_node::unspecified_bool_type() const
|
||||||
{
|
{
|
||||||
#ifdef __MWERKS__
|
|
||||||
return _root ? &xml_node::empty : 0;
|
|
||||||
#else
|
|
||||||
return _root ? &xml_node::_root : 0;
|
return _root ? &xml_node::_root : 0;
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bool xml_node::operator!() const
|
bool xml_node::operator!() const
|
||||||
|
|||||||
@ -411,11 +411,7 @@ namespace pugi
|
|||||||
xml_attribute_struct* _attr;
|
xml_attribute_struct* _attr;
|
||||||
|
|
||||||
/// \internal Safe bool type
|
/// \internal Safe bool type
|
||||||
#ifdef __MWERKS__
|
|
||||||
typedef bool (xml_attribute::*unspecified_bool_type)() const;
|
|
||||||
#else
|
|
||||||
typedef xml_attribute_struct* xml_attribute::*unspecified_bool_type;
|
typedef xml_attribute_struct* xml_attribute::*unspecified_bool_type;
|
||||||
#endif
|
|
||||||
|
|
||||||
/// \internal Initializing constructor
|
/// \internal Initializing constructor
|
||||||
explicit xml_attribute(xml_attribute_struct* attr);
|
explicit xml_attribute(xml_attribute_struct* attr);
|
||||||
@ -672,11 +668,7 @@ namespace pugi
|
|||||||
xml_node_struct* _root;
|
xml_node_struct* _root;
|
||||||
|
|
||||||
/// \internal Safe bool type
|
/// \internal Safe bool type
|
||||||
#ifdef __MWERKS__
|
|
||||||
typedef bool (xml_node::*unspecified_bool_type)() const;
|
|
||||||
#else
|
|
||||||
typedef xml_node_struct* xml_node::*unspecified_bool_type;
|
typedef xml_node_struct* xml_node::*unspecified_bool_type;
|
||||||
#endif
|
|
||||||
|
|
||||||
/// \internal Initializing constructor
|
/// \internal Initializing constructor
|
||||||
explicit xml_node(xml_node_struct* p);
|
explicit xml_node(xml_node_struct* p);
|
||||||
@ -1881,6 +1873,7 @@ namespace pugi
|
|||||||
xpath_ast_node* _root;
|
xpath_ast_node* _root;
|
||||||
xpath_parse_result _result;
|
xpath_parse_result _result;
|
||||||
|
|
||||||
|
/// \internal Safe bool type
|
||||||
typedef xpath_ast_node* xpath_query::*unspecified_bool_type;
|
typedef xpath_ast_node* xpath_query::*unspecified_bool_type;
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user