Skip to content

Consolidate on either string.Empty or "" #638

@Shane32

Description

@Shane32

To a huge part a matter of taste, but using the literal "" has a few advantages over using string.Empty (in general, not specifi to this repo):

  • less IL code as the literal is a constant as opposed a field load -> smaller assembly
  • less work for the JIT, as no load and inlining of that field is needed

If a change is done, we should it do for the whole project to be consistent.
If not, I'm also fine with it, as these two listed bullet don't change much here.

This is more a general note.

Originally posted by @gfoidl in #622 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions