Hello,
I want to match a leading_comments value with the related protobuf entity
it is written next to.
Let suppose that I got the following protobuf:
syntax = "proto3";
enum Greeting {
NONE = 0;
MR = 1;
MRS = 2;
MISS = 3;
}
// Documentation for the message
message Hello {
// Documentation for the greeting field
Greeting greeting = 1;
// Documentation for the name
string name = 2;
}
I'm using protoc and writing a short plugin that looks like this:
https://gist.github.com/remyleone/54725a5be6d152a406929036512981e4
It generates a request.txt that I print:
https://gist.github.com/remyleone/ddb558e3e39f84c0b828c55cc0227b6a
What I don't know is how to match the comments with the related protobuf
entity. I'm not sure about how to use location with its span and path. Is
there any helper to do the matching? Or a tutorial?
Do you know how to do this? Could I do with go?
Best regards
Rémy
--
You received this message because you are subscribed to the Google Groups
"Protocol Buffers" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/protobuf/938746ce-f7c6-4c0a-8ff0-07697d35db6b%40googlegroups.com.