lua

A copy of the Lua development repository
Log | Files | Refs | README

commit 5b01cb39b5ec36c544152351c35c43149d9bbfec
parent a0503305bd95c40c0cbf5e78b345c30721176998
Author: Roberto Ierusalimschy <roberto@inf.puc-rio.br>
Date:   Fri, 16 Jan 2015 13:40:38 -0200

larger MINSTRTABSIZE (standard Lua starts with ~230 strings, after
oppening the standard libraries)

Diffstat:
Mllimits.h | 11++++++++---
1 file changed, 8 insertions(+), 3 deletions(-)

diff --git a/llimits.h b/llimits.h @@ -1,5 +1,5 @@ /* -** $Id: llimits.h,v 1.126 2015/01/13 15:49:11 roberto Exp roberto $ +** $Id: llimits.h,v 1.127 2015/01/16 13:26:55 roberto Exp roberto $ ** Limits, basic types, and some other 'installation-dependent' definitions ** See Copyright Notice in lua.h */ @@ -166,9 +166,14 @@ typedef unsigned long Instruction; -/* minimum size for the string table (must be power of 2) */ +/* +** Initial size for the string table (must be power of 2). +** The Lua core alone registers ~50 strings (reserved words + +** metaevent keys + a few others). Libraries would typically add +** a few dozens more. +*/ #if !defined(MINSTRTABSIZE) -#define MINSTRTABSIZE 64 /* minimum size for "predefined" strings */ +#define MINSTRTABSIZE 128 #endif