Avoid number scanner overhead for all General formats
Change-Id: If28276a1f707c3eb462a013b5604a92ce56038d2 Reviewed-on: https://gerrit.libreoffice.org/53792 Reviewed-by: Eike Rathke <erack@redhat.com> Tested-by: Eike Rathke <erack@redhat.com>
This commit is contained in:
@@ -1095,6 +1095,13 @@ bool SvNumberFormatter::IsNumberFormat(const OUString& sString,
|
|||||||
FType = SvNumFormatType::DEFINED;
|
FType = SvNumFormatType::DEFINED;
|
||||||
}
|
}
|
||||||
ChangeIntl(pFormat->GetLanguage());
|
ChangeIntl(pFormat->GetLanguage());
|
||||||
|
// Avoid scanner overhead with the General format of any locale.
|
||||||
|
// These are never substituded above so safe to ignore.
|
||||||
|
if ((F_Index % SV_COUNTRY_LANGUAGE_OFFSET) == 0)
|
||||||
|
{
|
||||||
|
assert(FType == SvNumFormatType::NUMBER);
|
||||||
|
pFormat = nullptr;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
bool res;
|
bool res;
|
||||||
|
Reference in New Issue
Block a user