On Tue, Oct 1, 2013 at 2:40 PM, Brian Anderson <[email protected]>wrote:

>  On 10/01/2013 07:41 AM, Jason E. Aten wrote:
>
> On Tue, Oct 1, 2013 at 6:43 AM, Dan Cristian Octavian <
> [email protected]> wrote:
>
>>  One of my first thoughts when I saw the Rust project was to make it
>> runtimeless. Shortly after that was achieved rather trivially with
>> zero.rs. I don't know if any major improvement can be done there.
>>
>
>  I'm relatively new to Rust, but making Rust runtimeless is not-yet done
> if I understand the situation; and still seems a worth goal.
>
>
> This is true, and I believe 'runtimeless' is a misnomer. Rust needs some
> amount of support at runtime in order to support some features that are key
> to the language - allocation, unwinding, logging, task-local data in
> particular, but also key methods on strings and vectors, etc. that you
> really wouldn't want to live without. The current efforts around zero.rslet 
> you run without a runtime, but not utilize the full language. The real
> goal here is to factor libstd into subsystems that can be implemented or
> excluded from the build independently to support different environments.
> Just understanding the requirements here is a major effort, and I imagine
> that designing std in such a way that it can run properly on various
> embedded systems, while not being very difficult to maintain will take a
> long time and much iteration.
>
> _______________________________________________
> Rust-dev mailing list
> [email protected]
> https://mail.mozilla.org/listinfo/rust-dev
>
>

A minimal application now looks like this:

    #[no_std];

    #[start]
    fn main(_: int, _: **u8) -> int { 0 }

There's no need for zero.rs anymore since you're now able to define the
`#[lang]` items on an as-needed basis. You can even compile mixed
C/C++/Rust programs with link-time optimization by using `clang`.

It's a pain not having the standard library, but with a few intrinsics
wrapped it's still a nicer language than C.
_______________________________________________
Rust-dev mailing list
[email protected]
https://mail.mozilla.org/listinfo/rust-dev

Reply via email to