plutoo / protobuf-csharp-port

Automatically exported from code.google.com/p/protobuf-csharp-port
Other
0 stars 0 forks source link

Suffix missing for required non-primitive properties #85

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1. Create a protobuf file with the following definition:
package school;

message Name
{
    required string first_name  = 1;
    required string last_name = 2;  
}

message Student
{
    required Name student_name = 1;
    optional string course = 2;
    required bool has_paid_dues = 3;
}

2. Generate C# types with suffix for type name. Let's assume we required "_SUF" 
as suffix.

What is the expected output? What do you see instead?
The Student and StudentName types are correctly generated as Student_SUF and 
StudentName_SUF. But the student_name property in Student type still uses 
StudentName instead of StudentName_SUF.

What version of the product are you using? On what operating system?
Latest version.

Please provide any additional information below.

Original issue reported on code.google.com by shujaat...@gmail.com on 11 Apr 2014 at 1:55

Attachments:

GoogleCodeExporter commented 9 years ago
I think this would need a fix for in the XSLT used for C# code generation.

Original comment by shujaat...@gmail.com on 11 Apr 2014 at 1:56

GoogleCodeExporter commented 9 years ago
protobuf-csharp-port doesn't use XSLT, and I don't think we support type 
suffixes like this... are you thinking of a different Protocol Buffers 
implementation, e.g. protobuf-net?

Original comment by jonathan.skeet on 11 Apr 2014 at 5:09

GoogleCodeExporter commented 9 years ago
You are right. Mishhtakke... :) Thanks!

Original comment by shujaat...@gmail.com on 12 Apr 2014 at 3:46

GoogleCodeExporter commented 9 years ago
How can i delete or set it as "Not an issue"

Original comment by shujaat...@gmail.com on 12 Apr 2014 at 3:47

GoogleCodeExporter commented 9 years ago
Doing it myself :)

Original comment by jonathan.skeet on 12 Apr 2014 at 4:37