fix enum float value in C#, minor format fix in doc (#5726)

This commit is contained in:
wing328
2017-05-29 22:16:42 +08:00
committed by GitHub
parent 3df5b6f303
commit b84769d1e3
34 changed files with 1508 additions and 116 deletions
@@ -560,6 +560,9 @@ public class CSharpClientCodegen extends AbstractCSharpCodegen {
if ("int?".equalsIgnoreCase(datatype) || "long?".equalsIgnoreCase(datatype) ||
"double?".equalsIgnoreCase(datatype) || "float?".equalsIgnoreCase(datatype)) {
return value;
} else if ("float?".equalsIgnoreCase(datatype)) {
// for float in C#, append "f". e.g. 3.14 => 3.14f
return value + "f";
} else {
return "\"" + escapeText(value) + "\"";
}