D as A Better C?

exord exord at live.cn
Sun Feb 16 19:19:22 PST 2014


Cool, this is what I have been seeking for several years.

I have to face C everyday totally because my work needs it.
But I hate it!

Actually, before I know D, I have written down a C#-style 
codegenerator to convert a subset of C# codes to C codes. That's 
convinient for me and I really don't need some advance features 
such as GC, runtime support and library support.I don't need a 
full framwork, I just needs a language.

When I first had a glance of D, I think it is what I need. I 
don't need to write down a separate include file and I have 
well-orged namespace, and most fantasict thing is it compiles to 
native binary!

But as I looked into more, I think D are becoming more and more 
complex. Even to learn it will take someone lots of time. If we 
can prvide several variants or subsets will be helpful, such for 
system developer/web developer, they will only need to learn the 
things releated their variant.



On Tuesday, 11 February 2014 at 19:43:00 UTC, Walter Bright wrote:
> I've toyed with this idea for a while, and wondered what the 
> interest there is in something like this.
>
> The idea is to be able to use a subset of D that does not 
> require any of druntime or phobos - it can be linked merely 
> with the C standard library. To that end, there'd be a compiler 
> switch (-betterC) which would enforce the subset.
>
> (First off, I hate the name "better C", any suggestions?)
>
> The subset would disallow use of any features that rely on:
>
> 1. moduleinfo
> 2. exception handling
> 3. gc
> 4. Object
>
> I've used such a subset before when bringing D up on a new 
> platform, as the new platform didn't have a working phobos.
>
> What do you think?



More information about the Digitalmars-d mailing list