Skip to content

Commit

Permalink
fix: resolve parser class names for kaitai specs with underscores
Browse files Browse the repository at this point in the history
  • Loading branch information
hello-adam committed Sep 30, 2021
1 parent 1638feb commit 33613e9
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ def parse_data(input_filename, output_filename, action_progress):
module_file = os.path.basename(scripts[0])
sys.path.append(os.path.dirname(scripts[0]))
package_name = os.path.splitext(module_file)[0]
class_name = package_name.capitalize()
class_name = "".join([s.capitalize() for s in package_name.split("_")])
try:
del sys.modules[package_name]
except KeyError:
Expand Down

0 comments on commit 33613e9

Please sign in to comment.