Syntax in a loop

Hello all !

I have a small practical question.

For example if I want to replace something like this:

mesh Th=square(2,2);

fespace Vh1(Th, P1);
fespace Vh0(Th, P0);

func w1=1;
func w2=x;
func w3=y;

varf vL1(u,uu) = int2d(Th)(u*w1*uu);
varf vL2(u,uu) = int2d(Th)(u*w2*uu);
varf vL3(u,uu) = int2d(Th)(u*w3*uu);

matrix MatL1 = vL1(Vh0,Vh1);
matrix MatL2 = vL2(Vh0,Vh1);
matrix MatL3 = vL3(Vh0,Vh1);

By a loop as:

for (int k=1; k<4; k++){
  varf vLk(u,uu) = int2d(Th)(u*wk*uu);
  matrix MatLk = vLk(Vh0,Vh1);}

What is the syntax to do this ?
(I have tried several things, but it does not work)

Thank you in advance,

Best regards,

Loïc,

macro MyVarf(i) varf vL#i(u, uu) = int2d(Th)(u*w#i’*uu);