diff options
Diffstat (limited to 'tools/d2c/spec.c')
-rw-r--r-- | tools/d2c/spec.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/tools/d2c/spec.c b/tools/d2c/spec.c index a957587..675fd05 100644 --- a/tools/d2c/spec.c +++ b/tools/d2c/spec.c @@ -53,6 +53,7 @@ struct _encoding_spec { char *prefix; /* Distinction principale */ + char *lprefix; /* Distinction en minuscules */ unsigned int index; /* Distinction secondaire */ coding_bits *bits; /* Encodage des bits associƩs */ @@ -138,6 +139,7 @@ void delete_encoding_spec(encoding_spec *spec) void define_encoding_spec_code_name(encoding_spec *spec, char *prefix, unsigned int index) { spec->prefix = prefix; + spec->lprefix = make_string_lower(strdup(prefix)); spec->index = index; } @@ -269,7 +271,7 @@ bool write_encoding_spec_disass(const encoding_spec *spec, int fd, const char *a keyword = make_callable(ins, false); dprintf(fd, "\tGArchInstruction *%s_decode_%s%s_%s%u(uint%u_t _raw)\n", - arch, keyword, details, spec->prefix, spec->index, wide); + arch, keyword, details, spec->lprefix, spec->index, wide); dprintf(fd, "\t{\n"); @@ -338,7 +340,7 @@ bool write_encoding_spec_disass(const encoding_spec *spec, int fd, const char *a dprintf(fd, "\tif (result == NULL)\n"); dprintf(fd, "\t\tresult = %s_decode_%s%s_%s%u(raw);\n", - arch, keyword, details, spec->prefix, spec->index); + arch, keyword, details, spec->lprefix, spec->index); dprintf(fd, "\n"); |