www.digitalmars.com         C & C++   DMDScript  

digitalmars.D - So what about -betterC flag?

reply "Rel" <relmail rambler.ru> writes:
I remember that there was some buzz around undocumented -betterC 
compiler flag that should allow people get away from hard 
druntime dependencies and write bare metal code, drivers or 
kernel modules in some limited D subset. Could you make some 
comments about it. Does it exists and is it practical thing to 
do? What limitations does it require for your code? Is anyone 
using it right now and in what context? Thanks!
Sep 05 2015
parent reply "Adam D. Ruppe" <destructionator gmail.com> writes:
On Saturday, 5 September 2015 at 10:51:23 UTC, Rel wrote:
 I remember that there was some buzz around undocumented 
 -betterC compiler flag that should allow people get away from 
 hard druntime dependencies and write bare metal code, drivers 
 or kernel modules in some limited D subset.
-betterC used to exist, not sure if it still does, but it does very little and I don't think it helps much; you're still basically on your own in making such code work right.
Sep 05 2015
parent reply "Laeeth Isharc" <laeethnospam nospamlaeeth.com> writes:
On Saturday, 5 September 2015 at 12:56:48 UTC, Adam D. Ruppe 
wrote:
 On Saturday, 5 September 2015 at 10:51:23 UTC, Rel wrote:
 I remember that there was some buzz around undocumented 
 -betterC compiler flag that should allow people get away from 
 hard druntime dependencies and write bare metal code, drivers 
 or kernel modules in some limited D subset.
-betterC used to exist, not sure if it still does, but it does very little and I don't think it helps much; you're still basically on your own in making such code work right.
switch still there. don't know what it does, if anything. https://github.com/D-Programming-Language/dmd/search?utf8=%E2%9C%93&q=betterC
Sep 05 2015
parent "Rel" <relmail rambler.ru> writes:
On Saturday, 5 September 2015 at 14:32:39 UTC, Laeeth Isharc 
wrote:
 On Saturday, 5 September 2015 at 12:56:48 UTC, Adam D. Ruppe 
 wrote:
 On Saturday, 5 September 2015 at 10:51:23 UTC, Rel wrote:
 I remember that there was some buzz around undocumented 
 -betterC compiler flag that should allow people get away from 
 hard druntime dependencies and write bare metal code, drivers 
 or kernel modules in some limited D subset.
-betterC used to exist, not sure if it still does, but it does very little and I don't think it helps much; you're still basically on your own in making such code work right.
switch still there. don't know what it does, if anything. https://github.com/D-Programming-Language/dmd/search?utf8=%E2%9C%93&q=betterC
I see, it seems that all that flag does is prevent module info generation, I don't really know if it may be helpful or not in using D as a "better C" (without druntime). But thanks!
Sep 08 2015