ruby-core@ruby-lang.org archive (unofficial mirror)
 help / color / mirror / Atom feed
From: duerst@it.aoyama.ac.jp
To: ruby-core@ruby-lang.org
Subject: [ruby-core:89780] [Ruby trunk Bug#15299] hash.c: warning: ‘bin’ may be used uninitialized in this function
Date: Tue, 13 Nov 2018 09:39:10 +0000 (UTC)	[thread overview]
Message-ID: <redmine.issue-15299.20181113093909.d3a172412f8ff95f@ruby-lang.org> (raw)
In-Reply-To: redmine.issue-15299.20181113093909@ruby-lang.org

Issue #15299 has been reported by duerst (Martin Dürst).

----------------------------------------
Bug #15299: hash.c: warning: ‘bin’ may be used uninitialized in this function
https://bugs.ruby-lang.org/issues/15299

* Author: duerst (Martin Dürst)
* Status: Open
* Priority: Normal
* Assignee: nobu (Nobuyoshi Nakada)
* Target version: 
* ruby -v: ruby 2.4.0dev (2016-06-09 trunk 55334) [x86_64-linux]
* Backport: 2.3: UNKNOWN, 2.4: UNKNOWN, 2.5: UNKNOWN
----------------------------------------
When compiling the latest version of trunk, I get some warnings in hash.c, as follows:

```
compiling hash.c
hash.c: In function ‘linear_update’:
hash.c:849:24: warning: ‘bin’ may be used uninitialized in this function [-Wmaybe-uninitialized]
             clear_entry(RHASH_ARRAY_REF(hash, bin));
                        ^
hash.c: In function ‘rb_hash_stlike_update’:
hash.c:849:24: warning: ‘bin’ may be used uninitialized in this function [-Wmaybe-uninitialized]
hash.c:811:14: note: ‘bin’ was declared here
     unsigned bin;
              ^
```

This warning appeared already when I reported issue #15279, but I didn't mention it because I hoped it would also disappear when #15279 was fixed.



-- 
https://bugs.ruby-lang.org/

       reply	other threads:[~2018-11-13  9:39 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <redmine.issue-15299.20181113093909@ruby-lang.org>
2018-11-13  9:39 ` duerst [this message]
2018-12-09  2:32 ` [ruby-core:90382] [Ruby trunk Bug#15299] hash.c: warning: ‘bin’ may be used uninitialized in this function nobu
2018-12-09  3:25 ` [ruby-core:90383] " duerst

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-list from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

  List information: https://www.ruby-lang.org/en/community/mailing-lists/

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=redmine.issue-15299.20181113093909.d3a172412f8ff95f@ruby-lang.org \
    --to=ruby-core@ruby-lang.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).