Skip to content

Commit 172fb08

Browse files
committed
Add Copilot notes
1 parent da05752 commit 172fb08

2 files changed

Lines changed: 173 additions & 0 deletions

File tree

Lines changed: 55 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,55 @@
1+
# Plan: Apply 18 Git Patches for C# 9/10 Features
2+
3+
Sequential application of 18 git patches to the current branch, adding C# 9 and 10 language features to the standard specification. After each patch, pause for user validation. Track changes via both git history and detailed notes to resolve conflicts caused by earlier patches in the series.
4+
5+
## Workflow
6+
7+
For each patch URL provided by the user:
8+
9+
1. **Download and preview patch**: Use curl to download patch file, parse to identify affected files, report to user for context preparation
10+
2. **Apply with git am**: Execute `git am <patchfile>` and monitor for success or conflicts
11+
3. **Resolve conflicts using dual tracking**: First adjust patch file line numbers; if unsuccessful, consult both git diff history and maintained notes of section changes to merge updates from earlier patches with current patch
12+
4. **Document and pause**: After successful application, record modified sections and line ranges in notes, summarize feature changes, stop for user validation
13+
5. **Iterate through series**: Once user confirms, delete patch file and repeat for next patch URL
14+
15+
## Conflict Resolution Strategy
16+
17+
- **Primary approach**: Edit patch file to update line numbers and locations when git am fails
18+
- **Secondary approach**: Manually merge changes by consulting:
19+
- Git history showing what previous patches modified
20+
- Running notes of key section modifications per file
21+
- **Key principle**: Accept changes from both patches and merge updates, as each patch was originally non-conflicting
22+
23+
## Change Tracking
24+
25+
Maintain notes for files with high conflict risk:
26+
- **expressions.md** (12 patches) - most heavily modified
27+
- **classes.md** (5 patches)
28+
- **lexical-structure.md** (5 patches)
29+
- **conversions.md** (4 patches)
30+
- **portability-issues.md** (4 patches)
31+
32+
For each successfully applied patch, document:
33+
- Modified sections and approximate line ranges
34+
- Nature of changes (new sections, grammar updates, cross-reference additions)
35+
- Any renumbering or structural changes that might affect subsequent patches
36+
37+
## Patch Application Order
38+
39+
The user will provide patch URLs in their chosen order. The planned order from the prompt file is:
40+
41+
***fill in using algorithm form [notes](./alpha-branch-creation.md).***
42+
43+
## Session Management
44+
45+
- All patches applied in one continuous session to maintain full context and change history
46+
- User validation checkpoint after each patch before proceeding to next
47+
- No intermediate validation tools (grammar checks, example extraction) between patches
48+
- All patches applied directly to current branch (no feature branch creation)
49+
50+
## Success Criteria
51+
52+
- All 18 patches successfully applied with git commits
53+
- Working directory clean after entire series
54+
- User validates correctness after each patch application
55+
- Change notes maintained for conflict resolution reference

admin/alpha-branch-creation.md

Lines changed: 118 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,118 @@
1+
# Process to create an alpha branch for an upcoming version
2+
3+
Base a new version branch off the previous version's "feature complete alpha branch". That should provide the structure for the content coming in the ealier versions.
4+
5+
> This does increase the likelihood of merge conflicts as the "draft-vN" branch matures, and that work is merged into the earlier versions "feature complete alpha branch". The plan is to merge the draft-vN work into the corresponding "feature complete alpha" branch after each committee meeting. That should pay dividends as we move through upcoming versions.
6+
7+
## Ordering patches
8+
9+
Copilot can do a good job managing conflicts when applying patches, unless the scope of merge conflicts becomes too great. As a result, the order of applying patches is important. After several experiments, the best order is to apply the patches from most files changed to fewest files changes. Where different patches have changed the same number of files, order should work to minimize the potential conflict opportunities.
10+
11+
For example, this order worked best for V9:
12+
13+
1. *Native integers*
14+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1457.patch
15+
- Medium - 9 files, 0 potential conflict opportunities
16+
- arrays.md
17+
- classes.md
18+
- conversions.md
19+
- enums.md
20+
- expressions.md
21+
- lexical-structure.md
22+
- portability-issues.md
23+
- statements.md
24+
- types.md
25+
- unsafe-code.md
26+
- variables.md
27+
1. *Init Accessors*
28+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1452.patch
29+
- Medium 7 files, 4 potential conflict opportunities
30+
- attributes.md
31+
- basic-concepts.md
32+
- classes.md: 1
33+
- expressions.md: 1
34+
- interfaces.md
35+
- lexical-structure.md: 1
36+
- portability-issues.md: 1
37+
1. *Function pointers*
38+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1459.patch
39+
- Large - 6 files, 8 potential conflict opportunities
40+
- expressions.md: 2
41+
- lexical-structure.md: 2
42+
- portability-issues.md: 2
43+
- standard-library.md
44+
- types.md: 1
45+
- unsafe-code.md: 1
46+
1. *Static anonymous functions*
47+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1461.patch
48+
- Small - 4 files, 5 potential conflict opportunities
49+
- conversions.md: 1
50+
- expressions.md: 2
51+
- unsafe-code.md: 1
52+
- variables.md: 1
53+
1. *Top level statements*
54+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1454.patch
55+
- Medium - 4 files, 3 potential conflict opportunities
56+
- attributes.md: 1
57+
- basic-concepts.md
58+
- namespaces.md
59+
- portability-issues.md: 3
60+
1. *Records*
61+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1458.patch
62+
- Large - 3 files, 7 potential conflict opportunities
63+
- classes.md: 2
64+
- expressions.md: 3
65+
- lexical-structure.md: 2
66+
1. *Covariant return types*
67+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1462.patch
68+
- Small - 3 files, 8 potential conflict opportuntities (this was the toughest set of conflicts)
69+
- classes.md: 3
70+
- expressions.md: 4
71+
- interfaces.md: 1
72+
1. *Target-typed new*
73+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1469.patch
74+
- Small - 3 files, 8 potential conflict opportunities
75+
- conversions.md: 2
76+
- expressions.md: 5
77+
- statements.md: 1
78+
1. *Module initializers*
79+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1467.patch
80+
- Small - 3 files, 5 potential conflict opportunities
81+
- attributes.md: 2
82+
- portability-issues.md: 3
83+
- standard-library.md
84+
1. *Target-typed conditional expressions*
85+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1465.patch
86+
- Small - 2 files, 8 potential conflict opportunities. (This set was also very difficult conflicts)
87+
- conversions.md: 3
88+
- expressions.md: 5
89+
1. *Pattern matching*
90+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1460.patch
91+
- Medium - 2 files, 3 potential conflict opportunities
92+
- lexical-structure.md: 3
93+
- patterns.md
94+
1. *Attributes and extern on local functions*
95+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1466.patch
96+
- Small - 2 files, 3 potential conflict opportunities
97+
- attributes.md: 2
98+
- statements.md: 1
99+
1. *More better nullable*
100+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1221.patch
101+
- Small - 2 files, 3 potential conflict opportunities
102+
- attributes.md: 3
103+
- standard-library
104+
1. *Lambda discard parameters*
105+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1464.patch
106+
- Small - expressions.md: 6
107+
1. *New features for partial members*
108+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1468.patch
109+
- Small - classes.md: 3
110+
1. *Unconstrained type parameter annotations*
111+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1470.patch
112+
- Small - classes.md: 4
113+
1. *Variance safety for static interface members*
114+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1471.patch
115+
- Small - interfaces.md: 2
116+
1. *Extension GetEnumerator in foreach*
117+
- https://patch-diff.githubusercontent.com/raw/dotnet/csharpstandard/pull/1472.patch
118+
- Small - statements.md: 1

0 commit comments

Comments
 (0)