diff --git a/compiler/cpp/src/generate/t_csharp_generator.cc b/compiler/cpp/src/generate/t_csharp_generator.cc
index be20496..baa229e 100644
--- a/compiler/cpp/src/generate/t_csharp_generator.cc
+++ b/compiler/cpp/src/generate/t_csharp_generator.cc
@@ -922,7 +922,15 @@
   const vector<t_field*>& fields = tstruct->get_members();
   vector<t_field*>::const_iterator f_iter;
 
-  indent(out) << "bool __first = true;" << endl;
+  bool useFirstFlag = false;
+  for (f_iter = fields.begin(); f_iter != fields.end(); ++f_iter) {
+    if( ! field_is_required((*f_iter))) {
+      indent(out) << "bool __first = true;" << endl;
+	  useFirstFlag = true;
+    }
+    break;
+  }
+
   bool had_required = false;  // set to true after first required field has been processed
 
   for (f_iter = fields.begin(); f_iter != fields.end(); ++f_iter) {
@@ -944,17 +952,17 @@
       }
     }
 
-    if( ! had_required)	{
+    if( useFirstFlag && (! had_required)) {
       indent(out) << "if(!__first) { __sb.Append(\", \"); }" << endl;
-	  if( ! is_required) {
+      if( ! is_required) {
         indent(out) << "__first = false;" << endl;
-	  }
+      }
       indent(out) <<
         "__sb.Append(\"" << prop_name((*f_iter)) << ": \");" << endl;
     } else {
       indent(out) <<
         "__sb.Append(\", " << prop_name((*f_iter)) << ": \");" << endl;
-	}
+    }
         
           
     t_type* ttype = (*f_iter)->get_type();
diff --git a/compiler/cpp/src/generate/t_delphi_generator.cc b/compiler/cpp/src/generate/t_delphi_generator.cc
index 9a86566..954735a 100644
--- a/compiler/cpp/src/generate/t_delphi_generator.cc
+++ b/compiler/cpp/src/generate/t_delphi_generator.cc
@@ -3167,12 +3167,20 @@
 
   string tmp_sb = "__sb";
   string tmp_first = "__first";
+  bool useFirstFlag = false;
 
   indent_impl(out) << "function " << cls_prefix << cls_nm << ".ToString: string;" << endl;
   indent_impl(out) << "var" << endl;
   indent_up_impl();
   indent_impl(out) << tmp_sb << " : TThriftStringBuilder;" << endl;
-  indent_impl(out) << tmp_first << " : Boolean;" << endl;
+  for (f_iter = fields.begin(); f_iter != fields.end(); ++f_iter) {
+    bool is_optional  = ((*f_iter)->get_req() != t_field::T_REQUIRED);
+    if( is_optional) {
+      indent_impl(out) << tmp_first << " : Boolean;" << endl;
+      useFirstFlag = true;
+    }
+    break;
+  }
   indent_down_impl();
   indent_impl(out) << "begin" << endl;
   indent_up_impl();
@@ -3181,7 +3189,10 @@
   indent_impl(out) << "try" << endl;
   indent_up_impl();
 
-  indent_impl(out) << tmp_first << " := TRUE;" << endl;
+  if( useFirstFlag) {
+    indent_impl(out) << tmp_first << " := TRUE;" << endl;
+  }
+  
   bool had_required = false;  // set to true after first required field has been processed
   
   for (f_iter = fields.begin(); f_iter != fields.end(); ++f_iter) {
@@ -3201,9 +3212,9 @@
       }
     }
 
-    if( ! had_required)	{
-	  indent_impl(out) << "if not " << tmp_first << " then " << tmp_sb << ".Append(',');" << endl;
-	  if (is_optional) {
+    if( useFirstFlag && (! had_required)) {
+      indent_impl(out) << "if not " << tmp_first << " then " << tmp_sb << ".Append(',');" << endl;
+      if (is_optional) {
         indent_impl(out) << tmp_first << " := FALSE;" << endl;
       }
       indent_impl(out) <<
@@ -3212,7 +3223,7 @@
       indent_impl(out) <<
         tmp_sb << ".Append(', " << prop_name((*f_iter), is_exception) << ": ');" << endl;
     }
-	
+
 
     t_type* ttype = (*f_iter)->get_type();
     if (ttype->is_xception() || ttype->is_struct()) {
@@ -3225,12 +3236,12 @@
       indent_impl(out) <<
         tmp_sb << ".Append(" << prop_name((*f_iter), is_exception)  << ");" << endl;
     }
-	
+    
     if (null_allowed || is_optional) {
       indent_down_impl();
       indent_impl(out) << "end;" << endl;
     } 
-	
+    
     if (!is_optional) {
       had_required = true;  // now __first must be false, so we don't need to check it anymore
     }
@@ -3240,8 +3251,10 @@
     tmp_sb << ".Append(')');" << endl;
   indent_impl(out) <<
     "Result := " << tmp_sb <<  ".ToString;" << endl;
-  indent_impl(out) <<
-    "if " << tmp_first <<  " then {prevent warning};" << endl;
+  if( useFirstFlag) {
+    indent_impl(out) <<
+      "if " << tmp_first <<  " then {prevent warning};" << endl;
+  }
 
   indent_down_impl();
   indent_impl(out) << "finally" << endl;
