From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.ciao.gmane.io!not-for-mail From: "W. Lincoln Harvey" via "Bug reports for GUILE, GNU's Ubiquitous Extension Language" Newsgroups: gmane.lisp.guile.bugs Subject: bug#39999: BSD sed vs Gnu sed Date: Wed, 29 Apr 2020 12:30:22 -0700 Message-ID: <4BF90412-EB21-47F5-9F56-BADAA2079B18@mac.com> References: <12F04DBA-35DF-49B3-B2BB-B07A95550151@gmail.com> Reply-To: "W. Lincoln Harvey" Mime-Version: 1.0 (Mac OS X Mail 12.4 \(3445.104.11\)) Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable Injection-Info: ciao.gmane.io; posting-host="ciao.gmane.io:159.69.161.202"; logging-data="77608"; mail-complaints-to="usenet@ciao.gmane.io" To: 39999@debbugs.gnu.org Original-X-From: bug-guile-bounces+guile-bugs=m.gmane-mx.org@gnu.org Wed Apr 29 21:35:42 2020 Return-path: Envelope-to: guile-bugs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1jTsUf-000K6N-Un for guile-bugs@m.gmane-mx.org; Wed, 29 Apr 2020 21:35:41 +0200 Original-Received: from localhost ([::1]:46976 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jTsUe-0003KZ-Tp for guile-bugs@m.gmane-mx.org; Wed, 29 Apr 2020 15:35:40 -0400 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:46958) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1jTsU3-0002i7-Di for bug-guile@gnu.org; Wed, 29 Apr 2020 15:35:03 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.90_1) (envelope-from ) id 1jTsU2-0007Tm-S0 for bug-guile@gnu.org; Wed, 29 Apr 2020 15:35:03 -0400 Original-Received: from debbugs.gnu.org ([209.51.188.43]:33191) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1jTsU2-0007Tg-Fm for bug-guile@gnu.org; Wed, 29 Apr 2020 15:35:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1jTsU2-000532-8c for bug-guile@gnu.org; Wed, 29 Apr 2020 15:35:02 -0400 X-Loop: help-debbugs@gnu.org In-Reply-To: <12F04DBA-35DF-49B3-B2BB-B07A95550151@gmail.com> Resent-From: "W. Lincoln Harvey" Original-Sender: "Debbugs-submit" Resent-CC: bug-guile@gnu.org Resent-Date: Wed, 29 Apr 2020 19:35:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 39999 X-GNU-PR-Package: guile Original-Received: via spool by 39999-submit@debbugs.gnu.org id=B39999.158818887819369 (code B ref 39999); Wed, 29 Apr 2020 19:35:02 +0000 Original-Received: (at 39999) by debbugs.gnu.org; 29 Apr 2020 19:34:38 +0000 Original-Received: from localhost ([127.0.0.1]:44737 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jTsTd-00052L-N9 for submit@debbugs.gnu.org; Wed, 29 Apr 2020 15:34:37 -0400 Original-Received: from pv50p00im-ztdg10012101.me.com ([17.58.6.49]:46415) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1jTsPe-0004wh-9S for 39999@debbugs.gnu.org; Wed, 29 Apr 2020 15:30:30 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mac.com; s=1a1hai; t=1588188624; bh=EkVPnztrMdsJRiKhj+FG0ajD2V6VQzVcbUlQSrwNMpQ=; h=From:Content-Type:Subject:Message-Id:Date:To; b=hc7jlRgQplfX59EElGbz3AeZzIG8oUaMJfjcA2vl4j9x+L8sHSV1Ov6aWP589bJtY qG2oLmXQ7kxEo2jS2B+XqG5IiPx7I+vdF0atOuJOV2lb6z2ZFAz13O8W3GbCvgjK6F Pr+eZ3sgrIbwtoO6b4gw+HeIGzbMJh6C6NODbZpmIjKgkgsr4906G5A0LheUYz9uKY Xw6/dgrih5MESXjPofaQgc3V7xFxTx0NL95Vq2MvN4C2rj3DAg6wMbj5MC54SF7mce 1FgKjrSN/8grWzDccQ9aX7IvQezxvO9/jemofz6+fTNmmUeCIzOaxwP/yvhPoFtDes AL+KVca3F9M3A== Original-Received: from [192.168.0.8] (c-73-96-79-94.hsd1.wa.comcast.net [73.96.79.94]) by pv50p00im-ztdg10012101.me.com (Postfix) with ESMTPSA id 1FAA18407C1 for <39999@debbugs.gnu.org>; Wed, 29 Apr 2020 19:30:24 +0000 (UTC) X-Mailer: Apple Mail (2.3445.104.11) X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10434:6.0.138, 18.0.676 definitions=2020-04-29_10:2020-04-29, 2020-04-29 signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 suspectscore=1 malwarescore=0 phishscore=0 bulkscore=0 spamscore=0 clxscore=1015 mlxscore=0 mlxlogscore=644 adultscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=8.0.1-2002250000 definitions=main-2004290145 X-Mailman-Approved-At: Wed, 29 Apr 2020 15:34:35 -0400 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-Received-From: 209.51.188.43 X-BeenThere: bug-guile@gnu.org List-Id: "Bug reports for GUILE, GNU's Ubiquitous Extension Language" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guile-bounces+guile-bugs=m.gmane-mx.org@gnu.org Original-Sender: "bug-guile" Xref: news.gmane.io gmane.lisp.guile.bugs:9740 Archived-At: Sorry; my explanation above is not correct. =20 What I meant to say is that to edit a file in place WITHOUT CREATING a = backup file, BSD sed=E2=80=99s -i option requires a zero-length string = as a mandatory argument, while Gnu sed=E2=80=99s -i option does not take = any argument. If a backup file is wanted, then their option -i syntax = is identical. The INSTANTIATE macro as written is not including any argument to = sed=E2=80=99s -i option, meaning that no backup file is wanted. =20 Therefore, a very simply solution to this problem is to make a backup = file, then delete it. Both sed versions would work correctly. A more complicated solution is to determine which version of sed is = being used, and change the INSTANTIATE macro to use the correct syntax. Gnu sed has a version option (=E2=80=94version), but BSD sed does not = (it throws an error when either -v or =E2=80=94version are used). wlh=