How to use D for cross platform development?
Nick Sabalausky
a at a.a
Wed Mar 28 12:13:01 PDT 2012
"Bennie Copeland" <mugen.kanosei at gmail.com> wrote in message
news:mizfgcnxjpbfbclcsmwo at forum.dlang.org...
> On Sunday, 25 March 2012 at 16:20:51 UTC, Alex Rønne Petersen wrote:
>>
>> About ARM support: That's not strictly true. D on ARM should work fine at
>> this point in time if you build druntime/phobos in GDC
>> with -fno-section-anchors (there is even some experimental Android
>> support). But indeed, no iOS support.
>>
>
> I'm still new at low level programming topics like ABI's etc, so I'll
> betray my ignorance. Is the druntime only required for providing an
> interface between the executable and OS resources like IO, or is it
> inseparable from the language? For example, if I wrote the shell of an iOS
> app in Obj-C that handled the interface with the phone software/hardware,
> could the remaining core be written using D? Or is the language
> capabilities like GC, slicing, mixins, etc. intimately tied to the runtime
> or phobes?
Some basic things are tied into druntme/phobos. The GC is definitely one of
them. AIUI, Arrays and AAs have been moving to a druntime-based
implementation, and the Object class is implemented there.
Technically, you can use D without druntime/phobos. Hell, druntime itself is
implemented in D. And I've even done it myself ages ago (
https://www.semitwist.com/articles/article/view/d-on-gba-nds-progress-thanks-to-oopman )
. But you'd be limited to a relatively small C-like subset of the langauge
(which I'd argue *can* still be worthwhile in cases where C is your only
other option - like low-power embedded stuff).
More information about the Digitalmars-d
mailing list