Silence parser warnings about integer division

For use in brms, I want to implement the following Stan code:

for (k in 1:nresp) {
  for (j in 1:(k - 1)) {
    cor[(k - 1) * (k - 2) / 2 + j] = Cor[j, k];
  }
}

to extract the elements of a matrix above the diagonal.

Not surprisingly, this triggers warnings about integer division.
I know that the integer division will be valid in this case and want to silence the parser
about this issue. Is there any way to achieve this or to extract the
upper diagonal elements of a matrix in any other way?

cor[choose(k - 1, 2) + j] = Cor[j,k];

Thanks a lot Ben!