folly: adjust more headers to be -Wshadow-clean
authorJim Meyering <meyering@fb.com>
Sat, 24 Aug 2013 02:46:09 +0000 (19:46 -0700)
committerSara Golemon <sgolemon@fb.com>
Wed, 28 Aug 2013 21:30:13 +0000 (14:30 -0700)
commit820c91a0f9cb1d5c7938a6e9394e625781919772
treebede0f0fb9aa3665d1e2d5d6ac7f52462abdea96
parentcf0e592335227371fee3527e8a2c47fc7d3ca0ab
folly: adjust more headers to be -Wshadow-clean

Summary:
This is part of what's required to make mcrouter compile warning-free
with gcc -Wshadow.  In case it's not obvious why this is worth doing,
see t2719164.

I've used two techniques:
rename one of the shadowed variables
bracket offending code with #pragma directives to disable the warning there.

* folly/Bits.h (BitIterator): Guard this function with #pragma
to avoid a warning about its member-shadowing "bitOffset" parameter.
* folly/Memory.h (StlAllocator): Rename parameter in trivial, one-line
function definition, s/alloc/a/, to avoid shadowing the member function.
Let me know if you'd prefer #pragma directives instead.
* folly/io/Cursor.h (pull,skip,clone): Rename parameter, s/length/len/,
not to shadow the member function name.

Test Plan:
build and run tests of a few tools that use these headers

Reviewed By: jon.coens@fb.com

FB internal diff: D940493
folly/Bits.h
folly/Memory.h
folly/io/Cursor.h