Timeline for Array with pointers to objects initialization
Current License: CC BY-SA 3.0
Post Revisions
14 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Nov 5, 2012 at 1:18 | vote | accept | Theocharis K. | ||
| Nov 5, 2012 at 1:06 | answer | added | Lightness Races in Orbit | timeline score: 0 | |
| Nov 5, 2012 at 1:06 | comment | added | Recker |
@Aposperite....By the way...your erroneous code works and prints the value of INT_MAX million times on my system when I change the name of private variable because of error mentioned in earlier comment...
|
|
| Nov 5, 2012 at 1:05 | history | edited | Lightness Races in Orbit | CC BY-SA 3.0 |
added 4 characters in body
|
| Nov 5, 2012 at 1:03 | comment | added | Lightness Races in Orbit |
@Aposperite: For the constructor it is not a convention but a requirement. However, for your member variable of type int it is simply silly.
|
|
| Nov 5, 2012 at 0:59 | comment | added | Recker |
@Aposperite.... I am talking about the PID private variable....and that by the way was my gcc compiler...I was trying to see whats wrong with your code....
|
|
| Nov 5, 2012 at 0:57 | comment | added | Theocharis K. | @noleptr it is a convention to use the name of the class for the class constructor & destructor. You are the first guy to tell me something like this. Any tips on why I should avoid this? | |
| Nov 5, 2012 at 0:55 | comment | added | Recker |
error: field ‘int PID::PID’ with same name as class...avoid it....
|
|
| Nov 5, 2012 at 0:54 | comment | added | Theocharis K. | That was a bad statement of me. There must be a reason and actually this is the reason I am looking for. Any ideas? | |
| Nov 5, 2012 at 0:53 | answer | added | carlosdc | timeline score: 3 | |
| Nov 5, 2012 at 0:53 | history | edited | Theocharis K. | CC BY-SA 3.0 |
deleted 6 characters in body
|
| Nov 5, 2012 at 0:45 | history | edited | Theocharis K. | CC BY-SA 3.0 |
added 157 characters in body
|
| Nov 5, 2012 at 0:43 | comment | added | Ed Swangren | "My main crashes for no reason" - Doubtful. I'm inclined to believe the OS. | |
| Nov 5, 2012 at 0:40 | history | asked | Theocharis K. | CC BY-SA 3.0 |