> On July 29, 2014, 2:35 a.m., Ben Mahler wrote:
> > 3rdparty/libprocess/3rdparty/stout/include/stout/os/setns.hpp, line 49
> > <https://reviews.apache.org/r/20499/diff/4/?file=643983#file643983line49>
> >
> >     For all of these calls to os::ls, why not call the result 'entries', 
> > then each loop can be:
> >     
> >     foreach (entry, entries)
> >     
> >     That should fit with our variable naming conventions as well (avoid 
> > abbreviations, camelCase).
> 
> Dominic Hamon wrote:
>     ns is the only one that I see that is an abbreviation, but it's already 
> an abbreviation in the filename so i don't think this is causing an issue. 
> The others are named such that they describe the list which i think is better 
> than a non-descriptive name.

Why 'fileList' over 'files'?

However, in os::find calling it a 'filelist' seems misleading because it 
contains directories as well, at which point, why not call it 'entries'. Seems 
that we've already decided that 'files' are not directories, see: 
os::listfiles().

The same applies inside os::listfiles() and for the 'procfiles' in the pid 
functions, these are lists that contain files and directories (or, entries).


- Ben


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/20499/#review48959
-----------------------------------------------------------


On July 29, 2014, 4:12 p.m., Dominic Hamon wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/20499/
> -----------------------------------------------------------
> 
> (Updated July 29, 2014, 4:12 p.m.)
> 
> 
> Review request for mesos, Benjamin Hindman and Ben Mahler.
> 
> 
> Bugs: MESOS-1237
>     https://issues.apache.org/jira/browse/MESOS-1237
> 
> 
> Repository: mesos-git
> 
> 
> Description
> -------
> 
> see summary
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/3rdparty/stout/include/stout/os.hpp 
> 08251724fbe45431db2c3637c6beec81f5744c4c 
>   3rdparty/libprocess/3rdparty/stout/include/stout/os/ls.hpp 
> e916f027e1c9918ec4f2d41e03926c10a1080bca 
>   3rdparty/libprocess/3rdparty/stout/include/stout/os/setns.hpp 
> cf2215a90d6e2673085293b8eaf5a44418da3bf0 
>   3rdparty/libprocess/3rdparty/stout/include/stout/proc.hpp 
> c5509632988401ee96ed2471c7278c8e164800d7 
>   3rdparty/libprocess/3rdparty/stout/tests/os_tests.cpp 
> 7fa7346346a33a05fbcd30a11053948eedba4764 
> 
> Diff: https://reviews.apache.org/r/20499/diff/
> 
> 
> Testing
> -------
> 
> make check
> 
> 
> Thanks,
> 
> Dominic Hamon
> 
>

Reply via email to