From a4beeca8579f23560eb30ba3acd75a533ed1d4d8 Mon Sep 17 00:00:00 2001 From: Jeff Carr Date: Thu, 9 Jan 2025 05:49:23 -0600 Subject: mutex's are being added to the protoc pb.go file --- auto.proto | 19 +++++++++++-------- 1 file changed, 11 insertions(+), 8 deletions(-) (limited to 'auto.proto') diff --git a/auto.proto b/auto.proto index 2549294..a44b63f 100644 --- a/auto.proto +++ b/auto.proto @@ -64,21 +64,24 @@ message MsgName { // string name = 1; // the name of the message aka struct. for this example: "Shelf" - bool doMarshal = 2; // if "Shelf" should have Marshal & Unmarshal functions - bool doMutex = 3; // an experiment to insert a mutex into the protoc generated msg struct (bad idea?) - repeated string sort = 4; // "Book", "Picture", etc - repeated string unique = 5; // if the fields should have AppendUnique() functions + string lockname = 2; // ShelfMU + bool doMarshal = 3; // if "Shelf" should have Marshal & Unmarshal functions + bool doMutex = 4; // an experiment to insert a mutex into the protoc generated msg struct (bad idea?) + bool mutexFound = 5; // an experiment to insert a mutex into the protoc generated msg struct (bad idea?) + repeated string sort = 6; // "Book", "Picture", etc + repeated string unique = 7; // if the fields should have AppendUnique() functions } message File { // `autogenpb:nomarshal` string Package = 1; // whatever the package name is at the top of the .go file string filename = 2; // yellow.proto - string filebase = 3; // yellow - string uuid = 4; // the uuid to use in a func NewMsgName() - int64 version = 5; // the version to use in a func NewMsgName() + string pbfilename = 3; // yellow.pb.go + string filebase = 4; // yellow + string uuid = 5; // the uuid to use in a func NewMsgName() + int64 version = 6; // the version to use in a func NewMsgName() // every struct in this proto file, this file has: "Apple", "Apples", ... "File", etc... - repeated MsgName msgNames = 6; // `autogenpb:unique` // in this file + repeated MsgName msgNames = 7; // `autogenpb:unique` // in this file } // I know, I know, the whole point of using protobuf -- cgit v1.2.3