static EnumDataset <E, T> emit <E, T>(ReadOnlySpan <EnumLiteralInfo <E, T> > src, FS.FilePath dst) where E : unmanaged, Enum where T : unmanaged { using var writer = dst.Writer(); writer.WriteLine(header <F>()); var dataset = EnumDatasets.create <E, T>(); for (var i = 0; i < src.Length; i++) { writer.WriteLine(EnumDatasets.format(src[i])); } return(dataset); }
static EnumDataset <E, T> EmitDataset <E, T>(FS.FilePath dst) where E : unmanaged, Enum where T : unmanaged { using var writer = dst.Writer(); writer.WriteLine(header <F>()); var dataset = EnumDatasets.create <E, T>(); for (var i = 0; i < dataset.EntryCount; i++) { writer.WriteLine(EnumDatasets.format(dataset[i])); } return(dataset); }