https://bugs.freedesktop.org/show_bug.cgi?id=84938
Bug ID: 84938
Summary: replace #defined constants with ‘enum class’
Product: LibreOffice
Version: unspecified
Hardware: Other
OS: All
Status: UNCONFIRMED
Severity: enhancement
Priority: medium
Component: Libreoffice
Assignee: [email protected]
Reporter: [email protected]
Use something like this to find them:
$ git grep -P ‘#define\s+\w+\s+\d+’ — *.hxx
Pick any one and convert it to an enum class type.
Along the way convert any required fields and parameters and local variables to
use the new enum class type.
Special case: if the pattern of constant values looks like this:
#define XXX_1 1
#define XXX_1 2
#define XXX_1 4
then it is a set of flags and you need to use the template library in
include/o3tl/typed_flags.hxx
to convert it to a enum.
--
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Libreoffice-bugs mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs