diff options
-rwxr-xr-x | src/arch/isa_parser.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/arch/isa_parser.py b/src/arch/isa_parser.py index a0d671da1..0cb7bfc56 100755 --- a/src/arch/isa_parser.py +++ b/src/arch/isa_parser.py @@ -866,7 +866,11 @@ class Format: context = {} updateExportContext() context.update(exportContext) - context.update({ 'name': name, 'Name': string.capitalize(name) }) + if len(name): + Name = name[0].upper() + if len(name) > 1: + Name += name[1:] + context.update({ 'name': name, 'Name': Name }) try: vars = self.func(self.user_code, context, *args[0], **args[1]) except Exception, exc: |