Talk:Gotcha (programming)

message: Gotchas are potentially vast subject and it is extreeeeeemly useful to have a page warning people of some of the common gotchas.Dejvid 11:20, 13 August 2005 (UTC)
thread_title: Why I deleted the Transwiki tag

message: Googling for programming gotcha yields 619,000 hits. Clearly it's notable, though I'm not sure how to "establish" this in the text. More examples in more languages would help. Perhaps a reference to books on the subject, such as Koenig's C Traps and Pitfalls? Tualha (Talk) 10:04, 26 October 2006 (UTC)
replies: text: Okay. This is clearly a topic that's not confined to be a dicdef. Gotchas as a programming term are well known among programmers. Thus, probably notable (we don't have notability guide for technical concepts, though, but the gut feeling says this is important). If the article was expanded to cover more on the usage, then this would be definitely notable. I'll thus remove the notability tags and tag it for expansion instead. --wwwwolf (barks/growls) 14:39, 1 December 2006 (UTC)
thread_title:  Notability 

message: This section is about C programming language but the example code is written in C++.  —Preceding unsigned comment added by 83.21.19.168 (talk) 01:19, 27 September 2007 (UTC)
replies: text: #IF 0 up to #ENDIF should be deleted. It's a syntax error. The "gotcha" in the C function example foo; is a very good gotcha however - it compiles fine and does nothing of value - it puts the address of the function on the stack, whereafter the address is dropped. ... said: Rursus (mbork³) 17:08, 21 November 2009 (UTC)
thread_title:  Gotchas in the C programing language 

message: I don't think this is a gotcha. The example in particular works as expected. A (3..1) Range does not include any element. It's an empty one, since the initial element of the Range is bigger than the final one. Since it's an empty range, iterating over it produces no output, correctly and unsurprisingly.
I think this particular gotcha should be removed.I have removed this gotcha.
: It's still a gotcha because it behaves not the way people expect it to (which would be, iterating backwards: 3,2,1). It may be by design, but it's still a poor design that leads to errors. -- Wesha (talk) 17:58, 9 November 2010 (UTC)
thread_title: Iterating Range

message: Wikipedia is supposed to contain a description of important information relevant to the topic and perhaps a notable example or two simply as illustration.  This article is composed almost entirely of examples.  Wikipedia simply is not an exhaustive list of every possible thing that may potentially be confusing to a majority of people.  I don't think the page should be deleted, but I do think that the entire contents of it should be thrown out and the article re-written.  Anyone have any thoughts? Westphjm (talk) 19:45, 1 May 2012 (UTC)
replies: text: Belatedly, your advice was acted upon. I deleted the whole unreferenced example farm. A reference to a reliable source must attest that the particular case is a notable "gotcha", i.e., a very common source of programmer's mistake. I can name a dozen of these right out of my head. Such as having items  named  aValidNameOfATop and aValidNameOfABot and confuse them by cut and paste. Or name a variable 'tmp' and re-use it in two distant pieces of code, and then next coder modifies the code accidentally removing re-initialization of 'tmp'. Or zillion of other sloppiness a compiler will never catch. Staszek Lem (talk) 17:06, 17 August 2015 (UTC)
thread_title:  Relevance of Examples 

message: This is just the normal word "gotcha" meaning a trap. I don't see why it deserves a special programming-specific page. Equinox ◑ 20:16, 18 November 2023 (UTC)
thread_title:  Not a programming-specific term