mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2025-02-26 00:31:12 +00:00
eval/fate: try to fix nan printing format failures.
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
parent
e6d88f63a8
commit
16a565d0cb
@ -659,7 +659,11 @@ int main(int argc, char **argv)
|
|||||||
av_expr_parse_and_eval(&d, *expr,
|
av_expr_parse_and_eval(&d, *expr,
|
||||||
const_names, const_values,
|
const_names, const_values,
|
||||||
NULL, NULL, NULL, NULL, NULL, 0, NULL);
|
NULL, NULL, NULL, NULL, NULL, 0, NULL);
|
||||||
printf("'%s' -> %f\n\n", *expr, d);
|
if(isnan(d)){
|
||||||
|
printf("'%s' -> nan\n\n", *expr);
|
||||||
|
}else{
|
||||||
|
printf("'%s' -> %f\n\n", *expr, d);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
av_expr_parse_and_eval(&d, "1+(5-2)^(3-1)+1/2+sin(PI)-max(-2.2,-3.1)",
|
av_expr_parse_and_eval(&d, "1+(5-2)^(3-1)+1/2+sin(PI)-max(-2.2,-3.1)",
|
||||||
|
@ -134,7 +134,7 @@ Evaluating 'sqrt(1764)'
|
|||||||
'sqrt(1764)' -> 42.000000
|
'sqrt(1764)' -> 42.000000
|
||||||
|
|
||||||
Evaluating 'sqrt(-1)'
|
Evaluating 'sqrt(-1)'
|
||||||
'sqrt(-1)' -> -nan
|
'sqrt(-1)' -> nan
|
||||||
|
|
||||||
Evaluating 'not(1)'
|
Evaluating 'not(1)'
|
||||||
'not(1)' -> 0.000000
|
'not(1)' -> 0.000000
|
||||||
@ -155,7 +155,7 @@ Evaluating 'PI^1.23'
|
|||||||
'PI^1.23' -> 4.087844
|
'PI^1.23' -> 4.087844
|
||||||
|
|
||||||
Evaluating 'pow(-1,1.23)'
|
Evaluating 'pow(-1,1.23)'
|
||||||
'pow(-1,1.23)' -> -nan
|
'pow(-1,1.23)' -> nan
|
||||||
|
|
||||||
12.700000 == 12.7
|
12.700000 == 12.7
|
||||||
0.931323 == 0.931322575
|
0.931323 == 0.931322575
|
||||||
|
Loading…
Reference in New Issue
Block a user