RFC: Form binding with signals

I will go through the questions later. but could you please stop using this syntax:

add(new TextField() {{
  bindValue(text);
}});

This is very uncommon in Java, and even I, as a Java veteran, have to think twice about what happens here. And what’s happening is not good.

  1. It creates a hidden subclass
  2. Allocates a synthetic reference to the outer class (possible memory leak)

And finally, it’s tough to read, not to mention how to debug this.

1 Like