On 10/31/25 15:56, Bruno Haible wrote:
Can we view the 'open_how' structure as the data part of an object
(in the sense of object-oriented programming)? Then openat2 is
one of the methods of this object, and
   fstatat2
   fchmodat2
   mkdirat2
   realpath2 / canonicalize2
would be other methods on it.

Or maybe can the core of openat2 — let's call it a
"filename resolver algorithm" — be abstracted out in a way
that openat2, fstatat2, mkdirat2, etc. make use of it?

Something along these lines could work, I expect. However, a problem with the open_how struct is that it contains a grab-bag of stuff currently designed for openat, and arguably wrong for renameat, mknodat, etc.

Reply via email to