Closed haijinSk closed 2 months ago
I can't replicate this one.
$ git clone ... && cd trealla $ make $ tpl -v Trealla Prolog (c) Infradig 2020-2023, v2.50.21
$ tpl
?- use_module(library(clpz)).
true.
?- 4 #= 4 #<==> #B.
free(): corrupted unsorted chunks
Aborted (core dumped)
$ tpl
?- use_module(library(clpz)).
true.
?- 4 #= 4 #<==> B.
B = 1.
?- X #= 4 #<==> B.
free(): invalid pointer
Aborted (core dumped)
I get other core-dump messages.
Yeah, my bad.
On Sun, Apr 14, 2024 at 9:13 AM flexoron @.***> wrote:
$ git clone ... && cd trealla $ make $ tpl -v Trealla Prolog (c) Infradig 2020-2023, v2.50.21
$ tpl ?- use_module(library(clpz)). true. ?- 4 #= 4 #<==> #B. free(): corrupted unsorted chunks Aborted (core dumped)
$ tpl ?- use_module(library(clpz)). true. ?- 4 #= 4 #<==> B. B = 1.
?- X #= 4 #<==> B. free(): invalid pointer Aborted (core dumped)
I get other core-dump messages.
— Reply to this email directly, view it on GitHub https://github.com/trealla-prolog/trealla/issues/522#issuecomment-2053791759, or unsubscribe https://github.com/notifications/unsubscribe-auth/AFNKSESSZZLY5GX4MMTY5ITY5G32TAVCNFSM6AAAAABGFRGW4KVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDANJTG44TCNZVHE . You are receiving this because you commented.Message ID: @.***>
I thought, my hope was, that if the (#<==>)/2
examples will work, the (#=)/3
and (#<)/3
will work, not crashing. Now, in v2.50.23b, my (#<==>)/2
examples here work. Now (v2.50.23b), the (#=)/3
and (#<)/3
work, thank you; unfortunately they work only in isolation.
Used in tfilter/3
from reif library, or in maplist/3
, they are still crashing.
In isolation as expected:
?- #=(1,1,B).
B = true.
?- #<(1,2,B).
B = true.
But crashing if used in the metapredicate:
?- maplist(#=(3),[1,2,3],Bs).
realloc(): invalid next size
Aborted (core dumped)
?- maplist(#<(3),[1,2,3],Bs).
realloc(): invalid next size
Aborted (core dumped)
Ok, great, that's really useful. It seems somewhere in atts it's expanding the slots improperly.
On Sun, Apr 14, 2024 at 6:06 PM Peter @.***> wrote:
I thought, my hope was, that if the (#<==>)/2 examples will work, the (
=)/3 and (#<)/3 will work, not crashing. Now, in v2.50.23b my #<==>/2
examples here work. The #=/3 and #</3 work, thank you; unfortunately they work only in isolation.
But as a predicate of metapredicate, with tfilter/3 from reif library, or with maplist/3 they are still crashing.
In isolation as expected:
?- #=(1,1,B). B = true. ?- #<(1,2,B). B = true.
But crashing if used in a metapredicate:
?- maplist(#=(3),[1,2,3],Bs). realloc(): invalid next size Aborted (core dumped)
?- maplist(#<(3),[1,2,3],Bs). realloc(): invalid next size Aborted (core dumped)
— Reply to this email directly, view it on GitHub https://github.com/trealla-prolog/trealla/issues/522#issuecomment-2053956109, or unsubscribe https://github.com/notifications/unsubscribe-auth/AFNKSERYFK554WFJAZOWFYTY5I2IRAVCNFSM6AAAAABGFRGW4KVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDANJTHE2TMMJQHE . You are receiving this because you commented.Message ID: @.***>
v2.50.26, no crash, the examples work; thank you!
On Ubuntu using a binary release version "v2.50.20" (not the first release/version with this behavior).
Examples with clpz library already loaded.
Crashing:
By the way, no crash if
#
is removed from the#B
:But the "removed #" case is crashing with a variable in the left expression:
Thank you.