Re: [ROOT] TString::Form()

From: Rene Brun (Rene.Brun@cern.ch)
Date: Wed Nov 17 2004 - 18:06:39 MET


This a known problem connected with the support of vsnprintf by the compiler.

Use Double_t instead of Float_t.

The types accepted by Form are : char, int and double

Rene Brun

Lukasz Slusarczyk wrote:
> 
> Hi!
> 
>   Is seems that I have found a little bug. My macro looks like:
> 
> {
>    Float_t bug = 1;
>    TString bugStr;
>    bugStr.Form("%f\n",bug);
>    cout<<bugStr;
> }
> 
> but output is
> 
> 0.000000
> 
> I tested it on the following releases:
> 4.01/02  5 October 2004
> 4.00/08  6 September 2004
> 
>   regards
> 
> --
> Łukasz Ślusarczyk
>  http://rainbow.mimuw.edu.pl/~lucasso/
>  http://508.ds2.uw.edu.pl



This archive was generated by hypermail 2b29 : Sun Jan 02 2005 - 05:50:10 MET