3,919 reputation
717
bio website
location
age
visits member for 2 years, 9 months
seen 12 hours ago

Jul
28
comment Which is the more testable C function implementation?
Object-private state is exactly analogous to opaque context state, and both are much better than global state. You can write perfectly OO code in C, you just have to do it without compiler support and syntactic sugar.
Jul
24
answered Which is the more testable C function implementation?
Jul
16
revised In wikipedia it is referred that Remote Socket Address is the Client Socket Address but i doubt that
damn pronoun possessive apostrophes
Jul
16
answered In wikipedia it is referred that Remote Socket Address is the Client Socket Address but i doubt that
Jul
15
answered Pros and cons for choosing between different return types
Jun
17
answered Quadtree with duplicates
Jun
17
comment Quadtree with duplicates
How would you like it to behave? You're implementing it, so you have to decide what behaviour is correct for you. Maybe each unique coordinate can be a list of elements at that coordinate. Maybe your points are constrained to be unique. You know what you need, and we don't.
Jun
15
awarded  Nice Answer
Jun
13
awarded  Informed
Jun
13
revised Reconciling the Boy Scout Rule and Opportunistic Refactoring with code reviews
added 413 characters in body
Jun
13
revised Reconciling the Boy Scout Rule and Opportunistic Refactoring with code reviews
added 714 characters in body
Jun
13
comment Reconciling the Boy Scout Rule and Opportunistic Refactoring with code reviews
Yes, your understanding is correct, you'd have two sequential commits with the second (functional) depending on the first (refactoring). The diff/patch workflow described above is precisely a way of doing this that doesn't require manually deleting changes and then re-writing them.
Jun
13
comment Reconciling the Boy Scout Rule and Opportunistic Refactoring with code reviews
I think you're really not understanding me. Editing source and grouping edits into commits, yes even edits in the same file, are logically separate activities. If this seems difficult, you just need to learn the available source code management tools better.
Jun
12
comment Reconciling the Boy Scout Rule and Opportunistic Refactoring with code reviews
Different lines in the same file are fine in the workflows given. And given the two commits would be sequential, it's perfectly ok for the second (functional) commit to depend on the first. Oh, and TFS2013 allegedly supports git.
Jun
12
answered Reconciling the Boy Scout Rule and Opportunistic Refactoring with code reviews
Jun
12
comment Reconciling the Boy Scout Rule and Opportunistic Refactoring with code reviews
Bullet 1 doesn't claim that separating the commits is impossible. It just implies that you don't know how to do it, or your VCS makes it hard. I do this all the time, even taking a single commit and splitting it after the fact.
Jun
12
comment Reconciling the Boy Scout Rule and Opportunistic Refactoring with code reviews
@t0x1n just because you make the changes together, doesn't mean you have to commit them together. Besides, it's often useful to check your refactoring had no unexpected side-effects separately from checking your functional change had the expected effect. Obviously this may not apply to all refactorings, but it's not bad advice in general.
Jun
5
answered Writing a method to 'transform' an immutable object: how should I approach this?
Jun
3
comment Converting large files in python
What platform are you using? The available tools may differ ...
May
26
comment How can I have a shell script log into a remote server and execute imqcmd there?
You apparently also want the remote command to ask for user input. Are there any other requirements not shown in the question? Could you say exactly what you want it to do?