github.com/jhump/protocompile@v0.0.0-20221021153901-4f6f732835e8/parser/doc.go (about) 1 // Package parser contains the logic for parsing protobuf source code into an 2 // AST (abstract syntax tree) and also for converting an AST into a descriptor 3 // proto. 4 // 5 // A FileDescriptorProto is very similar to an AST, but the AST this package 6 // uses is more useful because it contains more information about the source 7 // code, including details about whitespace and comments, that cannot be 8 // represented by a descriptor proto. This makes it ideal for things like 9 // code formatters, which may want to preserve things like whitespace and 10 // comment format. 11 package parser