Commit f25b5369 authored by Davis King's avatar Davis King

Fixed a few more compile time errors when dlib is compiled with clang.

--HG--
extra : convert_revision : svn%3Afdd8eb12-d10e-0410-9acb-85c331704f74/trunk%404123
parent d39c6e16
...@@ -240,7 +240,7 @@ namespace dlib ...@@ -240,7 +240,7 @@ namespace dlib
{ {
try try
{ {
const typename clp_base::option_type& opt = option(option_name); const typename clp_base::option_type& opt = this->option(option_name);
const unsigned long number_of_arguments = opt.number_of_arguments(); const unsigned long number_of_arguments = opt.number_of_arguments();
const unsigned long count = opt.count(); const unsigned long count = opt.count();
for (unsigned long i = 0; i < number_of_arguments; ++i) for (unsigned long i = 0; i < number_of_arguments; ++i)
...@@ -307,7 +307,7 @@ namespace dlib ...@@ -307,7 +307,7 @@ namespace dlib
{ {
try try
{ {
const typename clp_base::option_type& opt = option(option_name); const typename clp_base::option_type& opt = this->option(option_name);
const unsigned long number_of_arguments = opt.number_of_arguments(); const unsigned long number_of_arguments = opt.number_of_arguments();
const unsigned long count = opt.count(); const unsigned long count = opt.count();
for (unsigned long i = 0; i < number_of_arguments; ++i) for (unsigned long i = 0; i < number_of_arguments; ++i)
...@@ -386,8 +386,8 @@ namespace dlib ...@@ -386,8 +386,8 @@ namespace dlib
{ {
for (size_t j = i+1; j < length; ++j) for (size_t j = i+1; j < length; ++j)
{ {
if (option(option_set[i]).count() > 0 && if (this->option(option_set[i]).count() > 0 &&
option(option_set[j]).count() > 0 ) this->option(option_set[j]).count() > 0 )
{ {
throw cmd_line_check_error( throw cmd_line_check_error(
EINCOMPATIBLE_OPTIONS, EINCOMPATIBLE_OPTIONS,
...@@ -410,8 +410,8 @@ namespace dlib ...@@ -410,8 +410,8 @@ namespace dlib
const string_type& option_name2 const string_type& option_name2
) const ) const
{ {
if (option(option_name1).count() > 0 && if (this->option(option_name1).count() > 0 &&
option(option_name2).count() > 0 ) this->option(option_name2).count() > 0 )
{ {
throw cmd_line_check_error( throw cmd_line_check_error(
EINCOMPATIBLE_OPTIONS, EINCOMPATIBLE_OPTIONS,
...@@ -462,13 +462,13 @@ namespace dlib ...@@ -462,13 +462,13 @@ namespace dlib
) const ) const
{ {
// first check if the sub_option is present // first check if the sub_option is present
if (option(sub_option).count() > 0) if (this->option(sub_option).count() > 0)
{ {
// now check if any of the parents are present // now check if any of the parents are present
bool parents_present = false; bool parents_present = false;
for (size_t i = 0; i < length; ++i) for (size_t i = 0; i < length; ++i)
{ {
if (option(parent_option_set[i]).count() > 0) if (this->option(parent_option_set[i]).count() > 0)
{ {
parents_present = true; parents_present = true;
break; break;
...@@ -497,7 +497,7 @@ namespace dlib ...@@ -497,7 +497,7 @@ namespace dlib
bool parents_present = false; bool parents_present = false;
for (size_t i = 0; i < parent_length; ++i) for (size_t i = 0; i < parent_length; ++i)
{ {
if (option(parent_option_set[i]).count() > 0) if (this->option(parent_option_set[i]).count() > 0)
{ {
parents_present = true; parents_present = true;
break; break;
...@@ -510,7 +510,7 @@ namespace dlib ...@@ -510,7 +510,7 @@ namespace dlib
size_t i = 0; size_t i = 0;
for (; i < sub_length; ++i) for (; i < sub_length; ++i)
{ {
if (option(sub_option_set[i]).count() > 0) if (this->option(sub_option_set[i]).count() > 0)
break; break;
} }
if (i != sub_length) if (i != sub_length)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment