Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/moses-smt/vowpal_wabbit.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Langford <jl@hunch.net>2012-06-20 23:01:32 +0400
committerJohn Langford <jl@hunch.net>2012-06-20 23:01:32 +0400
commita572a38b66b4348717fd18d8b90bc243a6ab0277 (patch)
treea7b708b13800cd872c41f651ac5bae9f3cb293de /vowpalwabbit/parse_primitives.h
parentc2bd69b99dcd41516edaff9a4460a1c73b6725e7 (diff)
dead code removal and minor tweak
Diffstat (limited to 'vowpalwabbit/parse_primitives.h')
-rw-r--r--vowpalwabbit/parse_primitives.h22
1 files changed, 0 insertions, 22 deletions
diff --git a/vowpalwabbit/parse_primitives.h b/vowpalwabbit/parse_primitives.h
index 0ed374eb..73afc3ae 100644
--- a/vowpalwabbit/parse_primitives.h
+++ b/vowpalwabbit/parse_primitives.h
@@ -158,31 +158,9 @@ inline float float_of_substring(substring s)
return f;
}
-inline float double_of_substring(substring s)
-{
- char* endptr = s.end;
- float f = strtod(s.begin,&endptr);
- if (endptr == s.begin && s.begin != s.end)
- {
- std::cout << "error: " << std::string(s.begin, s.end-s.begin).c_str() << " is not a double" << std::endl;
- f = 0;
- }
- return f;
-}
-
inline int int_of_substring(substring s)
{
return atoi(std::string(s.begin, s.end-s.begin).c_str());
}
-inline unsigned long ulong_of_substring(substring s)
-{
- return strtoul(std::string(s.begin, s.end-s.begin).c_str(),NULL,10);
-}
-
-inline unsigned long ss_length(substring s)
-{
- return (s.end - s.begin);
-}
-
#endif