objc_meta 1.0.16

Objective-C base for creating D bindings.


To use this package, run the following command in your project's root directory:

Manual usage
Put the following dependency into your project's dependences section:

D-objective-c

Repository used to keep a compatible Objective-C bindings generation with D.

Objective-C strings

NSLog("abcd".ns);

Objective-C Number

5.ns

Objective-C Blocks

Thanks to @jacob-carlborg, we now have support to passing D delegates to Objective-C code. For further information, this was supposed to be located in the D runtime, but it didn't made unfortunately. Nevertheless, it was a great project and further makes this binding possible!

extern(C) void foo(Block!()* block);
void main()
{
    // The `block` function is used to initialize an instance of `Block`.
    // A delegate will be passed to the `block` function which will be the
    // body of the block.
    auto b = block({ writeln("foo"); });
    foo(&b);
}

Creating Objective-C dictionaries in D

NSMutableDictionaryD a = ["hello": 5].ns;
Authors:
  • Hipreme
Dependencies:
none
Versions:
1.1.0 2024-Mar-17
1.0.16 2024-Mar-10
1.0.15 2024-Feb-12
1.0.14 2024-Feb-12
1.0.13 2024-Jan-14
Show all 9 versions
Download Stats:
  • 3 downloads today

  • 4 downloads this week

  • 15 downloads this month

  • 265 downloads total

Score:
1.1
Short URL:
objc_meta.dub.pm