[PATCH] D24128: [ELF] PR30221 - linker script expression parser does not accept '~'

George Rimar via llvm-commits llvm-commits at lists.llvm.org
Thu Sep 1 07:31:42 PDT 2016


grimar added a comment.

This looks fine for me. The only note I have is that gold/ld does not
support ~ without () it seems. So the only form that works is:

~(...)

So you could write:

  if (Tok == "~") {
    Expr E = readParenExpr();
    return [=](uint64_t Dot) { return ~E(Dot); };
  }

I don't know what is more correct though and why gnu linkers does
not allow to write just ~XXX.


Repository:
  rL LLVM

https://reviews.llvm.org/D24128





More information about the llvm-commits mailing list