Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ARROW-1419: [GLib] Suppress sign-conversion warnings #999

Closed
wants to merge 1 commit into from

Conversation

kou
Copy link
Member

@kou kou commented Aug 28, 2017

Apache Arrow C++ uses int as result type for expression that uses
size_t. It causes sign-conversion warning but the coding style is
expected.

Example:

.../arrow/buffer.h:296:41: warning:
      implicit conversion changes signedness: 'unsigned long' to 'int64_t'
      (aka 'long') [-Wsign-conversion]
  int64_t length() const { return size_ / sizeof(T); }
                           ~~~~~~ ~~~~~~^~~~~~~~~~~

Apache Arrow C++ uses int as result type for expression that uses
size_t. It causes sign-conversion warning but the coding style is
expected.

Example:

    .../arrow/buffer.h:296:41: warning:
          implicit conversion changes signedness: 'unsigned long' to 'int64_t'
          (aka 'long') [-Wsign-conversion]
      int64_t length() const { return size_ / sizeof(T); }
                               ~~~~~~ ~~~~~~^~~~~~~~~~~
Copy link
Member

@wesm wesm left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1. We should probably fix the particular compiler warning you cited in buffer.h

@asfgit asfgit closed this in 6cd2a17 Aug 28, 2017
@kou kou deleted the glib-suppress-warning-on-clang branch August 29, 2017 00:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants