Cannot set Thread Name

Hi,
in Island/Windows setting a Thread Name Property doesn’t function…

namespace Unbenannt;

interface

type
  Program = assembly static class
  public
    class method Main(args:array of String);
  end;

implementation

class method Program.Main(args:array of String);
var t:Thread;
begin
 t:=new Thread(nil);
 t.Name:='TestThread';
 writeln(t.Name);
 readln;
end;

end.

Seems that Thread.set_Name has a wrong start (value ↔ Name)

method Thread.set_Name(value: String);
begin
if not String.IsNullOrEmpty(Name) or (Name.Trim.Length <> 0) then begin

While awkward and unnecessarily complex, this check should still be valid (fixed). The problem is that it never updates fName, which is where writeln(t.Name); reds it from.

I’m not sure if the best option is set fName, or (better) to read the thread’s name when getting it, as to not miss if some external ting changes its name… Either way, we’ll fix that part.

I also think set_Name is implemented incorrectly, to set the name of the current thread, not the one referenced. I’ll review that too.