mirror of
https://github.com/freebsd/freebsd-src.git
synced 2024-12-03 08:22:44 +00:00
Don't try to use 'typedef struct foo' if just 'struct foo' makes more sense
and works on all compilers. This also removes the need for __CC_SUPPORTS_FORWARD_REFERENCE_CONSTRUCT in <sys/cdefs.h>. OK'ed by: marcel, dfr
This commit is contained in:
parent
e68c6390f4
commit
ea8b0ab337
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=143250
@ -231,17 +231,7 @@ typedef uint32_t UINTN;
|
||||
|
||||
#endif /* EFI_FW_NT */
|
||||
|
||||
/*
|
||||
* Some compilers don't support the forward reference construct:
|
||||
* typedef struct XXXXX
|
||||
*
|
||||
* The following macro provide a workaround for such cases.
|
||||
*/
|
||||
#ifdef NO_INTERFACE_DECL
|
||||
#define INTERFACE_DECL(x)
|
||||
#else
|
||||
#define INTERFACE_DECL(x) typedef struct x
|
||||
#endif
|
||||
#define INTERFACE_DECL(x) struct x
|
||||
|
||||
#if _MSC_EXTENSIONS
|
||||
#pragma warning ( disable : 4731 )
|
||||
|
@ -131,18 +131,4 @@ void __mf (void);
|
||||
#define LOAD_INTERNAL_DRIVER(_if, type, name, entry) \
|
||||
(_if)->LoadInternal(type, name, entry)
|
||||
|
||||
/*
|
||||
* Some compilers don't support the forward reference construct:
|
||||
* typedef struct XXXXX
|
||||
*
|
||||
* The following macro provide a workaround for such cases.
|
||||
*/
|
||||
#ifdef NO_INTERFACE_DECL
|
||||
#define INTERFACE_DECL(x)
|
||||
#else
|
||||
#ifdef __CC_SUPPORTS_FORWARD_REFERENCE_CONSTRUCT
|
||||
#define INTERFACE_DECL(x) struct x
|
||||
#else
|
||||
#define INTERFACE_DECL(x) typedef struct x
|
||||
#endif
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user