folly/dynamic-inl.h: avoid -Wsign-compare error
authorJim Meyering <meyering@fb.com>
Wed, 7 Jan 2015 16:16:07 +0000 (08:16 -0800)
committerViswanath Sivakumar <viswanath@fb.com>
Tue, 13 Jan 2015 19:01:05 +0000 (11:01 -0800)
commited281068685319a31741fcecb7917362463b3fdb
treef978e869677c498f720f0e6a59179b9d8307bd50
parent7fdf8141e4d3737ac2c45c16830a8dbaac19b445
folly/dynamic-inl.h: avoid -Wsign-compare error

Summary:
* folly/dynamic-inl.h (format): Add an explicit
int-to-size_t cast (that is ok because we've just ensured
it is non-negative) to avoid this error from gcc-4.9:

folly/dynamic-inl.h:953:29: error: comparison between signed and unsigned integer expressions [-Werror=sign-compare]

Test Plan:
Run this and note there are fewer errors than before:
fbconfig --platform-all=gcc-4.9-glibc-2.20 -r folly && fbmake dbgo

Reviewed By: delong.j@fb.com

Subscribers: trunkagent, folly-diffs@

FB internal diff: D1773242

Tasks: 5941250

Signature: t1:1773242:1420822301:b1e3c065cd25728c77957ce9e1f52e884ba8693b
folly/dynamic-inl.h