Timeline for Is "avoid extra null pointer risk" a reason to avoid "introduce parameter objects"?
Current License: CC BY-SA 4.0
7 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Sep 3, 2024 at 5:05 | history | edited | Doc Brown | CC BY-SA 4.0 |
deleted 3 characters in body
|
| Jul 24, 2024 at 19:06 | history | edited | Doc Brown | CC BY-SA 4.0 |
added 1 character in body
|
| Jul 23, 2024 at 14:44 | comment | added | Doc Brown | @Peter-ReinstateMonica: yes, I thought to add some words about the OP's misconception where the extra effort for null handling has to take place; it is typically not inside the function, but maybe on the callers side,.I currently lack some time to extend my answer properly. | |
| Jul 23, 2024 at 12:59 | comment | added | Peter - Reinstate Monica | It is in my opinion also not necessary to check for null, in many instances. If you didn't check for unexpected int values before (which would indicate an uninitialized or default-initialized value -- if that distinction can be made at all! --, essentially the same error): Then you don't need to check the pointer either. It makes complete sense to check values -- not only pointers! -- for sanity at the borders of your responsibility, but not everywhere within. It would usually indicate a programming error; what do you do then? Throw? You do that already with a null pointer access. | |
| S Jul 22, 2024 at 19:20 | history | suggested | serv-inc | CC BY-SA 4.0 |
just some grammar
|
| Jul 22, 2024 at 13:39 | review | Suggested edits | |||
| S Jul 22, 2024 at 19:20 | |||||
| Jul 22, 2024 at 5:06 | history | answered | Doc Brown | CC BY-SA 4.0 |