mongodb/mongo — pull request #426 by basak (2013-05-14 12:55:10+00:00)
Title: Use a signed char to store BSONType enumerations

MinKey is defined as -1, so a signed char must be used to store BSONType
enumerations. Using a char to store a negative value results in
undefined behaviour. On i386 and amd64 architectures it happens to work
because on these platforms a char is generally signed, but this is not
guaranteed.

This fixes a build failure on ARM, where chars are unsigned by default,
and using MinKey (defined as -1) results in a compiler error.