everettwilson21 / protobuf-netbeans-plugin

Automatically exported from code.google.com/p/protobuf-netbeans-plugin
0 stars 0 forks source link

protoc supports negative numbers for default values #8

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
Type the following message into any proto file created by the plugin.

message request {
    optional sint32 content_length = 1 [default = -1];
}

The plugin should see this as a valid protobuf message.
The plugin reports the line with the "-1" as being in error.
Protoc processed the message as expected.

What version of the product are you using? On what operating system?

I am using Netbeans 6.7.1 and ProtobufEditor 1.0.3. 
Problem occurs on both ubuntu 9.04 and winxp.

Please provide any additional information below.
I reviewed the nbs file from svn and see the problem is in the parsing. I 
do not know this parsing technology well enough to create the rules for 
parsing the default value based on the defined type as is done in 
parser.cc.

Original issue reported on code.google.com by jwho...@gmail.com on 9 Aug 2009 at 6:15

GoogleCodeExporter commented 8 years ago
Resolved in just released version 2.0.0

Original comment by piotr.tabor on 26 Aug 2009 at 6:48