v0.8.0
This release primarily fixes bugs in the compiler that resulted in differences between the source files that protocompile would accept vs. the source files that the reference compiler, protoc
, would accept. But one of these changes resulted in an unused AST node type. So this type has been removed from the exported API, which is why this v0.8.0 instead of v0.7.2.
Fixes:
- A
protocompile.Compiler
would previously accept some sources that would be rejected byprotoc
. In particular,protocompile
allowed for explicitly-signed positive numeric literals -- with a leading plus (+) sign. But this is not allowed by the reference compiler,protoc
, nor by implementations of the text format in myriad languages (which is also the format the compiler uses to parse custom option values that are message literals).- This change is not backwards compatible. The AST node type
ast.PositiveUintLiteralNode
has been removed. It was only used to support this invalid construct in the language. Code that refers to this node type (or its associated factory function andVisitor
method) must be removed.
- This change is not backwards compatible. The AST node type
- A
protocompile.Compiler
would previously reject some sources that wouldprotoc
would accept. In particular,protocompile
did not allow-nan
as a default field value or custom option value and it also did not acceptinf
and alternate case spellings (such as upper- or mixed-case) ofinfinity
andnan
in message literals, which are all allowed byprotoc
.