Skip to content
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

[hot_reload] Mono should ignore Param table row updates #56574

Closed
Tracked by #44806
lambdageek opened this issue Jul 29, 2021 · 1 comment · Fixed by #56800
Closed
Tracked by #44806

[hot_reload] Mono should ignore Param table row updates #56574

lambdageek opened this issue Jul 29, 2021 · 1 comment · Fixed by #56800
Assignees
Labels
area-EnC-mono Hot Reload for WebAssembly, iOS/Android, etc
Milestone

Comments

@lambdageek
Copy link
Member

Roslyn will emit these for changes like this:

Old code:

    public class MethodBody1 {
        public static string StaticMethod1 () {
            Func <string,string> fn = static (s) => s + "G";
            return fn ("OLD STRIN");
        }
    }

New code:

    public class MethodBody1 {
        public static string StaticMethod1 () {
            Func <string,string> fn = static (s) => s + "G";
            return fn ("NEW STRIN");
        }
    }

Roslyn will emit a param update for 's' even though nothing about the parameter has changed.

(Note that to get a clean delta it's necessary to use hotreload-utils that includes dotnet/hotreload-utils#65, otherwise the delta will be bloated with unnecessary field and method additions for the (unchanged) lambda).

This is part of #44806

@lambdageek lambdageek added the area-EnC-mono Hot Reload for WebAssembly, iOS/Android, etc label Jul 29, 2021
@lambdageek lambdageek added this to the 6.0.0 milestone Jul 29, 2021
@lambdageek lambdageek self-assigned this Jul 29, 2021
@dotnet-issue-labeler dotnet-issue-labeler bot added the untriaged New issue has not been triaged by the area owner label Jul 29, 2021
@jeffschwMSFT jeffschwMSFT removed the untriaged New issue has not been triaged by the area owner label Jul 31, 2021
@ghost ghost added the in-pr There is an active PR which will close this issue when it is merged label Aug 3, 2021
@ghost ghost removed the in-pr There is an active PR which will close this issue when it is merged label Aug 4, 2021
@lambdageek
Copy link
Member Author

The issue description is misleading. Roslyn generates these Param table updates for normal methods, too. Not just for lambdas.

  public virtual void (Builder builder) {
    builder.BuildString ("abcd");
  }
  public virtual void (Builder builder) {
    builder.BuildString ("defg");
  }

In this case, too Roslyn emits a Param update for builder.

@ghost ghost locked as resolved and limited conversation to collaborators Sep 11, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area-EnC-mono Hot Reload for WebAssembly, iOS/Android, etc
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants