From: Mikko Rasa Date: Wed, 23 Aug 2006 12:25:17 +0000 (+0000) Subject: Drop the commented out old conversion functions X-Git-Tag: 1.0~43 X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=a7da782db1fda2dade2bf104066ae4cf0a9aec48;p=libs%2Fdatafile.git Drop the commented out old conversion functions --- diff --git a/source/value.cpp b/source/value.cpp index 8cb1af0..6d5e032 100644 --- a/source/value.cpp +++ b/source/value.cpp @@ -4,47 +4,11 @@ Copyright © 2006 Mikko Rasa, Mikkosoft Productions Distributed under the LGPL */ #include -#include #include "value.h" namespace Msp { namespace Parser { -/*template<> -unsigned Value::get() const -{ - if(type!=INTEGER) - throw TypeError("Value is not an integer"); - errno=0; - unsigned long result=strtoul(data); - if(errno==ERANGE - return result; -} - -template<> -unsigned Value::get() const -{ - if(type!=INTEGER) - throw TypeError("Value is not an integer"); - return strtoul(data); -} - -template<> -unsigned Value::get() const -{ - if(type!=INTEGER) - throw TypeError("Value is not an integer"); - return strtoul(data); -} - -template<> -float Value::get() const -{ - if(type!=FLOAT && type!=INTEGER) - throw TypeError("Value is not a float"); - return strtod(data); -}*/ - template<> std::string Value::get() const {