lua-users home
lua-l archive

Re: Moving from Lua 4 to 5

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]


>a) Can I use the old I/O library with the new Lua until I have time to modify 
> the new library? I know the syntax is different but will it work?
Yes and Yes. I did this some time ago (to my regret), 
the 5 library is not that complex, do the couple of hours work.
>b) Is there a better way to do what I want than modifying the library? I need
> portable solution that will run on both Unix and Lose-dows.
I never found it. Replacing library table and metatable functions 
in a separate module still leaves you exposed.
Cloning the library and using a different set of names gives
you some insulation to change.
David B
Firestone, Rameses <rameses.firestone@intel.com> wrote:
>We have been using Lua 4 for about a year and now I want to switch over to
>the latest version. In order to make Lua work with our software I hacked the 
>I/O library so that it could optionally accept functions as I/O 
>descriptors. I did this so that I could take control of I/O directly. Our 
>software is mostly GUI oriented and we use QT so that it is portable. 
>With call back functions for descriptors, I could read and write to specific 
>windows with no problems. My questions are:
>
>
>a) Can I use the old I/O library with the new Lua until I have time to modify 
> the new library? I know the syntax is different but will it work?
>
>b) Is there a better way to do what I want than modifying the library? I need
> portable solution that will run on both Unix and Lose-dows.
>
>Ram
			

AltStyle によって変換されたページ (->オリジナル) /