lua-users home
lua-l archive

Search lua-l

This index contains 143,615 documents and 1,774,615 keywords. Last update on 2023-03-09 .

Query: [How to search]

Display: Description: Sort by:

Results:

References: [ Luis: 514 ] [ Carvalho: 322 ]

Total 256 documents matching your query.

161. Re: to confirm, userdata can implement the "eq" metamethod, but they are still different table keys? (score: 26)
Author: Sam Roberts <sroberts@...>
Date: Tue, 1 May 2007 09:31:09 -0700
Thanks Luis, but I would like the opposite, if a == b, then t[a] == t[b]: a = uint64(1) b = uint64(1) -- uint64() returns a userdata wrapping a uint64 t = {} t[a] = 'this' t[b] = 'that' assert(a == b
162. Re: to confirm, userdata can implement the "eq" metamethod, but they are still different table keys? (score: 447)
Author: Luis Carvalho <carvalho@...>
Date: Tue, 1 May 2007 01:29:13 -0400
I don't know exactly what you mean, but you can certainly have types as userdata stored in a weak-valued table indexed by type name as the equivalence relation, say, and, to answer your question in
163. Re: Lua string (score: 447)
Author: Luis Carvalho <carvalho@...>
Date: Thu, 26 Apr 2007 12:32:30 -0400
Like this: -- String.lua local setmetatable = setmetatable local ipairs = ipairs local tostring = tostring local concat = table.concat local sub = string.sub local wrap = coroutine.wrap local yield
164. Re: Calling module from a C function (score: 27)
Author: "Jérôme Vuarand" <jerome.vuarand@...>
Date: Thu, 26 Apr 2007 01:02:10 -0400
2007/4/25, Luis Carvalho <carvalho@dam.brown.edu>: It should work fine with C modules. This worked for me: [...] it works! So I tested your code, and it works perfectly. Since it is very similar to m
165. RE: Calling module from a C function (score: 18)
Author: "Jerome Vuarand" <jerome.vuarand@...>
Date: Wed, 25 Apr 2007 10:29:35 -0400
Thanks or the help. I'll try your code as soon I get home :-)
166. Re: Calling module from a C function (score: 447)
Author: Luis Carvalho <carvalho@...>
Date: Wed, 25 Apr 2007 08:20:59 -0400
It should work fine with C modules. This worked for me: include <lua.h> include <lauxlib.h> static int lua__new (lua_State *L) { lua_pushstring(L, "it works!"); return 1; } static const struct luaL_r
167. Re: Fwd: numlua? (score: 18)
Author: Doug Rogers <rogers@...>
Date: Tue, 27 Mar 2007 12:19:20 -0400
Sorry that I missed your message. I changed my Windows domain password yesterday and some Linux Thunderbird weirdness ensued. Doug -- Innovative Concepts, Inc. www.innocon.com 703-893-2007 x220
168. Re: Fwd: numlua? (score: 18)
Author: Doug Rogers <rogers@...>
Date: Tue, 27 Mar 2007 12:04:48 -0400
I was able to download numlua-0.2.tar.gz on Feb 23 2007. I've searched the archives for the link that I used but I don't see it. I've tried wgetting at the link at luaforge, changing the 0.1 to 0.2,
169. Re: Fwd: numlua? (score: 447)
Author: Luis Carvalho <carvalho@...>
Date: Tue, 27 Mar 2007 09:46:26 -0400
The project is still alive, but in a dare need of attention; I'll give some love to it and release a bug fix version /this week/. I also need to update this page. You can download the latest version
170. RE: module question: _PACKAGE (score: 18)
Author: "Jerome Vuarand" <jerome.vuarand@...>
Date: Tue, 27 Feb 2007 10:43:20 -0500
I was aware of that optimisation and almost did it myself (btw my original implementation has coeffs in increasing order), but optimizing a purely hypothetical example would just make my point harder
171. Re: module question: _PACKAGE (score: 447)
Author: Luis Carvalho <carvalho@...>
Date: Tue, 27 Feb 2007 09:36:58 -0500
A little off the topic, but this is a bit faster (the coeffs are assumed to be in decreasing power order): -- foo/math.lua module(..., package.seeall) function poly(coefs) return function(x) -- Horn
172. Re: split (was: A citation on Lua) (score: 122)
Author: "Andrew Wilson" <agrwagrw@...>
Date: Tue, 19 Dec 2006 08:53:39 -0500
Luis, the provided code doesn't work, is it missing something or am I missing something? Andrew On 12/19/06, Luis Carvalho < carvalho@dam.brown.edu> wrote: > Here is a version using a light wrapper a
173. split (was: A citation on Lua) (score: 447)
Author: Luis Carvalho <carvalho@...>
Date: Tue, 19 Dec 2006 07:11:17 -0500
Just to add my $.02, here is a terminator-free version. It should be slower then Jerome's version, of course, but the convenience of using a magic delimiter without the terminator might pay off if t
174. Re: [OT] Re: Lua 5.1 reference manual in Vim (score: 18)
Author: Sam Roberts <sroberts@...>
Date: Fri, 1 Dec 2006 09:34:33 -0800
[snip...] And practical matter... my terminal traps F1 and pops up the gnome help! I'll look for some other binding. Cheers, Sam
175. Re: [OT] Re: Lua 5.1 reference manual in Vim (score: 447)
Author: Luis Carvalho <carvalho@...>
Date: Thu, 30 Nov 2006 21:42:27 -0500
True. It worked for me on Vim 6.4 and 7.0, but not on 6.3. I think it might be easier to convince users to upgrade than to find a general fix. :) That's a good one. I try not to bind "usually prefer
176. Re: [OT] Re: Lua 5.1 reference manual in Vim (score: 18)
Author: Rici Lake <lua@...>
Date: Thu, 30 Nov 2006 19:52:24 -0500
That's because the 'iskeyword' option is set differently for help files, and it includes '(' (\lr should work fine in C/Lua code). To fix that, you can append "set iskeyword+=^(" to after/syntax/help
177. [OT] Re: Lua 5.1 reference manual in Vim (score: 447)
Author: Luis Carvalho <carvalho@...>
Date: Wed, 29 Nov 2006 19:09:24 -0500
You're welcome. :) Extra markups and settings for luarefvim. That's because the 'iskeyword' option is set differently for help files, and it includes '(' (\lr should work fine in C/Lua code). To fix
178. Lua 5.1 reference manual license (was: new project added) (score: 447)
Author: Luis Carvalho <carvalho@...>
Date: Wed, 29 Nov 2006 19:16:24 -0500
That's a good question, actually. I couldn't find the license for the Lua 5.1 reference manual, and should have asked the authors before including it in luarefvim. I could only find the license for
179. Re: Lua 5.1 reference manual in Vim (score: 35)
Author: Rici Lake <lua@...>
Date: Wed, 29 Nov 2006 17:30:32 -0500
http://www.vim.org/scripts/script.php?script_id=1291 That is truly great! Thanks! One thing I wonder, what is help.vim for? It adds some syntax colouring to help files, apparently. One tiny thing, I
180. Re: Lua 5.1 reference manual in Vim (score: 18)
Author: Sam Roberts <sroberts@...>
Date: Wed, 29 Nov 2006 11:21:00 -0800
That is truly great! Thanks! One thing I wonder, what is help.vim for? One tiny thing, I notice that whether c-] can jump to a description of a function while inside the help windows depends on wheth

Search by Namazu v2.0.21