Stream: t-compiler

Topic: errors building clang


nikomatsakis (May 16 2020 at 17:20, on Zulip):

Anybody know what's up with this?

/home/nmatsakis/versioned/rust-0/src/llvm-project/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp:3341:18: warning: assignment from temporary initializer_list does not extend the lifetime of the underlying array [-Winit-list-lifetime]
 3341 |       BaseOps = {};
      |                  ^
/home/nmatsakis/versioned/rust-0/src/llvm-project/llvm/lib/CodeGen/SelectionDAG/SelectionDAGBuilder.cpp:3347:18: warning: assignment from temporary initializer_list does not extend the lifetime of the underlying array [-Winit-list-lifetime]
 3347 |       BaseOps = {};
      |
nikomatsakis (May 16 2020 at 17:20, on Zulip):

er, those are warnings, but I'm getting a lot of random errors too

nikomatsakis (May 16 2020 at 17:20, on Zulip):
/home/nmatsakis/versioned/rust-0/src/llvm-project/llvm/include/llvm/IR/PatternMatch.h:440:20: error: ‘llvm::ICmpInst::PredicateKind’ has not been declared
  440 |     case ICmpInst::PredicateKind::ICMP_SGE:
      |                    ^~~~~~~~~~~~~
/home/nmatsakis/versioned/rust-0/src/llvm-project/llvm/include/llvm/IR/PatternMatch.h:442:20: error: ‘llvm::ICmpInst::PredicateKind’ has not been declared
  442 |     case ICmpInst::PredicateKind::ICMP_SLT:
      |                    ^~~~~~~~~~~~~
/home/nmatsakis/versioned/rust-0/src/llvm-project/llvm/include/llvm/IR/PatternMatch.h:444:20: error: ‘llvm::ICmpInst::PredicateKind’ has not been declared
  444 |     case ICmpInst::PredicateKind::ICMP_SLE:
      |                    ^~~~~~~~~~~~~
mark-i-m (May 16 2020 at 21:02, on Zulip):

What version of the compiler are you using? I find that when I upgrade gcc, I often get tons of extra warnings when compiling Linux, so it seems plausible to happen for other large C software projects.

nikomatsakis (May 18 2020 at 09:46, on Zulip):
> gcc --version
gcc (Ubuntu 9.2.1-9ubuntu2) 9.2.1 20191008
Copyright (C) 2019 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

> clang --version
clang version 9.0.0-2 (tags/RELEASE_900/final)
Target: x86_64-pc-linux-gnu
Thread model: posix
InstalledDir: /usr/bin
nikomatsakis (May 18 2020 at 09:50, on Zulip):

Oh

nikomatsakis (May 18 2020 at 09:50, on Zulip):

I think I have some local edits :)

nikomatsakis (May 18 2020 at 09:50, on Zulip):

search-and-replace gone awry

Last update: Jun 04 2020 at 18:25UTC