GNU bug report logs - #39954
[3.0.0] ‘frame-local-ref’ returns (SCM)0x0

Previous Next

Package: guile;

Reported by: Ludovic Courtès <ludo <at> gnu.org>

Date: Fri, 6 Mar 2020 16:06:01 UTC

Severity: normal

To reply to this bug, email your comments to 39954 AT debbugs.gnu.org.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guile <at> gnu.org:
bug#39954; Package guile. (Fri, 06 Mar 2020 16:06:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Ludovic Courtès <ludo <at> gnu.org>:
New bug report received and forwarded. Copy sent to bug-guile <at> gnu.org. (Fri, 06 Mar 2020 16:06:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: bug-guile <at> gnu.org
Subject: [3.0.0] ‘frame-local-ref’ returns (SCM)0x0
Date: Fri, 06 Mar 2020 17:05:04 +0100
The example below leads to a Guile 3.0.0 segfault while trying to
display a backtrace from the evaluator:

--8<---------------cut here---------------start------------->8---
$ cat ~/src/guile-debugging/scm_is_values-abort.scm
(use-modules (ice-9 time))

(time (ash 1 #;(expt 2 82) 4835703278458516698824704))
$ guile ~/src/guile-debugging/scm_is_values-abort.scm
;;; note: auto-compilation is enabled, set GUILE_AUTO_COMPILE=0
;;;       or pass the --no-auto-compile argument to disable.
;;; compiling /home/ludo/src/guile-debugging/scm_is_values-abort.scm
;;; WARNING: compilation of /home/ludo/src/guile-debugging/scm_is_values-abort.scm failed:
;;; In procedure bytevector-u32-native-set!: Argument 3 out of range: 1125899906842624
Backtrace:
           3 (primitive-load "/home/ludo/src/guile-debugging/scm_is_values-abort.scm")
In ice-9/time.scm:
    38:18  2 (time-proc #<procedure 7faa1889c2c0 at ice-9/eval.scm:330:13 ()>)
In unknown file:
Adres-eraro(nekropsio elŝutita)
$ gdb $(which guile) core

[...]

Core was generated by `guile /home/ludo/src/guile-debugging/scm_is_values-abort.scm'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0  0x00007faa1d3e4d74 in scm_is_values (x=0x0) at values.h:30
30	values.h: Dosiero aŭ dosierujo ne ekzistas.
[Current thread is 1 (Thread 0x7faa1ccf9b80 (LWP 9971))]
ERROR: In procedure type-pointer:
ERROR: In procedure gdbscm_type_pointer: Wrong type argument in position 1 (expecting gdb:type): #f
Error while executing Scheme code.(gdb) bt
#0  0x00007faa1d3e4d74 in scm_is_values (
    x=<error reading variable: ERROR: Cannot access memory at address 0x0>0x0) at values.h:30
#1  vm_regular_engine (thread=0x7faa1c9d5d80) at vm-engine.c:974
#2  0x00007faa1d3e61a5 in scm_call_n (proc=<optimized out>, argv=argv <at> entry=0x7ffcac33bf40, nargs=nargs <at> entry=4)
    at vm.c:1589
#3  0x00007faa1d3620d4 in scm_call_4 (proc=<optimized out>, arg1=arg1 <at> entry="#<vector>" = {...}, 
    arg2=arg2 <at> entry=#<port #<port-type file 7faa1ac60b40> 7faa1acac3c0>, arg3=arg3 <at> entry=#:count, 
    arg4=arg4 <at> entry=20) at eval.c:517
#4  0x00007faa1d3555f9 in display_backtrace_body (a=<optimized out>) at backtrace.c:239
#5  0x00007faa1d36387a in scm_c_with_exception_handler (type=type <at> entry=#t, 
    handler=handler <at> entry=0x7faa1d3db630 <catch_post_unwind_handler>, 
    handler_data=handler_data <at> entry=0x7ffcac33c0f0, thunk=thunk <at> entry=0x7faa1d3db770 <catch_body>, 
    thunk_data=thunk_data <at> entry=0x7ffcac33c0f0) at exceptions.c:170
#6  0x00007faa1d3db96d in scm_c_catch (tag=tag <at> entry=#t, body=body <at> entry=0x7faa1d3554d0 <display_backtrace_body>, 
    body_data=body_data <at> entry=0x7ffcac33c160, handler=handler <at> entry=0x7faa1d3558b0 <error_during_backtrace>, 
    handler_data=handler_data <at> entry=0x7faa1acac3c0, pre_unwind_handler=pre_unwind_handler <at> entry=0x0, 
    pre_unwind_handler_data=0x0) at throw.c:168
#7  0x00007faa1d3db98e in scm_internal_catch (tag=tag <at> entry=#t, 
    body=body <at> entry=0x7faa1d3554d0 <display_backtrace_body>, body_data=body_data <at> entry=0x7ffcac33c160, 
    handler=handler <at> entry=0x7faa1d3558b0 <error_during_backtrace>, handler_data=handler_data <at> entry=0x7faa1acac3c0)
    at throw.c:177
#8  0x00007faa1d3554c5 in scm_display_backtrace_with_highlights (stack=stack <at> entry="#<struct stack>" = {...}, 
    port=port <at> entry=#<port #<port-type file 7faa1ac60b40> 7faa1acac3c0>, first=first <at> entry=#f, 
    depth=depth <at> entry=#f, highlights=highlights <at> entry=()) at backtrace.c:277
#9  0x00007faa1d35e01f in print_exception_and_backtrace (
    args=(#f "Value out of range ~S to ~S: ~S" (0 #<bignum 7faa188852a0> #<bignum 7faa188852e0>) (#<bignum 7faa188852e0>)), tag=out-of-range, port=#<port #<port-type file 7faa1ac60b40> 7faa1acac3c0>) at continuations.c:409
#10 pre_unwind_handler (error_port=0x7faa1acac3c0, tag=out-of-range, 
    args=(#f "Value out of range ~S to ~S: ~S" (0 #<bignum 7faa188852a0> #<bignum 7faa188852e0>) (#<bignum 7faa188852e0>))) at continuations.c:453
#11 0x00007faa1d3db6eb in catch_pre_unwind_handler (data=0x7ffcac33cb90, 
    exn="#<struct &compound-exception>" = {...}) at throw.c:135
#12 0x00007faa1d3e4d6c in vm_regular_engine (thread=0x7faa1c9d5d80) at vm-engine.c:972
#13 0x00007faa1d3e61a5 in scm_call_n (proc=proc <at> entry=#<unmatched-tag 10045>, argv=<optimized out>, nargs=5)
    at vm.c:1589
#14 0x00007faa1d3623d4 in scm_apply_0 (proc=#<unmatched-tag 10045>, args=()) at eval.c:603
#15 0x00007faa1d36307d in scm_apply_1 (proc=<optimized out>, arg1=arg1 <at> entry=out-of-range, 
    args=args <at> entry=(#f "Value out of range ~S to ~S: ~S" (0 #<bignum 7faa188852a0> #<bignum 7faa188852e0>) (#<bignum 7faa188852e0>))) at eval.c:609
#16 0x00007faa1d3dbb29 in scm_throw (key=key <at> entry=out-of-range, 
    args=(#f "Value out of range ~S to ~S: ~S" (0 #<bignum 7faa188852a0> #<bignum 7faa188852e0>) (#<bignum 7faa188852e0>))) at throw.c:262
#17 0x00007faa1d3dbc79 in scm_ithrow (key=key <at> entry=out-of-range, args=<optimized out>, 
    no_return=no_return <at> entry=1) at throw.c:457
#18 0x00007faa1d360585 in scm_error_scm (key=key <at> entry=out-of-range, subr=<optimized out>, 
    message=message <at> entry="Value out of range ~S to ~S: ~S", 
    args=args <at> entry=(0 #<bignum 7faa188852a0> #<bignum 7faa188852e0>), data=data <at> entry=(#<bignum 7faa188852e0>))
    at error.c:90
#19 0x00007faa1d36061f in scm_error (key=out-of-range, subr=subr <at> entry=0x0, 
    message=message <at> entry=0x7faa1d4010f0 "Value out of range ~S to ~S: ~S", 
    args=(0 #<bignum 7faa188852a0> #<bignum 7faa188852e0>), rest=rest <at> entry=(#<bignum 7faa188852e0>))
    at error.c:62
#20 0x00007faa1d393d87 in scm_i_range_error (bad_val=bad_val <at> entry=#<bignum 7faa188852e0>, min=0, 
    max=max <at> entry=#<bignum 7faa188852a0>) at numbers.c:9764
#21 0x00007faa1d39cd13 in scm_to_uint64 (val=#<bignum 7faa188852e0>) at conv-uinteger.i.c:38
#22 0x00007faa1d3e4882 in vm_regular_engine (thread=0x7faa1c9d5d80) at vm-engine.c:1533
#23 0x00007faa1d3e61a5 in scm_call_n (proc=<optimized out>, argv=argv <at> entry=0x7ffcac33c648, nargs=nargs <at> entry=1)
    at vm.c:1589
#24 0x00007faa1d3631e7 in scm_primitive_eval (exp=<optimized out>) at eval.c:671
#25 0x00007faa1d38c30b in scm_primitive_load (filename=<optimized out>) at load.c:131
#26 0x00007faa1d3e4d6c in vm_regular_engine (thread=0x7faa1c9d5d80) at vm-engine.c:972
#27 0x00007faa1d3e61a5 in scm_call_n (proc=<optimized out>, argv=argv <at> entry=0x7ffcac33c818, nargs=nargs <at> entry=1)
    at vm.c:1589
#28 0x00007faa1d3631e7 in scm_primitive_eval (exp=<optimized out>, 
    exp <at> entry=((@ (ice-9 control) %) (begin ((@@ (ice-9 command-line) load/lang) "/home/ludo/src/guile-debugging/scm_is_values-abort.scm") (quit)))) at eval.c:671
#29 0x00007faa1d363243 in scm_eval (
    exp=((@ (ice-9 control) %) (begin ((@@ (ice-9 command-line) load/lang) "/home/ludo/src/guile-debugging/scm_is_values-abort.scm") (quit))), module_or_state=module_or_state <at> entry="#<struct module>" = {...}) at eval.c:705
#30 0x00007faa1d3bc130 in scm_shell (argc=2, argv=0x7ffcac33ce78) at script.c:357
#31 0x00007faa1d37ab4d in invoke_main_func (body_data=0x7ffcac33cd20) at init.c:308
#32 0x00007faa1d35de3a in c_body (d=0x7ffcac33cc60) at continuations.c:430
#33 0x00007faa1d3e4d6c in vm_regular_engine (thread=0x7faa1c9d5d80) at vm-engine.c:972
#34 0x00007faa1d3e61a5 in scm_call_n (proc=<optimized out>, argv=argv <at> entry=0x7ffcac33ca20, nargs=nargs <at> entry=2)
    at vm.c:1589
#35 0x00007faa1d36207a in scm_call_2 (proc=<optimized out>, arg1=<optimized out>, arg2=<optimized out>)
    at eval.c:503
#36 0x00007faa1d36387a in scm_c_with_exception_handler (type=type <at> entry=#t, 
    handler=handler <at> entry=0x7faa1d3db630 <catch_post_unwind_handler>, 
    handler_data=handler_data <at> entry=0x7ffcac33cb90, thunk=thunk <at> entry=0x7faa1d3db770 <catch_body>, 
    thunk_data=thunk_data <at> entry=0x7ffcac33cb90) at exceptions.c:170
#37 0x00007faa1d3db96d in scm_c_catch (tag=tag <at> entry=#t, body=body <at> entry=0x7faa1d35de30 <c_body>, 
    body_data=body_data <at> entry=0x7ffcac33cc60, handler=handler <at> entry=0x7faa1d35e0d0 <c_handler>, 
    handler_data=handler_data <at> entry=0x7ffcac33cc60, 
    pre_unwind_handler=pre_unwind_handler <at> entry=0x7faa1d35df30 <pre_unwind_handler>, 
    pre_unwind_handler_data=0x7faa1acac3c0) at throw.c:168
#38 0x00007faa1d35e3e3 in scm_i_with_continuation_barrier (body=body <at> entry=0x7faa1d35de30 <c_body>, 
    body_data=body_data <at> entry=0x7ffcac33cc60, handler=handler <at> entry=0x7faa1d35e0d0 <c_handler>, 
    handler_data=handler_data <at> entry=0x7ffcac33cc60, 
    pre_unwind_handler=pre_unwind_handler <at> entry=0x7faa1d35df30 <pre_unwind_handler>, 
    pre_unwind_handler_data=0x7faa1acac3c0) at continuations.c:368
#39 0x00007faa1d35e475 in scm_c_with_continuation_barrier (func=<optimized out>, data=<optimized out>)
    at continuations.c:464
#40 0x00007faa1d3da40f in with_guile (base=0x7ffcac33ccc8, data=0x7ffcac33ccf0) at threads.c:645
#41 0x00007faa1d2bfa68 in GC_call_with_stack_base ()
   from /gnu/store/3xs3dnc28p9fi8in7hkfcdx20incrdvq-libgc-7.6.12/lib/libgc.so.1
#42 0x00007faa1d3da728 in scm_i_with_guile (dynamic_state=<optimized out>, data=data <at> entry=0x7ffcac33ccf0, 
    func=func <at> entry=0x7faa1d37ab30 <invoke_main_func>) at threads.c:688
#43 scm_with_guile (func=func <at> entry=0x7faa1d37ab30 <invoke_main_func>, data=data <at> entry=0x7ffcac33cd20)
    at threads.c:694
#44 0x00007faa1d37acc2 in scm_boot_guile (argc=argc <at> entry=2, argv=argv <at> entry=0x7ffcac33ce78, 
    main_func=main_func <at> entry=0x401240 <inner_main>, closure=closure <at> entry=0x0) at init.c:291
#45 0x0000000000401100 in main (argc=2, argv=0x7ffcac33ce78) at guile.c:95
--8<---------------cut here---------------end--------------->8---

I traced it to ‘frame-call-representation’ calling ‘frame-local-ref’ via
‘application-arguments’, and getting (SCM)0x0 from there.

Ludo’.

PS: The ‘ash’ example is taken from <https://issues.guix.gnu.org/issue/39947>.




Information forwarded to bug-guile <at> gnu.org:
bug#39954; Package guile. (Sat, 21 Mar 2020 17:58:01 GMT) Full text and rfc822 format available.

Message #8 received at 39954 <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: 39954 <at> debbugs.gnu.org
Subject: Re: bug#39954: [3.0.0] ‘frame-local-ref’ returns (SCM)0x0
Date: Sat, 21 Mar 2020 18:57:14 +0100
More generally, it seems that ‘frame-local-ref’ gets it wrong anytime it
sees a stack frame for a subr.

Ludo’.




Information forwarded to bug-guile <at> gnu.org:
bug#39954; Package guile. (Sat, 21 Aug 2021 18:31:02 GMT) Full text and rfc822 format available.

Message #11 received at 39954 <at> debbugs.gnu.org (full text, mbox):

From: Maxime Devos <maximedevos <at> telenet.be>
To: 50153 <at> debbugs.gnu.org, 39954 <at> debbugs.gnu.org
Subject: Re: bug#50153: Acknowledgement (call-with-values outside tail
 position + backtrace + compilation causes segfault)
Date: Sat, 21 Aug 2021 20:30:25 +0200
[Message part 1 (text/plain, inline)]
This looks rather similar to 39954 <at> debbugs.gnu.org,
looking at the backtrace from GDB, maybe the cause is the same?

Thread 1 "guile" received signal SIGSEGV, Segmentation fault.
0x00007ffff7f40f3f in scm_is_values (x=<optimized out>) at values.h:30
30	  return SCM_HAS_TYP7 (x, scm_tc7_values);
(gdb) bt
#0  0x00007ffff7f40f3f in scm_is_values (x=<optimized out>) at values.h:30
#1  vm_debug_engine (thread=0x7ffff744cd80) at vm-engine.c:974
#2  0x00007ffff7f45c2d in scm_call_n (proc=0x7ffff49612a0, argv=argv <at> entry=0x7fffffffc080, 
    nargs=nargs <at> entry=4) at vm.c:1608
#3  0x00007ffff7ec1234 in scm_call_4 (proc=<optimized out>, arg1=arg1 <at> entry=0x7ffff35162d0, 
    arg2=arg2 <at> entry=0x7ffff5ad4600, arg3=arg3 <at> entry=0x7ffff495a0b0, arg4=arg4 <at> entry=0x52) at eval.c:517
#4  0x00007ffff7eb3815 in display_backtrace_body (a=<optimized out>) at backtrace.c:239
#5  0x00007ffff7ec29ea in scm_c_with_exception_handler (type=type <at> entry=0x404, 
    handler=handler <at> entry=0x7ffff7f3aed0 <catch_post_unwind_handler>, 
    handler_data=handler_data <at> entry=0x7fffffffc230, thunk=thunk <at> entry=0x7ffff7f3b010 <catch_body>, 
    thunk_data=thunk_data <at> entry=0x7fffffffc230) at exceptions.c:170
#6  0x00007ffff7f3b20d in scm_c_catch (tag=tag <at> entry=0x404, 
    body=body <at> entry=0x7ffff7eb36f0 <display_backtrace_body>, body_data=body_data <at> entry=0x7fffffffc2a0, 
    handler=handler <at> entry=0x7ffff7eb3b20 <error_during_backtrace>, 
    handler_data=handler_data <at> entry=0x7ffff5ad4600, pre_unwind_handler=pre_unwind_handler <at> entry=0x0, 
    pre_unwind_handler_data=0x0) at throw.c:168
#7  0x00007ffff7f3b22e in scm_internal_catch (tag=tag <at> entry=0x404, 
    body=body <at> entry=0x7ffff7eb36f0 <display_backtrace_body>, body_data=body_data <at> entry=0x7fffffffc2a0, 
    handler=handler <at> entry=0x7ffff7eb3b20 <error_during_backtrace>, 
    handler_data=handler_data <at> entry=0x7ffff5ad4600) at throw.c:177
#8  0x00007ffff7eb36e5 in scm_display_backtrace_with_highlights (stack=stack <at> entry=0x7ffff38604a0, 
    port=port <at> entry=0x7ffff5ad4600, first=first <at> entry=0x4, depth=depth <at> entry=0x4, 
    highlights=highlights <at> entry=0x304) at backtrace.c:277
#9  0x00007ffff7eb3970 in scm_backtrace_with_highlights (highlights=0x304) at backtrace.c:310
#10 0x00007ffff7f40f3b in vm_debug_engine (thread=0x7ffff744cd80) at vm-engine.c:972
#11 0x00007ffff7f45c2d in scm_call_n (proc=0x7ffff5a2e030, argv=argv <at> entry=0x7fffffffc498, 
    nargs=nargs <at> entry=1) at vm.c:1608
#12 0x00007ffff7ec2337 in scm_primitive_eval (exp=<optimized out>, exp <at> entry=0x7ffff5ba1a40)
    at eval.c:671
#13 0x00007ffff7ec2393 in scm_eval (exp=0x7ffff5ba1a40, 
    module_or_state=module_or_state <at> entry=0x7ffff5b93c80) at eval.c:705
#14 0x00007ffff7f1b780 in scm_shell (argc=4, argv=0x7fffffffcb08) at script.c:357
#15 0x00007ffff7edb1bd in invoke_main_func (body_data=0x7fffffffc9a0) at init.c:313
#16 0x00007ffff7ebc06a in c_body (d=0x7fffffffc8e0) at continuations.c:430
#17 0x00007ffff7f447d8 in vm_regular_engine (thread=0x7ffff744cd80) at vm-engine.c:972
#18 0x00007ffff7f45c2d in scm_call_n (proc=0x7ffff5b088a0, argv=argv <at> entry=0x7fffffffc6a0, 
    nargs=nargs <at> entry=2) at vm.c:1608
#19 0x00007ffff7ec11da in scm_call_2 (proc=<optimized out>, arg1=<optimized out>, arg2=<optimized out>)
    at eval.c:503
#20 0x00007ffff7ec29ea in scm_c_with_exception_handler (type=type <at> entry=0x404, 
    handler=handler <at> entry=0x7ffff7f3aed0 <catch_post_unwind_handler>, 
    handler_data=handler_data <at> entry=0x7fffffffc810, thunk=thunk <at> entry=0x7ffff7f3b010 <catch_body>, 
    thunk_data=thunk_data <at> entry=0x7fffffffc810) at exceptions.c:170
#21 0x00007ffff7f3b20d in scm_c_catch (tag=tag <at> entry=0x404, body=body <at> entry=0x7ffff7ebc060 <c_body>, 
    body_data=body_data <at> entry=0x7fffffffc8e0, handler=handler <at> entry=0x7ffff7ebc300 <c_handler>, 
    handler_data=handler_data <at> entry=0x7fffffffc8e0, 
    pre_unwind_handler=pre_unwind_handler <at> entry=0x7ffff7ebc160 <pre_unwind_handler>, 
    pre_unwind_handler_data=0x7ffff5ad45c0) at throw.c:168
#22 0x00007ffff7ebc603 in scm_i_with_continuation_barrier (body=body <at> entry=0x7ffff7ebc060 <c_body>, 
    body_data=body_data <at> entry=0x7fffffffc8e0, handler=handler <at> entry=0x7ffff7ebc300 <c_handler>, 
    handler_data=handler_data <at> entry=0x7fffffffc8e0, 
    pre_unwind_handler=pre_unwind_handler <at> entry=0x7ffff7ebc160 <pre_unwind_handler>, 
--Type <RET> for more, q to quit, c to continue without paging--c
    pre_unwind_handler_data=0x7ffff5ad45c0) at continuations.c:368
#23 0x00007ffff7ebc695 in scm_c_with_continuation_barrier (func=<optimized out>, data=<optimized out>) at continuations.c:464
#24 0x00007ffff7f39c9f in with_guile (base=0x7fffffffc948, data=0x7fffffffc970) at threads.c:645
#25 0x00007ffff7e16b48 in GC_call_with_stack_base () from /gnu/store/f6kngpp27585xh4564y9rvshqn8hph8v-libgc-8.0.4/lib/libgc.so.1
#26 0x00007ffff7f39fc8 in scm_i_with_guile (dynamic_state=<optimized out>, data=data <at> entry=0x7fffffffc970, func=func <at> entry=0x7ffff7edb1a0 <invoke_main_func>) at threads.c:688
#27 scm_with_guile (func=func <at> entry=0x7ffff7edb1a0 <invoke_main_func>, data=data <at> entry=0x7fffffffc9a0) at threads.c:694
#28 0x00007ffff7edb332 in scm_boot_guile (argc=argc <at> entry=4, argv=argv <at> entry=0x7fffffffcb08, main_func=main_func <at> entry=0x401230 <inner_main>, closure=closure <at> entry=0x0) at init.c:296
#29 0x00000000004010f6 in main (argc=4, argv=0x7fffffffcb08) at guile.c:94
[signature.asc (application/pgp-signature, inline)]

Information forwarded to bug-guile <at> gnu.org:
bug#39954; Package guile. (Sun, 22 Aug 2021 09:36:01 GMT) Full text and rfc822 format available.

Message #14 received at 39954 <at> debbugs.gnu.org (full text, mbox):

From: Maxime Devos <maximedevos <at> telenet.be>
To: 50153 <at> debbugs.gnu.org, 39954 <at> debbugs.gnu.org
Subject: Re: bug#50153: Acknowledgement (call-with-values outside tail
 position + backtrace + compilation causes segfault)
Date: Sat, 21 Aug 2021 22:17:56 +0200
[Message part 1 (text/plain, inline)]
I did some debugging on the C side, using 'rr':

LD_LIBRARY_PATH=.libs ../meta/uninstalled-env rr record ./.libs/guile --fresh-auto-compile -l ../crash.scm

it leads to a segfault, as expected.  According to #39954, which looks
similar, 'frame-local-ref' returns (SCM)0x0.  So I tried some reverse debugging:

rr replay guile-3
break scm_frame_local_ref
reverse-continue
reverse-continue

I noticed "repr" was STACK_ITEM_SCM, and item->as_scm was set to 0x07
(which is invalid).  On another run, it was set to 0x09 (also invalid?).
I modified scm_frame_local_ref a bit so it ignores these 0x07 and 0x09
and treats them like SCM_EOF_VAL instead.  That allows printing the backtrace,
though I don't see those #<eof> appearing in the output.

Would someone know what's going on here?

Greetings,
Maxime
[printf.patch (text/x-patch, inline)]
diff --git a/libguile/frames.c b/libguile/frames.c
index 0bb40579c..87afaec3d 100644
--- a/libguile/frames.c
+++ b/libguile/frames.c
@@ -41,6 +41,7 @@
 
 #include "frames.h"
 
+#include <stdio.h>
 
 SCM
 scm_c_make_frame (enum scm_vm_frame_kind kind, const struct scm_frame *frame)
@@ -272,6 +273,11 @@ scm_frame_local_ref (SCM frame, SCM index, SCM representation)
       switch (repr)
         {
           case STACK_ITEM_SCM:
+            fprintf(stderr, "i: %u  SCM: %p\n", (unsigned) i, (void*)item->as_u64);
+            if (item->as_u64 == 0x07)
+              return SCM_EOF_VAL;
+            if (item->as_u64 == 0x09)
+              return SCM_EOF_VAL;
             return item->as_scm;
           case STACK_ITEM_F64:
             return scm_from_double (item->as_f64);
[signature.asc (application/pgp-signature, inline)]

This bug report was last modified 3 years and 129 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.