Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.c > #111587
| From | T <T@invalid.invalid> |
|---|---|
| Newsgroups | comp.lang.c |
| Subject | Re: what does # mean? |
| Date | 2017-06-05 14:52 -0700 |
| Organization | A noiseless patient Spider |
| Message-ID | <oh4jl0$vqa$1@dont-email.me> (permalink) |
| References | <ogtotj$r7b$1@dont-email.me> <ogvtcl$e1f$1@dont-email.me> <oh001s$k4l$1@dont-email.me> <f638a4c5-bfca-4793-b1cf-d36dd7b2ea53@googlegroups.com> |
On 06/05/2017 12:44 PM, John Bode wrote: > On Saturday, June 3, 2017 at 10:53:59 PM UTC-5, T wrote: >> On 06/03/2017 08:08 PM, James Kuyper wrote: >>> On 06/03/2017 03:39 AM, T wrote: >>>> Hi All, >>>> >>>> I don't understand C. I am trying to find something >>>> in some source code. What does "#" mean as in >>> >>> There is one context in which # has a specific meaning of it's own. This >>> isn't that context. >>> >>>> #include "check_events.h" >>>> >>>> and >>>> >>>> #ifdef HAVE_LIBNOTIFY7 >>>> notification = notify_notification_new(summary, body, >>>> "dialog-warning"); >>>> #else >>>> notification = notify_notification_new(summary, body, >>>> "dialog-warning", NULL); >>>> #endif /* HAVE_LIBNOTIFY7 */ >>> >>> C has something called pre-processing directives. Every single >>> pre-processing directive starts with "#", and every line where the first >>> non-whitespace character is a "#" is a pre-processing directive (that's >>> true because, if # is followed by anything other than one of the >>> standard-defined pre-processing directives, it qualifies as a >>> "non-directive" - and, confusingly enough, a non-directive is considered >>> to be one kind of pre-processing directive. (6.10p1). >>> I'm not the one who chose to name those concepts that way, and I make no >>> attempt to justify choosing those names - I'm just telling you what the >>> standard says. >>> >> >> Thank you! I thought it was a comment. > > For reference, there are two sets of comment delimiters in C. There is the > pair of delimiters /* and */ - anything that appears between them is a > comment: > > /* This is a comment */ > > /** > * So is this > */ > > There's also the single delimiter // - anything between that and the next > newline is a comment: > > // the rest of this line is a comment > > Comments in C do not "nest" - You can't do something like > > /* some text /* some more text */ yet more text */ > > The compiler will consider the first */ it sees to end the comment, and > everything after that will be treated as source code, which will lead > to a compile error. > Thank you!
Back to comp.lang.c | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
what does # mean? T <T@invalid.invalid> - 2017-06-03 00:39 -0700
Re: what does # mean? GOTHIER Nathan <nathan.gothier@gmail.com> - 2017-06-03 10:06 +0200
Re: what does # mean? T <T@invalid.invalid> - 2017-06-03 01:25 -0700
Re: what does # mean? Leon Taylor <leontaylor476@gmail.com> - 2017-06-03 03:41 -0700
Re: what does # mean? Keith Thompson <kst-u@mib.org> - 2017-06-03 09:03 -0700
Re: what does # mean? bartc <bc@freeuk.com> - 2017-06-03 17:11 +0100
Re: what does # mean? T <T@invalid.invalid> - 2017-06-03 13:56 -0700
Re: what does # mean? Jerry Stuckle <jstucklex@attglobal.net> - 2017-06-03 09:24 -0400
Re: what does # mean? T <T@invalid.invalid> - 2017-06-03 13:52 -0700
Re: what does # mean? T <T@invalid.invalid> - 2017-06-03 13:55 -0700
Re: what does # mean? Jerry Stuckle <jstucklex@attglobal.net> - 2017-06-04 18:19 -0400
Re: what does # mean? T <T@invalid.invalid> - 2017-06-05 01:54 -0700
Re: what does # mean? Keith Thompson <kst-u@mib.org> - 2017-06-03 09:05 -0700
Re: what does # mean? gazelle@shell.xmission.com (Kenny McCormack) - 2017-06-03 16:18 +0000
Re: what does # mean? GOTHIER Nathan <nathan.gothier@gmail.com> - 2017-06-03 18:22 +0200
Re: what does # mean? gazelle@shell.xmission.com (Kenny McCormack) - 2017-06-03 16:30 +0000
Re: what does # mean? GOTHIER Nathan <nathan.gothier@gmail.com> - 2017-06-03 19:18 +0200
Re: what does # mean? gazelle@shell.xmission.com (Kenny McCormack) - 2017-06-03 18:03 +0000
Re: what does # mean? T <T@invalid.invalid> - 2017-06-03 13:59 -0700
Re: what does # mean? GOTHIER Nathan <nathan.gothier@gmail.com> - 2017-06-03 23:30 +0200
Re: what does # mean? T <T@invalid.invalid> - 2017-06-03 14:35 -0700
Re: what does # mean? GOTHIER Nathan <nathan.gothier@gmail.com> - 2017-06-03 23:55 +0200
Re: what does # mean? T <T@invalid.invalid> - 2017-06-03 15:30 -0700
Re: what does # mean? GOTHIER Nathan <nathan.gothier@gmail.com> - 2017-06-04 00:36 +0200
Re: what does # mean? T <T@invalid.invalid> - 2017-06-03 16:12 -0700
Re: what does # mean? Ian Collins <ian-news@hotmail.com> - 2017-06-04 11:17 +1200
Re: what does # mean? GOTHIER Nathan <nathan.gothier@gmail.com> - 2017-06-04 01:23 +0200
Re: what does # mean? Keith Thompson <kst-u@mib.org> - 2017-06-03 19:15 -0700
Re: what does # mean? T <T@invalid.invalid> - 2017-06-03 19:27 -0700
Re: what does # mean? Manfred <noname@invalid.add> - 2017-06-04 19:09 +0200
Re: what does # mean? T <T@invalid.invalid> - 2017-06-05 01:56 -0700
Re: what does # mean? Keith Thompson <kst-u@mib.org> - 2017-06-04 13:51 -0700
Re: what does # mean? T <T@invalid.invalid> - 2017-06-05 01:57 -0700
Re: what does # mean? James Kuyper <jameskuyper@verizon.net> - 2017-06-03 23:08 -0400
Re: what does # mean? T <T@invalid.invalid> - 2017-06-03 20:53 -0700
Re: what does # mean? John Bode <jfbode1029@gmail.com> - 2017-06-05 12:44 -0700
Re: what does # mean? T <T@invalid.invalid> - 2017-06-05 14:52 -0700
Re: what does # mean? T <T@invalid.invalid> - 2017-06-05 03:00 -0700
csiph-web