sqlparser/cobol.cpp
// Convert previously declared variable or parameter
Convert previously declared variable or parameter
Convert previously declared variable or parameter
Token* Cobol::ConvertDeclaredIdentifier(Token *name)
{
	if(name == NULL)
		return NULL;
	Token *var = _sqlparser->GetVariable(name);
	if(var != NULL && var->t_len != 0)
		_sqlparser->ConvertVariableIdentifier(name, var);
	Token *param = NULL;
	if(var == NULL)
		param = _sqlparser->GetParameter(name);
	if(param != NULL && param->t_len != 0)
		_sqlparser->ConvertParameterIdentifier(name, param);
	return name;
}
Token * Cobol :: ConvertDeclaredIdentifier ( Token * name ) { if ( name == NULL ) return NULL ; Token * var = _sqlparser -> GetVariable ( name ) ; if ( var != NULL && var -> t_len != 0 ) _sqlparser -> ConvertVariableIdentifier ( name , var ) ; Token * param = NULL ; if ( var == NULL ) param = _sqlparser -> GetParameter ( name ) ; if ( param != NULL && param -> t_len != 0 ) _sqlparser -> ConvertParameterIdentifier ( name , param ) ; return name ; }
Convert previously declared variable or parameter
Convert previously declared variable or parameter
// Check if a variable exists with this name // Change only if it was changed at the declaration // Check if a parameter exists with this name // Change only if it was changed at the declaration