◐ Shell
clean mode source ↗

Tweak Mode broken by // comment at end of code

Running a sketch in Tweak mode throws 'expecting "class", found TweakModeServer ' if the code ends with a // -style comment. A /* */ -style comment does not cause the issue. This issue appears only to be with a // comment at the end of the code.

void setup() {
  size(512, 512);
}

void draw() {
  strokeWeight(20);
} 

// this comment throws 'expecting "class", found TweakModeServer'

Environment: Processing 3.5.4 on macOS 10.15.7.