Closed
Description
opened on Aug 19, 2021
Consider the following piece of code:
myfunc1 := function( )
Display( ValueOption( "myopt" ) );
return 1;
end;
myfunc2 := function( )
return IdFunc( myfunc1( ) : myopt := "myopt_value" );
end;
x := myfunc2( );
x := IdFunc( myfunc1( ) : myopt := "myopt_value" );
Observed behaviour
The output is:
myopt_value
fail
Expected behaviour
I would expect the output to be
fail
fail
(or at least the same output in both lines) because I do not see a reason why the option should propagate into the call of myfunc1
in the first case but not in the second.
Copy and paste GAP banner (to tell us about your setup)
┌───────┐ GAP 4.12dev-1020-g1fe30f7 built on 2021-08-19 10:21:04+0200
│ GAP │ https://www.gap-system.org
└───────┘ Architecture: x86_64-pc-linux-gnu-default64-kv8
Configuration: gmp 6.2.1, GASMAN, readline
Loading the library and packages ...
Packages: Browse 1.8.9, GAPDoc 1.dev, IO 4.7.0dev, PrimGrp 3.4.0, SmallGrp 1.4.1, TransGrp 2.0.5
Try '??help' for help. See also '?copyright', '?cite' and '?authors'
Also happens with GAP 4.11.1.
Metadata
Assignees
Labels
No labels
Activity