great, that is the push in the right direction I needed. all sorted now.
-Steve On Thursday, 3 November 2022 at 15:35:29 UTC [email protected] wrote: > Things like comments and line numbers from the .proto file are represented > in the SourceCodeInfo message here > <https://github.com/protocolbuffers/protobuf/blob/88d8f6001d4b14520488f23de36366b7df673373/src/google/protobuf/descriptor.proto#L754>. > > Unfortunately I'm not familiar enough with Go protos or protogen to say > exactly how to get ahold of that, but this Location > <https://pkg.go.dev/google.golang.org/protobuf/compiler/protogen#Location> > type looks promising. > > On Thu, Nov 3, 2022 at 3:07 AM Steve Simon <[email protected]> wrote: > >> Hi, >> >> I am using protogen for go successfully. We are using >> extend google.protobuf.ServiceOptions { as we need to >> encode extra fields for our backend. >> >> When I find typos in the serviceOptions I am parsing I would like to >> generate diagnostics which reference the source proto file and line number. >> >> I have not found any way to extract the source line number for an object >> (Service record in my case). Is it possible? >> >> -Steve >> >> -- >> 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/e5e894ff-fba1-4889-9445-12a629d19907n%40googlegroups.com >> >> <https://groups.google.com/d/msgid/protobuf/e5e894ff-fba1-4889-9445-12a629d19907n%40googlegroups.com?utm_medium=email&utm_source=footer> >> . >> > -- 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/b8b82573-0528-4d0c-ae6d-19f4ee26bfcfn%40googlegroups.com.
