8
0
mirror of https://github.com/FirebirdSQL/firebird.git synced 2025-01-31 08:43:04 +01:00
firebird-mirror/src/intl/ldcommon.h

81 lines
2.1 KiB
C
Raw Normal View History

2001-05-23 15:26:42 +02:00
/*
* PROGRAM: InterBase International support
* MODULE: ldcommon.h
* DESCRIPTION: Common declarations for InterBase language drivers
*
* The contents of this file are subject to the Interbase Public
* License Version 1.0 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a copy
* of the License at http://www.Inprise.com/IPL.html
*
* Software distributed under the License is distributed on an
* "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either express
* or implied. See the License for the specific language governing
* rights and limitations under the License.
*
* The Original Code was created by Inprise Corporation
* and its predecessors. Portions created by Inprise Corporation are
* Copyright (C) Inprise Corporation.
*
* All Rights Reserved.
* Contributor(s): ______________________________________.
*/
#ifndef _INTL_LDCOMMON_H_
#define _INTL_LDCOMMON_H_
/* #include "../jrd/gdsassert.h" */
// Put the assert in here
2001-05-23 15:26:42 +02:00
#include "../jrd/intlobj.h"
#include "../intl/langdrv.h"
#include "../intl/charsets.h"
#include "../intl/country_codes.h"
#include "../intl/ld.h"
#undef DEBUG
#define STATIC static
typedef USHORT UNICODE;
/* Redirect the assertion code defined by gdsassert.h to a local routine */
#ifdef assert
#undef assert
#endif
#ifndef DEV_BUILD
#define ERR_assert /* nothing */
#define assert(ex) /* nothing */
#else
#define ERR_assert LD_assert
#define assert(ex) {if (!(ex)){(void) LD_assert (__FILE__, __LINE__); abort();}}
2003-02-13 10:58:19 +01:00
extern void LD_assert(const SCHAR*, int);
2001-05-23 15:26:42 +02:00
#endif
#define MIN(x,y) ((x)<(y)?(x):(y))
#define MAX(x,y) ((x)>(y)?(x):(y))
2001-05-23 15:26:42 +02:00
#define TEXTTYPE_ENTRY(name) USHORT name (TEXTTYPE cache, SSHORT parm1, SSHORT dummy)
2001-05-23 15:26:42 +02:00
#define TEXTTYPE_RETURN return (0)
#define CONVERT_ENTRY(cs1, cs2, name) USHORT name (CSCONVERT csptr, SSHORT dest_cs, SSHORT source_cs)
2001-05-23 15:26:42 +02:00
#define CONVERT_RETURN return (0)
#define CHARSET_ENTRY(name) USHORT name (CHARSET csptr, SSHORT cs_id, SSHORT dummy)
2001-05-23 15:26:42 +02:00
#define CHARSET_RETURN return (0)
extern void CV_convert_init(CSCONVERT, SSHORT, SSHORT, FPTR_SHORT, const void*, const void*);
2001-05-23 15:26:42 +02:00
#endif /* _INTL_LDCOMMON_H_ */