13,894 reputation
12049
bio website
location
age
visits member for 3 years, 7 months
seen yesterday

Jan
6
comment Private comments in git
@DocBrown: Yes. But the problem with comments in code is that they invariably remain there even when the code is refactored. And such comment is actually worse than no comment, because it becomes actively misleading.
Jan
6
answered How to include license for MIT-licensed CSS?
Jan
6
answered Private comments in git
Jan
6
revised Private comments in git
added 220 characters in body
Jan
6
answered Private comments in git
Jan
4
comment Can only integers be stored as register variables?
@Yousaf: That it depends on the platform, compiler, compiler options and exact piece of code. It's best left up to the compiler to decide.
Jan
3
comment Using std::sort et al. with user-defined comparison routine
Nor can I imagine an implementation of sort that would run out of bounds on invalid comparison function. Normal implementation of either quick sort, merge sort nor heap sort can't do that.
Jan
3
comment Using std::sort et al. with user-defined comparison routine
What implementation of std::sort is that? I've had my share of bugs in comparison operators, but the only think I've ever got from std::sort was an assertion, never segfault and never endless loop. True, you don't want assertion either.
Jan
3
revised Can only integers be stored as register variables?
added 80 characters in body
Jan
3
comment Can only integers be stored as register variables?
@delnan: The fact that they use heuristic algorithm does not change the nature of the problem itself and the heuristic is still based on the mathematical apparatus around graph colouring. Since the problem is NP-complete, I don't think any compiler searches exact solution; it would be too expensive.
Jan
3
answered Can only integers be stored as register variables?
Jan
3
revised What does the Apache licensing mean by “Permitted: Commercial Use”
added 4 characters in body
Jan
3
awarded  Nice Answer
Jan
3
revised What does the Apache licensing mean by “Permitted: Commercial Use”
added 574 characters in body
Jan
3
answered What does the Apache licensing mean by “Permitted: Commercial Use”
Jan
1
comment Emotional detachment from bad code
@gnat: It kind of does. Whether code is ugly is subjective.
Dec
28
comment Why are reference-counting smart pointers so popular?
@supercat: Yes, you can get a special type of pointers to work. It's basically what Microsoft did in Managed C++. And note, that they would not have to keep a list of anything at runtime; compile-time support is sufficient. But it would not be very useful with all the existing code using plain old pointers.
Dec
28
comment Why are reference-counting smart pointers so popular?
@supercat: Maintaining a list at runtime would be more expensive than reference counting, therefore it would not have any advantage over shared_ptr. Most probably it would be a lot more expensive.
Dec
28
comment Why are reference-counting smart pointers so popular?
@supercat: Standard pointers can be reinterpret-casted, which prevents the collector from ever being sure what is a pointer. You'd need special kind of pointers and special rules for them and than it would no longer be useful with existing code.
Dec
23
awarded  Nice Answer