Skip to content

Nullable annotations for DSP core package, and minor refactoring#2349

Draft
Sombody101 wants to merge 31 commits into
DSharpPlus:masterfrom
Sombody101:master
Draft

Nullable annotations for DSP core package, and minor refactoring#2349
Sombody101 wants to merge 31 commits into
DSharpPlus:masterfrom
Sombody101:master

Conversation

@Sombody101

Copy link
Copy Markdown
Contributor

Summary

Added nullable annotations to class fields/properties, as well as method parameters, and minor refactorings.

Details

A majority of this PR targets the task Nullability-annotating the libraries from #1580, v5 Mega-Issue. There are a few changes that target the task Cleaning up code readability, such as renaming PITA variable names to better match what they represent.

Simple examples include:

  • pld to payload
  • bgn64 to readLongMagic
  • ret to a simplified version of the type name, like webhook or message

Notes

I tried my best to be accurate, but I may have gone overboard in some data models. Please let me know if anything marked as nullable should not be, and I'll make the necessary adjustments to the PR.

@Plerx2493 Plerx2493 marked this pull request as draft July 13, 2025 19:32

@akiraveliara akiraveliara left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

please go through again and revert nullable annotations you added to value types. since value types require nullability to be annotated explicitly, the library is already built for and tested for NVT annotations being correct.

any such changes should be explicitly justified, ideally separate from this PR, because they are behavioural changes that need to be tested and not just annotations that make users' lives easier

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants