Pārlūkot izejas kodu

small docs fixes. small typo fixes in sqapi.cpp error messages

zeromus 9 gadi atpakaļ
vecāks
revīzija
3c4098da84

+ 3 - 3
doc/source/reference/api/object_manipulation.rst

@@ -91,7 +91,7 @@ resizes the array at the position idx in the stack.
     :returns: a SQRESULT
     :remarks: Only works on arrays.
 
-reverse an array in place.
+reverses an array in place.
 
 
 
@@ -106,7 +106,7 @@ reverse an array in place.
     :returns: a SQRESULT
     :remarks: Only works on tables and arrays.
 
-clears all the element of the table/array at position idx in the stack.
+clears all the elements of the table/array at position idx in the stack.
 
 
 
@@ -120,7 +120,7 @@ clears all the element of the table/array at position idx in the stack.
     :param SQInteger idx: index of the target object in the stack
     :returns: a SQRESULT
 
-Clones the table, array or class instance at the position idx, clones it and pushes the new object in the stack.
+pushes a clone of the table, array, or class instance at the position idx.
 
 
 

+ 2 - 2
doc/source/reference/language/classes.rst

@@ -46,7 +46,7 @@ For instance: ::
 
     }
 
-the previous code examples is a syntactic sugar for: ::
+the previous code example is a syntactic sugar for: ::
 
     Foo <- class {
         //constructor
@@ -67,7 +67,7 @@ the previous code examples is a syntactic sugar for: ::
 
     }
 
-in order to emulate namespaces, is also possible to declare something like this::
+in order to emulate namespaces, it is also possible to declare something like this::
 
     //just 2 regular nested tables
     FakeNamespace <- {

+ 3 - 3
squirrel/sqapi.cpp

@@ -510,7 +510,7 @@ SQRESULT sq_setclosureroot(HSQUIRRELVM v,SQInteger idx)
         v->Pop();
         return SQ_OK;
     }
-    return sq_throwerror(v, _SC("ivalid type"));
+    return sq_throwerror(v, _SC("invalid type"));
 }
 
 SQRESULT sq_getclosureroot(HSQUIRRELVM v,SQInteger idx)
@@ -558,7 +558,7 @@ SQRESULT sq_setroottable(HSQUIRRELVM v)
         v->Pop();
         return SQ_OK;
     }
-    return sq_throwerror(v, _SC("ivalid type"));
+    return sq_throwerror(v, _SC("invalid type"));
 }
 
 SQRESULT sq_setconsttable(HSQUIRRELVM v)
@@ -569,7 +569,7 @@ SQRESULT sq_setconsttable(HSQUIRRELVM v)
         v->Pop();
         return SQ_OK;
     }
-    return sq_throwerror(v, _SC("ivalid type, expected table"));
+    return sq_throwerror(v, _SC("invalid type, expected table"));
 }
 
 void sq_setforeignptr(HSQUIRRELVM v,SQUserPointer p)