Reply To: Project "lines of code" counter

Product Compare Forums Multi-Edit Support Project "lines of code" counter Reply To: Project "lines of code" counter

#3246
mayfield42
Participant

Ballpark line count would even be good for me.

You’re right though that most languages offer a “multiple statement” separator… “:” in VB, “;” in most others… you can complicate that further with line structures like ” for (i;i++;i<10) ” which use the C line separator in a non-line-separator role.

IF I were to argue the symantic side :) I’d say that’s more of a statement separator character anyway, rather than a line separator and therefore “a=b;c=d;” should still be counted as one line :) But then you’d throw something like this back at me:

if (a == b)
foo();

and ask if that’s one line or two. :)

Ok, so I opened a pandora’s box of possible exceptions here, but I can’t be the FIRST person to ask on this topic, can I? Surely someone’s already written a semi-workable macro?

Scott