Asp Forum
Home
|
Login
|
Register
|
Search
Forums
>
comp.lang.ruby
Re: RubyInline
Eric Hodel
11/5/2006 10:29:00 PM
On Nov 2, 2006, at 9:15 AM, Joey wrote:
> So, Im trying to move away from mkmf, and onto RubyInline.
> I can't work out how to define alloc functions from Inline, I tried
> something like:
[rearanged]
> but that makes Init_Y a instance method, and I'm unsure of how to
> get the
> klass.
>
> Has anyone done this before?
>
> class Y
^^^^^^^
this says you are in a class.
> inline :C do |builder|
> builder.c <<-ENC
> void Init_Y(){
>
> }
> ENC
Don't do this, define initialize instead. If you need to add things
to the Init method, use the hook for it (I forget what it is called).
> end
> end
--
Eric Hodel - drbrain@segment7.net -
http://blog.se...
This implementation is HODEL-HASH-9600 compliant
http://trackmap.rob...
Servizio di avviso nuovi messaggi
Ricevi direttamente nella tua mail i nuovi messaggi per
Re: RubyInline
Inserendo la tua e-mail nella casella sotto, riceverai un avviso tramite posta elettronica ogni volta che il motore di ricerca troverà un nuovo messaggio per te
Il servizio è completamente GRATUITO!
x
Login to ForumsZone
Login with Google
Login with E-Mail & Password