From bb4dd8289b351fae6b55e303f189127a394a1edd Mon Sep 17 00:00:00 2001 From: Anas Nashif Date: Mon, 26 Aug 2013 08:15:55 -0400 Subject: Imported Upstream version 1.51.0 --- tools/bcp/copy_path.cpp | 14 +++++++++----- tools/bcp/fileview.cpp | 2 +- tools/bcp/licence_info.cpp | 2 +- tools/bcp/main.cpp | 2 +- tools/bcp/output_licence_info.cpp | 2 ++ tools/bcp/scan_cvs_path.cpp | 2 +- tools/bcp/scan_licence.cpp | 4 ++-- 7 files changed, 17 insertions(+), 11 deletions(-) (limited to 'tools/bcp') diff --git a/tools/bcp/copy_path.cpp b/tools/bcp/copy_path.cpp index 4fe897d43d..497dcd5c86 100644 --- a/tools/bcp/copy_path.cpp +++ b/tools/bcp/copy_path.cpp @@ -134,7 +134,7 @@ void bcp_implementation::copy_path(const fs::path& p) "(?|" "(namespace\\s+)boost(_\\w+)?(?:(\\s*::\\s*)phoenix)?" "|" - "(namespace\\s+)(adstl|phoenix|rapidxml)\\>" + "(namespace\\s+(?:detail::)?)(adstl|phoenix|rapidxml)\\>" "|" "()\\ get_licenses() ) , }; - return std::pair(licenses, sizeof(licenses)/sizeof(licenses[0])); + return std::pair(licenses, static_cast(sizeof(licenses)/sizeof(licenses[0]))); } std::string format_authors_name(const std::string& name) diff --git a/tools/bcp/main.cpp b/tools/bcp/main.cpp index 28a5491e7c..aab15029d1 100644 --- a/tools/bcp/main.cpp +++ b/tools/bcp/main.cpp @@ -47,7 +47,7 @@ void show_usage() "output-path: the path to which files will be copied\n"; } -bool filesystem_name_check( const std::string & name ) +bool filesystem_name_check( const std::string & ) { return true; } diff --git a/tools/bcp/output_licence_info.cpp b/tools/bcp/output_licence_info.cpp index 2349acc83f..d42268fdbf 100644 --- a/tools/bcp/output_licence_info.cpp +++ b/tools/bcp/output_licence_info.cpp @@ -28,6 +28,8 @@ struct split_path const fs::path& file; split_path(const fs::path& r, const fs::path& f) : root(r), file(f){} +private: + split_path& operator=(const split_path&); }; std::ostream& operator << (std::ostream& os, const split_path& p) diff --git a/tools/bcp/scan_cvs_path.cpp b/tools/bcp/scan_cvs_path.cpp index 3c5eb2ea58..6d2eb3a600 100644 --- a/tools/bcp/scan_cvs_path.cpp +++ b/tools/bcp/scan_cvs_path.cpp @@ -31,7 +31,7 @@ void bcp_implementation::scan_cvs_path(const fs::path& p) static const boost::regex dir_expression("^(?:A\\s+)?D/([^/\\n]+)/"); static const int file_subs[] = {1,2,}; - for(int entry = 0; entry < sizeof(file_list)/sizeof(file_list[0]); ++entry) + for(std::size_t entry = 0; entry < sizeof(file_list)/sizeof(file_list[0]); ++entry) { fs::path entries(m_boost_path / p / file_list[entry]); if(fs::exists(entries)) diff --git a/tools/bcp/scan_licence.cpp b/tools/bcp/scan_licence.cpp index d1bf0bbebb..c061583a2c 100644 --- a/tools/bcp/scan_licence.cpp +++ b/tools/bcp/scan_licence.cpp @@ -27,8 +27,8 @@ context_before_license(const fileview& v, fileview::const_iterator start, { char last_char = '\0'; while (start != v.begin() && context_lines >= 0) { - if (*start == '\r' || *start == '\n' - && (last_char == *start || (last_char != '\r' && last_char != '\n'))) + if ((*start == '\r') || (*start == '\n') + && ((last_char == *start) || ((last_char != '\r') && (last_char != '\n')))) --context_lines; last_char = *start; -- cgit v1.2.3