-
Notifications
You must be signed in to change notification settings - Fork 3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fixed Getting Started #1
Conversation
syntax = "proto3"; | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't need those 2 lines
int32 f_int32 = 1; | ||
int64 f_int64 = 2; | ||
uint32 f_uint32 = 3; | ||
uint64 f_uint64 = 4; | ||
sint32 f_sint32 = 5; | ||
sint64 f_sint64 = 6; | ||
bool f_bool = 7; | ||
fixed32 f_fixed32 = 8; | ||
fixed64 f_fixed64 = 9; | ||
sfixed32 f_sfixed32 = 10; | ||
sfixed64 f_sfixed64 = 11; | ||
float f_float = 12; | ||
double f_double = 13; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Don't need all these fields. Just put a comment saying something like "fields here"
The "Getting Started" section isn't meant to be a full example, but rather a basic template for using |
Also you need to make sure both |
I've fixed the README Getting Started section with a more complete example, so this issue can be closed. If you continue having issues feel free to reopen. |
I like the straightforwardness of the "Getting Started" section, except it doesn't work. It says to add to Cargo.toml
But 1.
cargo build
tells me essentially to use "0.1.0" rather than "0.1", and then, 2. tells memicropb-gen
doesn't havecontainer-heapless
. After enablingcontainer-heapless
onmicropb
instead, I then 3. need to add the example.proto file given later, and 4. writeexample::example_::Example
instead ofexample::Example
and 5. import PbEncoder. THEN it appears to work, after filling in the example code. 6. For immediate out-of-the-box compilation, I reordered the example code to serialize an Example, then deserialize the bytes.