Ian Clatworthy wrote:
>> I'll note that if you use 'iter_entries_by_dir()' you don't have to
>> worry about passing 'no_recurse=True', you can just stop iterating once
>> you find you are no longer in that directory. Just a thought.
>
> That's true but it seems more fragile to me. (I'm not confident that all implementations of iter_entries_by_dir() will strictly implement the ordering in the future.) By making it a parameter, the behaviour is more explicit and easier to test IMO.
iter_entries_by_dir has strictly enforced ordering so that you can walk
iterators side-by-side. The ordering *is* part of the api.
That said, a flag certainly seems a bit more obvious.
John
=:->
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Ian Clatworthy wrote: by_dir( )' you don't have to by_dir( ) will strictly implement the ordering in the future.) By making it a parameter, the behaviour is more explicit and easier to test IMO.
>> I'll note that if you use 'iter_entries_
>> worry about passing 'no_recurse=True', you can just stop iterating once
>> you find you are no longer in that directory. Just a thought.
>
> That's true but it seems more fragile to me. (I'm not confident that all implementations of iter_entries_
iter_entries_by_dir has strictly enforced ordering so that you can walk
iterators side-by-side. The ordering *is* part of the api.
That said, a flag certainly seems a bit more obvious.
John
=:->
-----BEGIN PGP SIGNATURE----- enigmail. mozdev. org
RcDIACgkQJdeBCY SNAAO0IQCeIrf3Z dqZxV92gtyU+ VoDSjxh LtusMBFa/ RaJGay6K
Version: GnuPG v1.4.9 (Cygwin)
Comment: Using GnuPG with Mozilla - http://
iEYEARECAAYFAko
XP4An0TuM9IpJce
=NRKc
-----END PGP SIGNATURE-----