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

[CoreCLR] Code cleanup and filling-in gaps#10148

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
grendello merged 4 commits intomainfromdev/grendel/clr-host-cleanup
May 26, 2025

Conversation

@grendello
Copy link
Contributor

@grendellogrendello commentedMay 22, 2025
edited
Loading

This PR performs a comprehensive code cleanup by converting function parameter types and log messages to use std::string_view literal (sv) syntax and by removing unused or redundant parameters. Key changes include:

Updating function signatures to replace const char* with std::string_view and removal of unused parameters.Converting logging format strings throughout the codebase to use the new sv literal.Minor refactoring in host and assembly-related source files to improve code consistency.

@grendellogrendelloforce-pushed thedev/grendel/clr-host-cleanup branch from543b10a toa7599fbCompareMay 23, 2025 14:51
This needs to be revisited after the GC bridge is in. It is alsopossible that there is a problem in JI / Mono.Android.dll whichcauses this issue.
@grendellogrendelloforce-pushed thedev/grendel/clr-host-cleanup branch fromfc706c4 to43dfeccCompareMay 26, 2025 07:20
@grendellogrendello requested a review fromCopilotMay 26, 2025 08:31
Copy link

CopilotAI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR performs a comprehensive code cleanup by converting function parameter types and log messages to use std::string_view literal (sv) syntax and by removing unused or redundant parameters. Key changes include:

  • Updating function signatures to replace const char* with std::string_view and removal of unused parameters.
  • Converting logging format strings throughout the codebase to use the new sv literal.
  • Minor refactoring in host and assembly-related source files to improve code consistency.

Reviewed Changes

Copilot reviewed 12 out of 12 changed files in this pull request and generated 1 comment.

Show a summary per file
FileDescription
src/native/clr/include/runtime-base/util.hhUpdated set_environment_variable_for_directory() parameter type to use std::string_view.
src/native/clr/include/host/runtime-util.hhUpdated get_class_from_runtime_field() parameter type to std::string_view.
src/native/clr/include/host/assembly-store.hhRemoved the force_rw parameter from get_assembly_data() to simplify the API.
src/native/clr/host/typemap.ccUpdated log_debug() and log_warn() calls to include sv literal suffix.
src/native/clr/host/runtime-util.ccUpdated get_class_from_runtime_field() to use std::string_view and .data() accordingly.
src/native/clr/host/pinvoke-override.ccConverted logging calls to use the sv literal and ensured consistent formatting.
src/native/clr/host/os-bridge.ccUpdated include directive and logging calls to use RuntimeUtil and sv literal suffix.
src/native/clr/host/internal-pinvokes.ccDisabled a problematic log call (with appropriate comments) and updated logging syntax.
src/native/clr/host/host.ccAdded [[maybe_unused]] attributes, updated logging calls to sv literal, and refined env var usage.
src/native/clr/host/host-jni.ccMarked JNI methods with TODO comments for future implementation.
src/native/clr/host/fastdev-assemblies.ccUpdated logging calls to use sv literal suffix consistently.
src/native/clr/host/assembly-store.ccRemoved force_rw parameter use in get_assembly_data() and updated log messages to sv literal.
Comments suppressed due to low confidence (1)

src/native/clr/include/host/assembly-store.hh:27

  • The removal of the 'force_rw' parameter from get_assembly_data() alters its public API. Please confirm that this change is intentional and that all call sites no longer require the force_rw behavior.
static auto get_assembly_data (AssemblyStoreSingleAssemblyRuntimeData const& e, std::string_view const& name, bool force_rw = false) noexcept -> std::tuple<uint8_t*, uint32_t>;

@grendellogrendello marked this pull request as ready for reviewMay 26, 2025 08:52
@grendellogrendello merged commita3d4825 intomainMay 26, 2025
59 checks passed
@grendellogrendello deleted the dev/grendel/clr-host-cleanup branchMay 26, 2025 09:01
@github-actionsgithub-actionsbot locked and limited conversation to collaboratorsJun 25, 2025
Sign up for freeto subscribe to this conversation on GitHub. Already have an account?Sign in.

Reviewers

Copilot code reviewCopilotCopilot left review comments

@jonathanpeppersjonathanpeppersAwaiting requested review from jonathanpeppersjonathanpeppers is a code owner

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

2 participants

@grendello

[8]ページ先頭

©2009-2025 Movatter.jp