Quantum-Entanglement

 view release on metacpan or  search on metacpan

Entanglement.pm  view on Meta::CPAN

  "; croak "$0: something wrong in p_op $@" if $@;

  return binop($arg1, $arg2, $r, $tcref);
}

# allows for other functions to be performed accross states, can take
# as many entangled variables as you like...
# can take code ref, or "symbolic" function name (eg. p_func('substr', ..))
sub p_func {
  my $func = shift;
  my $package = (caller)[0];
  # build up the function call by shifting off
  # entangled variables until something isn't entangled
  my $foo = ref($func) ? "&\$func(" : "$func(";
  my @temp = @_;
  my $first = $temp[0];
  do {
    my $c = shift @temp;
    _join($first,$c);
  } while (ref($temp[0]) && UNIVERSAL::isa($temp[0],'Quantum::Entanglement'));
  my @p_codes = ();



( run in 1.722 second using v1.01-cache-2.11-cpan-a3c8064c92c )