mIRC version 6.35
//tokenize 32 aaaa b | echo -a test: $regsubex($1,/a/g,$2)

The $2 is not evaluated as a replace value which makes it return nothing. It will work by using a %var instead of $N (in which N is a number).

Personally I think the value of $2 should have been converted to the b value before calling the regsubex.