Reference to "This Entity" undefined in formula

I have recursive hierarchy and want to show the root entity. As maybe in

If(
  IsEmpty([Parent Module]),
  [This Module],
  [Parent Module].Root
)

but [This Module] does not work to begin with. What am I doing wrong?

There is no such use of [This Module] in formulas

It can only be used within a filter function, e.g. Tasks.Filter(Effort > [This Module].Score)

As a work around is to add a relation with autolinking based on public ID. Then the relation will just return its own entity. Can be a one to one. It’s a bit weird because it makes two relations that are identical, but it works!