From 29905d30625a89d442565e55d39e8014b7292198 Mon Sep 17 00:00:00 2001 From: Will Jones Date: Sun, 5 Feb 2023 15:25:57 -0800 Subject: [PATCH] fix(format): clarify const-ness of some pointers --- adbc.h | 4 ++-- c/driver/postgresql/connection.cc | 11 +++++------ c/driver/postgresql/connection.h | 2 +- c/driver/postgresql/postgresql.cc | 5 +++-- c/driver/sqlite/sqlite.c | 5 +++-- c/driver_manager/adbc_driver_manager.cc | 8 ++++---- go/adbc/drivermgr/adbc.h | 4 ++-- go/adbc/drivermgr/adbc_driver_manager.cc | 8 ++++---- go/adbc/pkg/_tmpl/driver.go.tmpl | 3 ++- go/adbc/pkg/_tmpl/utils.c.tmpl | 2 +- go/adbc/pkg/_tmpl/utils.h.tmpl | 2 +- go/adbc/pkg/flightsql/driver.go | 3 ++- go/adbc/pkg/flightsql/utils.c | 2 +- go/adbc/pkg/flightsql/utils.h | 5 +++-- go/adbc/pkg/panicdummy/driver.go | 3 ++- go/adbc/pkg/panicdummy/utils.c | 2 +- go/adbc/pkg/panicdummy/utils.h | 5 +++-- go/adbc/pkg/snowflake/driver.go | 3 ++- go/adbc/pkg/snowflake/utils.c | 2 +- go/adbc/pkg/snowflake/utils.h | 5 +++-- .../adbc_driver_manager/adbc_driver_manager/_lib.pxd | 2 +- 21 files changed, 47 insertions(+), 39 deletions(-) diff --git a/adbc.h b/adbc.h index e6befb8bdf..1ec2f05080 100644 --- a/adbc.h +++ b/adbc.h @@ -920,7 +920,7 @@ struct ADBC_EXPORT AdbcDriver { AdbcStatusCode (*DatabaseRelease)(struct AdbcDatabase*, struct AdbcError*); AdbcStatusCode (*ConnectionCommit)(struct AdbcConnection*, struct AdbcError*); - AdbcStatusCode (*ConnectionGetInfo)(struct AdbcConnection*, uint32_t*, size_t, + AdbcStatusCode (*ConnectionGetInfo)(struct AdbcConnection*, const uint32_t*, size_t, struct ArrowArrayStream*, struct AdbcError*); AdbcStatusCode (*ConnectionGetObjects)(struct AdbcConnection*, int, const char*, const char*, const char*, const char**, @@ -1461,7 +1461,7 @@ AdbcStatusCode AdbcConnectionCancel(struct AdbcConnection* connection, /// \param[out] error Error details, if an error occurs. ADBC_EXPORT AdbcStatusCode AdbcConnectionGetInfo(struct AdbcConnection* connection, - uint32_t* info_codes, size_t info_codes_length, + const uint32_t* info_codes, size_t info_codes_length, struct ArrowArrayStream* out, struct AdbcError* error); diff --git a/c/driver/postgresql/connection.cc b/c/driver/postgresql/connection.cc index 3be238fd33..c106ffca78 100644 --- a/c/driver/postgresql/connection.cc +++ b/c/driver/postgresql/connection.cc @@ -827,13 +827,12 @@ AdbcStatusCode PostgresConnectionGetInfoImpl(const uint32_t* info_codes, } AdbcStatusCode PostgresConnection::GetInfo(struct AdbcConnection* connection, - uint32_t* info_codes, size_t info_codes_length, + const uint32_t* info_codes, + size_t info_codes_length, struct ArrowArrayStream* out, struct AdbcError* error) { - // XXX: mistake in adbc.h (should have been const pointer) - const uint32_t* codes = info_codes; if (!info_codes) { - codes = kSupportedInfoCodes; + info_codes = kSupportedInfoCodes; info_codes_length = sizeof(kSupportedInfoCodes) / sizeof(kSupportedInfoCodes[0]); } @@ -842,8 +841,8 @@ AdbcStatusCode PostgresConnection::GetInfo(struct AdbcConnection* connection, struct ArrowArray array; std::memset(&array, 0, sizeof(array)); - AdbcStatusCode status = - PostgresConnectionGetInfoImpl(codes, info_codes_length, &schema, &array, error); + AdbcStatusCode status = PostgresConnectionGetInfoImpl(info_codes, info_codes_length, + &schema, &array, error); if (status != ADBC_STATUS_OK) { if (schema.release) schema.release(&schema); if (array.release) array.release(&array); diff --git a/c/driver/postgresql/connection.h b/c/driver/postgresql/connection.h index cb7647ed85..50d3ebe322 100644 --- a/c/driver/postgresql/connection.h +++ b/c/driver/postgresql/connection.h @@ -34,7 +34,7 @@ class PostgresConnection { AdbcStatusCode Cancel(struct AdbcError* error); AdbcStatusCode Commit(struct AdbcError* error); - AdbcStatusCode GetInfo(struct AdbcConnection* connection, uint32_t* info_codes, + AdbcStatusCode GetInfo(struct AdbcConnection* connection, const uint32_t* info_codes, size_t info_codes_length, struct ArrowArrayStream* out, struct AdbcError* error); AdbcStatusCode GetObjects(struct AdbcConnection* connection, int depth, diff --git a/c/driver/postgresql/postgresql.cc b/c/driver/postgresql/postgresql.cc index 28cc1beec8..2e25c4bedf 100644 --- a/c/driver/postgresql/postgresql.cc +++ b/c/driver/postgresql/postgresql.cc @@ -248,7 +248,8 @@ AdbcStatusCode PostgresConnectionCommit(struct AdbcConnection* connection, } AdbcStatusCode PostgresConnectionGetInfo(struct AdbcConnection* connection, - uint32_t* info_codes, size_t info_codes_length, + const uint32_t* info_codes, + size_t info_codes_length, struct ArrowArrayStream* stream, struct AdbcError* error) { if (!connection->private_data) return ADBC_STATUS_INVALID_STATE; @@ -436,7 +437,7 @@ AdbcStatusCode AdbcConnectionCommit(struct AdbcConnection* connection, } AdbcStatusCode AdbcConnectionGetInfo(struct AdbcConnection* connection, - uint32_t* info_codes, size_t info_codes_length, + const uint32_t* info_codes, size_t info_codes_length, struct ArrowArrayStream* stream, struct AdbcError* error) { return PostgresConnectionGetInfo(connection, info_codes, info_codes_length, stream, diff --git a/c/driver/sqlite/sqlite.c b/c/driver/sqlite/sqlite.c index 12538b8779..7b4072c2ba 100644 --- a/c/driver/sqlite/sqlite.c +++ b/c/driver/sqlite/sqlite.c @@ -350,7 +350,8 @@ AdbcStatusCode SqliteConnectionGetInfoImpl(const uint32_t* info_codes, } // NOLINT(whitespace/indent) AdbcStatusCode SqliteConnectionGetInfo(struct AdbcConnection* connection, - uint32_t* info_codes, size_t info_codes_length, + const uint32_t* info_codes, + size_t info_codes_length, struct ArrowArrayStream* out, struct AdbcError* error) { CHECK_CONN_INIT(connection, error); @@ -1695,7 +1696,7 @@ AdbcStatusCode AdbcConnectionRelease(struct AdbcConnection* connection, } AdbcStatusCode AdbcConnectionGetInfo(struct AdbcConnection* connection, - uint32_t* info_codes, size_t info_codes_length, + const uint32_t* info_codes, size_t info_codes_length, struct ArrowArrayStream* out, struct AdbcError* error) { return SqliteConnectionGetInfo(connection, info_codes, info_codes_length, out, error); diff --git a/c/driver_manager/adbc_driver_manager.cc b/c/driver_manager/adbc_driver_manager.cc index 0840224e81..516bf9bbf7 100644 --- a/c/driver_manager/adbc_driver_manager.cc +++ b/c/driver_manager/adbc_driver_manager.cc @@ -361,9 +361,9 @@ AdbcStatusCode ConnectionCommit(struct AdbcConnection*, struct AdbcError* error) return ADBC_STATUS_NOT_IMPLEMENTED; } -AdbcStatusCode ConnectionGetInfo(struct AdbcConnection* connection, uint32_t* info_codes, - size_t info_codes_length, struct ArrowArrayStream* out, - struct AdbcError* error) { +AdbcStatusCode ConnectionGetInfo(struct AdbcConnection* connection, + const uint32_t* info_codes, size_t info_codes_length, + struct ArrowArrayStream* out, struct AdbcError* error) { return ADBC_STATUS_NOT_IMPLEMENTED; } @@ -952,7 +952,7 @@ AdbcStatusCode AdbcConnectionCommit(struct AdbcConnection* connection, } AdbcStatusCode AdbcConnectionGetInfo(struct AdbcConnection* connection, - uint32_t* info_codes, size_t info_codes_length, + const uint32_t* info_codes, size_t info_codes_length, struct ArrowArrayStream* out, struct AdbcError* error) { if (!connection->private_driver) { diff --git a/go/adbc/drivermgr/adbc.h b/go/adbc/drivermgr/adbc.h index e6befb8bdf..1ec2f05080 100644 --- a/go/adbc/drivermgr/adbc.h +++ b/go/adbc/drivermgr/adbc.h @@ -920,7 +920,7 @@ struct ADBC_EXPORT AdbcDriver { AdbcStatusCode (*DatabaseRelease)(struct AdbcDatabase*, struct AdbcError*); AdbcStatusCode (*ConnectionCommit)(struct AdbcConnection*, struct AdbcError*); - AdbcStatusCode (*ConnectionGetInfo)(struct AdbcConnection*, uint32_t*, size_t, + AdbcStatusCode (*ConnectionGetInfo)(struct AdbcConnection*, const uint32_t*, size_t, struct ArrowArrayStream*, struct AdbcError*); AdbcStatusCode (*ConnectionGetObjects)(struct AdbcConnection*, int, const char*, const char*, const char*, const char**, @@ -1461,7 +1461,7 @@ AdbcStatusCode AdbcConnectionCancel(struct AdbcConnection* connection, /// \param[out] error Error details, if an error occurs. ADBC_EXPORT AdbcStatusCode AdbcConnectionGetInfo(struct AdbcConnection* connection, - uint32_t* info_codes, size_t info_codes_length, + const uint32_t* info_codes, size_t info_codes_length, struct ArrowArrayStream* out, struct AdbcError* error); diff --git a/go/adbc/drivermgr/adbc_driver_manager.cc b/go/adbc/drivermgr/adbc_driver_manager.cc index 0840224e81..516bf9bbf7 100644 --- a/go/adbc/drivermgr/adbc_driver_manager.cc +++ b/go/adbc/drivermgr/adbc_driver_manager.cc @@ -361,9 +361,9 @@ AdbcStatusCode ConnectionCommit(struct AdbcConnection*, struct AdbcError* error) return ADBC_STATUS_NOT_IMPLEMENTED; } -AdbcStatusCode ConnectionGetInfo(struct AdbcConnection* connection, uint32_t* info_codes, - size_t info_codes_length, struct ArrowArrayStream* out, - struct AdbcError* error) { +AdbcStatusCode ConnectionGetInfo(struct AdbcConnection* connection, + const uint32_t* info_codes, size_t info_codes_length, + struct ArrowArrayStream* out, struct AdbcError* error) { return ADBC_STATUS_NOT_IMPLEMENTED; } @@ -952,7 +952,7 @@ AdbcStatusCode AdbcConnectionCommit(struct AdbcConnection* connection, } AdbcStatusCode AdbcConnectionGetInfo(struct AdbcConnection* connection, - uint32_t* info_codes, size_t info_codes_length, + const uint32_t* info_codes, size_t info_codes_length, struct ArrowArrayStream* out, struct AdbcError* error) { if (!connection->private_driver) { diff --git a/go/adbc/pkg/_tmpl/driver.go.tmpl b/go/adbc/pkg/_tmpl/driver.go.tmpl index b849a0faa8..fc489a4016 100644 --- a/go/adbc/pkg/_tmpl/driver.go.tmpl +++ b/go/adbc/pkg/_tmpl/driver.go.tmpl @@ -32,6 +32,7 @@ package main // // typedef const char cchar_t; // typedef const uint8_t cuint8_t; +// typedef const uint32_t cuint32_t; // typedef const struct AdbcError ConstAdbcError; // // int {{.Prefix}}ArrayStreamGetSchema(struct ArrowArrayStream*, struct ArrowSchema*); @@ -1037,7 +1038,7 @@ func toStrSlice(in **C.cchar_t) []string { } //export {{.Prefix}}ConnectionGetInfo -func {{.Prefix}}ConnectionGetInfo(cnxn *C.struct_AdbcConnection, codes *C.uint32_t, len C.size_t, out *C.struct_ArrowArrayStream, err *C.struct_AdbcError) (code C.AdbcStatusCode) { +func {{.Prefix}}ConnectionGetInfo(cnxn *C.struct_AdbcConnection, codes *C.cuint32_t, len C.size_t, out *C.struct_ArrowArrayStream, err *C.struct_AdbcError) (code C.AdbcStatusCode) { defer func() { if e := recover(); e != nil { code = poison(err, "AdbcConnectionGetInfo", e) diff --git a/go/adbc/pkg/_tmpl/utils.c.tmpl b/go/adbc/pkg/_tmpl/utils.c.tmpl index 055bba5868..195e788cfa 100644 --- a/go/adbc/pkg/_tmpl/utils.c.tmpl +++ b/go/adbc/pkg/_tmpl/utils.c.tmpl @@ -163,7 +163,7 @@ AdbcStatusCode AdbcConnectionCommit(struct AdbcConnection* connection, } AdbcStatusCode AdbcConnectionGetInfo(struct AdbcConnection* connection, - uint32_t* info_codes, size_t info_codes_length, + const uint32_t* info_codes, size_t info_codes_length, struct ArrowArrayStream* out, struct AdbcError* error) { if (out) memset(out, 0, sizeof(*out)); diff --git a/go/adbc/pkg/_tmpl/utils.h.tmpl b/go/adbc/pkg/_tmpl/utils.h.tmpl index 025635b2cd..ce3dba9dbc 100644 --- a/go/adbc/pkg/_tmpl/utils.h.tmpl +++ b/go/adbc/pkg/_tmpl/utils.h.tmpl @@ -39,7 +39,7 @@ AdbcStatusCode {{.Prefix}}DatabaseSetOptionInt(struct AdbcDatabase*, const char* AdbcStatusCode {{.Prefix}}ConnectionCancel(struct AdbcConnection*, struct AdbcError*); AdbcStatusCode {{.Prefix}}ConnectionCommit(struct AdbcConnection* cnxn, struct AdbcError* err); -AdbcStatusCode {{.Prefix}}ConnectionGetInfo(struct AdbcConnection* cnxn, uint32_t* codes, size_t len, struct ArrowArrayStream* out, struct AdbcError* err); +AdbcStatusCode {{.Prefix}}ConnectionGetInfo(struct AdbcConnection* cnxn, const uint32_t* codes, size_t len, struct ArrowArrayStream* out, struct AdbcError* err); AdbcStatusCode {{.Prefix}}ConnectionGetObjects(struct AdbcConnection* cnxn, int depth, const char* catalog, const char* dbSchema, const char* tableName, const char** tableType, const char* columnName, struct ArrowArrayStream* out, struct AdbcError* err); AdbcStatusCode {{.Prefix}}ConnectionGetOption(struct AdbcConnection*, const char*, char*, size_t*, struct AdbcError*); AdbcStatusCode {{.Prefix}}ConnectionGetOptionBytes(struct AdbcConnection*, const char*, uint8_t*, size_t*, struct AdbcError*); diff --git a/go/adbc/pkg/flightsql/driver.go b/go/adbc/pkg/flightsql/driver.go index b11393cf69..925fd8658e 100644 --- a/go/adbc/pkg/flightsql/driver.go +++ b/go/adbc/pkg/flightsql/driver.go @@ -34,6 +34,7 @@ package main // // typedef const char cchar_t; // typedef const uint8_t cuint8_t; +// typedef const uint32_t cuint32_t; // typedef const struct AdbcError ConstAdbcError; // // int FlightSQLArrayStreamGetSchema(struct ArrowArrayStream*, struct ArrowSchema*); @@ -1041,7 +1042,7 @@ func toStrSlice(in **C.cchar_t) []string { } //export FlightSQLConnectionGetInfo -func FlightSQLConnectionGetInfo(cnxn *C.struct_AdbcConnection, codes *C.uint32_t, len C.size_t, out *C.struct_ArrowArrayStream, err *C.struct_AdbcError) (code C.AdbcStatusCode) { +func FlightSQLConnectionGetInfo(cnxn *C.struct_AdbcConnection, codes *C.cuint32_t, len C.size_t, out *C.struct_ArrowArrayStream, err *C.struct_AdbcError) (code C.AdbcStatusCode) { defer func() { if e := recover(); e != nil { code = poison(err, "AdbcConnectionGetInfo", e) diff --git a/go/adbc/pkg/flightsql/utils.c b/go/adbc/pkg/flightsql/utils.c index 6c30a7dd75..95920aa498 100644 --- a/go/adbc/pkg/flightsql/utils.c +++ b/go/adbc/pkg/flightsql/utils.c @@ -165,7 +165,7 @@ AdbcStatusCode AdbcConnectionCommit(struct AdbcConnection* connection, } AdbcStatusCode AdbcConnectionGetInfo(struct AdbcConnection* connection, - uint32_t* info_codes, size_t info_codes_length, + const uint32_t* info_codes, size_t info_codes_length, struct ArrowArrayStream* out, struct AdbcError* error) { if (out) memset(out, 0, sizeof(*out)); diff --git a/go/adbc/pkg/flightsql/utils.h b/go/adbc/pkg/flightsql/utils.h index 2b426a255f..e3b22fb737 100644 --- a/go/adbc/pkg/flightsql/utils.h +++ b/go/adbc/pkg/flightsql/utils.h @@ -51,8 +51,9 @@ AdbcStatusCode FlightSQLDatabaseSetOptionInt(struct AdbcDatabase*, const char*, AdbcStatusCode FlightSQLConnectionCancel(struct AdbcConnection*, struct AdbcError*); AdbcStatusCode FlightSQLConnectionCommit(struct AdbcConnection* cnxn, struct AdbcError* err); -AdbcStatusCode FlightSQLConnectionGetInfo(struct AdbcConnection* cnxn, uint32_t* codes, - size_t len, struct ArrowArrayStream* out, +AdbcStatusCode FlightSQLConnectionGetInfo(struct AdbcConnection* cnxn, + const uint32_t* codes, size_t len, + struct ArrowArrayStream* out, struct AdbcError* err); AdbcStatusCode FlightSQLConnectionGetObjects( struct AdbcConnection* cnxn, int depth, const char* catalog, const char* dbSchema, diff --git a/go/adbc/pkg/panicdummy/driver.go b/go/adbc/pkg/panicdummy/driver.go index b8c3959644..d1c143a762 100644 --- a/go/adbc/pkg/panicdummy/driver.go +++ b/go/adbc/pkg/panicdummy/driver.go @@ -34,6 +34,7 @@ package main // // typedef const char cchar_t; // typedef const uint8_t cuint8_t; +// typedef const uint32_t cuint32_t; // typedef const struct AdbcError ConstAdbcError; // // int PanicDummyArrayStreamGetSchema(struct ArrowArrayStream*, struct ArrowSchema*); @@ -1041,7 +1042,7 @@ func toStrSlice(in **C.cchar_t) []string { } //export PanicDummyConnectionGetInfo -func PanicDummyConnectionGetInfo(cnxn *C.struct_AdbcConnection, codes *C.uint32_t, len C.size_t, out *C.struct_ArrowArrayStream, err *C.struct_AdbcError) (code C.AdbcStatusCode) { +func PanicDummyConnectionGetInfo(cnxn *C.struct_AdbcConnection, codes *C.cuint32_t, len C.size_t, out *C.struct_ArrowArrayStream, err *C.struct_AdbcError) (code C.AdbcStatusCode) { defer func() { if e := recover(); e != nil { code = poison(err, "AdbcConnectionGetInfo", e) diff --git a/go/adbc/pkg/panicdummy/utils.c b/go/adbc/pkg/panicdummy/utils.c index db4a7fdd65..526cd27ca4 100644 --- a/go/adbc/pkg/panicdummy/utils.c +++ b/go/adbc/pkg/panicdummy/utils.c @@ -165,7 +165,7 @@ AdbcStatusCode AdbcConnectionCommit(struct AdbcConnection* connection, } AdbcStatusCode AdbcConnectionGetInfo(struct AdbcConnection* connection, - uint32_t* info_codes, size_t info_codes_length, + const uint32_t* info_codes, size_t info_codes_length, struct ArrowArrayStream* out, struct AdbcError* error) { if (out) memset(out, 0, sizeof(*out)); diff --git a/go/adbc/pkg/panicdummy/utils.h b/go/adbc/pkg/panicdummy/utils.h index 00ec5f8524..91d8294c4e 100644 --- a/go/adbc/pkg/panicdummy/utils.h +++ b/go/adbc/pkg/panicdummy/utils.h @@ -52,8 +52,9 @@ AdbcStatusCode PanicDummyDatabaseSetOptionInt(struct AdbcDatabase*, const char*, AdbcStatusCode PanicDummyConnectionCancel(struct AdbcConnection*, struct AdbcError*); AdbcStatusCode PanicDummyConnectionCommit(struct AdbcConnection* cnxn, struct AdbcError* err); -AdbcStatusCode PanicDummyConnectionGetInfo(struct AdbcConnection* cnxn, uint32_t* codes, - size_t len, struct ArrowArrayStream* out, +AdbcStatusCode PanicDummyConnectionGetInfo(struct AdbcConnection* cnxn, + const uint32_t* codes, size_t len, + struct ArrowArrayStream* out, struct AdbcError* err); AdbcStatusCode PanicDummyConnectionGetObjects( struct AdbcConnection* cnxn, int depth, const char* catalog, const char* dbSchema, diff --git a/go/adbc/pkg/snowflake/driver.go b/go/adbc/pkg/snowflake/driver.go index 8226d93134..6ca09646d4 100644 --- a/go/adbc/pkg/snowflake/driver.go +++ b/go/adbc/pkg/snowflake/driver.go @@ -34,6 +34,7 @@ package main // // typedef const char cchar_t; // typedef const uint8_t cuint8_t; +// typedef const uint32_t cuint32_t; // typedef const struct AdbcError ConstAdbcError; // // int SnowflakeArrayStreamGetSchema(struct ArrowArrayStream*, struct ArrowSchema*); @@ -1041,7 +1042,7 @@ func toStrSlice(in **C.cchar_t) []string { } //export SnowflakeConnectionGetInfo -func SnowflakeConnectionGetInfo(cnxn *C.struct_AdbcConnection, codes *C.uint32_t, len C.size_t, out *C.struct_ArrowArrayStream, err *C.struct_AdbcError) (code C.AdbcStatusCode) { +func SnowflakeConnectionGetInfo(cnxn *C.struct_AdbcConnection, codes *C.cuint32_t, len C.size_t, out *C.struct_ArrowArrayStream, err *C.struct_AdbcError) (code C.AdbcStatusCode) { defer func() { if e := recover(); e != nil { code = poison(err, "AdbcConnectionGetInfo", e) diff --git a/go/adbc/pkg/snowflake/utils.c b/go/adbc/pkg/snowflake/utils.c index f226984774..a2bc39ebf1 100644 --- a/go/adbc/pkg/snowflake/utils.c +++ b/go/adbc/pkg/snowflake/utils.c @@ -165,7 +165,7 @@ AdbcStatusCode AdbcConnectionCommit(struct AdbcConnection* connection, } AdbcStatusCode AdbcConnectionGetInfo(struct AdbcConnection* connection, - uint32_t* info_codes, size_t info_codes_length, + const uint32_t* info_codes, size_t info_codes_length, struct ArrowArrayStream* out, struct AdbcError* error) { if (out) memset(out, 0, sizeof(*out)); diff --git a/go/adbc/pkg/snowflake/utils.h b/go/adbc/pkg/snowflake/utils.h index c1b3c07da2..23391dfd70 100644 --- a/go/adbc/pkg/snowflake/utils.h +++ b/go/adbc/pkg/snowflake/utils.h @@ -51,8 +51,9 @@ AdbcStatusCode SnowflakeDatabaseSetOptionInt(struct AdbcDatabase*, const char*, AdbcStatusCode SnowflakeConnectionCancel(struct AdbcConnection*, struct AdbcError*); AdbcStatusCode SnowflakeConnectionCommit(struct AdbcConnection* cnxn, struct AdbcError* err); -AdbcStatusCode SnowflakeConnectionGetInfo(struct AdbcConnection* cnxn, uint32_t* codes, - size_t len, struct ArrowArrayStream* out, +AdbcStatusCode SnowflakeConnectionGetInfo(struct AdbcConnection* cnxn, + const uint32_t* codes, size_t len, + struct ArrowArrayStream* out, struct AdbcError* err); AdbcStatusCode SnowflakeConnectionGetObjects( struct AdbcConnection* cnxn, int depth, const char* catalog, const char* dbSchema, diff --git a/python/adbc_driver_manager/adbc_driver_manager/_lib.pxd b/python/adbc_driver_manager/adbc_driver_manager/_lib.pxd index df7903625d..88a61a66ec 100644 --- a/python/adbc_driver_manager/adbc_driver_manager/_lib.pxd +++ b/python/adbc_driver_manager/adbc_driver_manager/_lib.pxd @@ -160,7 +160,7 @@ cdef extern from "adbc.h" nogil: CAdbcError* error) CAdbcStatusCode AdbcConnectionGetInfo( CAdbcConnection* connection, - uint32_t* info_codes, + const uint32_t* info_codes, size_t info_codes_length, CArrowArrayStream* stream, CAdbcError* error)