rodneyrehm/CFPropertyList — Issue #10: Type detector interpreting string as integer
Author: huhitschris
Created: 2012-03-07 03:46:45+00:00
State: open

the CFTypeDetector uses is_numeric to determine if the value is a number (OR a numeric string) to convert to a CFNumber. Any numeric string will be converted to a CFNumber, even if some values may be converted to CFString. This is not consistent enough behavior for my iPhone app to rely on.

Moving the is_string function before the is_numeric function will allow me to keep my string values as strings, especially if I explicitly juggle the type using (string)$value.

Other users of this library may get inconsistent results when trying to work with strings which may or may not always be numeric, like a phone number.