summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorWerner Lemberg <wl@gnu.org>2001-06-18 10:35:00 +0000
committerWerner Lemberg <wl@gnu.org>2001-06-18 10:35:00 +0000
commitf8e9f4261b14d666b46a653c7a810793fb762039 (patch)
tree042882b8ce258600261260a18905ed2577103ff3
parentb9ae6d06d2aa198ef08e382edd5c3437ddb98673 (diff)
downloadfreetype2-f8e9f4261b14d666b46a653c7a810793fb762039.tar.gz
Make the new error scheme source compatible with older FT versions
by introducing another layer. * include/freetype/fterrors.h (FT_ERRORDEF_, FT_NOERRORDEF_): New macros. (FT_NOERRORDEF): Removed. * include/*/*err*.h: Use FT_ERRORDEF_ and FT_NOERRORDEF_.
-rw-r--r--ChangeLog10
-rw-r--r--include/freetype/fterrors.h180
-rw-r--r--src/autohint/aherrors.h6
-rw-r--r--src/cache/ftcerror.h6
-rw-r--r--src/cff/cfferrs.h6
-rw-r--r--src/cid/ciderrs.h6
-rw-r--r--src/pcf/pcferror.h6
-rw-r--r--src/psaux/psauxerr.h6
-rw-r--r--src/psnames/psnamerr.h6
-rw-r--r--src/raster/rasterrs.h6
-rw-r--r--src/sfnt/sferrors.h6
-rw-r--r--src/smooth/ftsmerrs.h6
-rw-r--r--src/truetype/tterrors.h6
-rw-r--r--src/type1/t1errors.h6
-rw-r--r--src/winfonts/fnterrs.h6
15 files changed, 161 insertions, 107 deletions
diff --git a/ChangeLog b/ChangeLog
index 549de612f..521129bad 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,13 @@
+2001-06-18 Werner Lemberg <wl@gnu.org>
+
+ Make the new error scheme source compatible with older FT versions
+ by introducing another layer.
+
+ * include/freetype/fterrors.h (FT_ERRORDEF_, FT_NOERRORDEF_): New
+ macros.
+ (FT_NOERRORDEF): Removed.
+ * include/*/*err*.h: Use FT_ERRORDEF_ and FT_NOERRORDEF_.
+
2001-06-16 Werner Lemberg <wl@gnu.org>
* include/freetype/freetype.h (FT_ENC_TAG): New macro.
diff --git a/include/freetype/fterrors.h b/include/freetype/fterrors.h
index 5cd3e090b..ee2b82ff6 100644
--- a/include/freetype/fterrors.h
+++ b/include/freetype/fterrors.h
@@ -34,8 +34,7 @@
/* */
/* { */
/* #undef __FTERRORS_H__ */
- /* #define FT_ERRORDEF( e, v, s ) { FT_Err_ ## e, s }, */
- /* #define FT_NOERRORDEF( e, v, s ) { FT_Err_ ## e, s }, */
+ /* #define FT_ERRORDEF( e, v, s ) { e, s }, */
/* #define FT_ERROR_START_LIST { */
/* #define FT_ERROR_END_LIST { 0, 0 } }; */
/* */
@@ -62,13 +61,11 @@
#undef FT_NEED_EXTERN_C
-#ifndef FT_ERRORDEF
+ /* public interface */
-#define FT_ERRORDEF( e, v, s ) FT_Err_ ## e = v + FT_Mod_Err_Base,
-#define FT_NOERRORDEF( e, v, s ) FT_Err_ ## e = v,
+#ifndef FT_ERRORDEF
-#define FT_ERROR_START_LIST enum {
-#define FT_ERROR_END_LIST FT_Err_Max };
+#define FT_ERRORDEF( e, v, s ) e = v,
#ifdef __cplusplus
#define FT_NEED_EXTERN_C
@@ -78,6 +75,26 @@
#endif /* !FT_ERRORDEF */
+#ifndef FT_ERROR_START_LIST
+
+#define FT_ERROR_START_LIST enum {
+#define FT_ERROR_END_LIST FT_Err_Max };
+
+#endif /* !FT_ERROR_START_LIST */
+
+
+ /* internal interface */
+
+#ifndef FT_ERRORDEF_
+
+#define FT_ERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( FT_Err_ ## e, v + FT_Mod_Err_Base, s )
+#define FT_NOERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( FT_Err_ ## e, v, s )
+
+#endif /* !FT_ERRORDEF_ */
+
+
#ifdef FT_ERROR_START_LIST
FT_ERROR_START_LIST
#endif
@@ -85,177 +102,177 @@
/* generic errors */
- FT_NOERRORDEF( Ok, 0x00, \
- "no error" )
+ FT_NOERRORDEF_( Ok, 0x00, \
+ "no error" )
- FT_ERRORDEF( Cannot_Open_Resource, 0x01, \
+ FT_ERRORDEF_( Cannot_Open_Resource, 0x01, \
"cannot open resource" )
- FT_ERRORDEF( Unknown_File_Format, 0x02, \
+ FT_ERRORDEF_( Unknown_File_Format, 0x02, \
"unknown file format" )
- FT_ERRORDEF( Invalid_File_Format, 0x03, \
+ FT_ERRORDEF_( Invalid_File_Format, 0x03, \
"broken file" )
- FT_ERRORDEF( Invalid_Version, 0x04, \
+ FT_ERRORDEF_( Invalid_Version, 0x04, \
"invalid FreeType version" )
- FT_ERRORDEF( Lower_Module_Version, 0x05, \
+ FT_ERRORDEF_( Lower_Module_Version, 0x05, \
"module version is too low" )
- FT_ERRORDEF( Invalid_Argument, 0x06, \
+ FT_ERRORDEF_( Invalid_Argument, 0x06, \
"invalid argument" )
- FT_ERRORDEF( Unimplemented_Feature, 0x07, \
+ FT_ERRORDEF_( Unimplemented_Feature, 0x07, \
"unimplemented feature" )
/* glyph/character errors */
- FT_ERRORDEF( Invalid_Glyph_Index, 0x10, \
+ FT_ERRORDEF_( Invalid_Glyph_Index, 0x10, \
"invalid glyph index" )
- FT_ERRORDEF( Invalid_Character_Code, 0x11, \
+ FT_ERRORDEF_( Invalid_Character_Code, 0x11, \
"invalid character code" )
- FT_ERRORDEF( Invalid_Glyph_Format, 0x12, \
+ FT_ERRORDEF_( Invalid_Glyph_Format, 0x12, \
"unsupported glyph image format" )
- FT_ERRORDEF( Cannot_Render_Glyph, 0x13, \
+ FT_ERRORDEF_( Cannot_Render_Glyph, 0x13, \
"cannot render this glyph format" )
- FT_ERRORDEF( Invalid_Outline, 0x14, \
+ FT_ERRORDEF_( Invalid_Outline, 0x14, \
"invalid outline" )
- FT_ERRORDEF( Invalid_Composite, 0x15, \
+ FT_ERRORDEF_( Invalid_Composite, 0x15, \
"invalid composite glyph" )
- FT_ERRORDEF( Too_Many_Hints, 0x16, \
+ FT_ERRORDEF_( Too_Many_Hints, 0x16, \
"too many hints" )
- FT_ERRORDEF( Invalid_Pixel_Size, 0x17, \
+ FT_ERRORDEF_( Invalid_Pixel_Size, 0x17, \
"invalid pixel size" )
/* handle errors */
- FT_ERRORDEF( Invalid_Handle, 0x20, \
+ FT_ERRORDEF_( Invalid_Handle, 0x20, \
"invalid object handle" )
- FT_ERRORDEF( Invalid_Library_Handle, 0x21, \
+ FT_ERRORDEF_( Invalid_Library_Handle, 0x21, \
"invalid library handle" )
- FT_ERRORDEF( Invalid_Driver_Handle, 0x22, \
+ FT_ERRORDEF_( Invalid_Driver_Handle, 0x22, \
"invalid module handle" )
- FT_ERRORDEF( Invalid_Face_Handle, 0x23, \
+ FT_ERRORDEF_( Invalid_Face_Handle, 0x23, \
"invalid face handle" )
- FT_ERRORDEF( Invalid_Size_Handle, 0x24, \
+ FT_ERRORDEF_( Invalid_Size_Handle, 0x24, \
"invalid size handle" )
- FT_ERRORDEF( Invalid_Slot_Handle, 0x25, \
+ FT_ERRORDEF_( Invalid_Slot_Handle, 0x25, \
"invalid glyph slot handle" )
- FT_ERRORDEF( Invalid_CharMap_Handle, 0x26, \
+ FT_ERRORDEF_( Invalid_CharMap_Handle, 0x26, \
"invalid charmap handle" )
- FT_ERRORDEF( Invalid_Cache_Handle, 0x27, \
+ FT_ERRORDEF_( Invalid_Cache_Handle, 0x27, \
"invalid cache manager handle" )
- FT_ERRORDEF( Invalid_Stream_Handle, 0x28, \
+ FT_ERRORDEF_( Invalid_Stream_Handle, 0x28, \
"invalid stream handle" )
/* driver errors */
- FT_ERRORDEF( Too_Many_Drivers, 0x30, \
+ FT_ERRORDEF_( Too_Many_Drivers, 0x30, \
"too many modules" )
- FT_ERRORDEF( Too_Many_Extensions, 0x31, \
+ FT_ERRORDEF_( Too_Many_Extensions, 0x31, \
"too many extensions" )
/* memory errors */
- FT_ERRORDEF( Out_Of_Memory, 0x40, \
+ FT_ERRORDEF_( Out_Of_Memory, 0x40, \
"out of memory" )
- FT_ERRORDEF( Unlisted_Object, 0x41, \
+ FT_ERRORDEF_( Unlisted_Object, 0x41, \
"unlisted object" )
/* stream errors */
- FT_ERRORDEF( Cannot_Open_Stream, 0x51, \
+ FT_ERRORDEF_( Cannot_Open_Stream, 0x51, \
"cannot open stream" )
- FT_ERRORDEF( Invalid_Stream_Seek, 0x52, \
+ FT_ERRORDEF_( Invalid_Stream_Seek, 0x52, \
"invalid stream seek" )
- FT_ERRORDEF( Invalid_Stream_Skip, 0x53, \
+ FT_ERRORDEF_( Invalid_Stream_Skip, 0x53, \
"invalid stream skip" )
- FT_ERRORDEF( Invalid_Stream_Read, 0x54, \
+ FT_ERRORDEF_( Invalid_Stream_Read, 0x54, \
"invalid stream read" )
- FT_ERRORDEF( Invalid_Stream_Operation, 0x55, \
+ FT_ERRORDEF_( Invalid_Stream_Operation, 0x55, \
"invalid stream operation" )
- FT_ERRORDEF( Invalid_Frame_Operation, 0x56, \
+ FT_ERRORDEF_( Invalid_Frame_Operation, 0x56, \
"invalid frame operation" )
- FT_ERRORDEF( Nested_Frame_Access, 0x57, \
+ FT_ERRORDEF_( Nested_Frame_Access, 0x57, \
"nested frame access" )
- FT_ERRORDEF( Invalid_Frame_Read, 0x58, \
+ FT_ERRORDEF_( Invalid_Frame_Read, 0x58, \
"invalid frame read" )
/* raster errors */
- FT_ERRORDEF( Raster_Uninitialized, 0x60, \
+ FT_ERRORDEF_( Raster_Uninitialized, 0x60, \
"raster uninitialized" )
- FT_ERRORDEF( Raster_Corrupted, 0x61, \
+ FT_ERRORDEF_( Raster_Corrupted, 0x61, \
"raster corrupted" )
- FT_ERRORDEF( Raster_Overflow, 0x62, \
+ FT_ERRORDEF_( Raster_Overflow, 0x62, \
"raster overflow" )
- FT_ERRORDEF( Raster_Negative_Height, 0x63, \
+ FT_ERRORDEF_( Raster_Negative_Height, 0x63, \
"negative height while rastering" )
/* cache errors */
- FT_ERRORDEF( Too_Many_Caches, 0x70, \
+ FT_ERRORDEF_( Too_Many_Caches, 0x70, \
"too many registered caches" )
/* TrueType and SFNT errors */
- FT_ERRORDEF( Invalid_Opcode, 0x80, \
+ FT_ERRORDEF_( Invalid_Opcode, 0x80, \
"invalid opcode" )
- FT_ERRORDEF( Too_Few_Arguments, 0x81, \
+ FT_ERRORDEF_( Too_Few_Arguments, 0x81, \
"too few arguments" )
- FT_ERRORDEF( Stack_Overflow, 0x82, \
+ FT_ERRORDEF_( Stack_Overflow, 0x82, \
"stack overflow" )
- FT_ERRORDEF( Code_Overflow, 0x83, \
+ FT_ERRORDEF_( Code_Overflow, 0x83, \
"code overflow" )
- FT_ERRORDEF( Bad_Argument, 0x84, \
+ FT_ERRORDEF_( Bad_Argument, 0x84, \
"bad argument" )
- FT_ERRORDEF( Divide_By_Zero, 0x85, \
+ FT_ERRORDEF_( Divide_By_Zero, 0x85, \
"division by zero" )
- FT_ERRORDEF( Invalid_Reference, 0x86, \
+ FT_ERRORDEF_( Invalid_Reference, 0x86, \
"invalid reference" )
- FT_ERRORDEF( Debug_OpCode, 0x87, \
+ FT_ERRORDEF_( Debug_OpCode, 0x87, \
"found debug opcode" )
- FT_ERRORDEF( ENDF_In_Exec_Stream, 0x88, \
+ FT_ERRORDEF_( ENDF_In_Exec_Stream, 0x88, \
"found ENDF opcode in execution stream" )
- FT_ERRORDEF( Nested_DEFS, 0x89, \
+ FT_ERRORDEF_( Nested_DEFS, 0x89, \
"nested DEFS" )
- FT_ERRORDEF( Invalid_CodeRange, 0x8A, \
+ FT_ERRORDEF_( Invalid_CodeRange, 0x8A, \
"invalid code range" )
- FT_ERRORDEF( Execution_Too_Long, 0x8B, \
+ FT_ERRORDEF_( Execution_Too_Long, 0x8B, \
"execution context too long" )
- FT_ERRORDEF( Too_Many_Function_Defs, 0x8C, \
+ FT_ERRORDEF_( Too_Many_Function_Defs, 0x8C, \
"too many function definitions" )
- FT_ERRORDEF( Too_Many_Instruction_Defs, 0x8D, \
+ FT_ERRORDEF_( Too_Many_Instruction_Defs, 0x8D, \
"too many instruction definitions" )
- FT_ERRORDEF( Table_Missing, 0x8E, \
+ FT_ERRORDEF_( Table_Missing, 0x8E, \
"SFNT font table missing" )
- FT_ERRORDEF( Horiz_Header_Missing, 0x8F, \
+ FT_ERRORDEF_( Horiz_Header_Missing, 0x8F, \
"horizontal header (hhea) table missing" )
- FT_ERRORDEF( Locations_Missing, 0x90, \
+ FT_ERRORDEF_( Locations_Missing, 0x90, \
"locations (loca) table missing" )
- FT_ERRORDEF( Name_Table_Missing, 0x91, \
+ FT_ERRORDEF_( Name_Table_Missing, 0x91, \
"name table missing" )
- FT_ERRORDEF( CMap_Table_Missing, 0x92, \
+ FT_ERRORDEF_( CMap_Table_Missing, 0x92, \
"character map (cmap) table missing" )
- FT_ERRORDEF( Hmtx_Table_Missing, 0x93, \
+ FT_ERRORDEF_( Hmtx_Table_Missing, 0x93, \
"horizontal metrics (hmtx) table missing" )
- FT_ERRORDEF( Post_Table_Missing, 0x94, \
+ FT_ERRORDEF_( Post_Table_Missing, 0x94, \
"PostScript (post) table missing" )
- FT_ERRORDEF( Invalid_Horiz_Metrics, 0x95, \
+ FT_ERRORDEF_( Invalid_Horiz_Metrics, 0x95, \
"invalid horizontal metrics" )
- FT_ERRORDEF( Invalid_CharMap_Format, 0x96, \
+ FT_ERRORDEF_( Invalid_CharMap_Format, 0x96, \
"invalid character map (cmap) format" )
- FT_ERRORDEF( Invalid_PPem, 0x97, \
+ FT_ERRORDEF_( Invalid_PPem, 0x97, \
"invalid ppem value" )
- FT_ERRORDEF( Invalid_Vert_Metrics, 0x98, \
+ FT_ERRORDEF_( Invalid_Vert_Metrics, 0x98, \
"invalid vertical metrics" )
- FT_ERRORDEF( Could_Not_Find_Context, 0x99, \
+ FT_ERRORDEF_( Could_Not_Find_Context, 0x99, \
"could not find context" )
- FT_ERRORDEF( Invalid_Post_Table_Format, 0x9A, \
+ FT_ERRORDEF_( Invalid_Post_Table_Format, 0x9A, \
"invalid PostScript (post) table format" )
- FT_ERRORDEF( Invalid_Post_Table, 0x9B, \
+ FT_ERRORDEF_( Invalid_Post_Table, 0x9B, \
"invalid PostScript (post) table" )
/* CFF, CID, and Type 1 errors */
- FT_ERRORDEF( Syntax_Error, 0xA0, \
+ FT_ERRORDEF_( Syntax_Error, 0xA0, \
"opcode syntax error" )
- FT_ERRORDEF( Stack_Underflow, 0xA1, \
+ FT_ERRORDEF_( Stack_Underflow, 0xA1, \
"argument stack underflow" )
@@ -267,7 +284,8 @@
#undef FT_ERROR_START_LIST
#undef FT_ERROR_END_LIST
#undef FT_ERRORDEF
-#undef FT_NOERRORDEF
+#undef FT_ERRORDEF_
+#undef FT_NOERRORDEF_
#ifdef FT_NEED_EXTERN_C
diff --git a/src/autohint/aherrors.h b/src/autohint/aherrors.h
index 25a6f8b15..b236a64e8 100644
--- a/src/autohint/aherrors.h
+++ b/src/autohint/aherrors.h
@@ -30,8 +30,10 @@
#undef __FTERRORS_H__
-#define FT_ERRORDEF( e, v, s ) AH_Err_ ## e = v + FT_Mod_Err_Autohint,
-#define FT_NOERRORDEF( e, v, s ) AH_Err_ ## e = v,
+#define FT_ERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( AH_Err_ ## e, v + FT_Mod_Err_Autohint, s )
+#define FT_NOERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( AH_Err_ ## e, v, s )
#define FT_ERROR_START_LIST enum {
#define FT_ERROR_END_LIST AH_Err_Max };
diff --git a/src/cache/ftcerror.h b/src/cache/ftcerror.h
index 456c249d2..3da42b3ea 100644
--- a/src/cache/ftcerror.h
+++ b/src/cache/ftcerror.h
@@ -30,8 +30,10 @@
#undef __FTERRORS_H__
-#define FT_ERRORDEF( e, v, s ) FTC_Err_ ## e = v + FT_Mod_Err_Cache,
-#define FT_NOERRORDEF( e, v, s ) FTC_Err_ ## e = v,
+#define FT_ERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( FTC_Err_ ## e, v + FT_Mod_Err_Cache, s )
+#define FT_NOERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( FTC_Err_ ## e, v, s )
#define FT_ERROR_START_LIST enum {
#define FT_ERROR_END_LIST FTC_Err_Max };
diff --git a/src/cff/cfferrs.h b/src/cff/cfferrs.h
index 99c0c3d4c..0ae0a3ded 100644
--- a/src/cff/cfferrs.h
+++ b/src/cff/cfferrs.h
@@ -29,8 +29,10 @@
#undef __FTERRORS_H__
-#define FT_ERRORDEF( e, v, s ) CFF_Err_ ## e = v + FT_Mod_Err_CFF,
-#define FT_NOERRORDEF( e, v, s ) CFF_Err_ ## e = v,
+#define FT_ERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( CFF_Err_ ## e, v + FT_Mod_Err_CFF, s )
+#define FT_NOERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( CFF_Err_ ## e, v, s )
#define FT_ERROR_START_LIST enum {
#define FT_ERROR_END_LIST CFF_Err_Max };
diff --git a/src/cid/ciderrs.h b/src/cid/ciderrs.h
index 25a043ae3..9aa2f38e4 100644
--- a/src/cid/ciderrs.h
+++ b/src/cid/ciderrs.h
@@ -29,8 +29,10 @@
#undef __FTERRORS_H__
-#define FT_ERRORDEF( e, v, s ) CID_Err_ ## e = v + FT_Mod_Err_CID,
-#define FT_NOERRORDEF( e, v, s ) CID_Err_ ## e = v,
+#define FT_ERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( CID_Err_ ## e, v + FT_Mod_Err_CID, s )
+#define FT_NOERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( CID_Err_ ## e, v, s )
#define FT_ERROR_START_LIST enum {
#define FT_ERROR_END_LIST CID_Err_Max };
diff --git a/src/pcf/pcferror.h b/src/pcf/pcferror.h
index c01bcab50..2404ea975 100644
--- a/src/pcf/pcferror.h
+++ b/src/pcf/pcferror.h
@@ -29,8 +29,10 @@
#undef __FTERRORS_H__
-#define FT_ERRORDEF( e, v, s ) PCF_Err_ ## e = v + FT_Mod_Err_PCF,
-#define FT_NOERRORDEF( e, v, s ) PCF_Err_ ## e = v,
+#define FT_ERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( PCF_Err_ ## e, v + FT_Mod_Err_PCF, s )
+#define FT_NOERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( PCF_Err_ ## e, v, s )
#define FT_ERROR_START_LIST enum {
#define FT_ERROR_END_LIST PCF_Err_Max };
diff --git a/src/psaux/psauxerr.h b/src/psaux/psauxerr.h
index 720c28cf8..2533277f2 100644
--- a/src/psaux/psauxerr.h
+++ b/src/psaux/psauxerr.h
@@ -30,8 +30,10 @@
#undef __FTERRORS_H__
-#define FT_ERRORDEF( e, v, s ) PSaux_Err_ ## e = v + FT_Mod_Err_PSaux,
-#define FT_NOERRORDEF( e, v, s ) PSaux_Err_ ## e = v,
+#define FT_ERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( PSaux_Err_ ## e, v + FT_Mod_Err_PSaux, s )
+#define FT_NOERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( PSaux_Err_ ## e, v, s )
#define FT_ERROR_START_LIST enum {
#define FT_ERROR_END_LIST PSaux_Err_Max };
diff --git a/src/psnames/psnamerr.h b/src/psnames/psnamerr.h
index b95a33ee9..c620a879d 100644
--- a/src/psnames/psnamerr.h
+++ b/src/psnames/psnamerr.h
@@ -30,8 +30,10 @@
#undef __FTERRORS_H__
-#define FT_ERRORDEF( e, v, s ) PSnames_Err_ ## e = v + FT_Mod_Err_PSnames,
-#define FT_NOERRORDEF( e, v, s ) PSnames_Err_ ## e = v,
+#define FT_ERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( PSnames_Err_ ## e, v + FT_Mod_Err_PSnames, s )
+#define FT_NOERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( PSnames_Err_ ## e, v, s )
#define FT_ERROR_START_LIST enum {
#define FT_ERROR_END_LIST PSnames_Err_Max };
diff --git a/src/raster/rasterrs.h b/src/raster/rasterrs.h
index dd689a286..a9b380520 100644
--- a/src/raster/rasterrs.h
+++ b/src/raster/rasterrs.h
@@ -30,8 +30,10 @@
#undef __FTERRORS_H__
-#define FT_ERRORDEF( e, v, s ) Raster_Err_ ## e = v + FT_Mod_Err_Raster,
-#define FT_NOERRORDEF( e, v, s ) Raster_Err_ ## e = v,
+#define FT_ERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( Raster_Err_ ## e, v + FT_Mod_Err_Raster, s )
+#define FT_NOERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( Raster_Err_ ## e, v, s )
#define FT_ERROR_START_LIST enum {
#define FT_ERROR_END_LIST Raster_Err_Max };
diff --git a/src/sfnt/sferrors.h b/src/sfnt/sferrors.h
index 776e11558..fefd160de 100644
--- a/src/sfnt/sferrors.h
+++ b/src/sfnt/sferrors.h
@@ -29,8 +29,10 @@
#undef __FTERRORS_H__
-#define FT_ERRORDEF( e, v, s ) SFNT_Err_ ## e = v + FT_Mod_Err_SFNT,
-#define FT_NOERRORDEF( e, v, s ) SFNT_Err_ ## e = v,
+#define FT_ERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( SFNT_Err_ ## e, v + FT_Mod_Err_SFNT, s )
+#define FT_NOERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( SFNT_Err_ ## e, v, s )
#define FT_ERROR_START_LIST enum {
#define FT_ERROR_END_LIST SFNT_Err_Max };
diff --git a/src/smooth/ftsmerrs.h b/src/smooth/ftsmerrs.h
index a319c9edf..0eb4062b0 100644
--- a/src/smooth/ftsmerrs.h
+++ b/src/smooth/ftsmerrs.h
@@ -30,8 +30,10 @@
#undef __FTERRORS_H__
-#define FT_ERRORDEF( e, v, s ) Smooth_Err_ ## e = v + FT_Mod_Err_Smooth,
-#define FT_NOERRORDEF( e, v, s ) Smooth_Err_ ## e = v,
+#define FT_ERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( Smooth_Err_ ## e, v + FT_Mod_Err_Smooth, s )
+#define FT_NOERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( Smooth_Err_ ## e, v, s )
#define FT_ERROR_START_LIST enum {
#define FT_ERROR_END_LIST Smooth_Err_Max };
diff --git a/src/truetype/tterrors.h b/src/truetype/tterrors.h
index ace9f7810..bb611b5b7 100644
--- a/src/truetype/tterrors.h
+++ b/src/truetype/tterrors.h
@@ -30,8 +30,10 @@
#undef __FTERRORS_H__
-#define FT_ERRORDEF( e, v, s ) TT_Err_ ## e = v + FT_Mod_Err_TrueType,
-#define FT_NOERRORDEF( e, v, s ) TT_Err_ ## e = v,
+#define FT_ERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( TT_Err_ ## e, v + FT_Mod_Err_TrueType, s )
+#define FT_NOERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( TT_Err_ ## e, v, s )
#define FT_ERROR_START_LIST enum {
#define FT_ERROR_END_LIST TT_Err_Max };
diff --git a/src/type1/t1errors.h b/src/type1/t1errors.h
index ebd0a81be..cf5c8b689 100644
--- a/src/type1/t1errors.h
+++ b/src/type1/t1errors.h
@@ -29,8 +29,10 @@
#undef __FTERRORS_H__
-#define FT_ERRORDEF( e, v, s ) T1_Err_ ## e = v + FT_Mod_Err_Type1,
-#define FT_NOERRORDEF( e, v, s ) T1_Err_ ## e = v,
+#define FT_ERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( T1_Err_ ## e, v + FT_Mod_Err_Type1, s )
+#define FT_NOERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( T1_Err_ ## e, v, s )
#define FT_ERROR_START_LIST enum {
#define FT_ERROR_END_LIST T1_Err_Max };
diff --git a/src/winfonts/fnterrs.h b/src/winfonts/fnterrs.h
index 8d8cf337a..730d4ead3 100644
--- a/src/winfonts/fnterrs.h
+++ b/src/winfonts/fnterrs.h
@@ -30,8 +30,10 @@
#undef __FTERRORS_H__
-#define FT_ERRORDEF( e, v, s ) FNT_Err_ ## e = v + FT_Mod_Err_Winfonts,
-#define FT_NOERRORDEF( e, v, s ) FNT_Err_ ## e = v,
+#define FT_ERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( FNT_Err_ ## e, v + FT_Mod_Err_Winfonts, s )
+#define FT_NOERRORDEF_( e, v, s ) \
+ FT_ERRORDEF( FNT_Err_ ## e, v, s )
#define FT_ERROR_START_LIST enum {
#define FT_ERROR_END_LIST FNT_Err_Max };