Difference between revisions of "D FAQ"

From D Wiki
Jump to: navigation, search
(How to generate stack trace when an exception occurs)
 
(One intermediate revision by the same user not shown)
Line 1: Line 1:
===How to prevent console from popping up when writing a GUI application with DMD?===
+
==How to prevent console from popping up when writing a GUI application with DMD?==
  
 
Pass the following argument to dmd
 
Pass the following argument to dmd
Line 6: Line 6:
  
  
===How to generate stack trace when an exception occurs ?===
+
==How to generate stack trace when an exception occurs ?==
  
 
Stack trace with function names is only supported in debug mode. So add -g option while compiling. Otherwise you would still get the stack trace but without function names.
 
Stack trace with function names is only supported in debug mode. So add -g option while compiling. Otherwise you would still get the stack trace but without function names.
  
 
See http://forum.dlang.org/post/mcczqpgaxinnryyzscns@forum.dlang.org
 
See http://forum.dlang.org/post/mcczqpgaxinnryyzscns@forum.dlang.org
 +
 +
[[Category:Tutorials]]

Latest revision as of 20:10, 19 May 2015

How to prevent console from popping up when writing a GUI application with DMD?

Pass the following argument to dmd

 > dmd.exe -L/SUBSYSTEM:WINDOWS gui_app.d

See http://forum.dlang.org/post/xkvdpdsfzevanucrgkud@forum.dlang.org


How to generate stack trace when an exception occurs ?

Stack trace with function names is only supported in debug mode. So add -g option while compiling. Otherwise you would still get the stack trace but without function names.

See http://forum.dlang.org/post/mcczqpgaxinnryyzscns@forum.dlang.org