analyze_data_flow
Trace variable lifecycle across a statement range in C# methods. Identifies declarations, reads, writes, captures, and flows to support safe code extraction decisions.
Instructions
Analyze data flow within a range of statements in a C# method. Returns variables declared, read, written, captured by lambdas, and flowing in/out of the region. Useful for understanding variable lifecycle before extracting code.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"filePath": "<filePath>",
"startLine": "<startLine>",
"endLine": "<endLine>"
},
"name": "analyze_data_flow"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| endLine | Yes | Last line of the statement range (1-based) | |
| filePath | Yes | Full path to the C# source file | |
| startLine | Yes | First line of the statement range (1-based) |