On May 15, 2012, at 12:56, David Blaikie wrote:

> +  SmallString<16> PrettySourceValue;
> +  Value.toString(PrettySourceValue);
> +  std::string PrettyTargetValue;
> +  if (T->isSpecificBuiltinType(BuiltinType::Bool))
> +    PrettyTargetValue = IntegerValue == 0 ? "false" : "true";
> +  else
> +    PrettyTargetValue = IntegerValue.toString(10);
> +

Why the std::string for the target?

SmallString<16> PrettyTargetValue;
if (T->isSpecificBuiltinType(BuiltinType::Bool))
  PrettyTargetValue = (IntegerValue == 0) ? "false" : "true";
else
  IntegerValue.toString(PrettyTargetValue);

(The base defaults to 10 for this version of toString.)

Jordy
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to