Squirrel

The programming language
Welcome to Squirrel Sign in | Join | Help
in Search

Accessing class member variables from C

Last post 05-07-2008, 3:03 AM by fagiano. 1 replies.
Sort Posts: Previous Next
  •  05-05-2008, 7:15 PM 2493

    Accessing class member variables from C

    How can I access a class' member variables from C, which I give as parameters to a function from Squirrel? And is there something like C++ pass by reference in functions?
  •  05-07-2008, 3:03 AM 2497 in reply to 2493

    Re: Accessing class member variables from C

    to fetch a member from a class/class instance/table/array simply use sq_get() or sq_rawget() (sq_set() to set :) ).

    no there isn't a byref for function parameters scalars are always passed by value, the rest is always by ref.

    ciao

    Alberto

View as RSS news feed in XML
Powered by Community Server, by Telligent Systems