Passing integer by reference in extension
Posted: 07 Mar 2011, 18:36
Hello,
I'm working on an extension and want to pass an integer argument by reference. I tried the following perl-glue code:
Neither "$" nor "$&" or anything else I tried has worked. Can you help me here?
The function signature is as follows:
Thank you!
Matthias Walter
I'm working on an extension and want to pass an integer argument by reference. I tried the following perl-glue code:
Code: Select all
UserFunction4perl("# Tests a given //matrix// for k-modularity, without certificates. It also computes k."
"# @param Matrix<int> matrix"
"# @param int& k"
"# @return Bool",
&is_k_modular_compute,"is_k_modular(Matrix<Integer>, $&)");
The function signature is as follows:
Code: Select all
bool is_k_modular_compute(const Matrix <Integer>& matrix, int& ko)
Matthias Walter