• Jon Skeet's avatar
    Provide simple access to descriptor declarations in C# · 17119990
    Jon Skeet authored
    This is primarily for access to comments, which would be expected to be available in a protoc plugin.
    
    The implementation has two fiddly aspects:
    
    - We use a Lazy<T> to avoid building the map before cross-linking. An alternative would be to crosslink at the end of the constructor, and remove the calls to CrossLink elsewhere. This would be generally better IMO, but deviate from the Java code.
    - The casts to IReadOnlyList<DescriptorBase> are unfortunate. They'll always work, because these lists are always ReadOnlyCollection<T> for a descriptor type... but we can't use IList<DescriptorBase> as that's not covariant, and it's annoyingly fiddly to change the field to be of type ReadOnlyCollection<T>.
    17119990
Name
Last commit
Last update
..
compatibility_tests/v3.0.0 Loading commit data...
keys Loading commit data...
protos Loading commit data...
src Loading commit data...
.gitignore Loading commit data...
CHANGES.txt Loading commit data...
Google.Protobuf.Tools.nuspec Loading commit data...
Google.Protobuf.Tools.targets Loading commit data...
README.md Loading commit data...
build_packages.bat Loading commit data...
build_tools.sh Loading commit data...
buildall.sh Loading commit data...
generate_protos.sh Loading commit data...
global.json Loading commit data...