Skip to content

Commit

Permalink
2002-04-24 Gonzalo Paniagua Javier <gonzalo@ximian.com>
Browse files Browse the repository at this point in the history
	* DecimalFormatter.cs (ToString): return correct value when the
	decimal number is 0.

svn path=/trunk/mcs/; revision=4022
  • Loading branch information
gonzalop committed Apr 24, 2002
1 parent 73e0b71 commit 9597512
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
5 changes: 5 additions & 0 deletions mcs/class/corlib/System/ChangeLog
@@ -1,3 +1,8 @@
2002-04-24 Gonzalo Paniagua Javier <gonzalo@ximian.com>

* DecimalFormatter.cs (ToString): return correct value when the
decimal number is 0.

2002-04-24 Patrik Torstensson <patrik.torstensson@labs2.com>

* Type.cs (GetProperty): fixed call syntax (needs an empty array not null)
Expand Down
3 changes: 3 additions & 0 deletions mcs/class/corlib/System/DecimalFormatter.cs
Expand Up @@ -109,6 +109,9 @@ public static string NumberToString(string format, NumberFormatInfo nfi, S.Decim
}
#endif

if (sb.ToString () == String.Empty && decPos > 0 && sign == 0)
sb.Append ('0');

// now build the format
switch (specifier)
{
Expand Down

0 comments on commit 9597512

Please sign in to comment.