From adb3a74de985ebc3692b78b99779e479967e2e4c Mon Sep 17 00:00:00 2001 From: Tobias Hunger <tobias.hunger@theqtcompany.com> Date: Fri, 18 Mar 2016 14:06:05 +0100 Subject: [PATCH] Wizards: Fix validation of C++ class names Task-number: QTCREATORBUG-15647 Change-Id: I265a7dbadb2f87e7e44a1770be2af3eb9b9cb53b Reviewed-by: Alessandro Portale <alessandro.portale@theqtcompany.com> --- share/qtcreator/templates/wizards/classes/cpp/wizard.json | 2 +- share/qtcreator/templates/wizards/classes/itemmodel/wizard.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/share/qtcreator/templates/wizards/classes/cpp/wizard.json b/share/qtcreator/templates/wizards/classes/cpp/wizard.json index 379d1d821f..781b647142 100644 --- a/share/qtcreator/templates/wizards/classes/cpp/wizard.json +++ b/share/qtcreator/templates/wizards/classes/cpp/wizard.json @@ -34,7 +34,7 @@ "trDisplayName": "Class name:", "mandatory": true, "type": "LineEdit", - "data": { "validator": "(?:(?:[a-zA-Z_][a-zA-Z_0-9]*::)+[a-zA-Z_][a-zA-Z_0-9]*|)" } + "data": { "validator": "(?:(?:[a-zA-Z_][a-zA-Z_0-9]*::)*[a-zA-Z_][a-zA-Z_0-9]*|)" } }, { "name": "BaseCB", diff --git a/share/qtcreator/templates/wizards/classes/itemmodel/wizard.json b/share/qtcreator/templates/wizards/classes/itemmodel/wizard.json index 97be3ba2e1..7ebea4c3b0 100644 --- a/share/qtcreator/templates/wizards/classes/itemmodel/wizard.json +++ b/share/qtcreator/templates/wizards/classes/itemmodel/wizard.json @@ -31,7 +31,7 @@ "trDisplayName": "Class name:", "mandatory": true, "type": "LineEdit", - "data": { "validator": "(?:(?:[a-zA-Z_][a-zA-Z_0-9]*::)+[a-zA-Z_][a-zA-Z_0-9]*|)" } + "data": { "validator": "(?:(?:[a-zA-Z_][a-zA-Z_0-9]*::)*[a-zA-Z_][a-zA-Z_0-9]*|)" } }, { "name": "Base", -- GitLab