[Lldb-commits] [PATCH] D48479: Represent invalid UUIDs as UUIDs with length zero

Leonard Mosescu via Phabricator via lldb-commits lldb-commits at lists.llvm.org
Fri Jun 22 12:54:27 PDT 2018


lemo added a comment.

> I'm not sure if there is a suitable place for that function. This is
>  needed in  "ObjectFileMachO" and two dynamic loader plugins.

Then your factory idea may be the next best thing. While we're at it, maybe
we can remove the UUID::SetBytes() from the public interface, and make the
UUID an immutable value type:

Ex. instead of:

UUID uuid;
...
uuid.SetBytes(...)

We'd have:

UUID uuid;

uuid = UUID(...);
// or
uuid = { ... };
// or
uuid = UUID::factory(...);

What do you think?


https://reviews.llvm.org/D48479





More information about the lldb-commits mailing list