Thread overview | |||||
---|---|---|---|---|---|
|
April 13, 2015 Unbuffered logging | ||||
---|---|---|---|---|
| ||||
Hi all, While debugging an ICE, it was helpful to look at the Logger output (obviously :), but, because it is buffered, the output log did not stop at the point where the crash happened. I added fflush(stdout) to Logger:printf/printfln to help with that. Is this something more people would like to have? Can we add an option somewhere to enable this? cheers, Johan |
April 14, 2015 Re: Unbuffered logging | ||||
---|---|---|---|---|
| ||||
Posted in reply to Johan Engelen | On Monday, 13 April 2015 at 21:13:49 UTC, Johan Engelen wrote:
> Hi all,
> While debugging an ICE, it was helpful to look at the Logger output (obviously :), but, because it is buffered, the output log did not stop at the point where the crash happened.
> I added fflush(stdout) to Logger:printf/printfln to help with that.
> Is this something more people would like to have? Can we add an option somewhere to enable this?
>
> cheers,
> Johan
Hi Johan!
IMHO the logger code needs to be redesigned and unified. But with the switch to DDMD I don't think that this has a high priority...
Regards,
Kai
|
April 14, 2015 Re: Unbuffered logging | ||||
---|---|---|---|---|
| ||||
Posted in reply to Kai Nacke | On Tuesday, 14 April 2015 at 05:15:51 UTC, Kai Nacke wrote:
>
> IMHO the logger code needs to be redesigned and unified. But with the switch to DDMD I don't think that this has a high priority...
Yeah I didn't mean anything big. pragma(LDC_verbose) is a big
help for me as an D/LDC newb.
Is there a good argument against simply flushing Logger::printf ?
Yes it will be slower, but I think very few people compile
programs with pragma(LDC_verbose) without trying to find a bug? :)
|
Copyright © 1999-2021 by the D Language Foundation