From 5bc27a128dc5fb6ec65591c0f0632973ce9e8116 Mon Sep 17 00:00:00 2001 From: Behdad Esfahbod Date: Thu, 24 Nov 2022 13:30:12 -0700 Subject: [PATCH] [machinery] Comment --- src/hb-machinery.hh | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/hb-machinery.hh b/src/hb-machinery.hh index 56669b970..5884872e4 100644 --- a/src/hb-machinery.hh +++ b/src/hb-machinery.hh @@ -136,6 +136,13 @@ static inline Type& StructAfter(TObject &X) /* * Lazy loaders. + * + * The lazy-loaders are thread-safe pointer-like objects that create their + * instead on-demand. They also support access to a "data" object that is + * necessary for creating their instance. The data object, if specified, + * is accessed via pointer math, located at a location before the position + * of the loader itself. This avoids having to store a pointer to data + * for every lazy-loader. Multiple lazy-loaders can access the same data. */ template