🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.std.c
Article #1899

Re: strings no longer writable?

#1899
From: Doug Gwyn
Date: Mon, 29 Oct 1990 22:41
12 lines
984 bytes
In article <1990Oct29.174410.28498@batcomputer.tn.cornell.edu> lijewski@theory.tn.cornell.edu (Mike Lijewski) writes:
>My understanding is that strings are no longer writable.

They never have been guaranteed to be writable.

>Is a conforming implementation required to issue a warning, an error, or
>what?

The standard says, "If the program attempts to modify a string literal of
either form, the behavior is undefined."  A diagnostic message is not
required; in fact, some implementations may support this operation as a
conforming extension.
Technical Details
Message-ID: <14274@smoke.brl.mil>
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!wuarchive!zaphod.mps.ohio-state.edu!uakari.primate.wisc.edu!aplcen!haven!adm!smoke!gwyn
References: <1990Oct29.174410.28498@batcomputer.tn.cornell.edu>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!attcan!uunet!wuarchive!zaphod.mps.ohio-state.edu!uakari.primate.wisc.edu!aplcen!haven!adm!smoke!gwyn
From: gwyn@smoke.brl.mil (Doug Gwyn)
Newsgroups: comp.std.c
Subject: Re: strings no longer writable?
Message-ID: <14274@smoke.brl.mil>
Date: 29 Oct 90 22:41:42 GMT
References: <1990Oct29.174410.28498@batcomputer.tn.cornell.edu>
Organization: U.S. Army Ballistic Research Laboratory, APG, MD.
Lines: 12