Re: [PATCH 1/5] xfs: convert XFS_IFORK_PTR to a static inline helper

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, Jul 11, 2022 at 06:20:40PM -0700, Darrick J. Wong wrote:
> I personally am not that bothered by shouty function names, but Dave
> has asked for shout-reduction in the past, so every time I convert
> something I also change the case.
> 
> AFAIK it /is/ sort of a C custom that macros get loud names and
> functions do not so that you ALWAYS KNOW, erm, when you're dealing with
> a macro that could rain bad coding conventions down on your head.

It is a bit of a historic custom, but not really followed strictly.
I tend to think of trivial container_of and similar addressing inline
functions just as macros with a saner implementation, and so does a
big part of the kernel community.  Where exactly that border is is not
clear, though.  And in doubt I think avoiding too much churn in changing
things unless there is a clear benefit is a good idea.  So maybe we
would have picked a lower case name for XFS_IFORK_PTR when adding it
new, but i don't really see any benefit in changing it now.

The same is true for some of the other patches later in the series,
except for maybe XFS_IFORK_Q, which has been really grossly and
confusingly misnamed.



[Index of Archives]     [XFS Filesystem Development (older mail)]     [Linux Filesystem Development]     [Linux Audio Users]     [Yosemite Trails]     [Linux Kernel]     [Linux RAID]     [Linux SCSI]


  Powered by Linux