On Sat, 9 Jun 2012 18:40:33 +0200
Campbell Barton <[email protected]> wrote:

> Good work - sent new review
> http://codereview.appspot.com/6305077/
>

It takes some time to get used to the style of a project, and in every
project I contribute I try hard to make my code "blend in" :), so I will
follow your directions.

However before I get started I just want to say that I like gotos in
_error_paths_ a lot, in the linux kernel (where I mainly got my current
coding style from) they are even encouraged, because they "just make
sense": they reduce code duplication, it is also less likely you forget
a deallocation this way, and they make it a little easier to see that
things are undone in the reverse order they were done; I tend to use the
goto in the "return NULL" case too for aesthetic consistency, but maybe
this is just a matter of personal taste.

That said, I'll do the changes you suggested Campbell, thanks.

> python is currently single threaded so you could use a static var
> here, though I would like to avoid this where possible.
> 

Ok, so I am going to use a static global var for now, with a big fat
comment mentioning that a portable qsort_r() alternative should be used
as soon as this becomes available in blender. I don't think I am going
to add that myself tho.

Regards,
   Antonio

-- 
Antonio Ospite
http://ao2.it

A: Because it messes up the order in which people normally read text.
   See http://en.wikipedia.org/wiki/Posting_style
Q: Why is top-posting such a bad thing?
_______________________________________________
Bf-python mailing list
[email protected]
http://lists.blender.org/mailman/listinfo/bf-python

Reply via email to