public inbox for devel@edk2.groups.io
 help / color / mirror / Atom feed
* GoogleTest Compatibility with MdePkg's IndustyStandard header files
@ 2023-05-23  0:40 aaronpop
  2023-05-24 19:49 ` Michael D Kinney
  0 siblings, 1 reply; 11+ messages in thread
From: aaronpop @ 2023-05-23  0:40 UTC (permalink / raw)
  To: devel@edk2.groups.io; +Cc: Kinney, Michael D

[-- Attachment #1: Type: text/plain, Size: 794 bytes --]

Google Test, and CPP, has more keywords  C uses.

Tpm12.h and Tpm20.h have references to struct names that are `operator` and `xor`, both of which trigger build errors because they conflict with CPP's keywords.

Operator triggered a build error in MSVC. Xor only triggered a build error under GCC, MSVC did not have a problem with it.

The work arounds suggested in the call, (using defines to get around the conflict) worked for operator, but did not work for xor with gcc.


Tpm12.h:
TPM_PERMANENT_FLAGS
  BOOLEAN                           operator;


Tpm20.h:
TPMU_SCHEME_KEYEDHASH
  TPMS_SCHEME_XOR  xor;

TPMU_SYM_KEY_BITS
  TPMI_ALG_HASH     xor;


What is the suggested method of trying to make existing header files compatible with google test?

Thanks,
Aaron

[-- Attachment #2: Type: text/html, Size: 3401 bytes --]

^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2023-05-25 18:22 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-05-23  0:40 GoogleTest Compatibility with MdePkg's IndustyStandard header files aaronpop
2023-05-24 19:49 ` Michael D Kinney
2023-05-24 20:07   ` Aaron Pop
2023-05-24 21:23     ` Michael D Kinney
2023-05-24 21:55       ` [edk2-devel] " Pedro Falcato
2023-05-25  0:23         ` Michael D Kinney
2023-05-25  9:44           ` Pedro Falcato
2023-05-25 17:06             ` Michael D Kinney
2023-05-25 17:43               ` Oliver Smith-Denny
2023-05-25 18:01                 ` Pedro Falcato
2023-05-25 18:22                   ` Michael D Kinney

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox