## start octave freshly to trigger the bug

function testfunction ()

  funs.f1 = @ f1;

  funs.f2 = @ f2;

  frec (@ () funs.f1 (funs), 1);

endfunction

function frec (f, v)

  f ();

  ## If the following line is commented out, the bug is not triggered
  ## anymore.
  h = @ __dummy_private_function__;

  if (v == 1)
    printf ("'v' according to printf: '%i', which is wrong,\n but examine the value of 'v' from keyboard now --- it has the correct value '2', which appearantly was not seen by 'if(v==1)'\n", v);
    keyboard ("wrong> ");
  endif

endfunction

function f1 (funs)

  frec (funs.f2, 2);

endfunction

function f2 (funs)


endfunction