增加索引而不在 xtend 上显示其值

Increment index without show its value on xtend

我正在尝试使用 xtend 函数生成一些代码,该函数使用 foor 循环,其变量已增加,问题是变量的值显示在生成的文件中,我如何才能避开它?

def codeGenerate(users u) '''
             «var index = 0»
            «FOR user :u»
                «index +=1» //The problem is here the value of index is printed, how I can incremet the value without printing it?
            «ENDFOR»
            
    '''

不太好,但应该可以解决这个问题:

«{index +=1; null}»