Skip to content
Open
Changes from all commits
Commits
Show all changes
26 commits
Select commit Hold shift + click to select a range
69f41a8
Update access-modifiers.md
bigboybamo Jun 11, 2024
b0e8850
Merge branch 'dotnet:main' into main
bigboybamo Jul 2, 2024
9afec84
Merge branch 'dotnet:main' into main
bigboybamo Aug 14, 2024
52abccd
Merge branch 'dotnet:main' into main
bigboybamo Aug 14, 2024
1706ff9
Merge branch 'dotnet:main' into main
bigboybamo Oct 1, 2024
8f859cb
Merge branch 'dotnet:main' into main
bigboybamo Oct 7, 2024
b638380
Merge branch 'dotnet:main' into main
bigboybamo Oct 10, 2024
f2a5570
Merge branch 'dotnet:main' into main
bigboybamo Nov 18, 2024
64c4bf8
Merge branch 'dotnet:main' into main
bigboybamo Dec 12, 2024
f66fddb
Merge branch 'dotnet:main' into main
bigboybamo Mar 11, 2025
78d4328
Merge branch 'dotnet:main' into main
bigboybamo Mar 21, 2025
ff4942a
Merge branch 'dotnet:main' into main
bigboybamo Mar 22, 2025
3042dbd
Merge branch 'dotnet:main' into main
bigboybamo Apr 5, 2025
bde738f
Merge branch 'dotnet:main' into main
bigboybamo Jun 9, 2025
9959d7a
Merge branch 'dotnet:main' into main
bigboybamo Jun 9, 2025
8ba2760
Merge branch 'dotnet:main' into main
bigboybamo Jul 2, 2025
995a0ec
Merge branch 'dotnet:main' into main
bigboybamo Jul 8, 2025
a9d399e
Merge branch 'dotnet:main' into main
bigboybamo Jul 31, 2025
68e5219
Merge branch 'dotnet:main' into main
bigboybamo Aug 21, 2025
a72eede
Merge branch 'dotnet:main' into main
bigboybamo Sep 25, 2025
7cd0684
Merge branch 'dotnet:main' into main
bigboybamo Oct 4, 2025
e1545bb
Merge branch 'dotnet:main' into main
bigboybamo Oct 8, 2025
d631fdd
Merge branch 'dotnet:main' into main
bigboybamo Nov 3, 2025
8ce5573
Merge branch 'dotnet:main' into main
bigboybamo Nov 10, 2025
4f82be0
Merge branch 'dotnet:main' into main
bigboybamo Nov 14, 2025
9ba23e6
Revise access modifiers summary table
bigboybamo Nov 14, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,14 @@ The [`record`](../../language-reference/builtin-types/record.md) modifier on a t

## Summary table

| Caller's location | `public` | `protected internal` | `protected` | `internal` | `private protected` | `private` | `file` |
|--|:-:|:-:|:-:|:-:|:-:|:-:|:-:|
| Within the file | ✔️️ | ✔️ | ✔️ | ✔️ | ✔️ | ✔️ | ✔️ |
| Within the class | ✔️️ | ✔️ | ✔️ | ✔️ | ✔️ | ✔️ | ❌ |
| Derived class (same assembly) | ✔️ | ✔️ | ✔️ | ✔️ | ✔️ | ❌ | ❌ |
| Non-derived class (same assembly) | ✔️ | ✔️ | ❌ | ✔️ | ❌ | ❌ | ❌ |
| Derived class (different assembly) | ✔️ | ✔️ | ✔️ | ❌ | ❌ | ❌ | ❌ |
| Non-derived class (different assembly) | ✔️ | ❌ | ❌ | ❌ | ❌ | ❌ | ❌ |
| Caller's location | `public` | `protected internal` | `protected` | `internal` | `private protected` | `private` |
|--|:-:|:-:|:-:|:-:|:-:|:-:|
| Within the file | ✔️️ | ✔️ | ✔️ | ✔️ | ✔️ | ✔️ |
| Within the class | ✔️️ | ✔️ | ✔️ | ✔️ | ✔️ | ✔️ |
| Derived class (same assembly) | ✔️ | ✔️ | ✔️ | ✔️ | ✔️ | ❌ |
| Non-derived class (same assembly) | ✔️ | ✔️ | ❌ | ✔️ | ❌ | ❌ |
| Derived class (different assembly) | ✔️ | ✔️ | ✔️ | ❌ | ❌ | ❌ |
| Non-derived class (different assembly) | ✔️ | ❌ | ❌ | ❌ | ❌ | ❌ |

The following examples demonstrate how to specify access modifiers on a type and member:

Expand Down
Loading