Skip to content

Commit

Permalink
Remove duplicates, fix copy&paste errors in cfg files (#6047)
Browse files Browse the repository at this point in the history
  • Loading branch information
chrchr-github authored Feb 27, 2024
1 parent da518aa commit d7e0120
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 173 deletions.
14 changes: 7 additions & 7 deletions cfg/qt.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -381,7 +381,7 @@
<!-- QMetaObject::Connection QObject::connect(const QObject *sender, PointerToMemberFunction signal, const QObject *receiver, PointerToMemberFunction method, Qt::ConnectionType type = Qt::AutoConnection) // static -->
<!-- QMetaObject::Connection QObject::connect(const QObject *sender, PointerToMemberFunction signal, Functor functor) // static -->
<!-- QMetaObject::Connection QObject::connect(const QObject *sender, PointerToMemberFunction signal, const QObject *context, Functor functor, Qt::ConnectionType type = Qt::AutoConnection) // static -->
<function name="connect,QObject::connect">
<function name="QObject::connect">
<noreturn>false</noreturn>
<leak-ignore/>
<arg nr="1" direction="in">
Expand Down Expand Up @@ -2280,7 +2280,7 @@
</arg>
</function>
<!-- bool QDir::cdUp() -->
<function name="QDir::cd">
<function name="QDir::cdUp">
<noreturn>false</noreturn>
<returnValue type="bool"/>
<use-retval type="error-code"/>
Expand All @@ -2298,7 +2298,7 @@
</arg>
</function>
<!-- uint QDir::count() const -->
<function name="QDir::cd">
<function name="QDir::count">
<noreturn>false</noreturn>
<returnValue type="uint"/>
<use-retval/>
Expand Down Expand Up @@ -3196,7 +3196,7 @@
</function>
<!-- QXmlStreamWriter https://doc.qt.io/qt-5/qxmlstreamwriter.html -->
<!-- bool QXmlStreamWriter::autoFormatting() const -->
<function name="QXmlStreamWriter::autoFormattingIndent">
<function name="QXmlStreamWriter::autoFormatting">
<noreturn>false</noreturn>
<returnValue type="bool"/>
<use-retval/>
Expand All @@ -3220,7 +3220,7 @@
<const/>
</function>
<!-- QIODevice *QXmlStreamWriter::device() const -->
<function name="QXmlStreamWriter::codec">
<function name="QXmlStreamWriter::device">
<noreturn>false</noreturn>
<returnValue type="QIODevice *"/>
<use-retval/>
Expand Down Expand Up @@ -3273,7 +3273,7 @@
</arg>
</function>
<!-- void QXmlStreamWriter::writeAttributes(const QXmlStreamAttributes &attributes) -->
<function name="QXmlStreamWriter::writeAttribute">
<function name="QXmlStreamWriter::writeAttributes">
<noreturn>false</noreturn>
<returnValue type="void"/>
<leak-ignore/>
Expand Down Expand Up @@ -3828,7 +3828,7 @@
</arg>
</function>
<!-- void QLabel::setWordWrap(bool on) -->
<function name="QLabel::setText">
<function name="QLabel::setWordWrap">
<noreturn>false</noreturn>
<returnValue type="void"/>
<leak-ignore/>
Expand Down
97 changes: 4 additions & 93 deletions cfg/std.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -4305,57 +4305,6 @@ The obsolete function 'gets' is called. With 'gets' you'll get a buffer overrun
<valid>!0.0</valid>
</arg>
</function>
<!-- double remquo(double, x, double y, int *quo); -->
<function name="remquo,std::remquo">
<use-retval/>
<pure/>
<returnValue type="double"/>
<noreturn>false</noreturn>
<leak-ignore/>
<arg nr="1" direction="in">
<not-uninit/>
</arg>
<arg nr="2" direction="in">
<not-uninit/>
</arg>
<arg nr="3" direction="out">
<not-null/>
</arg>
</function>
<!-- float remquof(float x, float y, int *quo); -->
<function name="remquof,std::remquof">
<use-retval/>
<pure/>
<returnValue type="float"/>
<noreturn>false</noreturn>
<leak-ignore/>
<arg nr="1" direction="in">
<not-uninit/>
</arg>
<arg nr="2" direction="in">
<not-uninit/>
</arg>
<arg nr="3" direction="out">
<not-null/>
</arg>
</function>
<!-- long double remquol(long double x, long double y, int *quo); -->
<function name="remquol,std::remquol">
<use-retval/>
<pure/>
<returnValue type="long double"/>
<noreturn>false</noreturn>
<leak-ignore/>
<arg nr="1" direction="in">
<not-uninit/>
</arg>
<arg nr="2" direction="in">
<not-uninit/>
</arg>
<arg nr="3" direction="out">
<not-null/>
</arg>
</function>
<!-- int printf(const char *format, ...); -->
<function name="printf,std::printf">
<returnValue type="int"/>
Expand Down Expand Up @@ -6430,14 +6379,7 @@ The obsolete function 'gets' is called. With 'gets' you'll get a buffer overrun
std::istringstream& std::istringstream::get (streambuf& sb, char delim);-->
<!-- There is currently no way to define this properly because Cppcheck lacks support for
overloaded functions.-->
<function name="std::istream::get,std::istringstream::get">
<noreturn>false</noreturn>
<leak-ignore/>
<arg nr="any"/>
</function>
<!-- std::basic_string<CharT,Traits,Allocator> str() const; -->
<!-- void str( const std::basic_string<CharT,Traits,Allocator>& s ); -->
<function name="std::stringstream::str,std::istringstream::str,std::ostringstream::str">
<function name="std::istream::get,std::ifstream::get,std::istringstream::get">
<noreturn>false</noreturn>
<leak-ignore/>
<arg nr="any"/>
Expand Down Expand Up @@ -6540,7 +6482,7 @@ The obsolete function 'gets' is called. With 'gets' you'll get a buffer overrun
<!-- std::string std::basic_stringstream::str() const; -->
<!-- @todo Implement the second version when function overloading is possible: -->
<!-- void std::ostringstream::str(const string & s); -->
<function name="std::ostringstream::str,std::stringstream::str,std::basic_stringstream::str">
<function name="std::istringstream::str,std::ostringstream::str,std::stringstream::str,std::basic_stringstream::str">
<use-retval/>
<const/>
<returnValue type="std::string"/>
Expand Down Expand Up @@ -6774,7 +6716,7 @@ The obsolete function 'gets' is called. With 'gets' you'll get a buffer overrun
<not-uninit/>
</arg>
</function>
<function name="std::vector::at,std::array::at,std::string::at,std::wstring::at,std::string_view::at,std::wstring_view::at">
<function name="std::vector::at,std::deque::at,std::array::at,std::string_view::at,std::wstring_view::at">
<use-retval/>
<noreturn>false</noreturn>
<arg nr="1">
Expand Down Expand Up @@ -7177,24 +7119,6 @@ The obsolete function 'gets' is called. With 'gets' you'll get a buffer overrun
<not-uninit/>
</arg>
</function>
<!-- istream& get (char* s, streamsize n ); -->
<!-- istream& get (char* s, streamsize n, char delim ); -->
<function name="std::istream::get,std::ifstream::get">
<noreturn>false</noreturn>
<leak-ignore/>
<arg nr="1" direction="out">
<not-null/>
<strz/>
<minsize type="argvalue" arg="2"/>
</arg>
<arg nr="2" direction="in">
<not-uninit/>
<valid>0:</valid>
</arg>
<arg nr="3" default="'\n'" direction="in">
<not-uninit/>
</arg>
</function>
<!-- Not part of standard, but widely supported by runtime libraries. -->
<!-- char * itoa (int value, char * str, int base); -->
<function name="itoa">
Expand Down Expand Up @@ -8262,19 +8186,6 @@ initializer list (7) string& replace (const_iterator i1, const_iterator i2, init
<not-uninit/>
</arg>
</function>
<!-- T& std::deque::at( size_type pos ); -->
<!-- const T& std::deque::at( size_type pos ) const; -->
<!-- T& std::array::at( size_type pos ); -->
<!-- const T& std::array::at( size_type pos ) const; -->
<function name="std::deque::at,std::array::at">
<noreturn>false</noreturn>
<use-retval/>
<leak-ignore/>
<arg nr="1" direction="in">
<not-uninit/>
<valid>0:</valid>
</arg>
</function>
<!-- C Threads https://en.cppreference.com/w/c/thread -->
<!-- int thrd_create( thrd_t *thr, thrd_start_t func, void *arg ); // since C11 -->
<function name="thrd_create">
Expand Down Expand Up @@ -8654,7 +8565,7 @@ initializer list (7) string& replace (const_iterator i1, const_iterator i2, init
<arg nr="variadic">
</arg>
</function>
<function name="std::exception::what,std::logic_error::what,std::invalid_argument::what,std::domain_error::what,std::length_error::what,std::out_of_range::what,std::future_error::what,std::runtime_error::what,std::range_error::what,std::overflow_error::what,std::underflow_error::what,std::regex_error::what,std::system_error::what,std::ios_base::failure::what,std::filesystem::filesystem_error::what,std::nonexistent_local_time::what,std::ambiguous_local_time::what,std::format_error::what,std::bad_typeid::what,std::bad_cast::what,std::bad_any_cast::what,std::bad_optional_access::what,std::bad_expected_access::what,std::bad_weak_ptr::what,std::bad_function_call::what,std::bad_alloc::what,std::bad_array_new_length::what,std::bad_exception::what,std::ios_base::failure::what,std::bad_variant_access::what">
<function name="std::exception::what,std::logic_error::what,std::invalid_argument::what,std::domain_error::what,std::length_error::what,std::out_of_range::what,std::future_error::what,std::runtime_error::what,std::range_error::what,std::overflow_error::what,std::underflow_error::what,std::regex_error::what,std::system_error::what,std::ios_base::failure::what,std::filesystem::filesystem_error::what,std::nonexistent_local_time::what,std::ambiguous_local_time::what,std::format_error::what,std::bad_typeid::what,std::bad_cast::what,std::bad_any_cast::what,std::bad_optional_access::what,std::bad_expected_access::what,std::bad_weak_ptr::what,std::bad_function_call::what,std::bad_alloc::what,std::bad_array_new_length::what,std::bad_exception::what,std::bad_variant_access::what">
<noreturn>false</noreturn>
<use-retval/>
<returnValue type="const char *"/>
Expand Down
73 changes: 0 additions & 73 deletions cfg/windows.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -2225,28 +2225,6 @@
<not-uninit/>
</arg>
</function>
<!-- int _stricmp_l(const char *string1, const char *string2, _locale_t locale); -->
<!-- int _wcsicmp_l(const wchar_t *string1, const wchar_t *string2, _locale_t locale); -->
<!-- int _mbsicmp_l(const wchar_t *string1, const wchar_t *string2, _locale_t locale); -->
<function name="_stricmp_l,_wcsicmp_l,_mbsicmp_l">
<noreturn>false</noreturn>
<returnValue type="int"/>
<leak-ignore/>
<use-retval/>
<arg nr="1" direction="in">
<not-uninit/>
<not-null/>
<strz/>
</arg>
<arg nr="2" direction="in">
<not-uninit/>
<not-null/>
<strz/>
</arg>
<arg nr="3" direction="in">
<not-uninit/>
</arg>
</function>
<!-- int stricmp(const char *s1, const char *s2); -->
<!-- int _stricmp(const char *s1, const char *s2); -->
<!-- int wcsicmp(const wchar_t *s1, const wchar_t *s2); -->
Expand Down Expand Up @@ -2550,18 +2528,6 @@ HFONT CreateFont(
</arg>
<arg nr="4"/>
</function>
<!-- char *strdup(const char *s); -->
<function name="strdup">
<noreturn>false</noreturn>
<returnValue type="char *"/>
<use-retval/>
<warn severity="style" alternatives="_strdup" reason="Obsolete">These POSIX functions are deprecated. Use the ISO C++ conformant _strdup, _wcsdup, _mbsdup instead.</warn>
<arg nr="1">
<not-null/>
<not-uninit/>
<not-bool/>
</arg>
</function>
<!-- wchar_t *wcsdup(const wchar_t *s); -->
<function name="wcsdup">
<noreturn>false</noreturn>
Expand Down Expand Up @@ -3347,26 +3313,6 @@ HFONT CreateFont(
<not-uninit/>
</arg>
</function>
<!-- int _stricmp(const char *str1, const char *str2); -->
<!-- int _wcsicmp(const wchar_t *str1, const wchar_t *str2) -->
<!-- int _mbsicmp(const unsigned char *str1, const unsigned char *str2) -->
<function name="_stricmp,_wcsicmp,_mbsicmp,_tcsicmp">
<use-retval/>
<pure/>
<returnValue type="int"/>
<noreturn>false</noreturn>
<leak-ignore/>
<arg nr="1" direction="in">
<not-null/>
<not-uninit/>
<strz/>
</arg>
<arg nr="2" direction="in">
<not-null/>
<not-uninit/>
<strz/>
</arg>
</function>
<!-- int _stricmp_l(const char *str1, const char *str2, _locale_t locale); -->
<!-- int _wcsicmp_l(const wchar_t *str1, const wchar_t *str2, _locale_t locale) -->
<!-- int _mbsicmp_l(const unsigned char *str1, const unsigned char *str2, _locale_t locale) -->
Expand Down Expand Up @@ -6907,25 +6853,6 @@ HFONT CreateFont(
<not-bool/>
</arg>
</function>
<!-- VERSIONHELPERAPI is defined as "inline bool" in VersionHelpers.h -->
<!-- VERSIONHELPERAPI IsWindowsXPOrGreater(); -->
<!-- VERSIONHELPERAPI IsWindowsXPSP1OrGreater(); -->
<!-- VERSIONHELPERAPI IsWindowsXPSP2OrGreater(); -->
<!-- VERSIONHELPERAPI IsWindowsXPSP3OrGreater(); -->
<!-- VERSIONHELPERAPI IsWindowsVistaOrGreater(); -->
<!-- VERSIONHELPERAPI IsWindowsVistaSP1OrGreater(); -->
<!-- VERSIONHELPERAPI IsWindowsVistaSP2OrGreater(); -->
<!-- VERSIONHELPERAPI IsWindows7OrGreater(); -->
<!-- VERSIONHELPERAPI IsWindows7SP1OrGreater(); -->
<!-- VERSIONHELPERAPI IsWindows8OrGreater(); -->
<!-- VERSIONHELPERAPI IsWindows8Point1OrGreater(); -->
<!-- VERSIONHELPERAPI IsWindows10OrGreater(); -->
<!-- VERSIONHELPERAPI IsWindowsServer(); -->
<function name="IsWindowsXPOrGreater,IsWindowsXPSP1OrGreater,IsWindowsXPSP2OrGreater,IsWindowsXPSP3OrGreater,IsWindowsVistaOrGreater,IsWindowsVistaSP1OrGreater,IsWindowsVistaSP2OrGreater,IsWindows7OrGreater,IsWindows7SP1OrGreater,IsWindows8OrGreater,IsWindows8Point1OrGreater,IsWindows10OrGreater,IsWindowsServer">
<noreturn>false</noreturn>
<returnValue type="bool"/>
<use-retval/>
</function>
<!-- int _setmode (int fd, int mode); -->
<function name="_setmode">
<noreturn>false</noreturn>
Expand Down

0 comments on commit d7e0120

Please sign in to comment.