YetAnotherForum
Welcome Guest Search | Active Topics | Log In | Register

Add the ability to retrieve the hash value of strings
m0pey
#1 Posted : Saturday, August 6, 2011 8:19:11 AM(UTC)
Rank: Advanced Member

Groups: Registered
Joined: 12/19/2005(UTC)
Posts: 90
Man
Location: Oxford

Thanks: 0 times
Was thanked: 9 time(s) in 9 post(s)
I just read this article on AltDevBlogADay about making lua bindings faster by using the raw string hashes when comparing instead of the string literal itself. The article requires some minor modifications to the lua api so lua_tolstring returns an optional third param which is the hash of the string.

Could a similar change be made to sq_getstring or a new sq_getstringhash function be added for the next release of squirrel?

Cheers
James
fagiano
#2 Posted : Saturday, August 6, 2011 8:37:08 PM(UTC)
Rank: Advanced Member

Groups: Registered, Administrators
Joined: 6/11/2005(UTC)
Posts: 1,055

Thanks: 0 times
Was thanked: 78 time(s) in 60 post(s)
I guess adding something like this should be pretty harmless. I'm currently in holiday, I'll try to remeber add it as soon as I'm back home :) . Anyway soon enough there will be a squirrel 3.0.1 .

thank you for the idea

ciao
Alberto
Follow me on Twitter @squirrellang
Guest
#3 Posted : Saturday, December 22, 2012 7:22:23 AM(UTC)
Rank: Guest

Groups:

Thanks: 0 times
Was thanked: 1 time(s) in 1 post(s)
Message was deleted by Moderator.
Users browsing this topic
Guest
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Clean Slate theme by Jaben Cargman (Tiny Gecko)
Powered by YAF 1.9.4 | YAF © 2003-2010, Yet Another Forum.NET
This page was generated in 0.081 seconds.