<H1>Peter's Patch to Sean's Patched <i>lil-gp</i><ahref="http://www.cs.umd.edu/users/seanl/patched-gp/gp.tar.gz">Kernel</a></h1>
<p><ahref="http://www.daimi.aau.dk/~ptr/">Peter Anderson</a> noted the following bug in the ERC facility. I've not yet verified that this bug exists or that the patch works, so you're own your own. I include his message to me below:
<pre>
Use of ERC terminal on the form "name:ERCindex" do not work.
The ECR terminal nodes are not constructed.
The first call to "mod_read_tree_recurse"
eind with the ERC structure is NULL, and the call to
"get_function_by_name" core dump on a I:1 structure.
I have modified the function "mod_read_tree_recurse" in populate.c so
the user can use ERC integer constant. By supplying a function to
insert the constant in the DATATYPE structure. The chances are as followed.
in the files:
populate.c
ckpoint.c
a) "get_function_by_name" in ckpoint.c is made safe by changing:
*ep = eind[j];
(*ep)->f = fs->cset+i;
change to:
if (eind != NULL) {
*ep = eind[j];
(*ep)->f = fs->cset+i;
}
b) "mod_read_tree_recurs" catch the ERCindex before the call to
"get_function_by_name"
f = get_function_by_name ( tree, string, &ep, eind );
chance to:
sl = strlen ( string );
for ( si = 0; si <sl;++si)
{
if ( string[si] == ':' )
{
/* names of the form "name:index" are chopped at the colon,
and the value of the index saved. */
string[si] = 0;
ECRvalue = atoi ( string+si+1 );
break;
}
}
f = get_function_by_name ( tree, string, &ep, eind );