Kilo7
Kilo7

Reputation: 31

Filepath of the assembly being analyzed by C# source generator

How do I find the full filepath of the assembly being analyzed by a C# source generator? I searched everywhere under context.SemanticModel.Compilation but I cannot find this information.

I am able to find the sources file location and the full file path of the referenced assemblies used by the assembly being analyzed but not the one of the assembly being analyzed!!

Can someone help?

Upvotes: 1

Views: 469

Answers (1)

Kilo7
Kilo7

Reputation: 31

After posting the question I realized that this is not possible....and after describing the problem to a colleague I came to the realization that this is not provided because the assembly would not have been compiled yet.

Upvotes: 1

Related Questions