Skip to content

Add support for generics <T> #880

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 53 commits into from
Apr 16, 2025
Merged

Add support for generics <T> #880

merged 53 commits into from
Apr 16, 2025

Conversation

josesimoes
Copy link
Member

@josesimoes josesimoes commented Mar 21, 2025

Description

  • Rewrote PDBX reader to use new format.
  • Add support for TypeSpec and MethodRef in debugger.
  • Update token types and add new ones for generic type and instances.
  • Global updates in debugger code following changes in debugger library.
  • Rename variable and fix code style.
  • Extension in now published to Open VSIX gallery for builds from develop branch.

Motivation and Context

How Has This Been Tested?

Screenshots

Types of changes

  • Improvement (non-breaking change that improves a feature, code or algorithm)
  • Bug fix (non-breaking change which fixes an issue with code or algorithm)
  • New feature (non-breaking change which adds functionality to code)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Config and build (change in the configuration and build system, has no impact on code or features)
  • Dependencies (update dependencies and changes associated, has no impact on code or features)
  • Unit Tests (add new Unit Test(s) or improved existing one(s), has no impact on code or features)
  • Documentation (changes or updates in the documentation, has no impact on code or features)

Checklist:

  • My code follows the code style of this project (only if there are changes in source code).
  • My changes require an update to the documentation (there are changes that require the docs website to be updated).
  • I have updated the documentation accordingly (the changes require an update on the docs in this repo).
  • I have read the CONTRIBUTING document.
  • I have tested everything locally and all new and existing tests passed (only if there are changes in source code).
  • I have added new tests to cover my changes.

Summary by CodeRabbit

  • Chores
    • Updated package dependencies to newer versions for improved compatibility and stability.
    • Increased version numbers for both Visual Studio 2019 and 2022 extensions.
    • Added automated upload of VSIX extension packages to the Open VSIX Gallery after successful builds on develop branch.
    • Refined release pipeline triggers to restrict GitHub release creation to main branch only.

Sorry, something went wrong.

josesimoes and others added 30 commits April 27, 2023 18:57
- Now using XmlDeserialize.
- Update PdbxFile class to use XML attributes.
- Add new fields to methods and classes to take advantage of new XML reader implementation.
- Add new constructor to CorDebugClass to accept type spec.
- Add code to handle generics in CorDebugValue.
***NO_CI***
- Rework vairables declaration to add sign group variables.

***NO_CI***
- Fix project path.

***NO_CI***
- Update task installing sign tool with new .NET Foundation tool.
- Migrate sign task to use new tool.
- Update file list for sign tool.

***NO_CI***
- Fix options passed to sign tool.

***NO_CI***
- Remove private Azure feed from nuget.config.

***NO_CI***
- Update sign version.
- Update config for github release tasks.
- No more build on tags.

***NO_CI***
- Fix config for github publish task.

***NO_CI***
- Fix syntax in label list.

***NO_CI***
***NO_CI***
***NO_CI***
@Ellerbach
Copy link
Member

Amazing work! Can't wait to test all this!

@josesimoes josesimoes changed the title Add support for generics Add support for generics <T> Mar 31, 2025
Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (1)
VisualStudio.Extension-2022/packages.lock.json (1)

1870-1876: New Project Dependency: nanoFramework.Tools.BuildTasks

A new project-level dependency for nanoFramework.Tools.BuildTasks has been added. This entry specifies dependencies on "Microsoft.Build.Framework": "[17.12.6, )" and "Microsoft.Build.Utilities.Core": "[17.11.4, )". Please verify that these dependency version ranges are aligned with the upstream requirements and that any consuming projects are compatible with these versions.

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between ac38402 and 33ebf19.

⛔ Files ignored due to path filters (6)
  • VisualStudio.Extension-2019/VisualStudio.Extension-vs2019.csproj is excluded by none and included by none
  • VisualStudio.Extension-2022/VisualStudio.Extension-vs2022.csproj is excluded by none and included by none
  • metadata-processor is excluded by none and included by none
  • nf-debugger is excluded by none and included by none
  • vs-extension.shared/CorDebug/CorDebugFunction.cs is excluded by none and included by none
  • vs-extension.shared/CorDebug/CorDebugProcess.cs is excluded by none and included by none
📒 Files selected for processing (2)
  • VisualStudio.Extension-2019/packages.lock.json (1 hunks)
  • VisualStudio.Extension-2022/packages.lock.json (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (3)
  • GitHub Check: nanoframework.nf-Visual-Studio-extension (VS2019)
  • GitHub Check: nanoframework.nf-Visual-Studio-extension (VS2022)
  • GitHub Check: nanoframework.nf-Visual-Studio-extension (Get_Build_Options)
🔇 Additional comments (3)
VisualStudio.Extension-2022/packages.lock.json (2)

1877-1883: Updated Dependency: nanoFramework.Tools.Debugger.Net

The dependency for nanoFramework.Tools.Debugger.Net has been refactored from a direct dependency to a project-level dependency. It now declares dependencies on:

  • "Polly": "[7.2.4, )"
  • "System.IO.Ports": "[8.0.0, )"

These changes aim to better manage dependency resolution. Please confirm that downstream components correctly reference the updated project-level dependency and that version constraints meet expectations.


1884-1888: Updated Dependency: nanoFramework.Tools.MetadataProcessor.MsBuildTask

The dependency for nanoFramework.Tools.MetadataProcessor.MsBuildTask has been updated to a project dependency. It now requires "System.Text.Json": "[8.0.5, )". Ensure that consuming projects are compatible with this version constraint and that the changes are consistent with dependency management across the solution.

VisualStudio.Extension-2019/packages.lock.json (1)

1838-1856: Updated Project-Level Dependency Entries for nanoFramework Tools

The changes in this range transition the affected packages from being managed as Direct dependencies to Project-level dependencies. In particular:

  • nanoFramework.Tools.BuildTasks now remains defined as a project with its dependencies on "Microsoft.Build.Framework" and "Microsoft.Build.Utilities.Core" constrained to [16.11.0, ).
  • nanoFramework.Tools.Debugger.Net has been revamped to a project dependency with its required packages now specified as:
    • "Polly": "[7.2.4, )", and
    • "System.IO.Ports": "[8.0.0, )".
  • nanoFramework.Tools.MetadataProcessor.MsBuildTask is similarly redefined as a project dependency, now depending on "System.Text.Json": "[8.0.5, )".

These changes align with the updated dependency management strategy outlined in the PR objectives and the high-level summary. They ensure consistency with the upcoming shift from direct references to NuGet package dependency management, thereby enhancing maintainability and future-proofing the project.

Please verify that this update integrates seamlessly with the overall dependency resolution mechanism and is consistent with similar changes made in the VisualStudio.Extension-2022 lock file.

- Also rename fields to follow code style.
Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 0

🧹 Nitpick comments (1)
azure-pipelines.yml (1)

338-341: Clarification: Enable Submodules for VS2022 Job

The VS2022 job’s checkout step now explicitly enables submodules with submodules: true. This change ensures that any required submodules—possibly needed for resolving the new generic support dependencies or related projects—are correctly checked out during the build. Please verify that:

  • These submodules are indeed required only for the VS2022 job.
  • There isn’t a need to enable submodules for the VS2019 job unless those builds also depend on them.

If the intent is to differentiate between the two environments (e.g., using distinct dependency mechanisms), this configuration is appropriate. Otherwise, consider consolidating the checkout settings for consistency.

🧰 Tools
🪛 YAMLlint (1.35.1)

[warning] 338-338: wrong indentation: expected 4 but found 2

(indentation)

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 9cea2ea and e591eaa.

⛔ Files ignored due to path filters (1)
  • nanoFramework.Tools.VisualStudio.sln is excluded by none and included by none
📒 Files selected for processing (1)
  • azure-pipelines.yml (1 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (3)
  • GitHub Check: nanoframework.nf-Visual-Studio-extension (VS2019)
  • GitHub Check: nanoframework.nf-Visual-Studio-extension (VS2022)
  • GitHub Check: nanoframework.nf-Visual-Studio-extension (Get_Build_Options)

- VS2022 job is not checking out sub-modules anymore.
- Add task to upload VSIX to Open VSIX gallery on develop builds.
- Fix condition to create github release only on commits to main branch.
@josesimoes josesimoes changed the base branch from main to develop April 16, 2025 15:30
Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between b76bddf and 98fd497.

⛔ Files ignored due to path filters (1)
  • VisualStudio.Extension-2022/source.extension.vsixmanifest is excluded by none and included by none
📒 Files selected for processing (1)
  • azure-pipelines.yml (2 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (6)
  • GitHub Check: nanoframework.nf-Visual-Studio-extension (VS2022)
  • GitHub Check: nanoframework.nf-Visual-Studio-extension (VS2019)
  • GitHub Check: nanoframework.nf-Visual-Studio-extension (VS2022)
  • GitHub Check: nanoframework.nf-Visual-Studio-extension (VS2019)
  • GitHub Check: nanoframework.nf-Visual-Studio-extension (Get_Build_Options)
  • GitHub Check: nanoframework.nf-Visual-Studio-extension (Get_Build_Options)
🔇 Additional comments (1)
azure-pipelines.yml (1)

312-312: Release trigger condition improved—good practice.

The release creation step now triggers only on the main branch, which is a best practice to avoid accidental releases from develop or other branches.

Also applies to: 511-511

@josesimoes josesimoes merged commit 3aee97b into develop Apr 16, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants