I18n: restore unit messages after c++ migration broke extraction

The units defined in blenkernel/intern/unit.c were extracted using a
regex which contained `NULL`. Commit 129f78eee7 converted this file to
c++, and these `NULL` were replaced with `nullptr`, breaking the
regex.

This commit changes the regex to `nullptr` as well to restore the
translations.

Pull Request: https://projects.blender.org/blender/blender/pulls/110420
This commit is contained in:
Damien Picard 2023-07-24 16:42:59 +02:00 committed by Gitea
parent b19011e2db
commit 39a94e370c
1 changed files with 2 additions and 2 deletions

View File

@ -282,8 +282,8 @@ PYGETTEXT_KEYWORDS = (() +
# NOTE: regex is a bit more complex than it would need too. Since the actual
# identifier (`B_UNIT_DEF_`) is at the end, if it's simpler/too general it
# becomes extremely slow to process some (unrelated) source files.
((r"\{(?:(?:\s*\"[^\",]+\"\s*,)|(?:\s*\"\\\"\",)|(?:\s*NULL\s*,)){4}\s*" +
_msg_re + r"\s*,(?:(?:\s*\"[^\"',]+\"\s*,)|(?:\s*NULL\s*,))(?:[^,]+,){2}"
((r"\{(?:(?:\s*\"[^\",]+\"\s*,)|(?:\s*\"\\\"\",)|(?:\s*nullptr\s*,)){4}\s*" +
_msg_re + r"\s*,(?:(?:\s*\"[^\"',]+\"\s*,)|(?:\s*nullptr\s*,))(?:[^,]+,){2}"
+ "(?:\|?\s*B_UNIT_DEF_[_A-Z]+\s*)+\}"),) +
tuple((r"{}\(\s*" + _msg_re + r"\s*,\s*(?:" +