Skip to content

DefineWithMethodsPerProperty = true fails when source doc has no using for ImmutableObjectGraph #108

Open
@AArnott

Description

@AArnott

When a file wants helper methods:

[GenerateImmutable(DefineWithMethodsPerProperty = true)]
public partial class X
{
    private readonly ImmutableList<int> values;
}

And that file does not have this line:

using ImmutableObjectGraph;

The generated code won't compile because extension method syntax is used that assumes that is present.

Similar to #104

Metadata

Metadata

Assignees

Labels

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions