Giter Club home page Giter Club logo

luaforge / luaobjc Goto Github PK

View Code? Open in Web Editor NEW
12.0 4.0 4.0 481 KB

This is a maintenance fork of LuaObjCBridge. While contributions/bugfixes are welcome, this project is no longer being actively maintained. This project has been superseded by LuaCocoa: http://playcontrol.net/opensource/LuaCocoa/ This repository was converted from a CVS repository on luaforge.net on Jan. 20, 2010. If you are the maintainer, please fork and then email [email protected] and ask us to "reroot" it to you. (Or you can ask us to delete the repository.)

Home Page: http://luaforge.net/projects/luaobjc

Lua 1.57% C 2.25% Objective-C 96.18%

luaobjc's People

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

luaobjc's Issues

Can't print the contents of a NSString

ObjC side

lua_pushstring(self.luaState, "test");
lua_objc_pushid(self.luaState, @"hello world");
lua_settable(self.luaState, LUA_GLOBALSINDEX);

Lua side

print(test:UTF8String())
print(test:cString())

The app gets stuck in this while loop

This snippet of code fix the problem but would need exhaustive testing

#ifndef LUA_OBJC_USE_RUNTIME_INSTEAD_OF_FOUNDATION
const char *type = [signature methodReturnType];
#else
const char *type = method->method_types;
#endif
int pos = 0;
if (type[0] == LUA_OBJC_TYPE_IN
    || type[0] == LUA_OBJC_TYPE_INOUT
    || type[0] == LUA_OBJC_TYPE_OUT
    || type[0] == LUA_OBJC_TYPE_BYCOPY
    || type[0] == LUA_OBJC_TYPE_BYREF
    || type[0] == LUA_OBJC_TYPE_CONST
    || type[0] == LUA_OBJC_TYPE_ONEWAY)
pos++;

switch(type[pos]){

Replace by the lines from 1762 to 1780 in LuaObjCBridge.m

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.