What is the semantic of Domain.self()?

Note that if you have to look at the runtime implementation this means that you are starting to rely on internal implementation details with no guarantees of backward stability.

In other words, you should consider that the domain ids are opaque identifiers that happen to be integers.