Top 5 (Blocks)

Tomas Lindquist Olsen tomas at famolsen.dk
Thu Oct 16 05:35:22 PDT 2008


bearophile wrote:
> Related to the LDC (LLVMDC), at the moment it's for D1, but when you want to adapt LDC to D2, this may be used to implement its closures. This stuff will be present in LLVM 2.4 that will be out in about two weeks:
> 
> http://lists.cs.uiuc.edu/pipermail/cfe-dev/2008-August/002670.html
> 
>> This feature is similar to nested functions and closures, but does not require stack trampolines (with most ABIs) and supports returning closures from functions that define them. Note that actually using Blocks requires a small runtime that is not included with llvm-gcc.<
> 
> Bye,
> bearophile

 From what I read 'Blocks' is not part of LLVM, just implemented on top of it. We'll probably 
do our own implementation of closures when we get to D2 (whenever that may be).

We already do things quite differently for D1's nested functions (compared to DMD).



More information about the Digitalmars-d mailing list