Commit Graph

26 Commits

Author SHA1 Message Date
Paul Fultz II 7f358b2bed
Format with uncrustify (#3388) 2021-08-07 20:51:18 +02:00
Paul fec2914700 Add tests for container changes 2020-08-09 22:52:03 -05:00
Paul 26693df788 Use forward analyzer for container forward 2020-08-08 00:10:03 -05:00
Jens Yllman aa380e0de1 fix a test that was suppressed because #9002 2020-06-19 23:04:15 +02:00
Sebastian 8fd17546ad
qt.cfg: #9650: Fix missing configuration for QString.chop() (#2556)
chop() and also remove() change the size of a QString, so they have to
be added in the container configuration accordingly to avoid false
positives.
2020-02-26 10:53:03 +01:00
Paul Fultz II 42d44f02a2 Use lifetime analysis for checking mismatching containers (#2456)
* Use lifetimes to check for mismatching containers

* Fix error messages

* Format

* Remove unused variables

* Fix configuration and track iterators through algorithms

* Fix iterator value types in qt config

* Fix library issue with QStringList

* Remove unused functions

* Fix cppcheck errors
2019-12-25 09:32:50 +01:00
Sebastian fbbaea3cd9
qt.cfg: Add some missing macro definitions (#2175)
Found by daca@home
2019-09-16 15:58:35 +02:00
Sebastian 2c673bd380
qt.cfg: Add container configuration for QStack (inherits from QVector) (#2102) 2019-08-20 20:37:52 +02:00
Sebastian 26dfee58f8
qt.cfg: Add QLinkedList container configuration and some tests. (#2099) 2019-08-20 07:09:43 +02:00
Sebastian 544bedc6ee
qt.cfg: Add QByteArray container configuration (similar to QString) (#2088)
Reference: https://doc.qt.io/qt-5/qbytearray.html
2019-08-15 16:14:17 +02:00
Sebastian 81edb23c16
qt.cfg: Fix and enhance Qt container configuration (#2055)
-Add iterator end patterns
-Add/fix size and access functions
-Remove marking QList and QStringList as std-like strings
-QStringList configuration now inherits from QList like it is actually the case
-Add tests
2019-08-15 10:23:05 +02:00
Sebastian 549452b7b9
qt.cfg: Add container and function configurations for QVector (#2052)
Reference: https://doc.qt.io/qt-5/qvector.html
2019-07-31 13:58:55 +02:00
Sebastian 61f911d39a
qt.cfg: Add Q_DECLARE_TR_FUNCTIONS() and others (#1677)
Add unknownMacro Q_DECLARE_TR_FUNCTIONS found via daca@home.
Add function QCoreApplication::translate() and macro
QT_DECLARE_DEPRECATED_TR_FUNCTIONS() the unknownMacro depends on.
Reference:
https://doc.qt.io/qt-5/qcoreapplication.html#Q_DECLARE_TR_FUNCTIONS
https://doc.qt.io/qt-5/qcoreapplication.html#translate
2019-02-26 13:39:37 +01:00
versat fe6ea282d3 qt.cfg: Add support for QT_TR_NOOP* and QT_TRANSLATE_NOOP* macros
Reference:
https://doc.qt.io/qt-5/i18n-source-translation.html#using-qt-tr-noop-and-qt-translate-noop-in-c
2019-02-12 10:21:56 +01:00
versat 8207e48adc qt.cfg: Add support for macros Q_LIKELY and Q_UNLIKELY
Reference:
https://doc.qt.io/qt-5/qtglobal.html#Q_LIKELY
https://doc.qt.io/qt-5/qtglobal.html#Q_UNLIKELY
2019-02-12 08:21:49 +01:00
Sebastian 2c1f97d787
qt.cfg: Add support for macros `forever` and `Q_FOREVER` (#1662)
Reference:
https://doc.qt.io/qt-5/qtglobal.html#forever
https://doc.qt.io/qt-5/qtglobal.html#Q_FOREVER
2019-02-11 16:35:01 +01:00
Sebastian 5fe7aad5e3
qt.cfg: Add configuration and tests for macro Q_NULLPTR (#1651)
Qt defines `Q_NULLPTR` with `nullptr` if it is available, otherwise with `NULL`.
Since there seems to be no (sane) way to configure it the same way in the library configuration it is just defined with `NULL`.
2019-02-07 12:27:25 +01:00
Sebastian 55ce6d2073
qt.cfg: Add support and tests for QFile::exists function (#1645)
Found by daca@home
2019-02-06 13:23:05 +01:00
Sebastian b1f68229f2
Library cfg tests: Enable all tests again, exclude regressions for now (#1626)
Use `--check-library` for all tests as it was done before.
Re-enable all tests in runtests.sh again.
The regressions where runtests.sh would fail are disabled via "FIXME"
comment in the inline suppression comment.
2019-01-25 17:03:16 +01:00
Sebastian 7a59949cb4 qt config test: Use pkg-config to retrieve Qt settings. (#1571)
To be able to use real Qt-Code in "test/cfg/qt.cpp" and still do a
syntax check the Qt settings are read out via pkg-config now if it is
available. This way the test now can contain Qt macros and functions and
the syntax check can still be used.
Additionally the same options as for the other tests are used now for
the Qt config tests.
Installing the package "qtbase5-dev" should be enough to enable the
syntax checks (already installed for travis tests).
2019-01-07 14:40:21 +01:00
Daniel Marjamäki 58034dee86 Fixed #8076 (unmatched suppression when calling ./runtests.sh (test/cfg)) 2018-01-10 15:52:06 +01:00
Daniel Marjamäki 1422487769 astyle formatting
[ci skip]
2017-04-20 17:43:28 +02:00
Daniel Marjamäki efcf71a5dc qt.cfg: attempt to fix cfg test 2017-04-18 19:26:54 +02:00
Daniel Marjamäki 296f250caa qt.cfg: configure some QString methods 2017-04-18 19:21:34 +02:00
Daniel Marjamäki 01c5c2fc5b qt.cfg: Add reademptycontainer test 2017-04-18 18:47:35 +02:00
Daniel Marjamäki c229754a70 qt.cfg: Add configuration for QString 2017-04-18 18:04:27 +02:00