Data types having a modifier are space sensitive e.g. a type 'int *' is not the same as 'int*' Reproducible: Always Steps to Reproduce: 1. start umbrello 2. Add a new class 3. Add a new attribute and set type to 'int *' 4. Press ok, reedit and set type to 'int*' (without space) Actual Results: A new data type is created. Expected Results: Because logical both spellings are refering to the same type there should no new type been added.
Git commit 999d6338f4c4baec178626fb3bff175e2bac7906 by Oliver Kellogg. Committed on 05/03/2022 at 07:09. Pushed by okellogg into branch 'master'. Fix "Data type with modifiers are space sensitive" umbrello/model_utils.{h,cpp} - New function normalize(QString type) removes interspersed spaces from given type name where possible: Between word and non word, between non word and word, between non word and non word. Space between word and word is left intact to preserve names such as "unsigned long long". - In function findUMLObject: - On assigning to name apply normalize() to inName. - As a peripheral change, fix bug number in #ifdef TRY_BUGFIX_120862. umbrello/codeimport/kdevcppparser/cpptree2uml.cpp - In function typeOfDeclaration for-loop over ptrOpList, on assigning to `text' remove spaces from ptrOpList.at(i)->text() as done in loop over declarator->arrayDimensionList(). umbrello/dialogs/dialog_utils.cpp - In function askName apply Model_Utils::normalize() on returned name. umbrello/dialogs/widgets/umldatatypewidget.cpp - In functions applyAttribute, applyEntityAttribute, applyOperation, applyParameter, on assigning to typeName apply Model_Utils::normalize on m_editField->currentText(). umbrello/umldoc.cpp - In function findDatatype apply Model_Utils::normalize() to name before processing. FIXED-IN:2.33.80 (KDE releases 22.03.80) M +4 -2 umbrello/codeimport/kdevcppparser/cpptree2uml.cpp M +4 -3 umbrello/dialogs/dialog_utils.cpp M +6 -5 umbrello/dialogs/widgets/umldatatypewidget.cpp M +32 -2 umbrello/model_utils.cpp M +2 -0 umbrello/model_utils.h M +1 -0 umbrello/umldoc.cpp https://invent.kde.org/sdk/umbrello/commit/999d6338f4c4baec178626fb3bff175e2bac7906