From 7bf2d96cc2b38114053a27210a61cef6aa3f35b5 Mon Sep 17 00:00:00 2001 From: "facility-bot[app]" Date: Fri, 19 Jun 2026 16:08:19 +0000 Subject: [PATCH] Update Facility .NET repository conventions --- .agents/skills/dotnet-inspect/SKILL.md | 12 +++++++++--- apm.lock.yaml | 6 +++--- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/.agents/skills/dotnet-inspect/SKILL.md b/.agents/skills/dotnet-inspect/SKILL.md index 28874cb..bb55a8b 100644 --- a/.agents/skills/dotnet-inspect/SKILL.md +++ b/.agents/skills/dotnet-inspect/SKILL.md @@ -106,7 +106,7 @@ dnx dotnet-inspect -y -- diff --platform System.Runtime@9.0.0..10.0.0 --additive ## Source and implementation workflow -Use `source` for SourceLink URLs, source text, or token/IL-offset mapping. Use `member Type Member:N -S "Decompiled Source"` when you need a selected member's lowered C# body, `-S "Original Source"` for SourceLink-backed source text, `-S Calls` for direct call-site evidence, `-S Callers` for the reverse edges (methods that call the selected member; defaults to the member's own assembly, widen with `--bin ` / `--project ` / `--caller-package ` for cross-assembly callers), `-S "Call Graph"` for the bounded outbound call tree (callees, depth/node-capped, in-assembly), `-S "Unsafe*"` for unsafe API-member and operation evidence, or `-S IL` / `-S "IL (Annotated)"` for IL. +Use `source` for SourceLink URLs, source text, or token/IL-offset mapping. Use `member Type Member:N -S "Decompiled Source"` when you need a selected member's lowered C# body, `-S "Original Source"` for SourceLink-backed source text, `-S Calls` for direct call-site evidence, `-S Callers` for the reverse edges (methods that call the selected member; defaults to the member's own assembly, widen with `--bin ` / `--project ` / `--caller-package ` for cross-assembly callers), `-S "Call Graph"` for the bounded outbound call tree (callees, depth/node-capped, in-assembly), `-S "Unsafe*"` for unsafe API-member and operation evidence, `-S IL` for raw IL, `-S "Annotated Source"` for the mixed view (C# with hidden-fact comments — allocations, unsafety, lifetime — and the IL interleaved beneath each statement), or `-S "Facts"` for the same hidden facts as a structured table (`--tsv` for agents). ```bash dnx dotnet-inspect -y -- source JsonSerializer --package System.Text.Json @@ -119,7 +119,13 @@ dnx dotnet-inspect -y -- member JsonSerializer --package System.Text.Json Serial dnx dotnet-inspect -y -- library MyLib.dll -S @Audit ``` -A selected overload defaults to `Signature`; use bare `-S` for `Signature` plus `Decompiled Source`, or select `Original Source`, `IL`, or `IL (Annotated)` when you need specific implementation evidence. +A selected overload defaults to `Signature`; use bare `-S` for `Signature` plus `Decompiled Source`, or select `Original Source`, `IL`, or `Annotated Source` when you need specific implementation evidence. + +When `Decompiled Source` looks wrong and you need to see *how* the decompiler raised IL to C#, dump the per-pass IR pipeline (JitDump-style) with `--dump-stages` (or `-S "IR (Stages)"`): it prints the typed IR tree after import and after each raising pass, so you can spot which pass introduced a defect. Like the other code sections it needs a selected overload (`--index N`/`Name:N`/`--params`), and it is a deep decompiler-debugging view — not a normal lookup path. + +```bash +dnx dotnet-inspect -y -- member string -m IsNullOrEmpty:1 --dump-stages --raw +``` To read a whole type instead of one member, use `type Name -S "Decompiled Source"`: it renders the entire type as one C# listing — declaration, fields (including non-public, for context), and every member body. Add `--raw` to print only the bare listing (no headings or code fences), suitable for redirecting to a file: @@ -127,7 +133,7 @@ To read a whole type instead of one member, use `type Name -S "Decompiled Source dnx dotnet-inspect -y -- type Stack --platform System.Collections -S "Decompiled Source" --raw > Stack.cs ``` -Fidelity expectations: `Original Source` is the SourceLink-backed original source when available. `Decompiled Source` is lowered C#, a best-effort readable reconstruction from IL that helps explain intent; it uses PDB debug information such as local names when available, but is not guaranteed to match original syntax or compiler transformations. Raw IL and annotated IL are the highest-fidelity displays for exact opcodes, offsets, branches, tokens, and member calls; use them to confirm behavior when precision matters. +Fidelity expectations: `Original Source` is the SourceLink-backed original source when available. `Decompiled Source` is lowered C#, a best-effort readable reconstruction from IL that helps explain intent; it uses PDB debug information such as local names when available, but is not guaranteed to match original syntax or compiler transformations. Raw IL and the interleaved IL in `Annotated Source` are the highest-fidelity displays for exact opcodes, offsets, branches, tokens, and member calls; use them to confirm behavior when precision matters. For crash/stack diagnostics that include a MethodDef token plus IL offset, `source --il-offset 0x06000001+0x5` can map the offset to source. This is a niche deep-debugging path; do not start there for normal API lookup. diff --git a/apm.lock.yaml b/apm.lock.yaml index f31b8b2..b3b012e 100644 --- a/apm.lock.yaml +++ b/apm.lock.yaml @@ -1,5 +1,5 @@ lockfile_version: '1' -generated_at: '2026-06-18T16:36:49.831472+00:00' +generated_at: '2026-06-19T16:08:19.152322+00:00' apm_version: 0.14.0 dependencies: - repo_url: Faithlife/RepoConventions @@ -13,10 +13,10 @@ dependencies: content_hash: sha256:6e4dc45d96d7adc8f1d3e3300d9ee90eef9c2d0231ea83ad86fed64fca105034 - repo_url: richlander/dotnet-inspect host: github.com - resolved_commit: 6b025d3a74b67e4bb941451e4518b3f2975700b5 + resolved_commit: 6745978a216375a68cd19a80d9e892204c2e5c59 virtual_path: skills/dotnet-inspect is_virtual: true package_type: claude_skill deployed_files: - .agents/skills/dotnet-inspect - content_hash: sha256:c6940b579fea31a229fdf9a5779f4c8421d2b3904e680bb27bc43fbff65868b2 + content_hash: sha256:63c7334e7df7b87c0dda52c1dec0b7e337112f4b9790ade3d4f4bbd5cb258c61