Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
| From | Ben Bacarisse <ben.usenet@bsb.me.uk> |
|---|---|
| Newsgroups | comp.std.c |
| Subject | Re: Adjacent string literals |
| Date | 2021-01-27 15:46 +0000 |
| Organization | A noiseless patient Spider |
| Message-ID | <87ft2mtmae.fsf@bsb.me.uk> (permalink) |
| References | (2 earlier) <rup90c$m3d$1@dont-email.me> <875z3jv0bg.fsf@bsb.me.uk> <ruq8il$g95$1@dont-email.me> <87lfcftc18.fsf@bsb.me.uk> <ruqnqh$7ie$1@dont-email.me> |
James Kuyper <jameskuyper@alumni.caltech.edu> writes: > On 1/26/21 8:16 PM, Ben Bacarisse wrote: >> James Kuyper <jameskuyper@alumni.caltech.edu> writes: > ... >>> Yes, it is. In "a""b", the two tokens are adjacent. In "a" "b", they are >>> not, because both are adjacent to some white-space instead. >> >> Adjacent does not mean with nothing in between (thought it can, of >> course). What's more, things can be adjacent to each other, and also >> adjacent to something in between. I can say that there was a fire in >> the house adjacent to mine. The two house are adjacent. But both are >> adjacent to the lane separating them. > > It takes at least two dimensions for the issue you raise to come up. I don't follow. 1 and 2 are adjacent integers on the real line (i.e. despite having other kinds of number between them). In addition, they are both integers adjacent to 1/2. > As > far as the C standard is concerned, source code is a one-dimensional > sequence of characters. It's possible to think of the text > two-dimensionally, but the standard doesn't make use of that fact in any > way that I'm aware of. I don't think anyone would suggest that two > string literals that are vertically adjacent to each other: > > char first = "James"; > char second = "Kuyper"; > > should be merged. > Even if you acknowledge only that this is one possible way of > interpreting "adjacent", that would mean the meaning is ambiguous. Lots of words in the standard could, at a pinch, be taken to mean something other than what is obviously intended. But if you think someone might read about phase 6 and think that "a""b" will be concatenated but not "a" "b", then you should file a defect report. > Moving the first sentence of translation phase 7 to be the first > sentence of translation phase 6 would remove all ambiguity, and have, as > far as I can see, no other consequence. I think the strongest case for the possibility of misunderstanding comes from this sentence being where it is. I don't see any problem with the word "adjacent", but I can imagine someone wondering why this sentence is where it is if not to do what you are suggesting. -- Ben.
Back to comp.std.c | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
Adjacent string literals James Kuyper <jameskuyper@alumni.caltech.edu> - 2021-01-25 10:15 -0500
Re: Adjacent string literals Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-01-26 12:22 +0000
Re: Adjacent string literals Jakob Bohm <jb-usenet@wisemo.com.invalid> - 2021-01-26 13:48 +0100
Re: Adjacent string literals Keith Thompson <Keith.S.Thompson+u@gmail.com> - 2021-01-26 13:05 -0800
Re: Adjacent string literals Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-01-26 21:40 +0000
Re: Adjacent string literals Jakob Bohm <jb-usenet@wisemo.com.invalid> - 2021-01-28 09:53 +0100
Re: Adjacent string literals James Kuyper <jameskuyper@alumni.caltech.edu> - 2021-01-28 05:45 -0500
Re: Adjacent string literals Richard Damon <Richard@Damon-Family.org> - 2021-01-26 07:52 -0500
Re: Adjacent string literals James Kuyper <jameskuyper@alumni.caltech.edu> - 2021-01-26 09:29 -0500
Re: Adjacent string literals Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-01-26 21:46 +0000
Re: Adjacent string literals James Kuyper <jameskuyper@alumni.caltech.edu> - 2021-01-26 18:28 -0500
Re: Adjacent string literals Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-01-27 01:16 +0000
Re: Adjacent string literals James Kuyper <jameskuyper@alumni.caltech.edu> - 2021-01-26 22:48 -0500
Re: Adjacent string literals Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-01-27 15:46 +0000
Re: Adjacent string literals James Kuyper <jameskuyper@alumni.caltech.edu> - 2021-01-27 11:20 -0500
Re: Adjacent string literals Ben Bacarisse <ben.usenet@bsb.me.uk> - 2021-01-28 03:05 +0000
Re: Adjacent string literals Tim Rentsch <tr.17687@z991.linuxsc.com> - 2021-07-10 08:49 -0700
Re: Adjacent string literals Keith Thompson <Keith.S.Thompson+u@gmail.com> - 2021-07-10 14:58 -0700
Re: Adjacent string literals Tim Rentsch <tr.17687@z991.linuxsc.com> - 2021-07-22 10:29 -0700
Re: Adjacent string literals James Kuyper <jameskuyper@alumni.caltech.edu> - 2021-07-11 11:41 -0700
Re: Adjacent string literals Tim Rentsch <tr.17687@z991.linuxsc.com> - 2021-07-22 15:26 -0700
Re: Adjacent string literals James Kuyper <jameskuyper@alumni.caltech.edu> - 2021-07-22 17:29 -0700
Re: Adjacent string literals Tim Rentsch <tr.17687@z991.linuxsc.com> - 2022-01-17 05:29 -0800
csiph-web