Giter Site home page Giter Site logo

varobject's People

Contributors

ejimlee avatar

Stargazers

 avatar

Watchers

 avatar

varobject's Issues

Advice needed

Hey.

Im trying to write a class that interfaces a scripting language's dynamic typing - but I am terribly stuck. x)

Appearently, in C++, I can not define multiple functions that differ only in their return type but otherwise have the same declaration.

And, I also can't seem to create a private subclass that I could return, that then could have operators to cast into the specified types. It just does not really want to work.

So I'd like to know if you could give me a tipp on doing that?

Here's some information about the scripting language I am trying to interface:

  • It has a stack-based VM
  • Values, except NULL, boolean and numbers, are idendified with an ID that can be obtained (getValueId(int offset))
  • Values can be retained and put into the stack by their ID.
  • Available types are: NULL, Bool, Number (int, float), String (Object: "string"), Array, Object, Function
  • There are methods such as toString(), toBool(), etc.

It's here: https://github.com/unitpoint/objectscript

I mainly want to do that, in order to be able to create a reference to a scirpted function, so I could store it. Actually, Im using VarObject in the same project already that I want to use the script-type interface at.

So if you have any tipp for this, it'd be nice to learn about it =)

Kind regards,
Ingwie

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.