Message58729
On 2007-12-17, Christian Heimes wrote:
> Christian Heimes added the comment:
>
> Hi Mark!
>
> In general the patch is fine but it has some small issues.
>
> * Your patches are all reversed. They remove (-) the new lines instead
> of adding (+) them. Why aren't you using svn diff > file.patch?
I didn't know about that. Have now used it.
> * You are mixing tabs with spaces. All 2.6 C files and most 3.0 C files
> are still using tabs.
Okay, have now switched to tabs.
> * You forgot about %f. For large values the format characters f and F
> are using the exponent display, too "%f" % 1e60 == '1e+60'
Good point; I now search for 'e' or 'E' in any number.
> * You cannot assume that char is unsigned. Use Py_CHARMAP(char) instead.
> I think that you can make the code more readable when you do format_char
> = tolower(Py_CHARMAP(format_char)); first.
I don't refer to format_char any more.
> * The code is not C89 conform. The standards dictate that you cannot
> declare a var in the middle of a block. New var must be declared right
> after the {
I didn't know that. I've now moved the variable declarations.
I've attached the diff you asked for, plus a diff for the test_float.py
file -- and I've done the changes in relation to 2.6 trunk since there's
nothing 3.0-specific.
Hope this is now okay. |
|
| Date |
User |
Action |
Args |
| 2007-12-18 08:47:51 | mark | set | spambayes_score: 1.28534e-05 -> 1.28534e-05 recipients:
+ mark, gvanrossum, christian.heimes |
| 2007-12-18 08:47:51 | mark | link | issue1600 messages |
| 2007-12-18 08:47:50 | mark | create | |
|