mirror of
https://github.com/KingDuckZ/dindexer.git
synced 2025-07-03 14:14:11 +00:00
Warning fix on clang
This commit is contained in:
parent
a27b1ccec8
commit
3a2db550d2
12 changed files with 22 additions and 22 deletions
|
@ -164,7 +164,7 @@ namespace mchlib {
|
||||||
auto end = parList.end();
|
auto end = parList.end();
|
||||||
for (auto it = parList.begin(); it != end; ++it) {
|
for (auto it = parList.begin(); it != end; ++it) {
|
||||||
if (not it->is_directory)
|
if (not it->is_directory)
|
||||||
return std::move(it);
|
return it;
|
||||||
}
|
}
|
||||||
return parList.end();
|
return parList.end();
|
||||||
}
|
}
|
||||||
|
@ -174,7 +174,7 @@ namespace mchlib {
|
||||||
auto end = parList.end();
|
auto end = parList.end();
|
||||||
for (auto it = parList.begin(); it != end; ++it) {
|
for (auto it = parList.begin(); it != end; ++it) {
|
||||||
if (not it->is_directory)
|
if (not it->is_directory)
|
||||||
return std::move(it);
|
return it;
|
||||||
}
|
}
|
||||||
return parList.end();
|
return parList.end();
|
||||||
}
|
}
|
||||||
|
|
|
@ -109,7 +109,7 @@ namespace mchlib {
|
||||||
std::vector<typename std::conditional<Const, const FileRecordData*, FileRecordData*>::type> retval;
|
std::vector<typename std::conditional<Const, const FileRecordData*, FileRecordData*>::type> retval;
|
||||||
|
|
||||||
implem::flattened_listing(parContent, retval);
|
implem::flattened_listing(parContent, retval);
|
||||||
return std::move(retval);
|
return retval;
|
||||||
}
|
}
|
||||||
} //namespace mchlib
|
} //namespace mchlib
|
||||||
|
|
||||||
|
|
|
@ -45,7 +45,7 @@ namespace dinlib {
|
||||||
("version", "Prints the program's version and quits")
|
("version", "Prints the program's version and quits")
|
||||||
//("dump-raw,D", po::value<std::string>(), "Saves the retrieved html to the named file; use - for stdout")
|
//("dump-raw,D", po::value<std::string>(), "Saves the retrieved html to the named file; use - for stdout")
|
||||||
;
|
;
|
||||||
return std::move(desc);
|
return desc;
|
||||||
}
|
}
|
||||||
|
|
||||||
void print_commandline_help (std::ostream& parStream, const std::string& parSummary, const boost::program_options::options_description& parOpts) {
|
void print_commandline_help (std::ostream& parStream, const std::string& parSummary, const boost::program_options::options_description& parOpts) {
|
||||||
|
|
|
@ -34,7 +34,7 @@ namespace din {
|
||||||
|
|
||||||
IDDescMap retmap;
|
IDDescMap retmap;
|
||||||
if (parIDs.empty()) {
|
if (parIDs.empty()) {
|
||||||
return std::move(retmap);
|
return retmap;
|
||||||
}
|
}
|
||||||
|
|
||||||
std::ostringstream oss;
|
std::ostringstream oss;
|
||||||
|
@ -46,7 +46,7 @@ namespace din {
|
||||||
for (const auto& record : resultset) {
|
for (const auto& record : resultset) {
|
||||||
retmap[lexical_cast<IDDescMap::key_type>(record["id"])] = record["desc"];
|
retmap[lexical_cast<IDDescMap::key_type>(record["id"])] = record["desc"];
|
||||||
}
|
}
|
||||||
return std::move(retmap);
|
return retmap;
|
||||||
}
|
}
|
||||||
} //unnamed namespace
|
} //unnamed namespace
|
||||||
|
|
||||||
|
|
|
@ -35,7 +35,7 @@ namespace din {
|
||||||
if (parOpen) {
|
if (parOpen) {
|
||||||
conn.connect();
|
conn.connect();
|
||||||
}
|
}
|
||||||
return std::move(conn);
|
return conn;
|
||||||
}
|
}
|
||||||
|
|
||||||
std::vector<LocatedSet> sets_result_to_vec (pq::ResultSet&& parResult) {
|
std::vector<LocatedSet> sets_result_to_vec (pq::ResultSet&& parResult) {
|
||||||
|
@ -52,7 +52,7 @@ namespace din {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
return std::move(retval);
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
std::vector<LocatedItem> file_result_to_vec (pq::ResultSet&& parResult) {
|
std::vector<LocatedItem> file_result_to_vec (pq::ResultSet&& parResult) {
|
||||||
|
@ -68,7 +68,7 @@ namespace din {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
return std::move(retval);
|
return retval;
|
||||||
}
|
}
|
||||||
} //unnamed namespace
|
} //unnamed namespace
|
||||||
|
|
||||||
|
|
|
@ -136,7 +136,7 @@ namespace mchlib {
|
||||||
retmap[std::move(mount)] = std::move(dev);
|
retmap[std::move(mount)] = std::move(dev);
|
||||||
}
|
}
|
||||||
|
|
||||||
return std::move(retmap);
|
return retmap;
|
||||||
}
|
}
|
||||||
|
|
||||||
#if defined(WITH_MEDIA_AUTODETECT)
|
#if defined(WITH_MEDIA_AUTODETECT)
|
||||||
|
|
|
@ -64,7 +64,7 @@ namespace mchlib {
|
||||||
for (; it_begin != it_end; ++it_begin) {
|
for (; it_begin != it_end; ++it_begin) {
|
||||||
retval.push_back(&*it_begin);
|
retval.push_back(&*it_begin);
|
||||||
}
|
}
|
||||||
return std::move(retval);
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
std::vector<int> check_missing_content (const std::vector<const FileRecordData*>& parContent, const std::vector<const char*>& parCheck) {
|
std::vector<int> check_missing_content (const std::vector<const FileRecordData*>& parContent, const std::vector<const char*>& parCheck) {
|
||||||
|
@ -84,7 +84,7 @@ namespace mchlib {
|
||||||
retval.push_back(z);
|
retval.push_back(z);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return std::move(retval);
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool identify_video_dvd (MediaTypes parMediaType, const ConstSetListingView& parContent, const std::vector<const FileRecordData*>& parFlatContent ) {
|
bool identify_video_dvd (MediaTypes parMediaType, const ConstSetListingView& parContent, const std::vector<const FileRecordData*>& parFlatContent ) {
|
||||||
|
|
|
@ -107,7 +107,7 @@ namespace mchlib {
|
||||||
slash = "/";
|
slash = "/";
|
||||||
}
|
}
|
||||||
assert(reserve == out.size());
|
assert(reserve == out.size());
|
||||||
return std::move(out);
|
return out;
|
||||||
}
|
}
|
||||||
} //unnamed namespace
|
} //unnamed namespace
|
||||||
|
|
||||||
|
@ -185,7 +185,7 @@ namespace mchlib {
|
||||||
for (std::size_t z = 0; z < remaining_atoms; ++z) {
|
for (std::size_t z = 0; z < remaining_atoms; ++z) {
|
||||||
retval.join(parOtherPath[z + common_atoms], parOtherPath.get_stringref_source(z + common_atoms));
|
retval.join(parOtherPath[z + common_atoms], parOtherPath.get_stringref_source(z + common_atoms));
|
||||||
}
|
}
|
||||||
return std::move(retval);
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
const std::string* PathName::get_stringref_source (std::size_t parIndex) const {
|
const std::string* PathName::get_stringref_source (std::size_t parIndex) const {
|
||||||
|
|
|
@ -110,7 +110,7 @@ namespace din {
|
||||||
for (const auto& row : res) {
|
for (const auto& row : res) {
|
||||||
retval.push_back(lexical_cast<uint32_t>(row[0]));
|
retval.push_back(lexical_cast<uint32_t>(row[0]));
|
||||||
}
|
}
|
||||||
return std::move(retval);
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
void DBSource::query_no_conditions (const ColumnList& parCols, boost::string_ref parTable, const std::vector<uint32_t>& parIDs, std::function<void(std::string&&)> parCallback) {
|
void DBSource::query_no_conditions (const ColumnList& parCols, boost::string_ref parTable, const std::vector<uint32_t>& parIDs, std::function<void(std::string&&)> parCallback) {
|
||||||
|
|
|
@ -105,13 +105,13 @@ namespace din {
|
||||||
std::vector<std::string> columns;
|
std::vector<std::string> columns;
|
||||||
columns.reserve(sizeof...(Details));
|
columns.reserve(sizeof...(Details));
|
||||||
|
|
||||||
const std::array<M, sizeof...(Details)> details { Details... };
|
const std::array<M, sizeof...(Details)> details { {Details...} };
|
||||||
//AtFunc at_func = &SetDetailsMap::at;
|
//AtFunc at_func = &SetDetailsMap::at;
|
||||||
//std::generate(details.begin(), details.end(), columns.begin(), std::bind(at_func, &details_dic, std::placeholders::_1));
|
//std::generate(details.begin(), details.end(), columns.begin(), std::bind(at_func, &details_dic, std::placeholders::_1));
|
||||||
for (auto detail : details) {
|
for (auto detail : details) {
|
||||||
columns.push_back(parDic.at(detail));
|
columns.push_back(parDic.at(detail));
|
||||||
}
|
}
|
||||||
return std::move(columns);
|
return columns;
|
||||||
}
|
}
|
||||||
} //namespace implem
|
} //namespace implem
|
||||||
|
|
||||||
|
@ -126,7 +126,7 @@ namespace din {
|
||||||
FlatInsertIn2DList<ReturnType> flat_list(&list, sizeof...(D));
|
FlatInsertIn2DList<ReturnType> flat_list(&list, sizeof...(D));
|
||||||
FlatPushBackFunc pback_func = &FlatInsertIn2DList<ReturnType>::push_back;
|
FlatPushBackFunc pback_func = &FlatInsertIn2DList<ReturnType>::push_back;
|
||||||
this->query_no_conditions(columns, "sets", parIDs, std::bind(pback_func, &flat_list, std::placeholders::_1));
|
this->query_no_conditions(columns, "sets", parIDs, std::bind(pback_func, &flat_list, std::placeholders::_1));
|
||||||
return std::move(list);
|
return list;
|
||||||
}
|
}
|
||||||
|
|
||||||
template <FileDetails... D>
|
template <FileDetails... D>
|
||||||
|
@ -140,7 +140,7 @@ namespace din {
|
||||||
FlatInsertIn2DList<ReturnType> flat_list(&list, sizeof...(D));
|
FlatInsertIn2DList<ReturnType> flat_list(&list, sizeof...(D));
|
||||||
FlatPushBackFunc pback_func = &FlatInsertIn2DList<ReturnType>::push_back;
|
FlatPushBackFunc pback_func = &FlatInsertIn2DList<ReturnType>::push_back;
|
||||||
this->query_files_in_dir(columns, parDir, parLevel, parSetID, std::bind(pback_func, &flat_list, std::placeholders::_1));
|
this->query_files_in_dir(columns, parDir, parLevel, parSetID, std::bind(pback_func, &flat_list, std::placeholders::_1));
|
||||||
return std::move(list);
|
return list;
|
||||||
}
|
}
|
||||||
} //namespace din
|
} //namespace din
|
||||||
|
|
||||||
|
|
|
@ -42,7 +42,7 @@ namespace din {
|
||||||
boost::copy(row, infix_ostream_iterator<std::string>(oss, "\t"));
|
boost::copy(row, infix_ostream_iterator<std::string>(oss, "\t"));
|
||||||
result.push_back(oss.str());
|
result.push_back(oss.str());
|
||||||
}
|
}
|
||||||
return std::move(result);
|
return result;
|
||||||
}
|
}
|
||||||
} //unnamed namespace
|
} //unnamed namespace
|
||||||
|
|
||||||
|
|
|
@ -187,13 +187,13 @@ namespace pq {
|
||||||
call_PQputf(retval.get(), parTypes, argp);
|
call_PQputf(retval.get(), parTypes, argp);
|
||||||
va_end(argp);
|
va_end(argp);
|
||||||
|
|
||||||
return std::move(retval);
|
return retval;
|
||||||
}
|
}
|
||||||
|
|
||||||
auto Connection::make_empty_params() const -> PGParams {
|
auto Connection::make_empty_params() const -> PGParams {
|
||||||
assert(is_connected());
|
assert(is_connected());
|
||||||
auto ret = PGParams(PQparamCreate(m_localData->connection), &PQparamClear);
|
auto ret = PGParams(PQparamCreate(m_localData->connection), &PQparamClear);
|
||||||
assert(ret.get());
|
assert(ret.get());
|
||||||
return std::move(ret);
|
return ret;
|
||||||
}
|
}
|
||||||
} //namespace pq
|
} //namespace pq
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue