Update generator to implement ID2D1PixelShaderDescriptor<T>
このコミットが含まれているのは:
1 親
85fd44d863
コミット
1a94d017bb
14ファイル変更
+53
-26
検索条件に一致するファイルはありません
@@ -48,8 +48,13 @@ internal sealed partial record HierarchyInfo(string FullyQualifiedMetadataName,
|
||||
/// <typeparam name="T">The type of state to pass to callbacks.</typeparam>
|
||||
/// <param name="state">The input state to pass to callbacks.</param>
|
||||
/// <param name="writer">The target <see cref="IndentedTextWriter"/> instance to write text to.</param>
|
||||
/// <param name="baseTypes">A list of base types to add to the generated type, if any.</param>
|
||||
/// <param name="memberCallbacks">The callbacks to use to write members into the declared type.</param>
|
||||
public void WriteSyntax<T>(T state, IndentedTextWriter writer, ReadOnlySpan<IndentedTextWriter.Callback<T>> memberCallbacks)
|
||||
public void WriteSyntax<T>(
|
||||
T state,
|
||||
IndentedTextWriter writer,
|
||||
ReadOnlySpan<string> baseTypes,
|
||||
ReadOnlySpan<IndentedTextWriter.Callback<T>> memberCallbacks)
|
||||
{
|
||||
// Write the generated file header
|
||||
writer.WriteLine("// <auto-generated/>");
|
||||
@@ -68,7 +73,20 @@ internal sealed partial record HierarchyInfo(string FullyQualifiedMetadataName,
|
||||
for (int i = Hierarchy.Length - 1; i >= 0; i--)
|
||||
{
|
||||
writer.WriteLine($$"""/// <inheritdoc cref="{{Hierarchy[i].QualifiedName}}"/>""");
|
||||
writer.WriteLine($$"""partial {{Hierarchy[i].GetTypeKeyword()}} {{Hierarchy[i].QualifiedName}}""");
|
||||
writer.Write($$"""partial {{Hierarchy[i].GetTypeKeyword()}} {{Hierarchy[i].QualifiedName}}""");
|
||||
|
||||
// Add any base types, if needed
|
||||
if (i == 0 && !baseTypes.IsEmpty)
|
||||
{
|
||||
writer.Write(" : ");
|
||||
writer.WriteInitializationExpressions(baseTypes, static (item, writer) => writer.Write(item));
|
||||
writer.WriteLine();
|
||||
}
|
||||
else
|
||||
{
|
||||
writer.WriteLine();
|
||||
}
|
||||
|
||||
writer.WriteLine($$"""{""");
|
||||
writer.IncreaseIndent();
|
||||
}
|
||||
|
||||
新しいイシューから参照
ユーザーをブロックする