鉴于double d
,我可以打印出来,
(lldb) expr d
(double) $2 = 3.05658e-08
有没有办法打印更多d的数字,例如
printf("%.15f", d) ?
有问题的LLDB版本是LLDB-112.2,随OS X 10.7.4提供
编辑:使用
(lldb) expr (int) printf("%.15f", d)
导致该进程被杀死,
LLVM ERROR: Internal relocations not supported.
错误消息。
答案 0 :(得分:1)
0.000000030565830
Process 77907 stopped
* thread #1: tid = 0x1c03, 0x0000000100000f34 a.out`main + 52 at a.c:6, stop reason = breakpoint 1.1
#0: 0x0000000100000f34 a.out`main + 52 at a.c:6
3 {
4 double d = .00000003056583;
5 printf ("%.15f\n", d);
-> 6 return 5;
7 }
(lldb) p d
(double) $0 = 3.05658e-08
(lldb) expr (int)printf("%.15f\n", d)
(int) $1 = 18
0.000000030565830
答案 1 :(得分:0)
你试过了吗?
printf("%.15f", d)