Reviewed-by: Ray Ni <[email protected]> > -----Original Message----- > From: Rebecca Cran <[email protected]> > Sent: Friday, April 7, 2023 6:23 AM > To: [email protected]; Gao, Liming <[email protected]>; > Kinney, Michael D <[email protected]>; Jiang, Guomin > <[email protected]>; Xu, Wei6 <[email protected]>; Dong, Guo > <[email protected]>; Ni, Ray <[email protected]>; Rhodes, Sean > <[email protected]>; Lu, James <[email protected]>; Guo, Gua > <[email protected]>; Andrew Fish <[email protected]>; Wu, Hao A > <[email protected]>; Maciej Rabeda <[email protected]>; > Siyuan Fu <[email protected]>; Yao, Jiewen <[email protected]>; > Wang, Jian J <[email protected]>; Lu, Xiaoyu1 <[email protected]>; > Ard Biesheuvel <[email protected]>; Sami Mujawar > <[email protected]>; Supreeth Venkatesh > <[email protected]>; Michael Kubacki > <[email protected]>; Desimone, Nathaniel L > <[email protected]>; Sean Brogan > <[email protected]> > Cc: Rebecca Cran <[email protected]>; Leif Lindholm > <[email protected]>; Abner Chang <[email protected]>; > Nickle Wang <[email protected]>; Igor Kulchytskyy <[email protected]>; > Daniel Schaefer <[email protected]>; Xu, Min M > <[email protected]>; Justen, Jordan L <[email protected]>; Gerd > Hoffmann <[email protected]>; Peter Grehan <[email protected]>; > Aktas, Erdem <[email protected]>; James Bottomley > <[email protected]>; Tom Lendacky <[email protected]>; > Michael Roth <[email protected]>; Sunil V L > <[email protected]>; Warkentin, Andrei > <[email protected]> > Subject: [PATCH 16/18] EmulatorPkg: Update code to be more C11 compliant > by using __func__ > > __FUNCTION__ is a pre-standard extension that gcc and Visual C++ among > others support, while __func__ was standardized in C99. > > Since it's more standard, replace __FUNCTION__ with __func__ throughout > EmulatorPkg. > > Visual Studio versions before VS 2015 don't support __func__ and so > will fail to compile. A workaround is to define __func__ as > __FUNCTION__ : > > #define __func__ __FUNCTION__ > > Signed-off-by: Rebecca Cran <[email protected]> > --- > > EmulatorPkg/Library/RedfishPlatformHostInterfaceLib/RedfishPlatformHostI > nterfaceLib.c | 2 +- > EmulatorPkg/Win/Host/WinPacketFilter.c > | 2 +- > 2 files changed, 2 insertions(+), 2 deletions(-) > > diff --git > a/EmulatorPkg/Library/RedfishPlatformHostInterfaceLib/RedfishPlatformHo > stInterfaceLib.c > b/EmulatorPkg/Library/RedfishPlatformHostInterfaceLib/RedfishPlatformHo > stInterfaceLib.c > index 4361bd4170e3..4332caa71016 100644 > --- > a/EmulatorPkg/Library/RedfishPlatformHostInterfaceLib/RedfishPlatformHo > stInterfaceLib.c > +++ > b/EmulatorPkg/Library/RedfishPlatformHostInterfaceLib/RedfishPlatformHo > stInterfaceLib.c > @@ -538,7 +538,7 @@ RedfishPlatformHostInterfaceConstructor ( > EFI_STATUS Status; > > Status = GetRedfishRecordFromVariable (&mRedfishOverIpProtocolData, > &mRedfishProtocolDataSize); > - DEBUG ((DEBUG_INFO, "%a: GetRedfishRecordFromVariable() - %r\n", > __FUNCTION__, Status)); > + DEBUG ((DEBUG_INFO, "%a: GetRedfishRecordFromVariable() - %r\n", > __func__, Status)); > if (!EFI_ERROR (Status)) { > DumpRedfishIpProtocolData (mRedfishOverIpProtocolData, > mRedfishProtocolDataSize); > } > diff --git a/EmulatorPkg/Win/Host/WinPacketFilter.c > b/EmulatorPkg/Win/Host/WinPacketFilter.c > index 21859897c85f..a71c7e8c131b 100644 > --- a/EmulatorPkg/Win/Host/WinPacketFilter.c > +++ b/EmulatorPkg/Win/Host/WinPacketFilter.c > @@ -966,7 +966,7 @@ WintNtInitializeNetUtilityData ( > goto ErrorReturn; > } > > - DEBUG ((DEBUG_INFO, "%a, total %d interface(s) found\n", > __FUNCTION__, InterfaceCount)); > + DEBUG ((DEBUG_INFO, "%a, total %d interface(s) found\n", __func__, > InterfaceCount)); > // > // Active interface index is set to first interface if given instance does > // not exist. > -- > 2.34.1
-=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#102659): https://edk2.groups.io/g/devel/message/102659 Mute This Topic: https://groups.io/mt/98115254/21656 Group Owner: [email protected] Unsubscribe: https://edk2.groups.io/g/devel/leave/9847357/21656/1706620634/xyzzy [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
