Re: Are source locations broken?

2022-03-25 Thread Maxime Devos
Maxime Devos schreef op vr 25-03-2022 om 21:22 [+0100]:
Here's a minimal reproducer:

$ cat trtr.scm:
> foo

$ guild compile trtr.scm
> : warning: possibly unbound variable `foo'
> wrote `$HOME/.cache/guile/ccache/3.0-LE-8-4.6/$HOME/trtr.scm.go'

Curiously, it seems that source locations were actually recorded:

(define-syntax pk-the-source-location
  (lambda (s)
(pk 'invocation (syntax-source s))
(syntax-case s ()
  ((_ stuff)
   (pk 'use (syntax-source #'stuff))
   #'stuff

(lambda () (pk-the-source-location foo))

;;; [...]
;;; (invocation ((filename . "$HOME/trtr.scm") (line . 8) (column . 11)))

;;; (use ((filename . "$HOME/trtr.scm") (line . 8) (column . 35)))
;;; : warning: possibly unbound variable `foo'
;;; compiled [...]



signature.asc
Description: This is a digitally signed message part


Re: Are source locations broken?

2022-03-25 Thread Maxime Devos
Jean Abou Samra schreef op vr 25-03-2022 om 21:11 [+0100]:
> Please have a look at:
> 
> $ ./libguile/guile test.scm
> ;;; note: auto-compilation is enabled, set GUILE_AUTO_COMPILE=0
> ;;;   or pass the --no-auto-compile argument to disable.
> ;;; compiling /home/jean/Bureau/ENS-1A/dm_anac/test.scm
> ;;; : warning: possibly unbound variable 
> `unbound-variable'
> ;;; compiled 
> /home/jean/.cache/guile/ccache/3.0-LE-8-4.6/home/jean/Bureau/ENS-1A/dm_anac/test.scm.go
>  
> 
> Backtrace:
> [snipped]
> 
> 
> Note the . In LilyPond, I suddenly lost
> all locations for compilation warnings when upgrading from
> Guile 3.0.5 to 3.0.8. The above is with the main branch.

Here's a minimal reproducer:

$ cat trtr.scm:
> foo

$ guild compile trtr.scm
> : warning: possibly unbound variable `foo'
> wrote `$HOME/.cache/guile/ccache/3.0-LE-8-4.6/$HOME/trtr.scm.go'

Greetings,
Maxime.


signature.asc
Description: This is a digitally signed message part


Are source locations broken?

2022-03-25 Thread Jean Abou Samra

Hi,

Please have a look at:

$ ./libguile/guile test.scm
;;; note: auto-compilation is enabled, set GUILE_AUTO_COMPILE=0
;;;   or pass the --no-auto-compile argument to disable.
;;; compiling /home/jean/Bureau/ENS-1A/dm_anac/test.scm
;;; : warning: possibly unbound variable 
`unbound-variable'
;;; compiled 
/home/jean/.cache/guile/ccache/3.0-LE-8-4.6/home/jean/Bureau/ENS-1A/dm_anac/test.scm.go 


Backtrace:
[snipped]


Note the . In LilyPond, I suddenly lost
all locations for compilation warnings when upgrading from
Guile 3.0.5 to 3.0.8. The above is with the main branch.