GCC warnings. Fixed bug with string concatenation in MSVC.

--HG--
branch : develop
This commit is contained in:
dismine 2014-10-18 13:51:40 +02:00
parent a06a162100
commit c717196199
3 changed files with 13 additions and 21 deletions

View File

@ -182,18 +182,19 @@ void Calculator::InitCharacterSets()
{ {
//String with all unique symbols for supported alpabets. //String with all unique symbols for supported alpabets.
// See script alphabets.py for generation and more information. // See script alphabets.py for generation and more information.
const QString symbols = QStringLiteral("ցЀĆЈVӧĎАғΕĖӅИқΝĞơРңњΥĦШҫ̆جگĮаҳѕεشԶиһνԾрυلՆӝшËՎҔPÓՖXӛӟŞӣզhëծpóӞնxßվāŁЃֆĉЋCŬđ\ //Note. MSVC doen't support normal string concatenation for long string. Thats why we use QStringList in this place.
ҐГΒęҘЛΚŘġҠУGاհЫدԱҰгβطԹõлκKՁÀуςهՉÈыvیՑÐSOřӘћաőcӐթèkàѓżűðsķչøӥӔĀփїІĈЎґĐΗЖҙĘȚ\ QStringList symbols = QStringList() << "ցЀĆЈVӧĎАғΕĖӅИқΝĞơРңњΥĦШҫ̆جگĮаҳѕεشԶиһνԾрυلՆӝшËՎҔPÓՖXӛӟŞӣզhëծpóӞնxßվāŁЃֆĉЋ"
ΟОҡĠآΧЦتЮұİزηжԸغοоÁՀقχцÉՈيюÑՐђӋіәťӆўáŠĺѐfөըnñŰӤӨӹոľЁրăЉŭċБӸēłΔҖЙŤěΜӜDСձģΤӰ\ << "CŬđҐГΒęҘЛΚŘġҠУGاհЫدԱҰгβطԹõлκKՁÀуςهՉÈыvیՑÐSOřӘћաőcӐթèkàѓżűðsķչøӥӔĀփїІĈЎ"
ЩīņحҮбưԳصδHйԻŇμӲӴсՃمτƠщՋєLQŹՓŕÖYśÞaգĽæiŽիӓîqճöyջþĂօЄӦĊЌΑĒДҗјΙȘĚМΡéĵĢФūӚΩبĪ\ << "ґĐΗЖҙĘȚΟОҡĠآΧЦتЮұİزηжԸغοоÁՀقχцÉՈيюÑՐђӋіәťӆўáŠĺѐfөըnñŰӤӨӹոľЁրăЉŭċБӸēłΔҖ"
ЬүќαذԲдҷιظԺмρՂфÇωوՊьÏՒTŚĻJբdçժlïӪղtպӫAւąЇčŃЏĕӯЗΖEțŮĝПΞأĥĹЧΦثÆӳЯIسŲԵзζԽпξكՅ\ << "ЙŤěΜӜDСձģΤӰЩīņحҮбưԳصδHйԻŇμӲӴсՃمτƠщՋєLQŹՓŕÖYśÞaգĽæiŽիӓîqճöyջþĂօЄӦĊЌΑĒДҗј"
ÄчφNMՍӌяӢՕÔWÎŝÜџёźեägխoӒյôwĶBžսüЂĄև̈ЊČƏљΓВҕĔӮΛКĜΣТҥĤکЪƯخγвŅԴŪضλкԼĴσтÅՄنъÍՌR\ << "ΙȘĚМΡéĵĢФūӚΩبĪЬүќαذԲдҷιظԺмρՂфÇωوՊьÏՒTŚĻJբdçժlïӪղtպӫAւąЇčŃЏĕӯЗΖEțŮĝПΞأĥ"
ӕՔZÝŜbåդjíլļrӵմzýռپêЅքćچЍďӱҒЕůėژșΘØҚНğńءΠFҢХħΨҪЭųįҶرҲеԷňعθҺнԿفπÂхՇψÊэšՏÒU\ << "ثĹЧΦÆӳЯIسŲԵзζԽпξكՅÄчφNMՍӌяӢՕÔWÎŝÜџёźեägխoӒյôwĶBžսüЂĄև̈ЊČƏљΓВҕĔӮΛКĜΣТҥĤک"
əÚѝŻşҤӑâeէŐımկòuշÕúտŔ"); << "ЪƯخγвŅԴŪضλкԼĴσтÅՄنъÍՌRӕՔZÝŜbåդjíլļrӵմzýռپêЅքćچЍďӱҒЕůėژșΘØҚНğńءΠFҢХħΨҪ"
<< "ЭųįҶرҲеԷňعθҺнԿفπÂхՇψÊэšՏÒUəÚѝŻşҤӑâeէŐımկòuշÕúտŔ";
// Defining identifier character sets // Defining identifier character sets
DefineNameChars(QStringLiteral("0123456789_") + symbols); DefineNameChars(QStringLiteral("0123456789_") + symbols.join(""));
DefineOprtChars(symbols + QStringLiteral("+-*^/?<>=#!$%&|~'_")); DefineOprtChars(symbols.join("") + QStringLiteral("+-*^/?<>=#!$%&|~'_"));
} }
//--------------------------------------------------------------------------------------------------------------------- //---------------------------------------------------------------------------------------------------------------------

View File

@ -45,7 +45,7 @@ class VException : public QException
public: public:
VException(const QString &what); VException(const QString &what);
VException(const VException &e); VException(const VException &e);
Q_NORETURN virtual ~VException() V_NOEXCEPT_EXPR (true){} virtual ~VException() V_NOEXCEPT_EXPR (true){}
Q_NORETURN virtual void raise() const; Q_NORETURN virtual void raise() const;
// cppcheck-suppress unusedFunction // cppcheck-suppress unusedFunction

View File

@ -37,15 +37,6 @@
#define QMUP_CHARS "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ" #define QMUP_CHARS "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"
//// Is noexcept supported?
//#if defined(__clang__) && defined(__has_feature) && __has_feature(cxx_noexcept) || \
// defined(__GXX_EXPERIMENTAL_CXX0X__) && __GNUC__ * 10 + __GNUC_MINOR__ >= 46 || \
// defined(_MSC_FULL_VER) && _MSC_FULL_VER >= 180021114
//# define QMUP_NOEXCEPT_EXPR(x) noexcept(x)
//#else
//# define QMUP_NOEXCEPT_EXPR(x)
//#endif
// Detect whether the compiler supports C++11 noexcept exception specifications. // Detect whether the compiler supports C++11 noexcept exception specifications.
# if defined(__clang__) # if defined(__clang__)
# if __has_feature(cxx_noexcept) # if __has_feature(cxx_noexcept)