public functions can now be passed as arguments, with the tag 'Function:'
--HG-- branch : dvander extra : convert_revision : svn%3A39bc706e-5318-0410-9160-8a85361fbb7c/branches/dvander%4015
This commit is contained in:
		
							parent
							
								
									3f8c9a83ad
								
							
						
					
					
						commit
						9cd64d946c
					
				@ -1670,13 +1670,29 @@ restart:
 | 
				
			|||||||
    if (sc_allowproccall) {
 | 
					    if (sc_allowproccall) {
 | 
				
			||||||
      callfunction(sym,lval1,FALSE);
 | 
					      callfunction(sym,lval1,FALSE);
 | 
				
			||||||
    } else {
 | 
					    } else {
 | 
				
			||||||
      lval1->sym=NULL;
 | 
					      int n=-1,iter=0;
 | 
				
			||||||
      lval1->ident=iEXPRESSION;
 | 
					      for (sym=glbtab.next; sym!=NULL; sym=sym->next) {
 | 
				
			||||||
      lval1->constval=0;
 | 
					        if (sym->ident==iFUNCTN
 | 
				
			||||||
      lval1->tag=0;
 | 
					            && (sym->usage & uPUBLIC)!=0 && (sym->usage & uDEFINE)!=0)
 | 
				
			||||||
      error(76);                /* invalid function call, or syntax error */
 | 
					        {
 | 
				
			||||||
    } /* if */
 | 
					          assert(sym->vclass==sGLOBAL);
 | 
				
			||||||
    return FALSE;
 | 
					          if (strcmp(sym->name, lval1->sym->name)==0) {
 | 
				
			||||||
 | 
					            n = iter;
 | 
				
			||||||
 | 
					            break;
 | 
				
			||||||
 | 
					          }
 | 
				
			||||||
 | 
					          iter++;
 | 
				
			||||||
 | 
					        }
 | 
				
			||||||
 | 
					      }
 | 
				
			||||||
 | 
					      if (n!=-1) {
 | 
				
			||||||
 | 
					        lval1->sym=NULL;
 | 
				
			||||||
 | 
					        lval1->ident=iCONSTEXPR;
 | 
				
			||||||
 | 
					        lval1->constval=n;
 | 
				
			||||||
 | 
					        lval1->tag=pc_addtag("Function");
 | 
				
			||||||
 | 
					      } else {
 | 
				
			||||||
 | 
					        error(76);                /* invalid function call, or syntax error */
 | 
				
			||||||
 | 
					      } /* if */
 | 
				
			||||||
 | 
					      return FALSE;
 | 
				
			||||||
 | 
					    }
 | 
				
			||||||
  } /* if */
 | 
					  } /* if */
 | 
				
			||||||
  return lvalue;
 | 
					  return lvalue;
 | 
				
			||||||
}
 | 
					}
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
		Reference in New Issue
	
	Block a user