From unknown Sun Jun 15 01:06:58 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#39854 <39854@debbugs.gnu.org> To: bug#39854 <39854@debbugs.gnu.org> Subject: Status: Not correct line and column numbers associated to function. Reply-To: bug#39854 <39854@debbugs.gnu.org> Date: Sun, 15 Jun 2025 08:06:58 +0000 retitle 39854 Not correct line and column numbers associated to function. reassign 39854 guile submitter 39854 Stefan Israelsson Tampe severity 39854 normal thanks From debbugs-submit-bounces@debbugs.gnu.org Sun Mar 01 07:17:51 2020 Received: (at submit) by debbugs.gnu.org; 1 Mar 2020 12:17:51 +0000 Received: from localhost ([127.0.0.1]:35821 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j8NXb-0005gp-4k for submit@debbugs.gnu.org; Sun, 01 Mar 2020 07:17:51 -0500 Received: from lists.gnu.org ([209.51.188.17]:46735) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j8NXY-0005gg-AA for submit@debbugs.gnu.org; Sun, 01 Mar 2020 07:17:49 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:60838) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1j8NXX-0000Es-4X for bug-guile@gnu.org; Sun, 01 Mar 2020 07:17:48 -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 1j8NXW-000722-22 for bug-guile@gnu.org; Sun, 01 Mar 2020 07:17:46 -0500 Received: from mail-wr1-x429.google.com ([2a00:1450:4864:20::429]:43614) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1j8NXV-00071H-PY for bug-guile@gnu.org; Sun, 01 Mar 2020 07:17:46 -0500 Received: by mail-wr1-x429.google.com with SMTP id e10so7526047wrr.10 for ; Sun, 01 Mar 2020 04:17:45 -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=z657yLL2GtESiAO8uSOaHNcRagI5x1rZcr73sc5jo6c=; b=n6Wk43iwChIoTRs/au/e1K/W5IUxrir/H2g8xS596ICFNPvSU4NUJ+GbJIC3DyhGdg nis+v89WBqJrpG/aQLqK1k4RYNz+yWcAiIr+2yCEKIU/vEKP4Zci8AjELsh0vwTNapRL MJkYP6gbpHAlLK7+Y5ueXwAty2Wcrv2SlNncJA23UfF+LkSK/nCw1KzPBo6T4DF9IleJ J4aJ3+w0rbnxYgEAWGN5geNosTVcSTmH2BUFaVDdZImAqCj8fF4CNKdZLGxzNVB9VSVi hxQNx4Ic5BMjQQ007o9gnQhL/gmtzE3it4yKw1wPAdeZFILFKUM/u7knHrGkO+4saxxe au3w== 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=z657yLL2GtESiAO8uSOaHNcRagI5x1rZcr73sc5jo6c=; b=C5qrC8phEG2042ySerWTbkqm44th03RI927laCe4IOe38Wz4Wv75AwcnF3B//lK90q xbW2VNFIKRUN7M6TXHLL9sPo2tAqbygvTu2+66PQpFljHU95vqfugtxbbURT8Nsc8kDW afYmtVhT/e4i+BcihFQO24uGUdC535OensZbGtYSEi+DPYsCcMy/X050GZvCRMQzm4wC Wt23Bdq/b4PB0/KVMW/Vha9AFWXfMc3Kfsro4aZHAP51D60/lp3gAm3pZC/W3SAxneJi pKVYGgKBII2KZh/0Fy8Bp2SKgERDR4Zs0VTMHDCEW5lgisfXSRmd4qR3676R9cN5eLLr 1Wqw== X-Gm-Message-State: APjAAAXzi6mMYNTqoet166HCZMYRZXDKJxxh/zLgQoeDIzWC4PW3RVi2 q3DKTiLTYKx8EKISXAhmCmS3HwQXvJKNeW8Ci5TsieCZ X-Google-Smtp-Source: APXvYqzxeAwjkJNVEWoqGgO/5sZiOzVlCzmb/HTy3ZDmuURQisKjmWR5azgnArYoM/5Ip8xcy74IFUrvbYXkmwNSU4Q= X-Received: by 2002:a5d:56c4:: with SMTP id m4mr16467794wrw.6.1583065063166; Sun, 01 Mar 2020 04:17:43 -0800 (PST) MIME-Version: 1.0 From: Stefan Israelsson Tampe Date: Sun, 1 Mar 2020 13:17:32 +0100 Message-ID: Subject: Not correct line and column numbers associated to function. To: bug-guile@gnu.org Content-Type: multipart/alternative; boundary="000000000000bf1683059fca0e1d" X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:4864:20::429 X-Spam-Score: 0.3 (/) 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: -0.7 (/) --000000000000bf1683059fca0e1d Content-Type: text/plain; charset="UTF-8" Consider this source file: test.scm: (use-modules (language python def) (system syntax internal) ((oop dict) #:select (slask-it))) (define-syntax m (lambda (x) (syntax-case x () ((_ n m y) (let* ((xx (syntax-expression x)) (yy (pk 'yy (source-properties xx))) (zz (syntax-expression #'y)) (ww (pk 'ww (source-properties zz))) (nn (assoc 'line yy)) (mm (assoc 'column yy)) (ii (assoc 'line ww)) (jj (assoc 'column ww))) (if nn (set-cdr! nn (syntax->datum #'n))) (if mm (set-cdr! mm (syntax->datum #'m))) (if ii (set-cdr! ii (syntax->datum #'n))) (if jj (set-cdr! jj (syntax->datum #'m))) (set-source-properties! xx (pk yy)) (set-source-properties! zz (pk ww)) #'y))))) (define f (slask-it (lambda () 1))) ;;----------------------------------------------------- Never mind the m macro and concentrate on the last define of f. slask-it is an imported function and equivalent to (lambda (x) x) (just to make sure to annynmous f. loading this source file an d quiring f lead to cheme@(guile-user)> f $10 = # Why 4:2? the line number is much higher and column number as well. Regards Stefan --000000000000bf1683059fca0e1d Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
Consider this source file: test.scm:

(u= se-modules (language python def) (system syntax internal) ((oop dict) #:sel= ect (slask-it)))

(define-syntax m
=C2=A0 (lambda (x)
=C2=A0 = =C2=A0 (syntax-case x ()
=C2=A0 =C2=A0 =C2=A0 ((_ n m y)
=C2=A0 =C2= =A0 =C2=A0 =C2=A0(let* ((xx (syntax-expression x))
=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 (yy (pk 'yy (source-properties xx)))
=C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (zz (syntax-expression #'= y))
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (ww (pk 'ww (so= urce-properties zz)))
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 (= nn (assoc 'line =C2=A0 yy))
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 (mm (assoc 'column yy))
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2= =A0 =C2=A0 =C2=A0 (ii (assoc 'line =C2=A0 ww))
=C2=A0 =C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0 =C2=A0 (jj (assoc 'column ww)))
=C2=A0 =C2=A0 = =C2=A0 =C2=A0 =C2=A0(if nn (set-cdr! nn (syntax->datum #'n)))
=C2= =A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(if mm (set-cdr! mm (syntax->datum #'= m)))
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(if ii (set-cdr! ii (syntax->d= atum #'n)))
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(if jj (set-cdr! jj (s= yntax->datum #'m)))
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(set-source= -properties! xx (pk yy))
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0(set-source-p= roperties! zz (pk ww))
=C2=A0 =C2=A0 =C2=A0 =C2=A0 =C2=A0#'y)))))
(define f (slask-it (lambda () 1)))

;;---= --------------------------------------------------

Never mind the m macro and concentrate on the last define of f. slask-it i= s an imported function
and equivalent to (lambda (x) x) (just to = make sure to annynmous f. loading this source file an d quiring f lead to

cheme@(guile-user)> f
$10 =3D #<procedure 7fa3c1db93b0 at test.scm:4:2 ()>

Why 4:2? th= e line number is much higher and column number as well.

Regards
Stefan
--000000000000bf1683059fca0e1d-- From debbugs-submit-bounces@debbugs.gnu.org Thu Mar 05 16:54:37 2020 Received: (at 39854) by debbugs.gnu.org; 5 Mar 2020 21:54:37 +0000 Received: from localhost ([127.0.0.1]:43816 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j9yRx-0001sj-44 for submit@debbugs.gnu.org; Thu, 05 Mar 2020 16:54:37 -0500 Received: from eggs.gnu.org ([209.51.188.92]:43707) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1j9yRv-0001sX-F5 for 39854@debbugs.gnu.org; Thu, 05 Mar 2020 16:54:36 -0500 Received: from fencepost.gnu.org ([2001:470:142:3::e]:52609) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1j9yRq-0007Go-91; Thu, 05 Mar 2020 16:54:30 -0500 Received: from [2a01:e0a:1d:7270:af76:b9b:ca24:c465] (port=34780 helo=ribbon) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1j9yRj-0003Jf-4T; Thu, 05 Mar 2020 16:54:29 -0500 From: =?utf-8?Q?Ludovic_Court=C3=A8s?= To: Stefan Israelsson Tampe Subject: Re: bug#39854: Not correct line and column numbers associated to function. References: Date: Thu, 05 Mar 2020 22:54:17 +0100 In-Reply-To: (Stefan Israelsson Tampe's message of "Sun, 1 Mar 2020 13:17:32 +0100") Message-ID: <87v9ni5uye.fsf@gnu.org> User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.3 (gnu/linux) MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Spam-Score: -0.7 (/) X-Debbugs-Envelope-To: 39854 Cc: 39854@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: -1.7 (-) Hi, Stefan Israelsson Tampe skribis: > Consider this source file: test.scm: > > (use-modules (language python def) (system syntax internal) ((oop dict) > #:select (slask-it))) > > (define-syntax m > (lambda (x) > (syntax-case x () > ((_ n m y) > (let* ((xx (syntax-expression x)) > (yy (pk 'yy (source-properties xx))) > (zz (syntax-expression #'y)) > (ww (pk 'ww (source-properties zz))) > (nn (assoc 'line yy)) > (mm (assoc 'column yy)) > (ii (assoc 'line ww)) > (jj (assoc 'column ww))) > (if nn (set-cdr! nn (syntax->datum #'n))) > (if mm (set-cdr! mm (syntax->datum #'m))) > (if ii (set-cdr! ii (syntax->datum #'n))) > (if jj (set-cdr! jj (syntax->datum #'m))) > (set-source-properties! xx (pk yy)) > (set-source-properties! zz (pk ww)) > #'y))))) > > (define f (slask-it (lambda () 1))) > > ;;----------------------------------------------------- > > Never mind the m macro and concentrate on the last define of f. slask-it = is > an imported function > and equivalent to (lambda (x) x) (just to make sure to annynmous f. loadi= ng > this source file an d quiring f lead to > > cheme@(guile-user)> f > $10 =3D # > > Why 4:2? the line number is much higher and column number as well. I wonder if it relates to and . Ludo=E2=80=99.