[all-commits] [llvm/llvm-project] b0d6dd: [ELF] Fix precedence of ? when there are 2 or more...

Fangrui Song via All-commits all-commits at lists.llvm.org
Sat Jun 25 13:49:04 PDT 2022


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: b0d6dd3905db145853c7c744ac92d49b00b1fa20
      https://github.com/llvm/llvm-project/commit/b0d6dd3905db145853c7c744ac92d49b00b1fa20
  Author: Fangrui Song <i at maskray.me>
  Date:   2022-06-25 (Sat, 25 Jun 2022)

  Changed paths:
    M lld/ELF/ScriptParser.cpp
    M lld/test/ELF/linkerscript/operators.test

  Log Message:
  -----------
  [ELF] Fix precedence of ? when there are 2 or more operators on the left hand side

For 1 != 1 <= 1 ? 1 : 2, the current code incorrectly considers that ?
has a higher precedence than != (minPrec).

Also, add a test for right associativity.




More information about the All-commits mailing list