Rocksolid Light

Welcome to novaBBS (click a section below)

mail  files  register  newsreader  groups  login

Message-ID:  

If Bill Gates is the Devil then Linus Torvalds must be the Messiah. -- Unknown source


devel / comp.lang.c / Implicit String-Literal Concatenation

SubjectAuthor
* Implicit String-Literal ConcatenationLawrence D'Oliveiro
+* Re: Implicit String-Literal ConcatenationJanis Papanagnou
|`* Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
| `- Re: Implicit String-Literal Concatenationbart
+- Re: Implicit String-Literal ConcatenationBlue-Maned_Hawk
+- Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
+* Re: Implicit String-Literal ConcatenationŁukasz 'Maly' Ostrowski
|`* Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
| `* Re: Implicit String-Literal ConcatenationJanis Papanagnou
|  `* Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
|   `- Re: Implicit String-Literal ConcatenationJanis Papanagnou
+- Re: Implicit String-Literal ConcatenationKaz Kylheku
`* Re: Implicit String-Literal ConcatenationMike Sanders
 +* Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
 |`- Re: Implicit String-Literal ConcatenationMike Sanders
 `* Re: Implicit String-Literal ConcatenationDavid Brown
  +- Re: Implicit String-Literal ConcatenationMike Sanders
  +* Re: Implicit String-Literal Concatenationbart
  |`* Re: Implicit String-Literal ConcatenationDavid Brown
  | `* Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
  |  `* Re: Implicit String-Literal ConcatenationKaz Kylheku
  |   `* Re: Implicit String-Literal ConcatenationDavid Brown
  |    `* Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
  |     +* Re: Implicit String-Literal Concatenationbart
  |     |`* Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
  |     | `* Re: Implicit String-Literal Concatenationbart
  |     |  +* Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
  |     |  |`- Re: Implicit String-Literal Concatenationbart
  |     |  `* Re: Implicit String-Literal ConcatenationScott Lurndal
  |     |   `* Re: Implicit String-Literal ConcatenationJanis Papanagnou
  |     |    `* Re: Implicit String-Literal ConcatenationScott Lurndal
  |     |     +* Re: Implicit String-Literal ConcatenationJanis Papanagnou
  |     |     |`* Re: Implicit String-Literal ConcatenationScott Lurndal
  |     |     | `* Re: Implicit String-Literal ConcatenationKeith Thompson
  |     |     |  `* Re: Implicit String-Literal Concatenationbart
  |     |     |   `* Re: Implicit String-Literal ConcatenationKeith Thompson
  |     |     |    `* Re: Implicit String-Literal ConcatenationJanis Papanagnou
  |     |     |     `* Re: Implicit String-Literal ConcatenationKeith Thompson
  |     |     |      `- Re: Implicit String-Literal ConcatenationJanis Papanagnou
  |     |     `- Re: Implicit String-Literal ConcatenationKeith Thompson
  |     `* Re: Implicit String-Literal ConcatenationDavid Brown
  |      `* Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
  |       `* Re: Implicit String-Literal ConcatenationDavid Brown
  |        `* Re: Implicit String-Literal ConcatenationKaz Kylheku
  |         `- Re: Implicit String-Literal ConcatenationDavid Brown
  `* Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
   +* Re: Implicit String-Literal ConcatenationKeith Thompson
   |`- Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
   `* Re: Implicit String-Literal Concatenationbart
    `* Re: Implicit String-Literal ConcatenationDavid Brown
     +* Re: Implicit String-Literal Concatenationbart
     |+- Re: Implicit String-Literal ConcatenationDavid Brown
     |+* Re: Implicit String-Literal ConcatenationKeith Thompson
     ||+* Re: Implicit String-Literal ConcatenationMalcolm McLean
     |||+* Re: Implicit String-Literal ConcatenationDavid Brown
     ||||`* Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
     |||| +- Re: Implicit String-Literal ConcatenationKeith Thompson
     |||| `* Re: Implicit String-Literal ConcatenationRichard Harnden
     ||||  `- Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
     |||`- Re: Implicit String-Literal ConcatenationKeith Thompson
     ||`* Re: Implicit String-Literal Concatenationbart
     || +* Re: Implicit String-Literal ConcatenationRichard Harnden
     || |`* Re: Implicit String-Literal ConcatenationChris M. Thomasson
     || | `* Re: Implicit String-Literal ConcatenationKeith Thompson
     || |  `* Re: Implicit String-Literal ConcatenationChris M. Thomasson
     || |   `* Re: Implicit String-Literal ConcatenationKeith Thompson
     || |    +- Re: Implicit String-Literal ConcatenationChris M. Thomasson
     || |    `* Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
     || |     `* Re: Implicit String-Literal ConcatenationKeith Thompson
     || |      `* Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
     || |       +* Re: Implicit String-Literal ConcatenationKaz Kylheku
     || |       |`* Re: Implicit String-Literal ConcatenationKeith Thompson
     || |       | +* Re: Implicit String-Literal ConcatenationKaz Kylheku
     || |       | |`- Re: Implicit String-Literal ConcatenationKeith Thompson
     || |       | +- Re: Implicit String-Literal ConcatenationChris M. Thomasson
     || |       | `- Re: Implicit String-Literal ConcatenationRichard Harnden
     || |       `- Re: Implicit String-Literal ConcatenationKeith Thompson
     || +* Re: Implicit String-Literal ConcatenationDavid Brown
     || |`- Re: Implicit String-Literal ConcatenationKeith Thompson
     || `* Re: Implicit String-Literal ConcatenationKeith Thompson
     ||  `* Re: Implicit String-Literal ConcatenationJanis Papanagnou
     ||   `* Re: Implicit String-Literal ConcatenationKeith Thompson
     ||    `* Re: Implicit String-Literal ConcatenationKaz Kylheku
     ||     `- Re: Implicit String-Literal ConcatenationJames Kuyper
     |`- Re: Implicit String-Literal ConcatenationKeith Thompson
     `* Re: Implicit String-Literal ConcatenationKeith Thompson
      +* Re: Implicit String-Literal Concatenationbart
      |`* Re: Implicit String-Literal ConcatenationKeith Thompson
      | `* Re: Implicit String-Literal Concatenationbart
      |  +- Re: Implicit String-Literal ConcatenationKeith Thompson
      |  +* Re: Implicit String-Literal ConcatenationtTh
      |  |`- Re: Implicit String-Literal ConcatenationScott Lurndal
      |  `* Re: Implicit String-Literal ConcatenationScott Lurndal
      |   `* Re: Implicit String-Literal ConcatenationKeith Thompson
      |    `* Re: Implicit String-Literal ConcatenationScott Lurndal
      |     `* Re: Implicit String-Literal ConcatenationDavid Brown
      |      `* Re: Implicit String-Literal ConcatenationScott Lurndal
      |       +* Re: Implicit String-Literal ConcatenationScott Lurndal
      |       |`* Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
      |       | `* Re: Implicit String-Literal Concatenationbart
      |       |  `* Re: Implicit String-Literal ConcatenationLawrence D'Oliveiro
      |       `- Re: Implicit String-Literal ConcatenationDavid Brown
      `* Re: Implicit String-Literal ConcatenationDavid Brown

Pages:12345
Implicit String-Literal Concatenation

<urdsob$1e8e4$7@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33745&group=comp.lang.c#33745

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo...@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c
Subject: Implicit String-Literal Concatenation
Date: Sat, 24 Feb 2024 23:05:47 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 16
Message-ID: <urdsob$1e8e4$7@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sat, 24 Feb 2024 23:05:47 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="5d3a24d1dc8cf78704609d9d7dcc21b3";
logging-data="1515972"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+3Z4mI3jqKo/SUFInDCnYG"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:gcPCbJ14X5KmLMu6dkDbIYnrqRE=
 by: Lawrence D'Oliv - Sat, 24 Feb 2024 23:05 UTC

I like using this for long strings:

fputs
(
"When an uncleft or a bulkbit wins one or more bernstonebits above\n"
"its own, it takes on a backward lading. When it loses one or\n"
"more, it takes on a forward lading. Such a mote is called a\n"
"*farer*, for that the drag between unlike ladings flits it. When\n"
"bernstonebits flit by themselves, it may be as a bolt of\n"
"lightning, a spark off some faststanding chunk, or the everyday\n"
"flow of bernstoneness through wires.\n",
stdout
);

Of languages that derive ideas from C, only C++ and Python seem to have
kept this. Java, JavaScript and PHP have not, for some reason.

Re: Implicit String-Literal Concatenation

<urfqef$1us0r$1@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33767&group=comp.lang.c#33767

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: janis_pa...@hotmail.com (Janis Papanagnou)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Sun, 25 Feb 2024 17:38:38 +0100
Organization: A noiseless patient Spider
Lines: 38
Message-ID: <urfqef$1us0r$1@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 7bit
Injection-Date: Sun, 25 Feb 2024 16:38:39 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="031f19860a42341c067d9633fc2fc264";
logging-data="2060315"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19bQAZMD7WrKqnEnqZ7Tyoh"
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101
Thunderbird/45.8.0
Cancel-Lock: sha1:IPZeNOIo6IAwI9DlrZc1gnivGpg=
In-Reply-To: <urdsob$1e8e4$7@dont-email.me>
X-Enigmail-Draft-Status: N1110
 by: Janis Papanagnou - Sun, 25 Feb 2024 16:38 UTC

On 25.02.2024 00:05, Lawrence D'Oliveiro wrote:
> I like using this for long strings:
>
> fputs
> (
> "When an uncleft or a bulkbit wins one or more bernstonebits above\n"
> "its own, it takes on a backward lading. When it loses one or\n"
> "more, it takes on a forward lading. Such a mote is called a\n"
> "*farer*, for that the drag between unlike ladings flits it. When\n"
> "bernstonebits flit by themselves, it may be as a bolt of\n"
> "lightning, a spark off some faststanding chunk, or the everyday\n"
> "flow of bernstoneness through wires.\n",
> stdout
> );

I also liked to be able to use this feature _in some cases_ in C++.

Not in the given case, though, where I like to more clearly see the
newlines, so I'd prefer cout << "..." << endl

>
> Of languages that derive ideas from C, only C++ and Python seem to have
> kept this. Java, JavaScript and PHP have not, for some reason.

In Java you have at least the string concatenation operator + which
is, IMO, pretty good for that line structuring across source lines.

In Awk (another "C like"), string concatenations have no visible
operators so we can for example write print "Hell" "o " "world"
But since lines have a much more restricted definition you cannot
without line continuation escape spread these strings across many
lines. (It's not too bad to add a terminating '\' where desired.)

As far as you're asking "for some reason", I could just speculate
(and abstain).

Janis

Re: Implicit String-Literal Concatenation

<pan$e03fe$425473e6$292cfbdb$faf6f045@invalid.invalid>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33768&group=comp.lang.c#33768

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!bluemanedhawk.eternal-september.org!.POSTED!not-for-mail
From: bluemane...@invalid.invalid (Blue-Maned_Hawk)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Sun, 25 Feb 2024 16:45:20 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 13
Message-ID: <pan$e03fe$425473e6$292cfbdb$faf6f045@invalid.invalid>
References: <urdsob$1e8e4$7@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sun, 25 Feb 2024 16:45:20 -0000 (UTC)
Injection-Info: bluemanedhawk.eternal-september.org; posting-host="26fdfc6798e7cb9c19f0283243d49f30";
logging-data="2059601"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19CUStJE41P4MJ4avLuTi/CO1JQd2JRuro="
User-Agent: Pan/0.154 (Izium; 517acf4)
Cancel-Lock: sha1:VHOTdhU1iFgsdei6fjdpHvA4ZhM=
X-Face: Llanfair­pwllgwyng
yll
­gogeryÂÃ
? ?­chwyrnÂÂÂÂÂÂ
­drobwll­llanÃ
‚Ã
ƒƒƒ‚­tysilioÂÂÂÃ
‚­gogo­goch
Face: iVBORw0KGgoAAAANSUhEUgAAADAAAAAwCAIAAADYYG7QAAACh0lEQVRYw71Z21bD
MAzzevbfkr4cHjrSXJyL044+MDa6WLEl2SkvkrZ1AbAvXO+bUGSCPYnsuIVGMpm
ZLnjX718GhAKNsp8lON2F9VrhELwIgJlBepkZjA78rVK+FkmNhEJK76UsJlz8+E
rJsjrpYouhLo/SC6qPHgakFOR8wV9+8rCfO/I/oVnmUZUp42/LW2XkLj9TCFNM9
jp5g2EmHZgpYZjCOkYU7sXVogRylJqpdggoFLG1g09Flah/7kErCxzR9HgXPYsq
0glb9cxjIz2Vsk9AmAoCSxECpD713joMKjQqLAtmMqJmXjdVvlMnMQCVITotJd1
z+fh1f1NNo+vuc1KnhWUmY7t03vydTud9BbXCtN3L2PL3bK7JCNG0GHzuZxafyB
fxevCxpm1vrwZltqw6SILCcdoCE6PGQC8wZWDA9Or7Qp5s3lAZezys0nDazs9S9
R0TjwEiksRxLkNPC1NMMWPs1bj0Ei0Yuo+JVtFLuzP1NRJ16qXWN8DhhtmS4PDg
O6mqRxs4bEJrYt087mSIow/1VzW2oFlMQuiuIy/KsUagvhdw6hSjJGlIavbLF8x
j3X47bccLcUSi0dkWh1nUZNhANT1tHKUXrNxNLbd9KPb9wDDVrKwmPQMOPQ1oy6
k5I1DwzDeRJd3jVIhDAUxq3ngzJG4CCkNXZxZVMcjefoK2J0gUY2S3rxz/RuTFx
2zHd9U+obimJXMG4edsk/2j5pTU5G1MmzbRLxkfq5EiT1GGsidvMGzi+1goGb2l
GCrN+nGnV8xj3q3JLRDVPL96vUc7Z4aJ3TN1mVqWAMJMfG+Jxh6TQqP+92iZkCU
xtglds1AB6r0aiSHKcnFck+p/c/0CbacFLQcajGcAAAAASUVORK5CYII=
 by: Blue-Maned_Hawk - Sun, 25 Feb 2024 16:45 UTC

I've used this to make strings with embedded newlines look in the source
file closer to how they'd look on output.

--
Blue-Maned_Hawk│shortens to
Hawk│/
blu.mɛin.dÊ°ak/
│he/him/his/himself/Mr.
blue-maned_hawk.srht.site
2017 called, but i couldn't understand what they were saying over all the
screams.

Re: Implicit String-Literal Concatenation

<urg7n4$21p1q$4@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33774&group=comp.lang.c#33774

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo...@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Sun, 25 Feb 2024 20:25:09 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 7
Message-ID: <urg7n4$21p1q$4@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sun, 25 Feb 2024 20:25:09 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="5d3a24d1dc8cf78704609d9d7dcc21b3";
logging-data="2155578"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/0DgPI9uTtfJN8Ex2DXaVY"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:4LLK4+2CRl8soEdRe1yQSeZe8/Y=
 by: Lawrence D'Oliv - Sun, 25 Feb 2024 20:25 UTC

On Sat, 24 Feb 2024 23:05:47 -0000 (UTC), Lawrence D'Oliveiro wrote:

> Of languages that derive ideas from C, only C++ and Python seem to have
> kept this. Java, JavaScript and PHP have not, for some reason.

I’d forgotten to check Perl; it doesn’t have implicit concatenation
either.

Re: Implicit String-Literal Concatenation

<urg8pj$21p1q$5@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33775&group=comp.lang.c#33775

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo...@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Sun, 25 Feb 2024 20:43:31 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 55
Message-ID: <urg8pj$21p1q$5@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me> <urfqef$1us0r$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Sun, 25 Feb 2024 20:43:31 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="5d3a24d1dc8cf78704609d9d7dcc21b3";
logging-data="2155578"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/agsM93M0IqkRVFA+lVYDu"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:UoewDNwC5Po1U/5gTetpRqCQTLM=
 by: Lawrence D'Oliv - Sun, 25 Feb 2024 20:43 UTC

On Sun, 25 Feb 2024 17:38:38 +0100, Janis Papanagnou wrote:

> In Java you have at least the string concatenation operator + which is,
> IMO, pretty good for that line structuring across source lines.

Implicit concatenation works well in Python because you also have the
“%” operator overloaded to perform printf-style formatting with a
string. If you had to use “+” then, because that binds less tightly
than “%”, you would have to have parentheses as well, which are
unnecessary with implicit concatenation. E.g.

# depreciation entries
sql.cursor.execute \
(
"insert into payments set when_made = %(when_made)s,"
" description = %(description)s, other_party_name = \"\","
" amount = %(amount)d, kind = \"D\", tax_year = %(tax_year)d"
%
{
"when_made" : end_for_tax_year(tax_year) - 1,
"description" :
sql_string
(
"%s: %s $%s at %d%% from %s"
%
(
entry["description"],
entry["method"],
format_amount(entry["initial_value"]),
entry["rate"],
format_date(entry["when_purchased"]),
)
),
"amount" : - entry["amount"],
"tax_year" : tax_year,
}
)

Or, for added fun, how about parameterizing a format:

num_format = "%%.%dg" % nr_digits
...
for axis in range(3) :
out.write \
(
" (%s, %s),\n"
%
(num_format, num_format)
%
(
min(v.co[axis] for v in the_mesh.vertices),
max(v.co[axis] for v in the_mesh.vertices)
)
)
#end for

Re: Implicit String-Literal Concatenation

<urgaud$22qdb$1@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33776&group=comp.lang.c#33776

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: bc...@freeuk.com (bart)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Sun, 25 Feb 2024 21:20:13 +0000
Organization: A noiseless patient Spider
Lines: 72
Message-ID: <urgaud$22qdb$1@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me> <urfqef$1us0r$1@dont-email.me>
<urg8pj$21p1q$5@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Date: Sun, 25 Feb 2024 21:20:13 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="d7962911a7e10b6c027d60cd269aa08c";
logging-data="2189739"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19FibqSIRX+PTXHhb7QrPgtafBGEn1Kg8s="
User-Agent: Mozilla Thunderbird
Cancel-Lock: sha1:Ez7OhLdXxvdzR2t5Yoh+uQACuto=
Content-Language: en-GB
In-Reply-To: <urg8pj$21p1q$5@dont-email.me>
 by: bart - Sun, 25 Feb 2024 21:20 UTC

On 25/02/2024 20:43, Lawrence D'Oliveiro wrote:
> On Sun, 25 Feb 2024 17:38:38 +0100, Janis Papanagnou wrote:
>
>> In Java you have at least the string concatenation operator + which is,
>> IMO, pretty good for that line structuring across source lines.
>
> Implicit concatenation works well in Python because you also have the
> “%” operator overloaded to perform printf-style formatting with a
> string. If you had to use “+” then, because that binds less tightly
> than “%”,

You mean it binds less tightly than implicit concatenation? So that:

"abc" % "def" "ghi" means "abc" % ("def" "ghi")
"abc" % "def" + "ghi" means ("abc" % "def") "ghi"

> you would have to have parentheses as well, which are
> unnecessary with implicit concatenation. E.g.
>
> # depreciation entries
> sql.cursor.execute \
> (
> "insert into payments set when_made = %(when_made)s,"
> " description = %(description)s, other_party_name = \"\","
> " amount = %(amount)d, kind = \"D\", tax_year = %(tax_year)d"
> %
> {
> "when_made" : end_for_tax_year(tax_year) - 1,
> "description" :
> sql_string
> (
> "%s: %s $%s at %d%% from %s"
> %
> (
> entry["description"],
> entry["method"],
> format_amount(entry["initial_value"]),
> entry["rate"],
> format_date(entry["when_purchased"]),
> )
> ),
> "amount" : - entry["amount"],
> "tax_year" : tax_year,
> }
> )
>
> Or, for added fun, how about parameterizing a format:
>
> num_format = "%%.%dg" % nr_digits
> ...
> for axis in range(3) :
> out.write \
> (
> " (%s, %s),\n"
> %
> (num_format, num_format)
> %
> (
> min(v.co[axis] for v in the_mesh.vertices),
> max(v.co[axis] for v in the_mesh.vertices)
> )
> )
> #end for

Although I can't see it made much difference here. Is this an example of
how bad it can be without implicit concatenation, or is it this
complicated despite that?

Since I can't see any "+" operators between strings, yet what follows
"%" is usually something starting with "(" or "{", not a string constant.

Re: Implicit String-Literal Concatenation

<1qf797ippluag.1p27j2yyk4ydt.dlg@40tude.net>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33819&group=comp.lang.c#33819

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: l3vi4t...@gmail.com (Łukasz 'Maly' Ostrowski)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Mon, 26 Feb 2024 21:12:39 +0100
Organization: Acme
Lines: 22
Message-ID: <1qf797ippluag.1p27j2yyk4ydt.dlg@40tude.net>
References: <urdsob$1e8e4$7@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset="iso-8859-2"
Content-Transfer-Encoding: 8bit
Injection-Info: dont-email.me; posting-host="6c315f149b0857105308252d39a38acd";
logging-data="2875362"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+N1yjkB9lJtUSjbVq5gVv5dI9H28HTEcQ="
User-Agent: 40tude_Dialog/2.0.15.84
Cancel-Lock: sha1:DcHtQqpcJB6lNWo3aXMF+/L7iVY=
 by: Łukasz 'Maly&# - Mon, 26 Feb 2024 20:12 UTC

On Sat, 24 Feb 2024 23:05:47 -0000 (UTC), Lawrence D'Oliveiro wrote:
> Of languages that derive ideas from C, only C++ and Python seem to have
> kept this. Java, JavaScript and PHP have not, for some reason.
Java (Text Blocks):
String s = """
multi
line
string""";

JavaScript (Template Literal):
let s = `multi
line
string`;

Still more convenient than C.

PHP? Don't care about PHP, it's shit, not even checking, most likely
some kind of a Perl-ish <<<EOF expression.

--
Kindest regards,
Łukasz 'Mały' Ostrowski.

Re: Implicit String-Literal Concatenation

<urisel$2nq9h$2@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33820&group=comp.lang.c#33820

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo...@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Mon, 26 Feb 2024 20:31:18 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 34
Message-ID: <urisel$2nq9h$2@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me>
<1qf797ippluag.1p27j2yyk4ydt.dlg@40tude.net>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Mon, 26 Feb 2024 20:31:18 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="ea15bd06c2061660f1136ed37eb9a688";
logging-data="2877745"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/3pxug/XW9wJXdxYvu4tGR"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:QewYkjHcqzS92/cFmxxjv1smN+Y=
 by: Lawrence D'Oliv - Mon, 26 Feb 2024 20:31 UTC

On Mon, 26 Feb 2024 21:12:39 +0100, Łukasz 'Maly' Ostrowski wrote:

> Java (Text Blocks):
> String s = """
> multi line string""";

Python has those, too. I use them sometimes. Generally I’m not fond of
them, because I think they’re wrongly defined.

> JavaScript (Template Literal):
> let s = `multi line string`;

I think Python has something like that now, too. F-strings?

> Still more convenient than C.

I still like having the choice of implicit concatenation, because then I
fully control what appears in the string.

Tip: I have Emacs macros defined to strip and add the quoting/escaping,
because I find the strings are easier to edit without that.

> PHP? Don't care about PHP, it's shit, not even checking, most likely
> some kind of a Perl-ish <<<EOF expression.

PHP is shit, not because of what it copied from Perl, but from what it
didn’t copy. Nowadays it is trying to copy from Python, and it is making
the same mistake.

The <<EOD construct that Perl has comes from POSIX shells, and it is very
useful in both places. Bash also adds a <<<-construct.

Question: How would you do two separate <<-strings in the same shell
command?

Re: Implicit String-Literal Concatenation

<20240226123520.857@kylheku.com>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33821&group=comp.lang.c#33821

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!news.samoylyk.net!hugayda.aid.in.ua!weretis.net!feeder8.news.weretis.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: 433-929-...@kylheku.com (Kaz Kylheku)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Mon, 26 Feb 2024 20:42:42 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 71
Message-ID: <20240226123520.857@kylheku.com>
References: <urdsob$1e8e4$7@dont-email.me>
Injection-Date: Mon, 26 Feb 2024 20:42:42 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="ac83573ee9d84690d9e3a2bd886df82b";
logging-data="2884358"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX184TebpE1m5mkbIG6cw0B3uBLrVZUB0wYA="
User-Agent: slrn/pre1.0.4-9 (Linux)
Cancel-Lock: sha1:SCDuGk1XihfGxM/X/TnDcdWkV4Q=
 by: Kaz Kylheku - Mon, 26 Feb 2024 20:42 UTC

On 2024-02-24, Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
> I like using this for long strings:
>
> fputs
> (
> "When an uncleft or a bulkbit wins one or more bernstonebits above\n"
> "its own, it takes on a backward lading. When it loses one or\n"
> "more, it takes on a forward lading. Such a mote is called a\n"
> "*farer*, for that the drag between unlike ladings flits it. When\n"
> "bernstonebits flit by themselves, it may be as a bolt of\n"
> "lightning, a spark off some faststanding chunk, or the everyday\n"
> "flow of bernstoneness through wires.\n",
> stdout
> );
>
> Of languages that derive ideas from C, only C++ and Python seem to have
> kept this. Java, JavaScript and PHP have not, for some reason.

Implicit string catenation means you need punctuation to separate
elements that are not catenated.

It's a nonstarter in Lisp where you want

("ab" "cd" "ef")

to have three elements, not one. So if it worked that way, we would
need

("ab", "cd", "ef")

which is too horrible a price to pay for string literal catenation.

ANSI Lisp just allows line breaks in strings. However, all the white
space is combined into it.

Allow line breaks in string literals means that if you forget to
close a quote, it might not be diagnosed until the end of file!
The strictness of having to close a string in the same line is
worthwhile for diagnosis.

In TXR Lisp, I solved multiple problems with a backslash continuation.

"abc \
def"

encodes the string "abcdef". All unescaped whitespace around the
backslash is deleted. If you want "abc def", you can plant an escaped
space in there:

"abc \ \
def"

or

"abc \
\ def"

Unfortunately, it does mean we have the run of backslashes down the
right side:

"abc \
def \
ghi \
... "

I can live with that.

--
TXR Programming Language: http://nongnu.org/txr
Cygnal: Cygwin Native Application Library: http://kylheku.com/cygnal
Mastodon: @Kazinator@mstdn.ca

Re: Implicit String-Literal Concatenation

<urj1qv$2p32o$1@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33831&group=comp.lang.c#33831

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: porkc...@invalid.foo (Mike Sanders)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Mon, 26 Feb 2024 22:03:11 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 36
Sender: Mike Sanders <busybox@sdf.org>
Message-ID: <urj1qv$2p32o$1@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me>
Injection-Date: Mon, 26 Feb 2024 22:03:11 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="9fa50c57887cea1a70066dff5b6f6ab0";
logging-data="2919512"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX186KvFA1N7SpJxfry1BSMhC"
User-Agent: tin/2.6.2-20221225 ("Pittyvaich") (NetBSD/9.3 (amd64))
Cancel-Lock: sha1:0X8fugwYdCYTo5pXMq72CErEI8I=
 by: Mike Sanders - Mon, 26 Feb 2024 22:03 UTC

Lawrence D'Oliveiro <ldo@nz.invalid> wrote:

> I like using this for long strings:
>
> fputs
> (
> "When an uncleft or a bulkbit wins one or more bernstonebits above\n"
> "its own, it takes on a backward lading. When it loses one or\n"
> "more, it takes on a forward lading. Such a mote is called a\n"
> "*farer*, for that the drag between unlike ladings flits it. When\n"
> "bernstonebits flit by themselves, it may be as a bolt of\n"
> "lightning, a spark off some faststanding chunk, or the everyday\n"
> "flow of bernstoneness through wires.\n",
> stdout
> );
>
> Of languages that derive ideas from C, only C++ and Python seem to have
> kept this. Java, JavaScript and PHP have not, for some reason.

Easy solution Lawrence. Why not use something like bin2c:

<https://www.segger.com/free-utilities/bin2c/>

void Usage() {

#include "my_text"

printf("%s\n", my_var);

}

--
:wq
Mike Sanders

Re: Implicit String-Literal Concatenation

<urj66g$2puef$4@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33835&group=comp.lang.c#33835

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo...@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Mon, 26 Feb 2024 23:17:36 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 6
Message-ID: <urj66g$2puef$4@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me> <urj1qv$2p32o$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Mon, 26 Feb 2024 23:17:36 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="d339ad4b21c64d41c58c7c072f1b4d54";
logging-data="2947535"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX19wHIR9BHiOec+0p+PhFQ92"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:3wXLwKBGkyqdEQPgzxdNqyj2IOg=
 by: Lawrence D'Oliv - Mon, 26 Feb 2024 23:17 UTC

On Mon, 26 Feb 2024 22:03:11 -0000 (UTC), Mike Sanders wrote:

> Easy solution Lawrence. Why not use something like bin2c:

My tool for easy editing of such embedded text is the Emacs macros in
multiquote.el, here <https://gitlab.com/ldo/emacs-prefs>.

Re: Implicit String-Literal Concatenation

<urk6um$33nqv$1@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33847&group=comp.lang.c#33847

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: david.br...@hesbynett.no (David Brown)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Tue, 27 Feb 2024 09:36:38 +0100
Organization: A noiseless patient Spider
Lines: 36
Message-ID: <urk6um$33nqv$1@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me> <urj1qv$2p32o$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Tue, 27 Feb 2024 08:36:38 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="5b013b32b0ae31855296b19afd591ff2";
logging-data="3268447"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18alhaVnR9kyDgHWrD06I+cPp2DLOjni5o="
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101
Thunderbird/102.11.0
Cancel-Lock: sha1:EhBviTciMlFpv09FpsyvFqOqWhQ=
In-Reply-To: <urj1qv$2p32o$1@dont-email.me>
Content-Language: en-GB
 by: David Brown - Tue, 27 Feb 2024 08:36 UTC

On 26/02/2024 23:03, Mike Sanders wrote:
> Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
>
>> I like using this for long strings:
>>
>> fputs
>> (
>> "When an uncleft or a bulkbit wins one or more bernstonebits above\n"
>> "its own, it takes on a backward lading. When it loses one or\n"
>> "more, it takes on a forward lading. Such a mote is called a\n"
>> "*farer*, for that the drag between unlike ladings flits it. When\n"
>> "bernstonebits flit by themselves, it may be as a bolt of\n"
>> "lightning, a spark off some faststanding chunk, or the everyday\n"
>> "flow of bernstoneness through wires.\n",
>> stdout
>> );
>>
>> Of languages that derive ideas from C, only C++ and Python seem to have
>> kept this. Java, JavaScript and PHP have not, for some reason.
>
> Easy solution Lawrence. Why not use something like bin2c:
>
> <https://www.segger.com/free-utilities/bin2c/>

Because it generates files that have Segger copyright notices stamped on
them? At least, that's how it appears from that web page.

There are lots of open source alternatives that do similar things, with
different variations in the way they generate the output. Or you can
write your own in about 10 lines of Python, which of course makes it a
lot easier to customise to fit your own styles and requirements.

And with C23, we will get #embed, though it is not yet supported by
major tools.

<https://en.cppreference.com/w/c/preprocessor/embed>

Re: Implicit String-Literal Concatenation

<urkjue$36npm$1@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33860&group=comp.lang.c#33860

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: janis_pa...@hotmail.com (Janis Papanagnou)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Tue, 27 Feb 2024 13:18:20 +0100
Organization: A noiseless patient Spider
Lines: 17
Message-ID: <urkjue$36npm$1@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me>
<1qf797ippluag.1p27j2yyk4ydt.dlg@40tude.net> <urisel$2nq9h$2@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 7bit
Injection-Date: Tue, 27 Feb 2024 12:18:22 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="bd525e439c6b5ce1313397c379b983be";
logging-data="3366710"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+oklL7HnHlVNKk6Gu2+RMn"
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101
Thunderbird/45.8.0
Cancel-Lock: sha1:5zWZRoqegQUOpUmwCa1MmubST3w=
In-Reply-To: <urisel$2nq9h$2@dont-email.me>
 by: Janis Papanagnou - Tue, 27 Feb 2024 12:18 UTC

On 26.02.2024 21:31, Lawrence D'Oliveiro wrote:
>
> The <<EOD construct that Perl has comes from POSIX shells, and it is very
> useful in both places. Bash also adds a <<<-construct.

Yes, bash adopted the '<<<' "here-strings".

> Question: How would you do two separate <<-strings in the same shell
> command?

Can you give an example what you intend here? (With what semantics?)

Since '<<' is redirecting the here-document text to stdin of the
command you can have only one channel.

Janis

Re: Implicit String-Literal Concatenation

<url62n$3amuj$1@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33870&group=comp.lang.c#33870

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: porkc...@invalid.foo (Mike Sanders)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Tue, 27 Feb 2024 17:27:51 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 11
Sender: Mike Sanders <busybox@sdf.org>
Message-ID: <url62n$3amuj$1@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me> <urj1qv$2p32o$1@dont-email.me> <urj66g$2puef$4@dont-email.me>
Injection-Date: Tue, 27 Feb 2024 17:27:51 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="28d6159f7628b8c7c4f39fba4e344acf";
logging-data="3496915"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18hRaSQ6yIqTfWa0vYiemSt"
User-Agent: tin/2.6.2-20221225 ("Pittyvaich") (NetBSD/9.3 (amd64))
Cancel-Lock: sha1:+nN5zMJ22aJr4+MbibbIiHnQ36M=
 by: Mike Sanders - Tue, 27 Feb 2024 17:27 UTC

Lawrence D'Oliveiro <ldo@nz.invalid> wrote:

> My tool for easy editing of such embedded text is the Emacs macros in
> multiquote.el, here <https://gitlab.com/ldo/emacs-prefs>.

Neato-burritto, built his own tool chain, 'atta-boy. Interesting page.

--
:wq
Mike Sanders

Re: Implicit String-Literal Concatenation

<url69o$3amuj$2@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33871&group=comp.lang.c#33871

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: porkc...@invalid.foo (Mike Sanders)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Tue, 27 Feb 2024 17:31:36 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 26
Sender: Mike Sanders <busybox@sdf.org>
Message-ID: <url69o$3amuj$2@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me> <urj1qv$2p32o$1@dont-email.me> <urk6um$33nqv$1@dont-email.me>
Injection-Date: Tue, 27 Feb 2024 17:31:36 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="28d6159f7628b8c7c4f39fba4e344acf";
logging-data="3496915"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18NKVCsW0asEALXXydklzrQ"
User-Agent: tin/2.6.2-20221225 ("Pittyvaich") (NetBSD/9.3 (amd64))
Cancel-Lock: sha1:PXS8ekXr4t1Fo2eJqVuL9wfg5Kk=
 by: Mike Sanders - Tue, 27 Feb 2024 17:31 UTC

David Brown <david.brown@hesbynett.no> wrote:

> Because it generates files that have Segger copyright notices stamped on
> them? At least, that's how it appears from that web page.

Then we build our own...
> There are lots of open source alternatives that do similar things, with
> different variations in the way they generate the output. Or you can
> write your own in about 10 lines of Python, which of course makes it a
> lot easier to customise to fit your own styles and requirements.

Yeah even simpler ways too, sed/awk/etc

> And with C23, we will get #embed, though it is not yet supported by
> major tools.
>
> <https://en.cppreference.com/w/c/preprocessor/embed>

Did not know that was coming down the pike, thanks for sharing the info
David.

--
:wq
Mike Sanders

Re: Implicit String-Literal Concatenation

<urlb8p$3bvbc$1@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33873&group=comp.lang.c#33873

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: bc...@freeuk.com (bart)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Tue, 27 Feb 2024 18:56:26 +0000
Organization: A noiseless patient Spider
Lines: 56
Message-ID: <urlb8p$3bvbc$1@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me> <urj1qv$2p32o$1@dont-email.me>
<urk6um$33nqv$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Date: Tue, 27 Feb 2024 18:56:25 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="20b1b8f346f60418f3ea58d335a2a8b5";
logging-data="3538284"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+EVxTv3XTtM1mzJVmf6+k0NoHKGBxHNWs="
User-Agent: Mozilla Thunderbird
Cancel-Lock: sha1:9fMSjNyrD8mxcq28d91XWmNg7tU=
In-Reply-To: <urk6um$33nqv$1@dont-email.me>
Content-Language: en-GB
 by: bart - Tue, 27 Feb 2024 18:56 UTC

On 27/02/2024 08:36, David Brown wrote:
> On 26/02/2024 23:03, Mike Sanders wrote:
>> Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
>>
>>> I like using this for long strings:
>>>
>>>      fputs
>>>        (
>>>          "When an uncleft or a bulkbit wins one or more bernstonebits
>>> above\n"
>>>          "its own, it takes on a backward lading. When it loses one
>>> or\n"
>>>          "more, it takes on a forward lading. Such a mote is called a\n"
>>>          "*farer*, for that the drag between unlike ladings flits it.
>>> When\n"
>>>          "bernstonebits flit by themselves, it may be as a bolt of\n"
>>>          "lightning, a spark off some faststanding chunk, or the
>>> everyday\n"
>>>          "flow of bernstoneness through wires.\n",
>>>          stdout
>>>        );
>>>
>>> Of languages that derive ideas from C, only C++ and Python seem to have
>>> kept this. Java, JavaScript and PHP have not, for some reason.
>>
>> Easy solution Lawrence. Why not use something like bin2c:
>>
>> <https://www.segger.com/free-utilities/bin2c/>
>
> Because it generates files that have Segger copyright notices stamped on
> them?  At least, that's how it appears from that web page.
>
> There are lots of open source alternatives that do similar things, with
> different variations in the way they generate the output.  Or you can
> write your own in about 10 lines of Python, which of course makes it a
> lot easier to customise to fit your own styles and requirements.
>
> And with C23, we will get #embed, though it is not yet supported by
> major tools.
>
> <https://en.cppreference.com/w/c/preprocessor/embed>

Actually I've had such feature, for text files, for some years in my
older compiler:

#include <stdio.h>

int main(void) {
puts(strinclude(__FILE__));
}

This prints out the contents of this sourcefile. Binary files don't work
because of embedded zeros, but could have been made to.

Some stuff is just very easy to do; other stuff like designator chains
less easy and also less useful.

Re: Implicit String-Literal Concatenation

<urlgfn$3d1ah$3@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33874&group=comp.lang.c#33874

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo...@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Tue, 27 Feb 2024 20:25:27 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 10
Message-ID: <urlgfn$3d1ah$3@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me> <urj1qv$2p32o$1@dont-email.me>
<urk6um$33nqv$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Tue, 27 Feb 2024 20:25:27 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="d339ad4b21c64d41c58c7c072f1b4d54";
logging-data="3573073"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18yDLQKYijYyRYz0EktuaRw"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:XTYlRoChOO1thwFkDScCzJSWBRM=
 by: Lawrence D'Oliv - Tue, 27 Feb 2024 20:25 UTC

On Tue, 27 Feb 2024 09:36:38 +0100, David Brown wrote:

> And with C23, we will get #embed, though it is not yet supported by
> major tools.

More and more hacks on the preprocessor. Why not just get rid of it and
replace it with something like m4?

Because then you will discover that string-based macros are inherently an
unmanageable problem.

Re: Implicit String-Literal Concatenation

<87msrlve5k.fsf@nosuchdomain.example.com>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33875&group=comp.lang.c#33875

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: Keith.S....@gmail.com (Keith Thompson)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Tue, 27 Feb 2024 12:35:35 -0800
Organization: None to speak of
Lines: 21
Message-ID: <87msrlve5k.fsf@nosuchdomain.example.com>
References: <urdsob$1e8e4$7@dont-email.me> <urj1qv$2p32o$1@dont-email.me>
<urk6um$33nqv$1@dont-email.me> <urlgfn$3d1ah$3@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain
Injection-Info: dont-email.me; posting-host="e411e02173c5727b001dab2051103785";
logging-data="3580449"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/QQGAGTv6seN0w4eHp5zE8"
User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/27.2 (gnu/linux)
Cancel-Lock: sha1:XQeOKDjsywR1Sa7GJII1i57iBYw=
sha1:SC/hxqFg60QSSEHUh4PZ7NPutDs=
 by: Keith Thompson - Tue, 27 Feb 2024 20:35 UTC

Lawrence D'Oliveiro <ldo@nz.invalid> writes:
> On Tue, 27 Feb 2024 09:36:38 +0100, David Brown wrote:
>> And with C23, we will get #embed, though it is not yet supported by
>> major tools.
>
> More and more hacks on the preprocessor. Why not just get rid of it and
> replace it with something like m4?

Because it would invalidate 99% or more of existing C code.

(m4? Seriously?)

> Because then you will discover that string-based macros are inherently an
> unmanageable problem.

The C preprocessor operates on preprocessor tokens, not just strings.

--
Keith Thompson (The_Other_Keith) Keith.S.Thompson+u@gmail.com
Working, but not speaking, for Medtronic
void Void(void) { Void(); } /* The recursive call of the void */

Re: Implicit String-Literal Concatenation

<urlmo7$3eg2j$1@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33877&group=comp.lang.c#33877

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: bc...@freeuk.com (bart)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Tue, 27 Feb 2024 22:12:23 +0000
Organization: A noiseless patient Spider
Lines: 29
Message-ID: <urlmo7$3eg2j$1@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me> <urj1qv$2p32o$1@dont-email.me>
<urk6um$33nqv$1@dont-email.me> <urlgfn$3d1ah$3@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 7bit
Injection-Date: Tue, 27 Feb 2024 22:12:23 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="20b1b8f346f60418f3ea58d335a2a8b5";
logging-data="3620947"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/6CxbUd5UJyZ2TKk5z+xMkSlkqkQhzf1E="
User-Agent: Mozilla Thunderbird
Cancel-Lock: sha1:AQ7o1J/44DBauQX8RJMmm4cYYPU=
In-Reply-To: <urlgfn$3d1ah$3@dont-email.me>
Content-Language: en-GB
 by: bart - Tue, 27 Feb 2024 22:12 UTC

On 27/02/2024 20:25, Lawrence D'Oliveiro wrote:
> On Tue, 27 Feb 2024 09:36:38 +0100, David Brown wrote:
>
>> And with C23, we will get #embed, though it is not yet supported by
>> major tools.
>
> More and more hacks on the preprocessor. Why not just get rid of it and
> replace it with something like m4?
>
> Because then you will discover that string-based macros are inherently an
> unmanageable problem.

I hadn't notice that #embed was a preprocessor directive. But that is
not the problem here, it is this:

"The expansion of a #embed directive is a token sequence formed from the
list of integer constant expressions described below."

If a string like "ABC" really is converted to the five tokens 'A' comma
'B' comma 'C', then it's going to make long strings and binary files
inefficient.

Embedding a 100KB file will result in a 100KB bigger executable, but
along the way it may have to generate 200,000 tokens within the
compiler, half of them commas. Which in turn will need to be turned into
100,000 integer expressions.

I would hope that implementations find some way of streamlining that
process, perhaps by turning that 100KB of data directly into a 100KB string.

Re: Implicit String-Literal Concatenation

<urln99$3ejjt$1@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33878&group=comp.lang.c#33878

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: david.br...@hesbynett.no (David Brown)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Tue, 27 Feb 2024 23:21:28 +0100
Organization: A noiseless patient Spider
Lines: 65
Message-ID: <urln99$3ejjt$1@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me> <urj1qv$2p32o$1@dont-email.me>
<urk6um$33nqv$1@dont-email.me> <urlb8p$3bvbc$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8; format=flowed
Content-Transfer-Encoding: 8bit
Injection-Date: Tue, 27 Feb 2024 22:21:29 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="e40919f6b3ce328bb641103b7af228fa";
logging-data="3624573"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18iStA5ifS4RIwZ0BvnHote18LwQL+w34I="
User-Agent: Mozilla Thunderbird
Cancel-Lock: sha1:OI0yHcVz8F7za+GtAds/Jwhm9RA=
In-Reply-To: <urlb8p$3bvbc$1@dont-email.me>
Content-Language: en-GB
 by: David Brown - Tue, 27 Feb 2024 22:21 UTC

On 27/02/2024 19:56, bart wrote:
> On 27/02/2024 08:36, David Brown wrote:
>> On 26/02/2024 23:03, Mike Sanders wrote:
>>> Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
>>>
>>>> I like using this for long strings:
>>>>
>>>>      fputs
>>>>        (
>>>>          "When an uncleft or a bulkbit wins one or more
>>>> bernstonebits above\n"
>>>>          "its own, it takes on a backward lading. When it loses one
>>>> or\n"
>>>>          "more, it takes on a forward lading. Such a mote is called
>>>> a\n"
>>>>          "*farer*, for that the drag between unlike ladings flits
>>>> it. When\n"
>>>>          "bernstonebits flit by themselves, it may be as a bolt of\n"
>>>>          "lightning, a spark off some faststanding chunk, or the
>>>> everyday\n"
>>>>          "flow of bernstoneness through wires.\n",
>>>>          stdout
>>>>        );
>>>>
>>>> Of languages that derive ideas from C, only C++ and Python seem to have
>>>> kept this. Java, JavaScript and PHP have not, for some reason.
>>>
>>> Easy solution Lawrence. Why not use something like bin2c:
>>>
>>> <https://www.segger.com/free-utilities/bin2c/>
>>
>> Because it generates files that have Segger copyright notices stamped
>> on them?  At least, that's how it appears from that web page.
>>
>> There are lots of open source alternatives that do similar things,
>> with different variations in the way they generate the output.  Or you
>> can write your own in about 10 lines of Python, which of course makes
>> it a lot easier to customise to fit your own styles and requirements.
>>
>> And with C23, we will get #embed, though it is not yet supported by
>> major tools.
>>
>> <https://en.cppreference.com/w/c/preprocessor/embed>
>
> Actually I've had such feature, for text files, for some years in my
> older compiler:
>
>     #include <stdio.h>
>
>     int main(void) {
>         puts(strinclude(__FILE__));
>     }
>
> This prints out the contents of this sourcefile. Binary files don't work
> because of embedded zeros, but could have been made to.
>
> Some stuff is just very easy to do; other stuff like designator chains
> less easy and also less useful.

The #embed pre-processor directive turns the file into a list of integer
constants, one per byte (unless an implementation offers other options).
That makes it a little less convenient for strings than your solution,
but more convenient for data files. There's no harm in supporting both!

Re: Implicit String-Literal Concatenation

<urlp3h$3ep9p$5@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33881&group=comp.lang.c#33881

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo...@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Tue, 27 Feb 2024 22:52:33 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 6
Message-ID: <urlp3h$3ep9p$5@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me> <urj1qv$2p32o$1@dont-email.me>
<urk6um$33nqv$1@dont-email.me> <urlb8p$3bvbc$1@dont-email.me>
<urln99$3ejjt$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Tue, 27 Feb 2024 22:52:33 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="d339ad4b21c64d41c58c7c072f1b4d54";
logging-data="3630393"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX18jHUImwcI+milGDbIel1vB"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:vydB+Al2nBdL0reXBTcwNSqWXlg=
 by: Lawrence D'Oliv - Tue, 27 Feb 2024 22:52 UTC

On Tue, 27 Feb 2024 23:21:28 +0100, David Brown wrote:

> The #embed pre-processor directive turns the file into a list of integer
> constants, one per byte (unless an implementation offers other options).

What a waste of time.

Re: Implicit String-Literal Concatenation

<urlpnc$3ep9p$6@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33882&group=comp.lang.c#33882

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo...@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Tue, 27 Feb 2024 23:03:08 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 10
Message-ID: <urlpnc$3ep9p$6@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me> <urj1qv$2p32o$1@dont-email.me>
<urk6um$33nqv$1@dont-email.me> <urlgfn$3d1ah$3@dont-email.me>
<87msrlve5k.fsf@nosuchdomain.example.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Tue, 27 Feb 2024 23:03:08 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="2b5f550de027bed53e7de3d0720ccb3e";
logging-data="3630393"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+T13bf19if/Wke6S+dhsUg"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:cEqkaEQ7Lxb9J37i1uXc+DxCzRQ=
 by: Lawrence D'Oliv - Tue, 27 Feb 2024 23:03 UTC

On Tue, 27 Feb 2024 12:35:35 -0800, Keith Thompson wrote:

> (m4? Seriously?)

Do you know of any more powerful string-based macro processor?

> The C preprocessor operates on preprocessor tokens, not just strings.

Think of “hygienic” macros in the Lisps, and why that is just impossible
in any string-based preprocessor.

Re: Implicit String-Literal Concatenation

<urlq4p$3ep9p$7@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33883&group=comp.lang.c#33883

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!weretis.net!feeder6.news.weretis.net!feeder8.news.weretis.net!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: ldo...@nz.invalid (Lawrence D'Oliveiro)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Tue, 27 Feb 2024 23:10:17 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 31
Message-ID: <urlq4p$3ep9p$7@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me>
<1qf797ippluag.1p27j2yyk4ydt.dlg@40tude.net> <urisel$2nq9h$2@dont-email.me>
<urkjue$36npm$1@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Injection-Date: Tue, 27 Feb 2024 23:10:17 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="2b5f550de027bed53e7de3d0720ccb3e";
logging-data="3630393"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX185VtDN/ZwwkK4pW58Fes60"
User-Agent: Pan/0.155 (Kherson; fc5a80b8)
Cancel-Lock: sha1:Pa4bRj3u4Wv/61TIXUj8GimJ4aY=
 by: Lawrence D'Oliv - Tue, 27 Feb 2024 23:10 UTC

On Tue, 27 Feb 2024 13:18:20 +0100, Janis Papanagnou wrote:

> On 26.02.2024 21:31, Lawrence D'Oliveiro wrote:
>>
>> Question: How would you do two separate <<-strings in the same shell
>> command?
>
> Can you give an example what you intend here? (With what semantics?)
>
> Since '<<' is redirecting the here-document text to stdin of the command
> you can have only one channel.

Perl lets you do something like

func(<<EOD1, <<EOD2);
... contents of first string ...
EOD1
... contents of second string ...
EOD2

But this doesn’t work in Bash. However, in a Posix shell, remember you can
specify the number of the file descriptor you want to redirect, e.g.

diff -u /dev/fd/8 /dev/fd/9 8<<'EOD1' 9<<'EOD2'
... contents of first string ...
EOD1
... contents of second string ...
EOD2

Note I add the single quotes to prevent expansion of “$”-sequences within
the strings. (I think this might be needed in Perl, too.)

Re: Implicit String-Literal Concatenation

<urlsgn$3fkrn$1@dont-email.me>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33884&group=comp.lang.c#33884

  copy link   Newsgroups: comp.lang.c comp.unix.shell
Followup: comp.unix.shell
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: janis_pa...@hotmail.com (Janis Papanagnou)
Newsgroups: comp.lang.c,comp.unix.shell
Subject: Re: Implicit String-Literal Concatenation
Followup-To: comp.unix.shell
Date: Wed, 28 Feb 2024 00:50:46 +0100
Organization: A noiseless patient Spider
Lines: 38
Message-ID: <urlsgn$3fkrn$1@dont-email.me>
References: <urdsob$1e8e4$7@dont-email.me>
<1qf797ippluag.1p27j2yyk4ydt.dlg@40tude.net> <urisel$2nq9h$2@dont-email.me>
<urkjue$36npm$1@dont-email.me> <urlq4p$3ep9p$7@dont-email.me>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Transfer-Encoding: 8bit
Injection-Date: Tue, 27 Feb 2024 23:50:48 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="c4b9753b38fe667b839cfcc70e6edcca";
logging-data="3658615"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+EkTj1FTYVo5jI7PTRUwRl"
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:45.0) Gecko/20100101
Thunderbird/45.8.0
Cancel-Lock: sha1:yDx2+fVDUg/8CWQcbmJZxJzuz80=
In-Reply-To: <urlq4p$3ep9p$7@dont-email.me>
X-Enigmail-Draft-Status: N1110
 by: Janis Papanagnou - Tue, 27 Feb 2024 23:50 UTC

On 28.02.2024 00:10, Lawrence D'Oliveiro wrote:
> On Tue, 27 Feb 2024 13:18:20 +0100, Janis Papanagnou wrote:
>
>> On 26.02.2024 21:31, Lawrence D'Oliveiro wrote:
>>>
>>> Question: How would you do two separate <<-strings in the same shell
>>> command?
>>
>> Can you give an example what you intend here? (With what semantics?)
>>
>> Since '<<' is redirecting the here-document text to stdin of the command
>> you can have only one channel.
>
> Perl lets you do something like
>
> func(<<EOD1, <<EOD2);
> ... contents of first string ...
> EOD1
> ... contents of second string ...
> EOD2
>
> But this doesn’t work in Bash. However, in a Posix shell, remember you can
> specify the number of the file descriptor you want to redirect, e.g.
>
> diff -u /dev/fd/8 /dev/fd/9 8<<'EOD1' 9<<'EOD2'
> ... contents of first string ...
> EOD1
> ... contents of second string ...
> EOD2
>
> Note I add the single quotes to prevent expansion of “$”-sequences within
> the strings. (I think this might be needed in Perl, too.)

I see. - Yes, you can do that in POSIX shells as well. - Note that I set
F'up-to CUS. And post the response there as a f'up to this post.

Janis

Re: Implicit String-Literal Concatenation

<20240227170925.837@kylheku.com>

  copy mid

https://www.novabbs.com/devel/article-flat.php?id=33889&group=comp.lang.c#33889

  copy link   Newsgroups: comp.lang.c
Path: i2pn2.org!i2pn.org!eternal-september.org!feeder3.eternal-september.org!news.eternal-september.org!.POSTED!not-for-mail
From: 433-929-...@kylheku.com (Kaz Kylheku)
Newsgroups: comp.lang.c
Subject: Re: Implicit String-Literal Concatenation
Date: Wed, 28 Feb 2024 01:09:46 -0000 (UTC)
Organization: A noiseless patient Spider
Lines: 14
Message-ID: <20240227170925.837@kylheku.com>
References: <urdsob$1e8e4$7@dont-email.me> <urj1qv$2p32o$1@dont-email.me>
<urk6um$33nqv$1@dont-email.me> <urlb8p$3bvbc$1@dont-email.me>
<urln99$3ejjt$1@dont-email.me> <urlp3h$3ep9p$5@dont-email.me>
Injection-Date: Wed, 28 Feb 2024 01:09:46 -0000 (UTC)
Injection-Info: dont-email.me; posting-host="8db9a85693c796a45b822e4215883be9";
logging-data="3684551"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1/TRiMr2v1bnHkKkDUHti3cYDH019nM6bo="
User-Agent: slrn/pre1.0.4-9 (Linux)
Cancel-Lock: sha1:62Yqri95+kOFVRPeLUkJHj9Q9hg=
 by: Kaz Kylheku - Wed, 28 Feb 2024 01:09 UTC

On 2024-02-27, Lawrence D'Oliveiro <ldo@nz.invalid> wrote:
> On Tue, 27 Feb 2024 23:21:28 +0100, David Brown wrote:
>
>> The #embed pre-processor directive turns the file into a list of integer
>> constants, one per byte (unless an implementation offers other options).
>
> What a waste of time.

Plus easily doable in 1970's Lisp.

--
TXR Programming Language: http://nongnu.org/txr
Cygnal: Cygwin Native Application Library: http://kylheku.com/cygnal
Mastodon: @Kazinator@mstdn.ca

Pages:12345
server_pubkey.txt

rocksolid light 0.9.8
clearnet tor