/[ascend]/trunk/base/generic/compiler/relation.c
ViewVC logotype

Diff of /trunk/base/generic/compiler/relation.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 730 by johnpye, Mon Jul 3 11:52:45 2006 UTC revision 731 by johnpye, Tue Jul 4 07:42:06 2006 UTC
# Line 2066  struct relation *CreateRelationStructure Line 2066  struct relation *CreateRelationStructure
2066    
2067    newrelation = ASC_NEW(struct relation);    newrelation = ASC_NEW(struct relation);
2068    assert(newrelation!=NULL);    assert(newrelation!=NULL);
2069    CONSOLE_DEBUG("Created 'struct relation' at %p",newrelation);    /* CONSOLE_DEBUG("Created 'struct relation' at %p",newrelation); */
2070    
2071    newrelation->residual = DBL_MAX;    newrelation->residual = DBL_MAX;
2072    newrelation->multiplier = DBL_MAX;    newrelation->multiplier = DBL_MAX;
# Line 2140  struct relation *CreateBlackBoxRelation( Line 2140  struct relation *CreateBlackBoxRelation(
2140    unsigned long c,len,pos;    unsigned long c,len,pos;
2141    unsigned long n_inputs;    unsigned long n_inputs;
2142    
2143    CONSOLE_DEBUG("CREATING BLACK BOX RELATION");    /* CONSOLE_DEBUG("CREATING BLACK BOX RELATION"); */
2144    
2145    n_inputs = gl_length(inputs);    n_inputs = gl_length(inputs);
2146    len = n_inputs + 1; /* an extra for the output variable. */    len = n_inputs + 1; /* an extra for the output variable. */
# Line 2156  struct relation *CreateBlackBoxRelation( Line 2156  struct relation *CreateBlackBoxRelation(
2156    
2157    for (c=1;c<=n_inputs;c++) {    for (c=1;c<=n_inputs;c++) {
2158      var = (struct Instance *)gl_fetch(inputs,c);      var = (struct Instance *)gl_fetch(inputs,c);
2159      CONSOLE_DEBUG("ADDING INPUT '%p' TO INCIDENCE",var);      /* CONSOLE_DEBUG("ADDING INPUT '%p' TO INCIDENCE",var); */
2160    
2161      pos = gl_search(newlist,var,(CmpFunc)CmpP);      pos = gl_search(newlist,var,(CmpFunc)CmpP);
2162      if (pos) {      if (pos) {
# Line 2176  struct relation *CreateBlackBoxRelation( Line 2176  struct relation *CreateBlackBoxRelation(
2176      I think that this means the output  variable. -- JP      I think that this means the output  variable. -- JP
2177    */    */
2178    pos = gl_search(newlist,subject,(CmpFunc)CmpP);    pos = gl_search(newlist,subject,(CmpFunc)CmpP);
2179    CONSOLE_DEBUG("ADDING OUTPUT INSTACE %p TO INCIDENCE",subject);    /* CONSOLE_DEBUG("ADDING OUTPUT INSTANCE %p TO INCIDENCE",subject); */
2180    if(pos){    if(pos){
2181      FPRINTF(ASCERR,"An input and output variable are the same !!\n");      FPRINTF(ASCERR,"An input and output variable are the same !!\n");
2182      *args++ = (int)pos;      *args++ = (int)pos;

Legend:
Removed from v.730  
changed lines
  Added in v.731

john.pye@anu.edu.au
ViewVC Help
Powered by ViewVC 1.1.22