Skip to content

Type register and method export attributes for objc in Rust like C# in xamarin? #56

@aristotle9

Description

@aristotle9

It is very convenient to expose a C# class to objc by using attributes. (Usage: https://developer.xamarin.com/guides/ios/advanced_topics/registrar/ Implement: https://github.com/mono/cocoa-sharp/) .

Rust has the same attribute system like C#. So is it possible to have these attributes in Rust?

One of the benefits or needs is to use solid type instead of marked type connect between Rust and objc, and to wrap Rust struct method instead of static method for objc message receiving.

cocoa-sharp has these tricks.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions