12
1
On StackOverflow I often see this:
I’m having a code which (does such and such, followed by a fragment of code)
Is I am having a code grammatically correct? I think it is incorrect, and that it should be, I have some code, but I continue to see it more and more frequently.
Is it grammatically correct, or is it a common error? If it is correct, why?
It is fine to say "I'm having a code" in the sense of "I am having a swim", i.e. enjoying an activity (in this case coding), but the example you give is not that usage and appears wrong. – Francis Davey – 2014-08-27T11:54:01.180
In what context do you hear this? – Squazic – 2013-01-29T22:51:10.220
@Squazic Forms like this appear quite frequently on Stack Overflow.
– ctype.h – 2013-01-29T22:54:29.9401As in, can you give some more context like examples and such? – Squazic – 2013-01-29T23:06:44.230
1Personally I would write "I have this piece (bit) of code" or "I have this code". – Barranka – 2013-01-29T23:34:10.707
3I've taken the liberty of incorporating an SO example into your question - something concrete like this provides context which will avoid confusion. Also, it's conventional in discussion of language to italicize examples being discussed rather than to enclose them in quotes; certainly you don't need both. – StoneyB on hiatus – 2013-01-30T01:11:19.167
This is two questions, though you may not realize it. The first is the proper use of "I am having a NNN", the present progressive of have. The second is which determiner is the correct one to use with the noun code. – Mark Beadles – 2013-01-30T14:47:18.980
@ctype.h Search for the whole phrase; you're right, it is shockingly common.
– Ken Bellows – 2013-01-30T15:24:52.023