Conversation
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Update changelog documentation site
…too look for both when checking whether a body is available.
Bumps [zstd](https://github.com/facebook/zstd) from 1.5.5.bcr.1 to 1.5.7.bcr.1. - [Release notes](https://github.com/facebook/zstd/releases) - [Changelog](https://github.com/facebook/zstd/blob/dev/CHANGELOG) - [Commits](https://github.com/facebook/zstd/commits) --- updated-dependencies: - dependency-name: zstd dependency-version: 1.5.7.bcr.1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] <support@github.com>
Bumps [abseil-cpp](https://github.com/abseil/abseil-cpp) from 20240116.1 to 20260107.1. - [Release notes](https://github.com/abseil/abseil-cpp/releases) - [Commits](abseil/abseil-cpp@20240116.1...20260107.1) --- updated-dependencies: - dependency-name: abseil-cpp dependency-version: '20260107.1' dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com>
Bumps [rules_python](https://github.com/bazel-contrib/rules_python) from 0.40.0 to 1.9.0. - [Release notes](https://github.com/bazel-contrib/rules_python/releases) - [Changelog](https://github.com/bazel-contrib/rules_python/blob/main/CHANGELOG.md) - [Commits](bazel-contrib/rules_python@0.40.0...1.9.0) --- updated-dependencies: - dependency-name: rules_python dependency-version: 1.9.0 dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] <support@github.com>
…thon-1.9.0 Bump rules_python from 0.40.0 to 1.9.0
….7.bcr.1 Bump zstd from 1.5.5.bcr.1 to 1.5.7.bcr.1
…pp-20260107.1 Bump abseil-cpp from 20240116.1 to 20260107.1
…mplify C#: Disentangle SwitchStmt AST and CFG.
…-summary-models C++: Add model validation for constructor summary models
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Bumps [rules_android](https://github.com/bazelbuild/rules_android) from 0.6.4 to 0.7.1. - [Release notes](https://github.com/bazelbuild/rules_android/releases) - [Commits](bazelbuild/rules_android@v0.6.4...v0.7.1) --- updated-dependencies: - dependency-name: rules_android dependency-version: 0.7.1 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
Bumps [googletest](https://github.com/google/googletest) from 1.14.0.bcr.1 to 1.17.0.bcr.2. - [Release notes](https://github.com/google/googletest/releases) - [Commits](https://github.com/google/googletest/commits) --- updated-dependencies: - dependency-name: googletest dependency-version: 1.17.0.bcr.2 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
Bumps [rules_shell](https://github.com/bazelbuild/rules_shell) from 0.5.0 to 0.6.1. - [Release notes](https://github.com/bazelbuild/rules_shell/releases) - [Commits](bazelbuild/rules_shell@v0.5.0...v0.6.1) --- updated-dependencies: - dependency-name: rules_shell dependency-version: 0.6.1 dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] <support@github.com>
Cfg: Share more code for switch statements.
Add `/rerun` slash command for failed internal checks
…un-slash-command Revert "Add `/rerun` slash command for failed internal checks"
…droid-0.7.1 Bump rules_android from 0.6.4 to 0.7.1
C++: Small simplification
…ell-0.6.1 Bump rules_shell from 0.5.0 to 0.6.1
…st-1.17.0.bcr.2 Bump googletest from 1.14.0.bcr.1 to 1.17.0.bcr.2
…thod-call-order Python: Fix bad join in method call order computation
| var getter = BodyDeclaringSymbol.GetMethod; | ||
| var setter = BodyDeclaringSymbol.SetMethod; | ||
| var getter = Symbol.GetMethod; | ||
| var setter = Symbol.SetMethod; |
Check notice
Code scanning / CodeQL
Local scope variable shadows member Note
Show autofix suggestion
Hide autofix suggestion
Copilot Autofix
AI about 13 hours ago
In general, to fix a “local variable shadows member” issue, rename the local variable or parameter so it no longer has the same name as the field or property, and then update all its references accordingly. This preserves behavior while removing ambiguity about which symbol is being referenced.
Here, the member field is type (backing the Type property), and the local variable var type = Type; is only used within Populate for the property trap and for TypeMention.Create. The simplest fix is to rename the local variable to something like propertyType (or resolvedType) and update both of its uses:
- Line 42: change
var type = Type;tovar propertyType = Type;. - Line 43: change
type.TypeReftopropertyType.TypeRef. - Line 108: change the last argument
typetopropertyType.
No imports or new methods are needed; this is purely a local rename within Populate. This will remove the shadowing and make it clear when the code is accessing the cached Type versus the Lazy<Type> field.
| @@ -39,8 +39,8 @@ | ||
| PopulateNullability(trapFile, Symbol.GetAnnotatedType()); | ||
| PopulateRefKind(trapFile, Symbol.RefKind); | ||
|
|
||
| var type = Type; | ||
| trapFile.properties(this, Symbol.GetName(), ContainingType!, type.TypeRef, Create(Context, Symbol.OriginalDefinition)); | ||
| var propertyType = Type; | ||
| trapFile.properties(this, Symbol.GetName(), ContainingType!, propertyType.TypeRef, Create(Context, Symbol.OriginalDefinition)); | ||
|
|
||
| var getter = Symbol.GetMethod; | ||
| var setter = Symbol.SetMethod; | ||
| @@ -105,7 +105,7 @@ | ||
| } | ||
|
|
||
| foreach (var syntax in declSyntaxReferences) | ||
| TypeMention.Create(Context, syntax.Type, this, type); | ||
| TypeMention.Create(Context, syntax.Type, this, propertyType); | ||
| } | ||
| } | ||
|
|
Importing from upstream - conflicts in Leap year queries resolved: