+2005-06-09 Duncan Mak <duncan@novell.com>
+
+ * *.h: Added G_BEGIN_DECLS and G_END_DECLS where appropriate to
+ all public headers. Fixes #74919.
+
2005-05-30 Zoltan Varga <vargaz@freemail.hu>
* atomic.h: Add IA64 atomic ops.
#include <glib.h>
+G_BEGIN_DECLS
+
#define _WAPI_HANDLE_COLLECTION_UPDATE_INTERVAL 10
#define _WAPI_HANDLE_COLLECTION_EXPIRED_INTERVAL 60
_wapi_thr_ret = _wapi_shm_sem_unlock (_WAPI_SHARED_SEM_COLLECTION); \
g_assert (_wapi_thr_ret == 0); \
}
-
+
extern void _wapi_collection_init (void);
extern void _wapi_handle_collect (void);
+G_END_DECLS
+
#endif /* _WAPI_COLLECTION_H_ */
guint8 ExtendedRegisters[MAXIMUM_SUPPORTED_EXTENSION];
} WapiContext;
+G_BEGIN_DECLS
+
extern gboolean GetThreadContext(gpointer handle, WapiContext *context);
+G_END_DECLS
+
#endif /* _WAPI_COMPEX_H_ */
#include "mono-mutex.h"
+G_BEGIN_DECLS
+
typedef struct _WapiCriticalSection WapiCriticalSection;
struct _WapiCriticalSection
extern void EnterCriticalSection(WapiCriticalSection *section);
extern void LeaveCriticalSection(WapiCriticalSection *section);
+G_END_DECLS
+
#endif /* _WAPI_CRITICAL_SECTIONS_H_ */
#include <glib.h>
+G_BEGIN_DECLS
+
extern gpointer CreateEvent(WapiSecurityAttributes *security, gboolean manual,
gboolean initial, const gunichar2 *name);
extern gboolean PulseEvent(gpointer handle);
extern gboolean ResetEvent(gpointer handle);
extern gboolean SetEvent(gpointer handle);
+G_END_DECLS
+
#endif /* _WAPI_EVENTS_H_ */
#define INVALID_HANDLE_VALUE (gpointer)-1
+G_BEGIN_DECLS
+
extern gboolean CloseHandle(gpointer handle);
+G_END_DECLS
+
#endif /* _WAPI_HANDLES_H_ */
#include "mono/io-layer/wapi.h"
#include "mono/io-layer/timefuncs.h"
+G_BEGIN_DECLS
+
typedef struct _WapiSecurityAttributes WapiSecurityAttributes;
struct _WapiSecurityAttributes
guint32 offset_high, guint32 length_low,
guint32 length_high);
+G_END_DECLS
+
#endif /* _WAPI_IO_H_ */
#include <pthread.h>
#include <time.h>
+G_BEGIN_DECLS
+
typedef struct {
pthread_mutex_t mutex;
gboolean complete;
#define MONO_MUTEX_INITIALIZER { 0, MONO_THREAD_NONE, 0, 0, PTHREAD_MUTEX_INITIALIZER, 0 }
#define MONO_RECURSIVE_MUTEX_INITIALIZER { 0, MONO_THREAD_NONE, 0, 0, PTHREAD_MUTEX_INITIALIZER, PTHREAD_COND_INITIALIZER }
-
int mono_mutexattr_init (mono_mutexattr_t *attr);
int mono_mutexattr_settype (mono_mutexattr_t *attr, int type);
int mono_mutexattr_gettype (mono_mutexattr_t *attr, int *type);
#include <glib.h>
+G_BEGIN_DECLS
+
extern gpointer CreateMutex(WapiSecurityAttributes *security, gboolean owned,
const gunichar2 *name);
extern gboolean ReleaseMutex(gpointer handle);
+G_END_DECLS
+
#endif /* _WAPI_MUTEXES_H_ */
#include <mono/io-layer/handles.h>
#include <mono/io-layer/access.h>
+G_BEGIN_DECLS
+
typedef enum {
STARTF_USESHOWWINDOW=0x001,
STARTF_USESIZE=0x002,
extern gboolean TerminateProcess (gpointer process, gint32 exitCode);
+G_END_DECLS
+
#endif /* _WAPI_PROCESSES_H_ */
#include <glib.h>
+G_BEGIN_DECLS
+
extern gboolean ImpersonateLoggedOnUser (gpointer handle);
extern gboolean RevertToSelf (void);
+G_END_DECLS
+
#endif /* _WAPI_SECURITY_H_ */
#include <glib.h>
+G_BEGIN_DECLS
+
extern gpointer CreateSemaphore(WapiSecurityAttributes *security,
gint32 initial, gint32 max,
const gunichar2 *name);
extern gboolean ReleaseSemaphore(gpointer handle, gint32 count,
gint32 *prevcount);
+G_END_DECLS
#endif /* _WAPI_SEMAPHORES_H_ */
#include "mono/io-layer/wapi.h"
+G_BEGIN_DECLS
+
#define WSADESCRIPTION_LEN 256
#define WSASYS_STATUS_LEN 128
gchar *output, gint o_len, glong *written,
void *unused1, void *unused2);
+G_END_DECLS
#endif /* _WAPI_SOCKETS_H_ */
#include <glib.h>
+G_BEGIN_DECLS
+
typedef struct _WapiSystemInfo WapiSystemInfo;
struct _WapiSystemInfo
extern void GetSystemInfo(WapiSystemInfo *info);
+G_END_DECLS
#endif /* _WAPI_SYSTEM_H_ */
#include <mono/io-layer/processes.h>
#include <mono/io-layer/access.h>
+G_BEGIN_DECLS
+
#define TLS_MINIMUM_AVAILABLE 64
#define TLS_OUT_OF_INDEXES 0xFFFFFFFF
extern guint32 SleepEx(guint32 ms, gboolean alertable);
extern guint32 QueueUserAPC (WapiApcProc apc_callback, gpointer thread_handle,
gpointer param);
-
+G_END_DECLS
#endif /* _WAPI_THREADS_H_ */
#include "mono/io-layer/wapi.h"
+G_BEGIN_DECLS
+
/* The typical idiom for this struct is to cast it to and from 64bit
* ints, hence the endian switch.
*/
extern gboolean QueryPerformanceFrequency(WapiLargeInteger *freq);
extern guint32 GetTickCount (void);
+G_END_DECLS
#endif /* _WAPI_TIME_H_ */
#include "mono/io-layer/status.h"
+G_BEGIN_DECLS
+
#define MAXIMUM_WAIT_OBJECTS 64
#define INFINITE 0xFFFFFFFF
extern guint32 WaitForMultipleObjectsEx(guint32 numobjects, gpointer *handles,
gboolean waitall, guint32 timeout, gboolean alertable);
+G_END_DECLS
#endif /* _WAPI_WAIT_H_ */
+2005-06-09 Duncan Mak <duncan@novell.com>
+
+ * *.h: Added G_BEGIN_DECLS and G_END_DECLS where appropriate to
+ all public headers. Fixes #74919.
+
2005-06-09 Lluis Sanchez Gual <lluis@novell.com>
* domain.c: The key for proxy_vtable_hash is now a pointer
#include <mono/metadata/reflection.h>
#include <mono/metadata/mempool.h>
+G_BEGIN_DECLS
+
typedef void (*MonoThreadStartCB) (guint32 tid, gpointer stack_start,
gpointer func);
typedef void (*MonoThreadAttachCB) (guint32 tid, gpointer stack_start);
MonoClass*
mono_get_exception_class (void);
+G_END_DECLS
#endif /* _MONO_METADATA_APPDOMAIN_H_ */
#include <mono/metadata/image.h>
+G_BEGIN_DECLS
+
void mono_assemblies_init (void);
MonoAssembly *mono_assembly_open (const char *filename,
MonoImageOpenStatus *status);
void mono_register_bundled_assemblies (const MonoBundledAssembly **assemblies);
void mono_register_config_for_assembly (const char* assembly_name, const char* config_xml);
+G_END_DECLS
#endif
#include <mono/metadata/image.h>
#include <mono/metadata/loader.h>
+G_BEGIN_DECLS
+
typedef struct MonoVTable MonoVTable;
typedef struct _MonoClassField MonoClassField;
char *
mono_class_name_from_token (MonoImage *image, guint32 type_token, MonoGenericContext *context);
+G_END_DECLS
+
#endif /* _MONO_CLI_CLASS_H_ */
#include <glib.h>
#include <mono/metadata/class.h>
+G_BEGIN_DECLS
+
typedef struct MonoDisHelper MonoDisHelper;
typedef char* (*MonoDisIndenter) (MonoDisHelper *dh, MonoMethod *method, guint32 ip_offset);
char* mono_method_full_name (MonoMethod *method, gboolean signature);
+G_END_DECLS
+
#endif /* __MONO_DEBUG_HELPERS_H__ */
#define MONO_SYMBOL_FILE_VERSION 38
#define MONO_SYMBOL_FILE_MAGIC 0x45e82623fd7fa614ULL
+G_BEGIN_DECLS
+
MonoSymbolFile *
mono_debug_open_mono_symbol_file (MonoDebugHandle *handle,
gboolean create_symfile);
MonoDebugMethodInfo *
mono_debug_find_method (MonoDebugHandle *handle,
MonoMethod *method);
+G_END_DECLS
#endif /* __MONO_SYMFILE_H__ */
#ifndef _MONO_METADATA_ENVIRONMENT_H_
#define _MONO_METADATA_ENVIRONMENT_H_
+G_BEGIN_DECLS
+
extern gint32 mono_environment_exitcode_get (void);
extern void mono_environment_exitcode_set (gint32 value);
extern MonoString* ves_icall_System_Environment_GetOSVersionString (void);
+G_END_DECLS
+
#endif /* _MONO_METADATA_ENVIRONMENT_H_ */
#include <mono/metadata/object.h>
#include <mono/metadata/image.h>
+G_BEGIN_DECLS
+
extern MonoException *
mono_exception_from_name (MonoImage *image,
const char* name_space,
MonoException *
mono_get_exception_reflection_type_load (MonoArray *types, MonoArray *exceptions);
+G_END_DECLS
+
#endif /* _MONO_METADATA_EXCEPTION_H_ */
#include <mono/metadata/object-internals.h>
#include <mono/io-layer/io-layer.h>
+G_BEGIN_DECLS
+
/* This is a copy of System.IO.FileAccess */
typedef enum {
FileAccess_Read=0x01,
extern void ves_icall_System_IO_MonoIO_Unlock (HANDLE handle, gint64 position,
gint64 length, gint32 *error);
+G_END_DECLS
+
#endif /* _MONO_METADATA_FILEIO_H_ */
#include <glib.h>
#include <gmodule.h>
+G_BEGIN_DECLS
+
typedef struct _MonoImage MonoImage;
typedef struct _MonoAssembly MonoAssembly;
typedef struct _MonoTableInfo MonoTableInfo;
const char *name, guint32 idx);
gboolean mono_image_has_authenticode_entry (MonoImage *image);
+G_END_DECLS
#endif
#include <mono/metadata/metadata.h>
#include <mono/metadata/image.h>
+G_BEGIN_DECLS
+
typedef struct _MonoMethod MonoMethod;
typedef gboolean (*MonoStackWalk) (MonoMethod *method, gint32 native_offset, gint32 il_offset, gboolean managed, gpointer data);
void
mono_stack_walk_no_il (MonoStackWalk func, gpointer user_data);
+G_END_DECLS
+
#endif
#include <mono/metadata/opcodes.h>
#include <mono/metadata/reflection.h>
+G_BEGIN_DECLS
+
typedef struct _MonoMethodBuilder MonoMethodBuilder;
/* marshaling helper functions */
MonoDelegate*
ves_icall_System_Runtime_InteropServices_Marshal_GetDelegateForFunctionPointerInternal (void *ftn, MonoReflectionType *type);
+G_END_DECLS
+
#endif /* __MONO_MARSHAL_H__ */
#ifndef _MONO_MEMPOOL_H_
#define _MONO_MEMPOOL_H_
+G_BEGIN_DECLS
+
typedef struct _MonoMemPool MonoMemPool;
MonoMemPool *
gboolean
mono_mempool_contains_addr (MonoMemPool *pool,
- gpointer addr);
+ gpointer addr);
+
+G_END_DECLS
#endif
#include <mono/metadata/row-indexes.h>
#include <mono/metadata/image.h>
+G_BEGIN_DECLS
+
#ifdef __GNUC__
#define MONO_ZERO_LEN_ARRAY 0
#else
guint32 mono_metadata_declsec_from_index (MonoImage *meta, guint32 idx);
+G_END_DECLS
+
#endif /* __MONO_METADATA_H__ */
#define _MONO_METADATA_MONITOR_H_
#include <glib.h>
-
#include <mono/metadata/object.h>
+G_BEGIN_DECLS
+
void mono_monitor_init (void);
extern gboolean ves_icall_System_Threading_Monitor_Monitor_try_enter(MonoObject *obj, guint32 ms);
extern void ves_icall_System_Threading_Monitor_Monitor_pulse_all(MonoObject *obj);
extern gboolean ves_icall_System_Threading_Monitor_Monitor_wait(MonoObject *obj, guint32 ms);
+G_END_DECLS
+
#endif /* _MONO_METADATA_MONITOR_H_ */
#include <glib.h>
+G_BEGIN_DECLS
+
void mono_gc_collect (int generation);
int mono_gc_max_generation (void);
gint64 mono_gc_get_used_size (void);
gint64 mono_gc_get_heap_size (void);
+G_END_DECLS
+
#endif /* __METADATA_MONO_GC_H__ */
#include <mono/metadata/class.h>
+G_BEGIN_DECLS
+
typedef guchar MonoBoolean;
typedef struct _MonoReflectionMethod MonoReflectionMethod;
MonoObject* mono_gchandle_get_target (guint32 gchandle);
void mono_gchandle_free (guint32 gchandle);
+G_END_DECLS
+
#endif
#include <glib.h>
+G_BEGIN_DECLS
+
#define MONO_CUSTOM_PREFIX 0xf0
#define OPDEF(a,b,c,d,e,f,g,h,i,j) \
MonoOpcodeEnum
mono_opcode_value (const guint8 **ip, const guint8 *end);
+G_END_DECLS
+
#endif /* __MONO_METADATA_OPCODES_H__ */
#include <mono/metadata/object.h>
#include <mono/metadata/appdomain.h>
+G_BEGIN_DECLS
+
typedef enum {
MONO_PROFILE_NONE = 0,
MONO_PROFILE_APPDOMAIN_EVENTS = 1 << 0,
typedef struct _MonoProfiler MonoProfiler;
+
/*
* Functions that the runtime will call on the profiler.
*/
void mono_profiler_load (const char *desc);
+G_END_DECLS
+
#endif /* __MONO_PROFILER_H__ */
#include <mono/metadata/object.h>
+G_BEGIN_DECLS
+
typedef struct MonoTypeNameParse MonoTypeNameParse;
struct MonoTypeNameParse {
MonoBoolean mono_declsec_get_class_action (MonoClass *klass, guint32 action, MonoDeclSecurityEntry *entry);
MonoBoolean mono_declsec_get_assembly_action (MonoAssembly *assembly, guint32 action, MonoDeclSecurityEntry *entry);
+G_END_DECLS
+
#endif /* __METADATA_REFLECTION_H__ */
#include <mono/metadata/object.h>
+G_BEGIN_DECLS
/* System.Environment */
extern MonoString* ves_icall_System_Environment_get_UserName (void);
/* System.Security.Policy.Evidence */
MonoBoolean ves_icall_System_Security_Policy_Evidence_IsAuthenticodePresent (MonoReflectionAssembly *refass);
+G_END_DECLS
#endif /* _MONO_METADATA_SECURITY_H_ */
#include <mono/metadata/object.h>
#include <mono/metadata/appdomain.h>
+G_BEGIN_DECLS
+
typedef void (*MonoThreadCleanupFunc) (MonoThread* thread);
extern int mono_thread_get_abort_signal (void);
extern void mono_thread_force_interruption_checkpoint (void);
extern gint32* mono_thread_interruption_request_flag (void);
+G_END_DECLS
+
#endif /* _MONO_METADATA_THREADS_H_ */
#include <mono/metadata/image.h>
#include <mono/metadata/loader.h>
+G_BEGIN_DECLS
+
typedef enum {
MONO_VERIFY_OK,
MONO_VERIFY_ERROR,
void mono_free_verify_list (GSList *list);
char* mono_verify_corlib (void);
+G_END_DECLS
+
#endif /* __MONO_METADATA_VERIFY_H__ */
+2005-06-09 Duncan Mak <duncan@novell.com>
+
+ * *.h: Added G_BEGIN_DECLS and G_END_DECLS where appropriate to
+ all public headers. Fixes #74919.
+
2005-05-18 Zoltan Varga <vargaz@freemail.hu>
* mono-codeman.c: Align code on a 16 byte boundary on ia64.
typedef int (*MonoCodeManagerFunc) (void *data, int csize, int size, void *user_data);
void mono_code_manager_foreach (MonoCodeManager *cman, MonoCodeManagerFunc func, void *user_data);
-
#endif /* __MONO_CODEMAN_H__ */
#include <glib.h>
+G_BEGIN_DECLS
+
typedef struct {
guint32 buf[4];
guint32 bits[2];
void mono_digest_get_public_token (guchar* token, const guchar *pubkey, guint32 len);
+G_END_DECLS
#endif /* __MONO_DIGEST_H__ */
#include <glib.h>
+G_BEGIN_DECLS
+
typedef enum {
MONO_TRACE_ASSEMBLY = (1<<0),
MONO_TRACE_TYPE = (1<<1),
va_end (args);
}
+G_END_DECLS
+
#endif /* !__GNUC__ */
#endif /* __MONO_LOGGER_H__ */