\msg_new:nnnn
  { foo }
  { bar }
  { #5~#6 }  % two errors on this line
  { #6~#7 }  % two errors on this line
