3,387 reputation
11018
bio website
location Italy
age 49
visits member for 3 years
seen 17 hours ago

Born an living in the suburbs of Milan (Italy), I graduated in 1989 as a Master Electronic Engineer, specializing in information technology an inter-networking systems and plants.

Interested in programming since the early '80s, today working mainly in C++ and D programming languages, in libraries development.


Aug
22
comment C++ class with only pure virtual functions: what's that called?
A "protocol" is the "sequence of actions that have to be taken from cooperating interfaces to perform certain tasks". It cannot be a sinonimous of "interface", since it is defined around interfaces. A protocol describes how interface have to be used. an interface describes what an object exposes.
Aug
22
answered Without C++-like destructors, how do we return resources that aren't managed by garbage collector in Java?
May
12
answered Heap overflow vs stack overflow
May
11
awarded  Nice Answer
Apr
20
comment Nested classes vs namespaces
I don't see any nested class ...
Mar
8
comment What non-theoretical, practical programming language has no reserved keywords?
@SK-logic: usually. But what are "identifiers" if you dint't tokenize yet? Since a token is "whatever recognizable sting", "int", "myvalue" and "+" are not different, before a syntax rule had been given. If "+" is not defined as operator, it can be just a name for a thing like whatever other unicode single character string. Operators, by a pure syntax stand point, are nothing more that "single character keywords".
Mar
8
comment What non-theoretical, practical programming language has no reserved keywords?
Do operators and punctuation count as "keyword"? if yes, then no language may exist, since no syntax can be defined.
Feb
25
awarded  Caucus
Feb
8
comment When do you 'speak' C++ fluently?
Comparing with "fluent English" I would say: "When you upgrade your code so fast no one can see the bugs"
Feb
2
answered Should methods always return from one place?
Feb
1
comment How does C++ handle multiple inheritance with a shared common ancestor?
About CRTP, the assertion "nothing is required to be virtual" is true in your example as in the most of the CRTP classes implementation cases, but has a difference in respect to regular inheritance: IComparable<A> and IComparable<B> are distinct types and there is not anymore an IComaprable* that can point to them both (no runtime polymorphism). For calasses used as values, or where object types are statically known, this is not an issue. Otherwise IComparamble<Derived> will most likely have an IComparabeBase (not templetized) with all pure virtual methods (2nd grade polymorphism).
Nov
9
comment Should I use C style in C++?
from the google style guide: "Use only approved libraries and language extensions from C++11 (formerly known as C++0x). Currently, none are approved." Uhmmmm... Time to upgrade the style guide ...
Nov
6
answered What is the way to understand someone else's giant uncommented spaghetti code?
Nov
6
comment In C and C++, what methods can prevent accidental use of the assignment(=) where equivalence(==) is needed?
@JohnR.Strohm This is just half of the cake: if C had := for assign and = for compare you will not mistake comparisons with assignment, but could potentially mistake assignments with comparisons (writing a = b where a:=b is required). You and karl are both right taken together and both wrong taken individually. Of course we can discuss about the "probability" of one mistake respect to the other, but -at the and- it just all about each one's personal habits.
Oct
28
comment Is “send us a page with code” a typical interview requirement?
After reading the "sort of stuff" and the comment to that I was frankly terrified about how many of them focused on the poor structure, without even get what the real problem was. (the logic inversion: to permit only numbers he denied all the ASCII non-number individually. Every other non-number that lives outside the 0..127 space remained permitted!) If that's the result, I wonder about the knowledge of recruiters!
Oct
22
awarded  Enlightened
Oct
22
awarded  Nice Answer
Oct
22
answered Does putting types/functions inside namespace make compiler's parsing work easy?
Oct
21
awarded  Custodian
Oct
21
reviewed Approve suggested edit on How can I explain object-oriented programming to someone who's only coded in Fortran 77?