#include "db.h"
Go to the source code of this file.
Functions | |
MY_FLOAT | evaluate (const tmpstats *statistics, cache_type *cache, const char **co, int i, int m) |
Main evaluation logic. |
See implementation for details.
MY_FLOAT evaluate | ( | const tmpstats * | stats, | |
cache_type * | cache, | |||
const char ** | co, | |||
int | i, | |||
int | m | |||
) |
Main evaluation logic.
Expressions uses prefix function notation and they are evaluated recursively. Main methods function can be found in file functions.h. This functions mainly parse expression and call appropriate functions. So parsing and logic is somehow divided. But some basic functions not related to the methods are also implemented here (like +, -, *, /, &, |). This is because it's simpler to implement shortcut evaluation here.
References bentr(), bsqrs(), clearblanks(), closing(), dbentr(), dfentr(), evaluate(), fentr(), fillargs, fillonearg, firstarg(), fsqrs(), lalt(), nextarg(), ralt(), skiparg(), sqrs(), trian(), VPRINTF, and VWPRINTF.
Referenced by evaluate(), and find_it_thread().