[PATCH] D128409: [clang-cl] Add -emit-ast to clang-cl driver

Hans Wennborg via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Mon Jun 27 08:10:45 PDT 2022


hans added a comment.

> Regarding /Fo bit - if you want I can change it to only handle /o in this if statement. I don't mind either way.

Just doing `/o` seems better. Thanks.



================
Comment at: clang/test/Driver/ast.c:30
+// Also check clang-cl since the driver is slightly different
+// RUN: %clang_cl -ccc-print-phases -emit-ast %s 2> %t
+// RUN: echo 'END' >> %t
----------------
thieta wrote:
> hans wrote:
> > This needs a `--` before `%s` otherwise clang-cl might interpret the filename as a flag, e.g. if it starts with /Users which is common on Mac.
> Fixed - will also fix the other tests in the same file as a NFC.
It's only an issue for clang-cl since it supports flags starting with slashes. I don't think there are other clang-cl tests in the file.


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D128409/new/

https://reviews.llvm.org/D128409



More information about the cfe-commits mailing list