liblua: fix mix of spaces & tabs

This commit is contained in:
Philippe Teuwen 2019-03-09 18:16:50 +01:00
commit 2b1b76c2a9
53 changed files with 1030 additions and 1029 deletions

View file

@ -23,8 +23,8 @@ typedef struct {
int status;
} DumpState;
#define DumpMem(b,n,size,D) DumpBlock(b,(n)*(size),D)
#define DumpVar(x,D) DumpMem(&x,1,sizeof(x),D)
#define DumpMem(b,n,size,D) DumpBlock(b,(n)*(size),D)
#define DumpVar(x,D) DumpMem(&x,1,sizeof(x),D)
static void DumpBlock(const void* b, size_t size, DumpState* D)
{
@ -67,13 +67,13 @@ static void DumpString(const TString* s, DumpState* D)
}
else
{
size_t size=s->tsv.len+1; /* include trailing '\0' */
size_t size=s->tsv.len+1; /* include trailing '\0' */
DumpVar(size,D);
DumpBlock(getstr(s),size*sizeof(char),D);
}
}
#define DumpCode(f,D) DumpVector(f->code,f->sizecode,sizeof(Instruction),D)
#define DumpCode(f,D) DumpVector(f->code,f->sizecode,sizeof(Instruction),D)
static void DumpFunction(const Proto* f, DumpState* D);
@ -88,16 +88,16 @@ static void DumpConstants(const Proto* f, DumpState* D)
switch (ttypenv(o))
{
case LUA_TNIL:
break;
break;
case LUA_TBOOLEAN:
DumpChar(bvalue(o),D);
break;
DumpChar(bvalue(o),D);
break;
case LUA_TNUMBER:
DumpNumber(nvalue(o),D);
break;
DumpNumber(nvalue(o),D);
break;
case LUA_TSTRING:
DumpString(rawtsvalue(o),D);
break;
DumpString(rawtsvalue(o),D);
break;
default: lua_assert(0);
}
}