The regular expression driver is mixing types it defines with edk2 types. The
regular expression types are less portable in regards to assumptions about the
sign of char. Matching the types removes a compiler warning on Xcode clang.
/Users/andrewfish/work/src/edk2/MdeModulePkg/Universal/RegularExpressionDxe/RegularExpressionDxe.c:123:29:
error: passing 'CHAR8 [90]' to parameter of type 'OnigUChar *' (aka 'unsigned
char *') converts between pointers to integer types with different sign
[-Werror,-Wpointer-sign]
onig_error_code_to_str (ErrorMessage, OnigResult, &ErrorInfo);
^~~~~~~~~~~~
DFDFD
diff --git a/MdeModulePkg/Universal/RegularExpressionDxe/RegularExpressionDxe.c
b/MdeModulePkg/Universal/RegularExpressionDxe/RegularExpressionDxe.c
index cffbcb8..598d8ad 100644
--- a/MdeModulePkg/Universal/RegularExpressionDxe/RegularExpressionDxe.c
+++ b/MdeModulePkg/Universal/RegularExpressionDxe/RegularExpressionDxe.c
@@ -88,7 +88,7 @@ OnigurumaMatch (
OnigRegion *Region;
INT32 OnigResult;
OnigErrorInfo ErrorInfo;
- CHAR8 ErrorMessage[ONIG_MAX_ERROR_MESSAGE_LEN];
+ OnigUChar ErrorMessage[ONIG_MAX_ERROR_MESSAGE_LEN];
UINT32 Index;
OnigUChar *Start;
Contributed-under: TianoCore Contribution Agreement 1.0
Thanks,
Andrew Fish
_______________________________________________
edk2-devel mailing list
[email protected]
https://lists.01.org/mailman/listinfo/edk2-devel