(Folly/Gen) Fix compilation with clang
authorHannes Roth <hannesr@fb.com>
Thu, 17 Apr 2014 15:49:51 +0000 (08:49 -0700)
committerSara Golemon <sgolemon@fb.com>
Fri, 18 Apr 2014 19:04:15 +0000 (12:04 -0700)
commitd456b584d94f9e5e48b01277d514999e0f461a7f
treea2921b12ff4315c330c4b091f5882a1cbc77cc61
parentec06f66c17f2469fc62221259c66d6bb417f7692
(Folly/Gen) Fix compilation with clang

Summary:
Clang chokes because it tries to instantiate both versions of `from<const int*>`, one of which calls `std::begin(const int*)`, which doesn't work. By casting the intializer list to the right type, it can pick the overload.

Clang, because it makes debugging these templates so much better.

Test Plan: `fbconfig --clang folly/gen/test && fbmake runtests_dbg`

Reviewed By: tjackson@fb.com

FB internal diff: D1280888
folly/gen/test/BaseTest.cpp