aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Thomas Van Lenten <thomasvl@google.com>2020-06-11 17:27:21 -0400
committerGravatar Thomas Van Lenten <thomasvl@google.com>2020-06-11 17:53:07 -0400
commit39450c586d1f6bce9b57246dbf29a96643a0fe47 (patch)
treef2c1b51203c7ee9647c0da5864b1c565c93a8dc6
parent960dd6068bb7f98d31808a223f4de081efa57e0f (diff)
Add some more assert context.
-rw-r--r--Foundation/GTMSQLite.m8
1 files changed, 5 insertions, 3 deletions
diff --git a/Foundation/GTMSQLite.m b/Foundation/GTMSQLite.m
index d3add68..f5d25ba 100644
--- a/Foundation/GTMSQLite.m
+++ b/Foundation/GTMSQLite.m
@@ -47,7 +47,7 @@ GTM_INLINE CFStringEncoding SqliteTextEncodingToCFStringEncoding(int enc) {
CFStringEncoding encoding = kCFStringEncodingUTF8;
_GTMDevAssert(enc == SQLITE_UTF16BE ||
enc == SQLITE_UTF16LE,
- @"Passed in encoding was not a UTF16 encoding");
+ @"Passed in encoding was not a UTF16 encoding: %d", enc);
switch(enc) {
case SQLITE_UTF16BE:
encoding = kCFStringEncodingUTF16BE;
@@ -531,7 +531,8 @@ static void UpperLower8(sqlite3_context *context, int argc, sqlite3_value **argv
}
_GTMDevAssert(userArgs->textRep == SQLITE_UTF8,
- @"Received non UTF8 encoding in UpperLower8");
+ @"Received non UTF8 encoding in UpperLower8: %d",
+ userArgs->textRep);
// Worker string, must be mutable for case conversion so order our calls
// to only copy once
@@ -725,7 +726,8 @@ static void UpperLower16(sqlite3_context *context,
// we might as well use the preferred encoding of the original call.
_GTMDevAssert(userArgs->textRep == SQLITE_UTF16BE ||
userArgs->textRep == SQLITE_UTF16LE,
- @"Received non UTF8 encoding in UpperLower8");
+ @"Received non UTF16 encoding in UpperLower16: %d",
+ userArgs->textRep);
switch (userArgs->textRep) {
case SQLITE_UTF16BE:
sqlite3_result_text16be(context, returnBuffer,