io7m-com / cedarbridge

Cedarbridge message protocol specification language
https://www.io7m.com/software/cedarbridge
ISC License
0 stars 0 forks source link

Limit and deduplicate type references to 255 types #23

Closed io7m closed 2 years ago

io7m commented 2 years ago

Currently, code generation fails if a type references more than 255 types. Worse, type references are not deduplicated - a record type with 255 integer-typed fields results in code generation that refers to 255 integer serializers.

Type references should be deduplicated for code generation, and limits should be put in place in the compiler to reject type declarations that reference more than 255 deduplicated types.

io7m commented 2 years ago

The new static generator doesn't have this problem.