mirror of
https://github.com/VCMP-SqMod/SqMod.git
synced 2025-06-22 01:57:14 +02:00
Update squirrel to the latest version straight from the official repository.
This commit is contained in:
2
external/Squirrel/Lib/sqstdblob.cpp
vendored
2
external/Squirrel/Lib/sqstdblob.cpp
vendored
@ -7,7 +7,7 @@
|
||||
#include "sqstdstream.h"
|
||||
#include "sqstdblobimpl.h"
|
||||
|
||||
#define SQSTD_BLOB_TYPE_TAG (SQSTD_STREAM_TYPE_TAG | 0x00000002)
|
||||
#define SQSTD_BLOB_TYPE_TAG ((SQUnsignedInteger)(SQSTD_STREAM_TYPE_TAG | 0x00000002))
|
||||
|
||||
//Blob
|
||||
|
||||
|
4
external/Squirrel/Lib/sqstdio.cpp
vendored
4
external/Squirrel/Lib/sqstdio.cpp
vendored
@ -5,7 +5,7 @@
|
||||
#include <sqstdio.h>
|
||||
#include "sqstdstream.h"
|
||||
|
||||
#define SQSTD_FILE_TYPE_TAG (SQSTD_STREAM_TYPE_TAG | 0x00000001)
|
||||
#define SQSTD_FILE_TYPE_TAG ((SQUnsignedInteger)(SQSTD_STREAM_TYPE_TAG | 0x00000001))
|
||||
//basic API
|
||||
SQFILE sqstd_fopen(const SQChar *filename ,const SQChar *mode)
|
||||
{
|
||||
@ -401,7 +401,7 @@ SQRESULT sqstd_dofile(HSQUIRRELVM v,const SQChar *filename,SQBool retval,SQBool
|
||||
{
|
||||
//at least one entry must exist in order for us to push it as the environment
|
||||
if(sq_gettop(v) == 0)
|
||||
return sq_throwerror(v,_SC("environment table expected"));
|
||||
return sq_throwerror(v,_SC("environment table expected"));
|
||||
|
||||
if(SQ_SUCCEEDED(sqstd_loadfile(v,filename,printerror))) {
|
||||
sq_push(v,-2);
|
||||
|
6
external/Squirrel/Lib/sqstdrex.cpp
vendored
6
external/Squirrel/Lib/sqstdrex.cpp
vendored
@ -155,7 +155,7 @@ static SQInteger sqstd_rex_charnode(SQRex *exp,SQBool isclass)
|
||||
}
|
||||
case 0:
|
||||
sqstd_rex_error(exp,_SC("letter expected for argument of escape sequence"));
|
||||
break;
|
||||
break;
|
||||
case 'b':
|
||||
case 'B':
|
||||
if(!isclass) {
|
||||
@ -578,9 +578,9 @@ SQRex *sqstd_rex_compile(const SQChar *pattern,const SQChar **error)
|
||||
scprintf(_SC("\n"));
|
||||
for(i = 0;i < nsize; i++) {
|
||||
if(exp->_nodes[i].type>MAX_CHAR)
|
||||
scprintf(_SC("[%02d] %10s "),i,g_nnames[exp->_nodes[i].type-MAX_CHAR]);
|
||||
scprintf(_SC("[%02d] %10s "), (SQInt32)i,g_nnames[exp->_nodes[i].type-MAX_CHAR]);
|
||||
else
|
||||
scprintf(_SC("[%02d] %10c "),i,exp->_nodes[i].type);
|
||||
scprintf(_SC("[%02d] %10c "), (SQInt32)i,exp->_nodes[i].type);
|
||||
scprintf(_SC("left %02d right %02d next %02d\n"), (SQInt32)exp->_nodes[i].left, (SQInt32)exp->_nodes[i].right, (SQInt32)exp->_nodes[i].next);
|
||||
}
|
||||
scprintf(_SC("\n"));
|
||||
|
4
external/Squirrel/Lib/sqstdstream.cpp
vendored
4
external/Squirrel/Lib/sqstdstream.cpp
vendored
@ -11,7 +11,7 @@
|
||||
|
||||
#define SETUP_STREAM(v) \
|
||||
SQStream *self = NULL; \
|
||||
if(SQ_FAILED(sq_getinstanceup(v,1,(SQUserPointer*)&self,(SQUserPointer)SQSTD_STREAM_TYPE_TAG))) \
|
||||
if(SQ_FAILED(sq_getinstanceup(v,1,(SQUserPointer*)&self,(SQUserPointer)((SQUnsignedInteger)SQSTD_STREAM_TYPE_TAG)))) \
|
||||
return sq_throwerror(v,_SC("invalid type tag")); \
|
||||
if(!self || !self->IsValid()) \
|
||||
return sq_throwerror(v,_SC("the stream is invalid"));
|
||||
@ -259,7 +259,7 @@ void init_streamclass(HSQUIRRELVM v)
|
||||
if(SQ_FAILED(sq_get(v,-2))) {
|
||||
sq_pushstring(v,_SC("std_stream"),-1);
|
||||
sq_newclass(v,SQFalse);
|
||||
sq_settypetag(v,-1,(SQUserPointer)SQSTD_STREAM_TYPE_TAG);
|
||||
sq_settypetag(v,-1,(SQUserPointer)((SQUnsignedInteger)SQSTD_STREAM_TYPE_TAG));
|
||||
SQInteger i = 0;
|
||||
while(_stream_methods[i].name != 0) {
|
||||
const SQRegFunction &f = _stream_methods[i];
|
||||
|
2
external/Squirrel/Lib/sqstdstring.cpp
vendored
2
external/Squirrel/Lib/sqstdstring.cpp
vendored
@ -159,7 +159,7 @@ static SQInteger _string_printf(HSQUIRRELVM v)
|
||||
SQInteger length = 0;
|
||||
if(SQ_FAILED(sqstd_format(v,2,&length,&dest)))
|
||||
return -1;
|
||||
|
||||
|
||||
SQPRINTFUNCTION printfunc = sq_getprintfunc(v);
|
||||
if(printfunc) printfunc(v,dest);
|
||||
|
||||
|
Reference in New Issue
Block a user