diff options
Diffstat (limited to 'compat.c')
-rw-r--r-- | compat.c | 47 |
1 files changed, 23 insertions, 24 deletions
@@ -81,7 +81,7 @@ typedef struct _CompatInfo /***====================================================================***/ static char * -siText(SymInterpInfo * si, CompatInfo * info) +siText(const SymInterpInfo *si, const CompatInfo *info) { static char buf[128]; @@ -170,7 +170,7 @@ NextInterp(CompatInfo * info) } static SymInterpInfo * -FindMatchingInterp(CompatInfo * info, SymInterpInfo * new) +FindMatchingInterp(CompatInfo *info, const SymInterpInfo *new) { SymInterpInfo *old; @@ -255,7 +255,7 @@ AddInterp(CompatInfo * info, SymInterpInfo * new) } static Bool -AddGroupCompat(CompatInfo * info, unsigned group, GroupCompatInfo * newGC) +AddGroupCompat(CompatInfo *info, unsigned group, const GroupCompatInfo *newGC) { GroupCompatInfo *gc; unsigned merge; @@ -281,9 +281,9 @@ AddGroupCompat(CompatInfo * info, unsigned group, GroupCompatInfo * newGC) /***====================================================================***/ static Bool -ResolveStateAndPredicate(ExprDef * expr, - unsigned *pred_rtrn, - unsigned *mods_rtrn, CompatInfo * info) +ResolveStateAndPredicate(const ExprDef *expr, + unsigned *pred_rtrn, unsigned *mods_rtrn, + const CompatInfo *info) { ExprResult result; @@ -386,14 +386,14 @@ MergeIncludedCompatMaps(CompatInfo * into, CompatInfo * from, unsigned merge) return; } -typedef void (*FileHandler) (XkbFile * /* rtrn */ , +typedef void (*FileHandler) (const XkbFile * /* rtrn */ , XkbDescPtr /* xkb */ , unsigned /* merge */ , CompatInfo * /* info */ ); static Bool -HandleIncludeCompatMap(IncludeStmt * stmt, +HandleIncludeCompatMap(IncludeStmt *stmt, XkbDescPtr xkb, CompatInfo * info, FileHandler hndlr) { unsigned newMerge; @@ -485,10 +485,9 @@ static LookupEntry useModMapValues[] = { }; static int -SetInterpField(SymInterpInfo * si, - XkbDescPtr xkb, - const char *field, - ExprDef * arrayNdx, ExprDef * value, CompatInfo * info) +SetInterpField(SymInterpInfo *si, XkbDescPtr xkb, const char *field, + const ExprDef *arrayNdx, const ExprDef *value, + const CompatInfo *info) { int ok = 1; ExprResult tmp; @@ -597,7 +596,7 @@ LookupEntry groupNames[] = { }; static int -HandleInterpVar(VarDef * stmt, XkbDescPtr xkb, CompatInfo * info) +HandleInterpVar(const VarDef *stmt, XkbDescPtr xkb, CompatInfo *info) { ExprResult elem, field; ExprDef *ndx; @@ -617,8 +616,8 @@ HandleInterpVar(VarDef * stmt, XkbDescPtr xkb, CompatInfo * info) } static int -HandleInterpBody(VarDef * def, XkbDescPtr xkb, SymInterpInfo * si, - CompatInfo * info) +HandleInterpBody(const VarDef *def, XkbDescPtr xkb, SymInterpInfo *si, + CompatInfo *info) { int ok = 1; ExprResult tmp, field; @@ -640,8 +639,8 @@ HandleInterpBody(VarDef * def, XkbDescPtr xkb, SymInterpInfo * si, } static int -HandleInterpDef(InterpDef * def, XkbDescPtr xkb, unsigned merge, - CompatInfo * info) +HandleInterpDef(const InterpDef *def, XkbDescPtr xkb, unsigned merge, + CompatInfo *info) { unsigned pred, mods; SymInterpInfo si; @@ -682,8 +681,8 @@ HandleInterpDef(InterpDef * def, XkbDescPtr xkb, unsigned merge, } static int -HandleGroupCompatDef(GroupCompatDef * def, - XkbDescPtr xkb, unsigned merge, CompatInfo * info) +HandleGroupCompatDef(const GroupCompatDef *def, + XkbDescPtr xkb, unsigned merge, CompatInfo *info) { ExprResult val; GroupCompatInfo tmp; @@ -714,8 +713,8 @@ HandleGroupCompatDef(GroupCompatDef * def, } static void -HandleCompatMapFile(XkbFile * file, - XkbDescPtr xkb, unsigned merge, CompatInfo * info) +HandleCompatMapFile(const XkbFile *file, + XkbDescPtr xkb, unsigned merge, CompatInfo *info) { ParseCommon *stmt; @@ -784,7 +783,7 @@ HandleCompatMapFile(XkbFile * file, } static void -CopyInterps(CompatInfo * info, +CopyInterps(const CompatInfo *info, XkbCompatMapPtr compat, Bool needSymbol, unsigned pred) { for (SymInterpInfo *si = info->interps; si; @@ -806,8 +805,8 @@ CopyInterps(CompatInfo * info, } Bool -CompileCompatMap(XkbFile * file, - XkbFileInfo * result, unsigned merge, LEDInfo ** unboundLEDs) +CompileCompatMap(const XkbFile *file, + XkbFileInfo *result, unsigned merge, LEDInfo **unboundLEDs) { CompatInfo info; XkbDescPtr xkb; |