kimgr / asn1ate

A Python library for translating ASN.1 into other forms.
Other
69 stars 41 forks source link

Add automatic tags. #29

Closed james-ward closed 8 years ago

james-ward commented 8 years ago

ConstructedTypes now have a method to autotag their components. This will wrap all components in a TaggedType with incrementing tag number, but only if no components are already tagged (as per the ASN.1 specification).

After generating the module(s) this method is called on all ConstructedTypes in the tree if the module's tag default is AUTOMATIC.

Ignore ExtensionMarkers when autotagging.

Resolves #20.

kimgr commented 8 years ago

Thanks! Sorry this took so long.

I'll make a few local refactors, I had some ideas I think will simplify the TaggedType construction.