Skip to content

Commit 09c7711

Browse files
authored
chore(c): fix typo (#2924)
Fixed only comments and messages. There are no code changes. This PR is intended to fix typos in `c/`, but I also fix `go/adbc/drivermgr/arrow-adbc/adbc.h` because this needs to be synced with `adbc.h` in `c/`. Closes #2923
1 parent 9bda49a commit 09c7711

File tree

10 files changed

+23
-23
lines changed

10 files changed

+23
-23
lines changed

c/driver/postgresql/bind_stream.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ struct BindStream {
215215

216216
int64_t param_length = param_buffer->size_bytes - last_offset - sizeof(int32_t);
217217
if (param_length > (std::numeric_limits<int>::max)()) {
218-
return Status::Internal("Paramter ", col, "serialized to >2GB of binary");
218+
return Status::Internal("Parameter ", col, "serialized to >2GB of binary");
219219
}
220220

221221
param_lengths[col] = static_cast<int>(param_length);

c/driver/postgresql/connection.cc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -181,8 +181,8 @@ class PostgresGetObjectsHelper : public adbc::driver::GetObjectsHelper {
181181
some_constraints_(conn, ConstraintsQuery()) {}
182182

183183
// Allow Redshift to execute this query without constraints
184-
// TODO(paleolimbot): Investigate to see if we can simplify the constraits query so that
185-
// it works on both!
184+
// TODO(paleolimbot): Investigate to see if we can simplify the constraints query so
185+
// that it works on both!
186186
void SetEnableConstraints(bool enable_constraints) {
187187
enable_constraints_ = enable_constraints;
188188
}

c/driver/postgresql/copy/postgres_copy_test_common.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121

2222
namespace adbcpq {
2323

24-
// New cases can be genereated using:
24+
// New cases can be generated using:
2525
// psql --host 127.0.0.1 --port 5432 --username postgres -c "COPY (SELECT ...) TO STDOUT
2626
// WITH (FORMAT binary);" > test.copy Rscript -e "dput(brio::read_file_raw('test.copy'))"
2727

c/driver/postgresql/copy/reader.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -864,7 +864,7 @@ static inline ArrowErrorCode MakeCopyFieldReader(
864864
case PostgresTypeId::kRecord: {
865865
if (pg_type.n_children() != schema->n_children) {
866866
ArrowErrorSet(error,
867-
"Can't convert Postgres record type with %ld chlidren to Arrow "
867+
"Can't convert Postgres record type with %ld children to Arrow "
868868
"struct type with %ld children",
869869
static_cast<long>(pg_type.n_children()), // NOLINT(runtime/int)
870870
static_cast<long>(schema->n_children)); // NOLINT(runtime/int)

c/driver/postgresql/copy/writer.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -726,7 +726,7 @@ static inline ArrowErrorCode MakeCopyFieldWriter(
726726
case NANOARROW_TYPE_LARGE_LIST:
727727
case NANOARROW_TYPE_FIXED_SIZE_LIST: {
728728
// For now our implementation only supports primitive children types
729-
// See PostgresCopyListFieldWriter::Write for limtiations
729+
// See PostgresCopyListFieldWriter::Write for limitations
730730
struct ArrowSchemaView child_schema_view;
731731
NANOARROW_RETURN_NOT_OK(
732732
ArrowSchemaViewInit(&child_schema_view, schema->children[0], error));

c/driver/postgresql/postgres_type.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -211,7 +211,7 @@ class PostgresType {
211211
// initialize and set the appropriate number of children). Returns NANOARROW_OK
212212
// on success and perhaps ENOMEM if memory cannot be allocated. Types that
213213
// do not have a corresponding Arrow type are returned as Binary with field
214-
// metadata ADBC:posgresql:typname. These types can be represented as their
214+
// metadata ADBC:postgresql:typname. These types can be represented as their
215215
// binary COPY representation in the output.
216216
ArrowErrorCode SetSchema(ArrowSchema* schema,
217217
const std::string& vendor_name = "PostgreSQL") const {

c/driver/postgresql/result_helper.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ class PqResultRow {
110110
};
111111

112112
// Helper to manager the lifecycle of a PQResult. The query argument
113-
// will be evaluated as part of the constructor, with the desctructor handling cleanup
113+
// will be evaluated as part of the constructor, with the destructor handling cleanup
114114
// Caller must call Prepare then Execute, checking both for an OK AdbcStatusCode
115115
// prior to iterating
116116
class PqResultHelper {

c/include/arrow-adbc/adbc.h

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -302,7 +302,7 @@ struct ADBC_EXPORT AdbcError {
302302
///
303303
/// This field may not be used unless vendor_code is
304304
/// ADBC_ERROR_VENDOR_CODE_PRIVATE_DATA. If present, this field is NULLPTR
305-
/// iff the error is unintialized/freed.
305+
/// iff the error is uninitialized/freed.
306306
///
307307
/// \since ADBC API revision 1.1.0
308308
void* private_data;
@@ -859,7 +859,7 @@ const struct AdbcError* AdbcErrorFromArrayStream(struct ArrowArrayStream* stream
859859
/// Must be kept alive as long as any connections exist.
860860
struct ADBC_EXPORT AdbcDatabase {
861861
/// \brief Opaque implementation-defined state.
862-
/// This field is NULLPTR iff the connection is unintialized/freed.
862+
/// This field is NULLPTR iff the connection is uninitialized/freed.
863863
void* private_data;
864864
/// \brief The associated driver (used by the driver manager to help
865865
/// track state).
@@ -882,7 +882,7 @@ struct ADBC_EXPORT AdbcDatabase {
882882
/// serialize accesses to a connection.
883883
struct ADBC_EXPORT AdbcConnection {
884884
/// \brief Opaque implementation-defined state.
885-
/// This field is NULLPTR iff the connection is unintialized/freed.
885+
/// This field is NULLPTR iff the connection is uninitialized/freed.
886886
void* private_data;
887887
/// \brief The associated driver (used by the driver manager to help
888888
/// track state).
@@ -920,7 +920,7 @@ struct ADBC_EXPORT AdbcConnection {
920920
/// serialize accesses to a statement.
921921
struct ADBC_EXPORT AdbcStatement {
922922
/// \brief Opaque implementation-defined state.
923-
/// This field is NULLPTR iff the connection is unintialized/freed.
923+
/// This field is NULLPTR iff the connection is uninitialized/freed.
924924
void* private_data;
925925

926926
/// \brief The associated driver (used by the driver manager to help
@@ -959,7 +959,7 @@ struct AdbcPartitions {
959959
const size_t* partition_lengths;
960960

961961
/// \brief Opaque implementation-defined state.
962-
/// This field is NULLPTR iff the connection is unintialized/freed.
962+
/// This field is NULLPTR iff the connection is uninitialized/freed.
963963
void* private_data;
964964

965965
/// \brief Release the contained partitions.
@@ -987,11 +987,11 @@ struct AdbcPartitions {
987987
/// worrying about multiple definitions of the same symbol.
988988
struct ADBC_EXPORT AdbcDriver {
989989
/// \brief Opaque driver-defined state.
990-
/// This field is NULL if the driver is unintialized/freed (but
990+
/// This field is NULL if the driver is uninitialized/freed (but
991991
/// it need not have a value even if the driver is initialized).
992992
void* private_data;
993993
/// \brief Opaque driver manager-defined state.
994-
/// This field is NULL if the driver is unintialized/freed (but
994+
/// This field is NULL if the driver is uninitialized/freed (but
995995
/// it need not have a value even if the driver is initialized).
996996
void* private_manager;
997997

c/validation/adbc_validation_util.cc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -320,7 +320,7 @@ std::string GetDriverVendorVersion(struct AdbcConnection* connection) {
320320
reader.GetSchema();
321321
if (error.release) {
322322
error.release(&error);
323-
throw std::runtime_error("error occured calling AdbcConnectionGetInfo!");
323+
throw std::runtime_error("error occurred calling AdbcConnectionGetInfo!");
324324
}
325325

326326
reader.Next();

go/adbc/drivermgr/arrow-adbc/adbc.h

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -302,7 +302,7 @@ struct ADBC_EXPORT AdbcError {
302302
///
303303
/// This field may not be used unless vendor_code is
304304
/// ADBC_ERROR_VENDOR_CODE_PRIVATE_DATA. If present, this field is NULLPTR
305-
/// iff the error is unintialized/freed.
305+
/// iff the error is uninitialized/freed.
306306
///
307307
/// \since ADBC API revision 1.1.0
308308
void* private_data;
@@ -859,7 +859,7 @@ const struct AdbcError* AdbcErrorFromArrayStream(struct ArrowArrayStream* stream
859859
/// Must be kept alive as long as any connections exist.
860860
struct ADBC_EXPORT AdbcDatabase {
861861
/// \brief Opaque implementation-defined state.
862-
/// This field is NULLPTR iff the connection is unintialized/freed.
862+
/// This field is NULLPTR iff the connection is uninitialized/freed.
863863
void* private_data;
864864
/// \brief The associated driver (used by the driver manager to help
865865
/// track state).
@@ -882,7 +882,7 @@ struct ADBC_EXPORT AdbcDatabase {
882882
/// serialize accesses to a connection.
883883
struct ADBC_EXPORT AdbcConnection {
884884
/// \brief Opaque implementation-defined state.
885-
/// This field is NULLPTR iff the connection is unintialized/freed.
885+
/// This field is NULLPTR iff the connection is uninitialized/freed.
886886
void* private_data;
887887
/// \brief The associated driver (used by the driver manager to help
888888
/// track state).
@@ -920,7 +920,7 @@ struct ADBC_EXPORT AdbcConnection {
920920
/// serialize accesses to a statement.
921921
struct ADBC_EXPORT AdbcStatement {
922922
/// \brief Opaque implementation-defined state.
923-
/// This field is NULLPTR iff the connection is unintialized/freed.
923+
/// This field is NULLPTR iff the connection is uninitialized/freed.
924924
void* private_data;
925925

926926
/// \brief The associated driver (used by the driver manager to help
@@ -959,7 +959,7 @@ struct AdbcPartitions {
959959
const size_t* partition_lengths;
960960

961961
/// \brief Opaque implementation-defined state.
962-
/// This field is NULLPTR iff the connection is unintialized/freed.
962+
/// This field is NULLPTR iff the connection is uninitialized/freed.
963963
void* private_data;
964964

965965
/// \brief Release the contained partitions.
@@ -987,11 +987,11 @@ struct AdbcPartitions {
987987
/// worrying about multiple definitions of the same symbol.
988988
struct ADBC_EXPORT AdbcDriver {
989989
/// \brief Opaque driver-defined state.
990-
/// This field is NULL if the driver is unintialized/freed (but
990+
/// This field is NULL if the driver is uninitialized/freed (but
991991
/// it need not have a value even if the driver is initialized).
992992
void* private_data;
993993
/// \brief Opaque driver manager-defined state.
994-
/// This field is NULL if the driver is unintialized/freed (but
994+
/// This field is NULL if the driver is uninitialized/freed (but
995995
/// it need not have a value even if the driver is initialized).
996996
void* private_manager;
997997

0 commit comments

Comments
 (0)