Skip to content
This repository has been archived by the owner on Jan 18, 2022. It is now read-only.

Commit

Permalink
T -> TDetails, TR -> TGenOutput
Browse files Browse the repository at this point in the history
Signed-off-by: Paul Balaji <[email protected]>
  • Loading branch information
Paul Balaji committed Feb 17, 2020
1 parent 49b11bf commit 5e53f4e
Showing 1 changed file with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -86,14 +86,14 @@ protected void AddJobTarget(string filePath, Func<string> generateFunc)
jobTargets.Add(new JobTarget(Path.Combine(OutputDirectory, filePath), generateFunc));
}

protected delegate TR GenerateDelegate<in T, out TR>(T details)
where T : GeneratorInputDetails;
protected delegate TGenOutput GenerateDelegate<in TDetails, out TGenOutput>(TDetails details)
where TDetails : GeneratorInputDetails;

protected delegate (string relativeFilePath, GenerateDelegate<T, TR> generateFunc) GeneratorSetupDelegate<T, TR>(T details)
where T : GeneratorInputDetails;
protected delegate (string relativeFilePath, GenerateDelegate<TDetails, TGenOutput> generateFunc) GeneratorSetupDelegate<TDetails, TGenOutput>(TDetails details)
where TDetails : GeneratorInputDetails;

protected void AddGenerators<T>(IEnumerable<T> details, params GeneratorSetupDelegate<T, CodeWriter.CodeWriter>[] generatorSetupDelegates)
where T : GeneratorInputDetails
protected void AddGenerators<TDetails>(IEnumerable<TDetails> details, params GeneratorSetupDelegate<TDetails, CodeWriter.CodeWriter>[] generatorSetupDelegates)
where TDetails : GeneratorInputDetails
{
jobTargets.AddRange(details.SelectMany(detail =>
{
Expand All @@ -105,8 +105,8 @@ protected void AddGenerators<T>(IEnumerable<T> details, params GeneratorSetupDel
}));
}

protected void AddGenerators<T>(IEnumerable<T> details, params GeneratorSetupDelegate<T, string>[] generatorSetupDelegates)
where T : GeneratorInputDetails
protected void AddGenerators<TDetails>(IEnumerable<TDetails> details, params GeneratorSetupDelegate<TDetails, string>[] generatorSetupDelegates)
where TDetails : GeneratorInputDetails
{
jobTargets.AddRange(details.SelectMany(detail =>
{
Expand Down

0 comments on commit 5e53f4e

Please sign in to comment.