Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

OptimizeTypeMemberReflector#2320

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged

Conversation

@jnyrup
Copy link
Member

@jnyrupjnyrup commentedSep 25, 2023
edited
Loading

Picking some low-hanging fruits inTypeMemberReflector to speed it up a bit.

The_Old suffix is the version ofTypeMemberReflector indevelop.
The "Ratio" column is manually calculated asnew / old

MethodMeanRatioErrorStdDevGen0AllocatedRatio
Publicc2.759 us0.550.0548 us0.0631 us0.56463.46 KB0.60
Publicc_Old5.006 us0.0433 us0.0384 us0.93845.77 KB
Public_Internal4.190 us0.600.0386 us0.0342 us0.82405.06 KB0.70
Public_Internal_Old6.947 us0.0212 us0.0177 us1.16737.18 KB
Public_Internal_ExplicitlyImplemented6.302 us0.900.0206 us0.0182 us1.00716.20 KB0.84
Public_Internal_ExplicitlyImplemented_Old7.017 us0.0212 us0.0198 us1.19027.34 KB

IMPORTANT

  • If the PR touches the public API, the changes have been approved in a separate issue with the "api-approved" label.
  • The code complies with theCoding Guidelines for C#.
  • The changes are covered by unit tests which follow the Arrange-Act-Assert syntax and the naming conventions such as is usedin these tests.
  • If the PR adds a feature or fixes a bug, please updatethe release notes with a functional description that explains what the change means to consumers of this library, which are published on thewebsite.
  • If the PR changes the public API the changes needs to be included by runningAcceptApiChanges.ps1 orAcceptApiChanges.sh.
  • If the PR affectsthe documentation, please include your changes in this pull request so the documentation will appear on thewebsite.
    • Please also run./build.sh --target spellcheck or.\build.ps1 --target spellcheck before pushing and check the good outcome

github-actions[bot] reacted with thumbs up emoji
@github-actions
Copy link

github-actionsbot commentedSep 25, 2023
edited
Loading

Qodana for .NET

It seems all right 👌

No new problems were found according to the checks applied

💡 Qodana analysis was run in the pull request mode: only the changed files were checked

View the detailed Qodana report

To be able to view the detailed Qodana report, you can either:

  1. Register atQodana Cloud andconfigure the action
  2. UseGitHub Code Scanning with Qodana
  3. HostQodana report at GitHub Pages
  4. Inspect and useqodana.sarif.json (seethe Qodana SARIF format for details)

To get*.log files or any other Qodana artifacts, run the action withupload-result option set totrue,
so that the action will upload the files as the job artifacts:

      -name:'Qodana Scan'uses:JetBrains/qodana-action@v2023.2.6with:upload-result:true
Contact Qodana team

Contact us atqodana-support@jetbrains.com

@coveralls
Copy link

Pull Request Test Coverage Report forBuild 6303663841

  • 7 of7(100.0%) changed or added relevant lines in1 file are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage decreased (-0.001%) to97.276%

TotalsCoverage Status
Change from baseBuild 6302426774:-0.001%
Covered Lines:11621
Relevant Lines:11827

💛 -Coveralls

@jnyrup
Copy link
MemberAuthor

The file still has 100% line and branch coverage.
The reduction is because we now do the same in less code.

Duplicate check of!field.IsPrivate
image

We null-GuardedGetMethod inIsExplicitImplementation and later removing members without a getter.
image

Copy link
Member

@dennisdoomendennisdoomen left a comment

Choose a reason for hiding this comment

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

What about the Qodana issue?

@jnyrup
Copy link
MemberAuthor

What about the Qodana issue?

Hadn't noticed that.

Qodana cannot see thatHasGetter filters out properties without aGetMethod.

So either the code must be restructured to make that visible to Qodana, or we add! inIsExplicitImplementation

@dennisdoomen
Copy link
Member

So either the code must be restructured to make that visible to Qodana, or we add! inIsExplicitImplementation

That's what my pragmatic mind would do ;-)

@jnyrupjnyrup merged commit97da756 intofluentassertions:developSep 28, 2023
@jnyrupjnyrup deleted the jn/TypeMemberReflector branchSeptember 28, 2023 19:57
This was referencedJul 21, 2025
This was referencedNov 17, 2025
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@dennisdoomendennisdoomendennisdoomen approved these changes

Assignees

No one assigned

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

3 participants

@jnyrup@coveralls@dennisdoomen

[8]ページ先頭

©2009-2025 Movatter.jp