Skip to content

Commit ca16ce9

Browse files
authored
Merge pull request #285 from jmarrec/MSVC_support
Allow building on MSVC by disabling a warning turned error.
2 parents 6fc5073 + 69bbc8f commit ca16ce9

1 file changed

Lines changed: 9 additions & 0 deletions

File tree

ext/sqlite3/database.c

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
#include <sqlite3_ruby.h>
22
#include <aggregator.h>
33

4+
#if _MSC_VER
5+
#pragma warning( push )
6+
#pragma warning( disable : 4028 )
7+
#endif
8+
49
#define REQUIRE_OPEN_DB(_ctxt) \
510
if(!_ctxt->db) \
611
rb_raise(rb_path2class("SQLite3::Exception"), "cannot use a closed database");
@@ -825,3 +830,7 @@ void init_sqlite3_database()
825830

826831
rb_sqlite3_aggregator_init();
827832
}
833+
834+
#if _MSC_VER
835+
#pragma warning( pop )
836+
#endif

0 commit comments

Comments
 (0)