From f441c63ea491f30fbbaa3e557badc5752ebca7d3 Mon Sep 17 00:00:00 2001 From: Arseny Kapoulkine Date: Tue, 2 Feb 2016 08:39:45 -0800 Subject: Implement set/set_value/operator= for long types This makes the coverage for basic numeric types complete (sans long double). Fixes #78. --- src/pugixml.hpp | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/pugixml.hpp') diff --git a/src/pugixml.hpp b/src/pugixml.hpp index 5d5fe2b..09bd692 100644 --- a/src/pugixml.hpp +++ b/src/pugixml.hpp @@ -359,6 +359,8 @@ namespace pugi // Set attribute value with type conversion (numbers are converted to strings, boolean is converted to "true"/"false") bool set_value(int rhs); bool set_value(unsigned int rhs); + bool set_value(long rhs); + bool set_value(unsigned long rhs); bool set_value(double rhs); bool set_value(float rhs); bool set_value(bool rhs); @@ -372,6 +374,8 @@ namespace pugi xml_attribute& operator=(const char_t* rhs); xml_attribute& operator=(int rhs); xml_attribute& operator=(unsigned int rhs); + xml_attribute& operator=(long rhs); + xml_attribute& operator=(unsigned long rhs); xml_attribute& operator=(double rhs); xml_attribute& operator=(float rhs); xml_attribute& operator=(bool rhs); @@ -706,6 +710,8 @@ namespace pugi // Set text with type conversion (numbers are converted to strings, boolean is converted to "true"/"false") bool set(int rhs); bool set(unsigned int rhs); + bool set(long rhs); + bool set(unsigned long rhs); bool set(double rhs); bool set(float rhs); bool set(bool rhs); @@ -719,6 +725,8 @@ namespace pugi xml_text& operator=(const char_t* rhs); xml_text& operator=(int rhs); xml_text& operator=(unsigned int rhs); + xml_text& operator=(long rhs); + xml_text& operator=(unsigned long rhs); xml_text& operator=(double rhs); xml_text& operator=(float rhs); xml_text& operator=(bool rhs); -- cgit v1.2.3