While setting the tool tip text for a Control, an
ArrayIndexOutOfBoundsException exception is thrown if the text ends with
an ampersand (&) character.
Can you tell me what OS and what version of Eclipse you ran your code on?
I ran your code on WinXP with the latest SWT (from HEAD) and I don't see
the exception.
In any case, you should double up the ampersand if you really want to
display it. Eg. "test &&"