Welcome to the Sonar Community forum and thank you for reporting this issue.
I had a go with reproducing it but I can’t observe the described behaviour. To help us investigate this, could you please provide logs from SonarLint output (See this page for how to do it) and a list of enabled extensions in your VSCode?