Does your editor/ide highlight that a++;
in this C/C++ code as part of a comment?
int a=1;
//some comment \
a++;
printf("%d\n",a);
And what about this?
int a=1;
//some comment ??/
a++;
printf("%d\n",a);
Does your editor/ide highlight that a++;
in this C/C++ code as part of a comment?
int a=1;
//some comment \
a++;
printf("%d\n",a);
And what about this?
int a=1;
//some comment ??/
a++;
printf("%d\n",a);
emacs 22.3.1: No to both, sadly
vim 7.2 sees it as a comment, and gcc 3.4.3 compiles it as a comment.
Slickedit - yes
KDevelop - yes
QT Creator - No
CodeBlocks - No
emacs 22.3.1: No to both, sadly
Kate (3.4) only highlights the first test, fails hilighting the second test
// hello folks \
int a = 0;
// hello folks ??/
int a = 0;
Good question! I was going to ask a question about this until I found this one.
The Visual-DSP++ IDE from Analog Devices does not highlight either comment when writing in assembly or C. For example:
r1 = dm(pPointer1); // Store pointer to r0\
r0 = lshift r1 by -16; // Not highlighted as a comment but DOES NOT EXECUTE.
dm(i0,m1) = r0;
dm(i0,m1) = r1;
XCode and CodeWarrior handle it properly. (But not the trigraph, lol.)
From http://forums.topcoder.com/?module=Thread&threadID=666932
Quick note on which popular editors show this as a comment : vim - yes emacs - no :) kate - no gedit - yes netbeans - yes kwrite - yes
© 2022 - 2024 — McMap. All rights reserved.