From unknown Fri Aug 15 14:45:38 2025 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 X-Mailer: MIME-tools 5.509 (Entity 5.509) Content-Type: text/plain; charset=utf-8 From: bug#38617 <38617@debbugs.gnu.org> To: bug#38617 <38617@debbugs.gnu.org> Subject: Status: should internal defines be callable with incorrect number of args? Reply-To: bug#38617 <38617@debbugs.gnu.org> Date: Fri, 15 Aug 2025 21:45:38 +0000 retitle 38617 should internal defines be callable with incorrect number of = args? reassign 38617 guile submitter 38617 Christopher Lam severity 38617 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Sat Dec 14 20:03:19 2019 Received: (at submit) by debbugs.gnu.org; 15 Dec 2019 01:03:19 +0000 Received: from localhost ([127.0.0.1]:35908 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1igIJb-0001y2-1y for submit@debbugs.gnu.org; Sat, 14 Dec 2019 20:03:19 -0500 Received: from lists.gnu.org ([209.51.188.17]:35941) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1igIJZ-0001xt-5t for submit@debbugs.gnu.org; Sat, 14 Dec 2019 20:03:17 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:55298) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1igIJY-0005te-84 for bug-guile@gnu.org; Sat, 14 Dec 2019 20:03:17 -0500 X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org X-Spam-Level: X-Spam-Status: No, score=0.8 required=5.0 tests=BAYES_50,FREEMAIL_FROM, HTML_MESSAGE autolearn=disabled version=3.3.2 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1igIJV-0007wx-7r for bug-guile@gnu.org; Sat, 14 Dec 2019 20:03:16 -0500 Received: from mail-ed1-x52d.google.com ([2a00:1450:4864:20::52d]:39521) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1igIJU-0007tB-HG for bug-guile@gnu.org; Sat, 14 Dec 2019 20:03:13 -0500 Received: by mail-ed1-x52d.google.com with SMTP id v16so2164888edy.6 for ; Sat, 14 Dec 2019 17:03:09 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=Xg9l0RxxraOI8pPXGYNpuYRf/4HAcEkIAoPeM29jPP0=; b=hSQpF1IqVUb9+1fNbJB1SDt+7opPpgNfdSj+nzX23nNHJVEGFSkqYXm9YdmaWpGbku hM9T9m3LkBxs6/RUpSHJ40tjb6yX9rXhz8xEtpwFrB3RkRh2iVrwd+EZWyJM7ZdHWzLK DgShZfcCG+DkjZ4h6hgwB0eqCQcsomZes5lIe9hQgnWT97PpxXJehlBj5o+vfrzIzyth kETvbYMVV3wImP3XAO/gcA2oyrPivp3BPFFbZ83KQhJZ+Z7jJrz18l+8AFWDX9hjOXsT 2wGx1nB688boE16iIQijW9n/CXzNITFkDT9UmeudlfV6XXw4QR9OYmhxFhEu5F6pI+h4 0q7w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=Xg9l0RxxraOI8pPXGYNpuYRf/4HAcEkIAoPeM29jPP0=; b=LbdQ3+MNzY6kZlGEtq8LutoUkIMppyMb44ssEAmM1ieJOCJmoMJycBGFkOvIIqqCmr byFCjoumZUpCOIOxah94Y8pZYf3CjhHbuXcKfrB70cQV2Uk6IcP3axLtC29vUEmm3AS+ CS5QTZ/1TiPgGcCCokT2OJvUHDjAkLI/qOfa2hfVqlC0vPwIduLoOTLSnJJKh+855VJF ERcX2PQLOejUGzvFLGfIetkC+SKyhovRwgyL8Qp78iZ+Irpe3zI2EacGlbZfUjFjFGQR o6zNBY6sboSyBYbfF5Nx2+c7c1tEO36KjSXy1BnRqMKxbeBNYdrAkgjW5neoXaPc5Edp LjUw== X-Gm-Message-State: APjAAAXUiSRR0eNjX9MKxtjHXjaVyw1E8e6D1AhbywnlQzv7Dt285GhK 0wtVqi2l63H8JtsIx1/xR2fRFi8itogp9iJ0pC4H7mOHrdY= X-Google-Smtp-Source: APXvYqzKxcQv+Ne1z4zuwtOAzVsQdcpSs03nPwC/H2pxDAxWVFKhLCCP/rIbfbSYTfa31gQwqeugeUsnoBTvtDEMgHQ= X-Received: by 2002:a17:906:2894:: with SMTP id o20mr25694842ejd.199.1576371788040; Sat, 14 Dec 2019 17:03:08 -0800 (PST) MIME-Version: 1.0 From: Christopher Lam Date: Sun, 15 Dec 2019 01:02:41 +0000 Message-ID: Subject: should internal defines be callable with incorrect number of args? To: bug-guile@gnu.org Content-Type: multipart/alternative; boundary="00000000000075ce970599b3a839" X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::52d X-Spam-Score: 0.7 (/) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) --00000000000075ce970599b3a839 Content-Type: text/plain; charset="UTF-8" See snippet below. IMHO the second call to add1 should fail. On guile-2.2.6 it does not error out. On guile-2.0 it does throw error (as I think it should). Is this intentional? =-=-= (define (main) (define (add1 num) (+ num 1)) (display "testing") (display (add1 2)) (display (add1 2 3))) (main) =-=-= --00000000000075ce970599b3a839 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
See snippet below.
IMHO the second cal= l to add1 should fail. On guile-2.2.6 it does not error out.
On g= uile-2.0 it does throw error (as I think it should).
Is this inte= ntional?

=3D-=3D-=3D
(define (ma= in)
=C2=A0 (define (add1 num)
=C2=A0 =C2=A0 (+ num 1))
=C2=A0 (dis= play "testing")
=C2=A0 (display (add1 2))
=C2=A0 (display (= add1 2 3)))

(main)
=3D-=3D-=3D
--00000000000075ce970599b3a839-- From debbugs-submit-bounces@debbugs.gnu.org Sun Jan 12 15:52:39 2020 Received: (at 38617-done) by debbugs.gnu.org; 12 Jan 2020 20:52:39 +0000 Received: from localhost ([127.0.0.1]:58100 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iqkDv-0007h7-6X for submit@debbugs.gnu.org; Sun, 12 Jan 2020 15:52:39 -0500 Received: from fanzine.igalia.com ([178.60.130.6]:36834) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1iqkDt-0007gs-5y for 38617-done@debbugs.gnu.org; Sun, 12 Jan 2020 15:52:37 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=igalia.com; s=20170329; h=Content-Type:MIME-Version:Message-ID:In-Reply-To:Date:References:Subject:Cc:To:From; bh=zmCsBaJGE/f0U4PYVKj5JmdtKw8sguLzOva0xnfLn0Q=; b=ZTDGILaoI9t3/VxBNUxxxB0B7ERawMnNVfm6VL+WMJH4daL0vWWnCs6OSSe+MTit22EBS89YoH+L6s1bZoTC2N7X1sCrV28Y+hOoYe0+8c0+PNYe8mR04Fh7FumKboOfkz+joFH0vt9yFx/v3paKY20AtpamjTwDlGvjvlEUmet41nwzDACDHe0n5XxXsZxFDkcgsOyzTMPwm246Fq7aFQ/dpmSB+E2++I0c/bScCn8T/4t3SQOyCY4gqSQvBGIzsbG2FhA/4lbZFDqRnL6iwoDdniF46VmHgKJfLLE2+UyDoERWIVO47ObdHXfdniUPsaD4ocGIMKemgbPfHzsayQ==; Received: from [88.123.12.110] (helo=sparrow) by fanzine.igalia.com with esmtpsa (Cipher TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim) id 1iqkDm-00088g-Or; Sun, 12 Jan 2020 21:52:30 +0100 From: Andy Wingo To: Christopher Lam Subject: Re: bug#38617: should internal defines be callable with incorrect number of args? References: Date: Sun, 12 Jan 2020 21:52:20 +0100 In-Reply-To: (Christopher Lam's message of "Sun, 15 Dec 2019 01:02:41 +0000") Message-ID: <87blr8o0sb.fsf@pobox.com> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain X-Spam-Score: 0.7 (/) X-Debbugs-Envelope-To: 38617-done Cc: 38617-done@debbugs.gnu.org X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -0.3 (/) On Sun 15 Dec 2019 02:02, Christopher Lam writes: > See snippet below. > IMHO the second call to add1 should fail. On guile-2.2.6 it does not error out. > On guile-2.0 it does throw error (as I think it should). > Is this intentional? OMG what an embarrassing bug! Thank you for finding and reporting it! Fixed on 2.2 and master. Andy From unknown Fri Aug 15 14:45:38 2025 Received: (at fakecontrol) by fakecontrolmessage; To: internal_control@debbugs.gnu.org From: Debbugs Internal Request Subject: Internal Control Message-Id: bug archived. Date: Mon, 10 Feb 2020 12:24:05 +0000 User-Agent: Fakemail v42.6.9 # This is a fake control message. # # The action: # bug archived. thanks # This fakemail brought to you by your local debbugs # administrator