Skip to content

[pull] main from MicrosoftDocs:main #319

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 20 commits into from
Jun 6, 2025
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
one more example
  • Loading branch information
TylerMSFT committed Jun 6, 2025
commit d7aaa866932ed25f0ee4e3bd104f3d1d63cad569
12 changes: 9 additions & 3 deletions docs/build/reference/experimental-log.md
Original file line number Diff line number Diff line change
Expand Up @@ -37,18 +37,24 @@ Diagnostics are also output as text to the console as usual.
1. Select the **Configuration Properties** > **C/C++** > **Command Line** property page.
1. Modify the **Additional Options** property, and then choose **OK**.

## Example
## Examples

The following command produces SARIF information for the compilation of `main.cpp` and saves it in the file `main.sarif`:

```cmd
CL /experimental:log main.cpp
cl /experimental:log main.cpp
```

The following command produces SARIF information for the compilation of `main.cpp` and saves it in the file `mySarifInfo.sarif`:

```cmd
cl /experimental:log mySarifInfo main.cpp
```

The following command produces SARIF information for the entire compilation and saves it in the `sarif_output` directory in the files `main.sarif` and `other.sarif`:

```cmd
CL /experimental:log sarif_output\ main.cpp other.cpp
cl /experimental:log sarif_output\ main.cpp other.cpp
```

## See also
Expand Down