diff --git a/db/sqlite3/src/moz.build b/db/sqlite3/src/moz.build index b5016fe93809..be44e843332c 100644 --- a/db/sqlite3/src/moz.build +++ b/db/sqlite3/src/moz.build @@ -83,6 +83,7 @@ if CONFIG['OS_ARCH'] == 'WINNT' and CONFIG['MOZ_MEMORY']: # Omit unused functions to save some library footprint. DEFINES['SQLITE_OMIT_DEPRECATED'] = True DEFINES['SQLITE_OMIT_BUILTIN_TEST'] = True +DEFINES['SQLITE_OMIT_DECLTYPE'] = True # Suppress warnings in third-party code. if CONFIG['GNU_CC']: diff --git a/db/sqlite3/src/sqlite.symbols b/db/sqlite3/src/sqlite.symbols index 640ee4382f8f..58110f2df8f3 100644 --- a/db/sqlite3/src/sqlite.symbols +++ b/db/sqlite3/src/sqlite.symbols @@ -26,8 +26,6 @@ sqlite3_column_blob sqlite3_column_bytes sqlite3_column_bytes16 sqlite3_column_count -sqlite3_column_decltype -sqlite3_column_decltype16 sqlite3_column_double sqlite3_column_int sqlite3_column_int64 diff --git a/storage/mozIStorageStatement.idl b/storage/mozIStorageStatement.idl index 28abc59791e8..a264cfdfab14 100644 --- a/storage/mozIStorageStatement.idl +++ b/storage/mozIStorageStatement.idl @@ -65,16 +65,6 @@ interface mozIStorageStatement : mozIStorageBaseStatement { */ unsigned long getColumnIndex(in AUTF8String aName); - /** - * Obtains the declared column type of a prepared statement. - * - * @param aParamIndex - * The zero-based index of the column who's declared type we are - * interested in. - * @return the declared index type. - */ - AUTF8String getColumnDecltype(in unsigned long aParamIndex); - /** * Reset parameters/statement execution */ diff --git a/storage/mozStorageStatement.cpp b/storage/mozStorageStatement.cpp index 6f032dde54a8..7210274d0f6d 100644 --- a/storage/mozStorageStatement.cpp +++ b/storage/mozStorageStatement.cpp @@ -652,19 +652,6 @@ Statement::GetState(int32_t *_state) return NS_OK; } -NS_IMETHODIMP -Statement::GetColumnDecltype(uint32_t aParamIndex, - nsACString &_declType) -{ - if (!mDBStatement) - return NS_ERROR_NOT_INITIALIZED; - - ENSURE_INDEX_VALUE(aParamIndex, mResultColumnCount); - - _declType.Assign(::sqlite3_column_decltype(mDBStatement, aParamIndex)); - return NS_OK; -} - //////////////////////////////////////////////////////////////////////////////// //// mozIStorageValueArray (now part of mozIStorageStatement too) diff --git a/storage/test/unit/test_storage_statement.js b/storage/test/unit/test_storage_statement.js index 7e2841f9a3fc..026e271ac5f0 100644 --- a/storage/test/unit/test_storage_statement.js +++ b/storage/test/unit/test_storage_statement.js @@ -130,20 +130,6 @@ function test_state_after_finalize() do_check_eq(Ci.mozIStorageStatement.MOZ_STORAGE_STATEMENT_INVALID, stmt.state); } -function test_getColumnDecltype() -{ - var stmt = createStatement("SELECT name, id FROM test"); - do_check_eq("TEXT", stmt.getColumnDecltype(0)); - do_check_eq("INTEGER", stmt.getColumnDecltype(1)); - try { - do_check_eq("GARBAGE", stmt.getColumnDecltype(2)); - do_throw("should not get here"); - } catch (e) { - do_check_eq(Cr.NS_ERROR_ILLEGAL_VALUE, e.result); - } - stmt.finalize(); -} - function test_failed_execute() { var stmt = createStatement("INSERT INTO test (name) VALUES ('foo')"); @@ -181,7 +167,6 @@ var tests = [test_parameterCount_none, test_parameterCount_one, test_getColumnName, test_getColumnIndex_same_case, test_getColumnIndex_different_case, test_state_ready, test_state_executing, test_state_after_finalize, - test_getColumnDecltype, test_failed_execute, test_bind_undefined, ];