Skip to content

How I can make a Lunatic-Ruby? #73

Description

@xskullcrow

Hi, I used Lunatic Python to make the Love framework compatible with Python, but right now I want to do the same but instead of Python with Ruby, it has its own C Api, although different from Python or Lua, but is it possible to make a Lunatic Ruby?, that is, in the same way that Lunatic Python was made, but with Ruby, how can I do it?

Activity

  1. greatwolf commented on Apr 26, 2020

    @greatwolf
    Collaborator

    I'm not familiar with the Ruby C api but I'd assume it provides all the tools and functions you'll need to get at Ruby's language features and semantics. I don't see why Lunatic-Ruby isn't possible, it's just a matter of learning and getting familiar with the api and build a bridge with it.

    There is the issue of data type mapping and translation; at some point you'll have to decided how you want to handle it from the foreign language. Some of the types are self explanatory, like value/ non-reference types eg. numbers, bools, nil, null, strings etc. But what about other things like functions, closures, array list-type containers, coroutines etc. In lunatic-python most of the latter is handled by wrapping a reference to it in some meta-object and you use that object through that meta-object.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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