File tree Expand file tree Collapse file tree 3 files changed +10
-6
lines changed
Expand file tree Collapse file tree 3 files changed +10
-6
lines changed Original file line number Diff line number Diff line change @@ -45,10 +45,14 @@ class Exception : public std::runtime_error
4545#endif
4646
4747// Detect whether the compiler supports C++11 noexcept exception specifications.
48- #if (defined(__GNUC__) && ((__GNUC__ == 4 && __GNUC_MINOR__ >= 7) || (__GNUC__ > 4)) && defined(__GXX_EXPERIMENTAL_CXX0X__))
48+ #if ( defined(__GNUC__) && ((__GNUC__ == 4 && __GNUC_MINOR__ >= 7) || (__GNUC__ > 4)) \
49+ && defined (__GXX_EXPERIMENTAL_CXX0X__))
4950// GCC 4.7 and following have noexcept
5051#elif defined(__clang__) && __has_feature(cxx_noexcept)
5152// Clang 3.0 and above have noexcept
53+ #elif defined(_MSC_VER) && _MSC_VER > 1800
54+ // Visual Studio 2015 and above have noexcept
5255#else
53- #define noexcept throw ()
56+ // Visual Studio 2013 does not support noexcept, and "throw()" is deprecated by C++11
57+ #define noexcept
5458#endif
Original file line number Diff line number Diff line change @@ -44,9 +44,9 @@ class Column;
4444 */
4545class Statement
4646{
47- public:
48- class Ptr ;
47+ friend class Column ; // For access to Statement::Ptr inner class
4948
49+ public:
5050 /* *
5151 * @brief Compile and register the SQL query for the provided SQLite Database Connection
5252 *
@@ -400,7 +400,7 @@ class Statement
400400 return sqlite3_errmsg (mStmtPtr );
401401 }
402402
403- public :
403+ private :
404404 /* *
405405 * @brief Shared pointer to the sqlite3_stmt SQLite Statement Object.
406406 *
Original file line number Diff line number Diff line change @@ -65,7 +65,7 @@ double Column::getDouble() const noexcept // nothrow
6565// Return a pointer to the text value (NULL terminated string) of the column specified by its index starting at 0
6666const char * Column::getText (const char * apDefaultValue /* = "" */ ) const noexcept // nothrow
6767{
68- const char * pText = ( const char *) sqlite3_column_text (mStmtPtr , mIndex );
68+ const char * pText = reinterpret_cast < const char *>( sqlite3_column_text (mStmtPtr , mIndex ) );
6969 return (pText?pText:apDefaultValue);
7070}
7171
You can’t perform that action at this time.
0 commit comments