From f424c3460f135aee2facc111869b678d65f125a6 Mon Sep 17 00:00:00 2001 From: Oswald Buddenhagen Date: Mon, 22 Nov 2010 12:08:39 +0100 Subject: fix misleading uppercasing deprecation warning don't complain about uppercasing in the function's name if the real problem is that it's not defined at all. this is also slighly more efficient, as we try to lowercase only as a fallback now. Reviewed-by: joerg --- qmake/project.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/qmake/project.cpp b/qmake/project.cpp index 2586c57..d967a63 100644 --- a/qmake/project.cpp +++ b/qmake/project.cpp @@ -1813,11 +1813,10 @@ QMakeProject::doProjectExpand(QString func, QList args_list, for(int i = 0; i < args_list.size(); ++i) args += args_list[i].join(QString(Option::field_sep)); - QString lfunc = func.toLower(); - if (!lfunc.isSharedWith(func)) + ExpandFunc func_t = qmake_expandFunctions().value(func); + if (!func_t && (func_t = qmake_expandFunctions().value(func.toLower()))) warn_msg(WarnDeprecated, "%s:%d: Using uppercased builtin functions is deprecated.", parser.file.toLatin1().constData(), parser.line_no); - ExpandFunc func_t = qmake_expandFunctions().value(lfunc); debug_msg(1, "Running project expand: %s(%s) [%d]", func.toLatin1().constData(), args.join("::").toLatin1().constData(), func_t); -- cgit v0.12