ntdll: Replace inline static with static inline.
This commit is contained in:
parent
503b338e88
commit
0108667754
|
@ -37,17 +37,17 @@
|
|||
WINE_DEFAULT_DEBUG_CHANNEL(ntdll);
|
||||
WINE_DECLARE_DEBUG_CHANNEL(relay);
|
||||
|
||||
inline static LONG interlocked_inc( PLONG dest )
|
||||
static inline LONG interlocked_inc( PLONG dest )
|
||||
{
|
||||
return interlocked_xchg_add( (int *)dest, 1 ) + 1;
|
||||
}
|
||||
|
||||
inline static LONG interlocked_dec( PLONG dest )
|
||||
static inline LONG interlocked_dec( PLONG dest )
|
||||
{
|
||||
return interlocked_xchg_add( (int *)dest, -1 ) - 1;
|
||||
}
|
||||
|
||||
inline static void small_pause(void)
|
||||
static inline void small_pause(void)
|
||||
{
|
||||
#ifdef __i386__
|
||||
__asm__ __volatile__( "rep;nop" : : : "memory" );
|
||||
|
|
|
@ -111,19 +111,19 @@ static FARPROC find_named_export( HMODULE module, const IMAGE_EXPORT_DIRECTORY *
|
|||
DWORD exp_size, const char *name, int hint );
|
||||
|
||||
/* convert PE image VirtualAddress to Real Address */
|
||||
inline static void *get_rva( HMODULE module, DWORD va )
|
||||
static inline void *get_rva( HMODULE module, DWORD va )
|
||||
{
|
||||
return (void *)((char *)module + va);
|
||||
}
|
||||
|
||||
/* check whether the file name contains a path */
|
||||
inline static int contains_path( LPCWSTR name )
|
||||
static inline int contains_path( LPCWSTR name )
|
||||
{
|
||||
return ((*name && (name[1] == ':')) || strchrW(name, '/') || strchrW(name, '\\'));
|
||||
}
|
||||
|
||||
/* convert from straight ASCII to Unicode without depending on the current codepage */
|
||||
inline static void ascii_to_unicode( WCHAR *dst, const char *src, size_t len )
|
||||
static inline void ascii_to_unicode( WCHAR *dst, const char *src, size_t len )
|
||||
{
|
||||
while (len--) *dst++ = (unsigned char)*src++;
|
||||
}
|
||||
|
|
|
@ -83,14 +83,14 @@ static const WCHAR **debug_from_snoop_includelist;
|
|||
static BOOL init_done;
|
||||
|
||||
/* compare an ASCII and a Unicode string without depending on the current codepage */
|
||||
inline static int strcmpAW( const char *strA, const WCHAR *strW )
|
||||
static inline int strcmpAW( const char *strA, const WCHAR *strW )
|
||||
{
|
||||
while (*strA && ((unsigned char)*strA == *strW)) { strA++; strW++; }
|
||||
return (unsigned char)*strA - *strW;
|
||||
}
|
||||
|
||||
/* compare an ASCII and a Unicode string without depending on the current codepage */
|
||||
inline static int strncmpiAW( const char *strA, const WCHAR *strW, int n )
|
||||
static inline int strncmpiAW( const char *strA, const WCHAR *strW, int n )
|
||||
{
|
||||
int ret = 0;
|
||||
for ( ; n > 0; n--, strA++, strW++)
|
||||
|
|
|
@ -56,7 +56,7 @@ static LANGID user_ui_language, system_ui_language;
|
|||
*
|
||||
* Check if a module handle is for a LOAD_LIBRARY_AS_DATAFILE module.
|
||||
*/
|
||||
inline static int is_data_file_module( HMODULE hmod )
|
||||
static inline int is_data_file_module( HMODULE hmod )
|
||||
{
|
||||
return (ULONG_PTR)hmod & 1;
|
||||
}
|
||||
|
|
|
@ -283,7 +283,7 @@ static void read_reply_data( void *buffer, size_t size )
|
|||
*
|
||||
* Wait for a reply from the server.
|
||||
*/
|
||||
inline static void wait_reply( struct __server_request_info *req )
|
||||
static inline void wait_reply( struct __server_request_info *req )
|
||||
{
|
||||
read_reply_data( &req->u.reply, sizeof(req->u.reply) );
|
||||
if (req->u.reply.reply_header.reply_size)
|
||||
|
@ -473,7 +473,7 @@ struct fd_cache_entry
|
|||
static struct fd_cache_entry *fd_cache[FD_CACHE_ENTRIES];
|
||||
static struct fd_cache_entry fd_cache_initial_block[FD_CACHE_BLOCK_SIZE];
|
||||
|
||||
inline static unsigned int handle_to_index( obj_handle_t handle, unsigned int *entry )
|
||||
static inline unsigned int handle_to_index( obj_handle_t handle, unsigned int *entry )
|
||||
{
|
||||
unsigned long idx = ((unsigned long)handle >> 2) - 1;
|
||||
*entry = idx / FD_CACHE_BLOCK_SIZE;
|
||||
|
|
|
@ -352,7 +352,7 @@ enum i386_trap_code
|
|||
/***********************************************************************
|
||||
* dispatch_signal
|
||||
*/
|
||||
inline static int dispatch_signal(unsigned int sig)
|
||||
static inline int dispatch_signal(unsigned int sig)
|
||||
{
|
||||
if (handlers[sig] == NULL) return 0;
|
||||
return handlers[sig](sig);
|
||||
|
@ -539,7 +539,7 @@ typedef void (WINAPI *raise_func)( EXCEPTION_RECORD *rec, CONTEXT *context );
|
|||
*
|
||||
* Handler initialization when the full context is not needed.
|
||||
*/
|
||||
inline static void *init_handler( const SIGCONTEXT *sigcontext, WORD *fs, WORD *gs )
|
||||
static inline void *init_handler( const SIGCONTEXT *sigcontext, WORD *fs, WORD *gs )
|
||||
{
|
||||
void *stack = (void *)(ESP_sig(sigcontext) & ~3);
|
||||
TEB *teb = get_current_teb();
|
||||
|
@ -596,7 +596,7 @@ inline static void *init_handler( const SIGCONTEXT *sigcontext, WORD *fs, WORD *
|
|||
*
|
||||
* Save the thread FPU context.
|
||||
*/
|
||||
inline static void save_fpu( CONTEXT *context )
|
||||
static inline void save_fpu( CONTEXT *context )
|
||||
{
|
||||
#ifdef __GNUC__
|
||||
context->ContextFlags |= CONTEXT_FLOATING_POINT;
|
||||
|
@ -610,7 +610,7 @@ inline static void save_fpu( CONTEXT *context )
|
|||
*
|
||||
* Restore the FPU context to a sigcontext.
|
||||
*/
|
||||
inline static void restore_fpu( const CONTEXT *context )
|
||||
static inline void restore_fpu( const CONTEXT *context )
|
||||
{
|
||||
FLOATING_SAVE_AREA float_status = context->FloatSave;
|
||||
/* reset the current interrupt status */
|
||||
|
@ -626,7 +626,7 @@ inline static void restore_fpu( const CONTEXT *context )
|
|||
*
|
||||
* Build a context structure from the signal info.
|
||||
*/
|
||||
inline static void save_context( CONTEXT *context, const SIGCONTEXT *sigcontext, WORD fs, WORD gs )
|
||||
static inline void save_context( CONTEXT *context, const SIGCONTEXT *sigcontext, WORD fs, WORD gs )
|
||||
{
|
||||
struct ntdll_thread_regs * const regs = ntdll_get_thread_regs();
|
||||
|
||||
|
@ -674,7 +674,7 @@ inline static void save_context( CONTEXT *context, const SIGCONTEXT *sigcontext,
|
|||
*
|
||||
* Restore the signal info from the context.
|
||||
*/
|
||||
inline static void restore_context( const CONTEXT *context, SIGCONTEXT *sigcontext )
|
||||
static inline void restore_context( const CONTEXT *context, SIGCONTEXT *sigcontext )
|
||||
{
|
||||
struct ntdll_thread_regs * const regs = ntdll_get_thread_regs();
|
||||
|
||||
|
|
|
@ -167,7 +167,7 @@ static wine_signal_handler handlers[256];
|
|||
/***********************************************************************
|
||||
* dispatch_signal
|
||||
*/
|
||||
inline static int dispatch_signal(unsigned int sig)
|
||||
static inline int dispatch_signal(unsigned int sig)
|
||||
{
|
||||
if (handlers[sig] == NULL) return 0;
|
||||
return handlers[sig](sig);
|
||||
|
@ -239,7 +239,7 @@ static void restore_context( const CONTEXT *context, SIGCONTEXT *sigcontext )
|
|||
*
|
||||
* Set the FPU context from a sigcontext.
|
||||
*/
|
||||
inline static void save_fpu( CONTEXT *context, const SIGCONTEXT *sigcontext )
|
||||
static inline void save_fpu( CONTEXT *context, const SIGCONTEXT *sigcontext )
|
||||
{
|
||||
#define C(x) context->Fpr##x = FLOAT_sig(x,sigcontext)
|
||||
C(0); C(1); C(2); C(3); C(4); C(5); C(6); C(7); C(8); C(9); C(10);
|
||||
|
@ -256,7 +256,7 @@ inline static void save_fpu( CONTEXT *context, const SIGCONTEXT *sigcontext )
|
|||
*
|
||||
* Restore the FPU context to a sigcontext.
|
||||
*/
|
||||
inline static void restore_fpu( CONTEXT *context, const SIGCONTEXT *sigcontext )
|
||||
static inline void restore_fpu( CONTEXT *context, const SIGCONTEXT *sigcontext )
|
||||
{
|
||||
#define C(x) FLOAT_sig(x,sigcontext) = context->Fpr##x
|
||||
C(0); C(1); C(2); C(3); C(4); C(5); C(6); C(7); C(8); C(9); C(10);
|
||||
|
|
|
@ -54,7 +54,7 @@ static wine_signal_handler handlers[256];
|
|||
/***********************************************************************
|
||||
* dispatch_signal
|
||||
*/
|
||||
inline static int dispatch_signal(unsigned int sig)
|
||||
static inline int dispatch_signal(unsigned int sig)
|
||||
{
|
||||
if (handlers[sig] == NULL) return 0;
|
||||
return handlers[sig](sig);
|
||||
|
|
|
@ -124,7 +124,7 @@ static wine_signal_handler handlers[256];
|
|||
/***********************************************************************
|
||||
* dispatch_signal
|
||||
*/
|
||||
inline static int dispatch_signal(unsigned int sig)
|
||||
static inline int dispatch_signal(unsigned int sig)
|
||||
{
|
||||
if (handlers[sig] == NULL) return 0;
|
||||
return handlers[sig](sig);
|
||||
|
|
|
@ -61,12 +61,12 @@ struct work_item
|
|||
PVOID context;
|
||||
};
|
||||
|
||||
inline static LONG interlocked_inc( PLONG dest )
|
||||
static inline LONG interlocked_inc( PLONG dest )
|
||||
{
|
||||
return interlocked_xchg_add( (int *)dest, 1 ) + 1;
|
||||
}
|
||||
|
||||
inline static LONG interlocked_dec( PLONG dest )
|
||||
static inline LONG interlocked_dec( PLONG dest )
|
||||
{
|
||||
return interlocked_xchg_add( (int *)dest, -1 ) - 1;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue