Visitar URL original
SystemIo: target .NET 10 by ghostflyby · Pull Request #250 · ForNeVeR/TruePath · GitHub
Skip to content

SystemIo: target .NET 10 - #250

Open
ghostflyby wants to merge 1 commit into
ForNeVeR:mainfrom
ghostflyby:pathio-net10
Open

ghostflyby wants to merge 1 commit into
ForNeVeR:mainfrom
ghostflyby:pathio-net10

Conversation

@ghostflyby

Copy link
Copy Markdown
Contributor

Depends on #249 — this PR is stacked on top of the source generator change and should be merged after it. Until #249 merges, the diff below includes its commits.

Summary

Add a net10.0 target (the current LTS) to TruePath.SystemIo. With the source generator from #249 in place this is a one-line change that automatically exposes the .NET 10 BCL surface for file and directory operations: 112 extension methods on this target, including the new span- and Memory-based overloads:

  • AppendAllText/WriteAllText with ReadOnlySpan contents,
  • AppendAllBytes/WriteAllBytes with ReadOnlySpan,
  • the ReadOnlyMemory-based async counterparts of all of the above.

The existing netstandard2.0 and net8.0 targets are unchanged.

Changes

  • TruePath.SystemIo: add net10.0 to TargetFrameworks; no other change is needed because the generator projects the per-target-framework BCL automatically.
  • TruePath.Tests: add a net10.0 target so the reflection completeness test validates the generated net10.0 surface against the matching runtime.

Testing

Add a net10.0 target (the current LTS) to TruePath.SystemIo. With the source
generator from ForNeVeR#249 in place this is nearly a one-line change: the generator
projects the per-target-framework BCL automatically, exposing 123 extension
methods on this target, including the new span- and Memory-based overloads:

- AppendAllText/WriteAllText with ReadOnlySpan<char> contents,
- AppendAllBytes/WriteAllBytes with ReadOnlySpan<byte>,
- the ReadOnlyMemory-based async counterparts of all of the above.

The existing netstandard2.0 and net8.0 targets are unchanged.

The net10.0 public API baseline records the 110 members that already exist on the
other targets as shipped, and only the 14 span- and Memory-based overloads this
target adds as unshipped. Keeping them shipped matches how the net8.0 and
netstandard2.0 baselines are maintained: each lists the full API surface of its
target at the last release rather than its difference from the other targets.

TruePath.Tests also gains a net10.0 target so the reflection completeness test
validates the generated net10.0 surface against the matching runtime.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant