Timeline for "Is" prefix and "On" suffix as reasonable exceptions to a "non-hungarian" naming standard?
Current License: CC BY-SA 3.0
19 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Mar 23, 2016 at 15:32 | comment | added | 8bittree | @Izkata The difference between Systems Hungarian and Apps Hungarian is simply whether the compiler/interpreter knows about the type (Systems) or not (Apps). A safer solution for that article's example (in a language that supports creating new types) is to create a SafeString type and use it appropriately. Suddenly all that Apps Hungarian becomes Systems Hungarian noise. Use the compiler/interpreter to enforce type safety, not your eyes. | |
| Jun 29, 2013 at 16:37 | comment | added | shannon | jk - so if I replaced bool, fully spelling it out as boolean, it wouldn't apply? | |
| Jun 20, 2013 at 6:55 | comment | added | jk. | Er "Is" and "On" are words, so not Hungarian warts (apologies to actual Hungarians) | |
| Jun 20, 2013 at 2:04 | comment | added | Izkata | @shannon What doesn't make sense to you is called "Systems Hungarian Notation" (or sometimes, "Bad Hungarian Notation") as it is a complete misunderstanding of the original intent. This article has more information on the two versions of Hungarian Notation. | |
| Jun 20, 2013 at 1:08 | answer | added | jmoreno | timeline score: 4 | |
| May 28, 2013 at 14:55 | audit | Suggested edits | |||
| May 29, 2013 at 18:03 | |||||
| May 11, 2013 at 10:18 | comment | added | shannon | @AakashM: That question looks like a potential debate, but let me just say I'm referring to applying any naming prefix/suffix rule based entirely on a variable type. When I asked the question I was considering making a naive commitment to do so. (Is, On). | |
| May 10, 2013 at 14:41 | comment | added | AakashM | When you say "Hungarian in general does not [make sense to me]", what are you understanding by 'Hungarian' ? | |
| May 10, 2013 at 13:57 | answer | added | Michael Riley - AKA Gunny | timeline score: 2 | |
| May 10, 2013 at 13:56 | vote | accept | shannon | ||
| May 10, 2013 at 13:43 | answer | added | Bart van Ingen Schenau | timeline score: 10 | |
| May 10, 2013 at 13:22 | comment | added | shannon | Looking more at what seems right to me, natural language does seem to play the largest role for me. I find that "FirstVerified", "LastVerified", and "LastActivity" make sense to me. "Begin" and "End" are reasonable to me on an "Engagement" object, but would need clarification on a "Building" object. But "CreatedOn", "OpenedOn", and "ResolvedOn" all help clarify the intent is to record some type of time, where it would be reasonable to interpret the core function of the variable incorrectly when reading naturally. Conversely, "IsOffered" helps clarify also. | |
| May 10, 2013 at 12:44 | review | First posts | |||
| May 10, 2013 at 12:53 | |||||
| May 10, 2013 at 12:42 | history | edited | shannon | CC BY-SA 3.0 | added 39 characters in body |
| May 10, 2013 at 12:39 | answer | added | Aleksandra | timeline score: 2 | |
| May 10, 2013 at 12:36 | history | edited | shannon | CC BY-SA 3.0 | added 39 characters in body |
| May 10, 2013 at 12:31 | comment | added | shannon | Very good point. That could certainly explain why it "feels right" to me. I wonder, does that mean it IS right? It just seems that invariably when I do not use "Is" and "On" I have a harder time understanding my own code. | |
| May 10, 2013 at 12:29 | comment | added | thorsten müller | Maybe because in everyday speaking you often use things like "this problem is resolved" while you rarely hear somebody claim that he owns two intDogs? | |
| May 10, 2013 at 12:24 | history | asked | shannon | CC BY-SA 3.0 |