Skip to content

Commit 40d1904

Browse files
Merge pull request #12459 from MicrosoftDocs/main
Auto Publish – main to live - 2025-10-22 22:00 UTC
2 parents 8ff14d8 + 8849da7 commit 40d1904

File tree

5 files changed

+32
-18
lines changed

5 files changed

+32
-18
lines changed

reference/5.1/Microsoft.PowerShell.Core/About/about_Classes_Constructors.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
description: Describes how to define constructors for PowerShell classes.
33
Locale: en-US
4-
ms.date: 11/13/2023
4+
ms.date: 10/22/2025
55
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_classes_constructors?view=powershell-5.1&WT.mc_id=ps-gethelp
66
schema: 2.0.0
77
title: about_Classes_Constructors
@@ -393,8 +393,11 @@ For classes that don't inherit from another class, the ordering is:
393393

394394
For derived classes that inherit from another class, the ordering is:
395395

396-
1. The static constructor for the base class.
397-
1. The static constructor for the derived class.
396+
1. If the static constructor of the derived class doesn't depend on the base
397+
class, the static constructor of the derived class is called first.
398+
1. If the static constructor of the derived class depends on the base class,
399+
the static constructor of the base class is called before executing the line
400+
of code in the derived class that depends on base.
398401
1. If the derived class constructor explicitly calls a base constructor
399402
overload, it runs that constructor for the base class. If it doesn't
400403
explicitly call a base constructor, it runs the default constructor for the

reference/5.1/PSReadLine/About/about_PSReadLine_Functions.md

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ description: >
33
This article documents the functions provided by PSReadLine. These functions
44
can be bound to keystrokes for easy access and invocation.
55
Locale: en-US
6-
ms.date: 10/10/2023
6+
ms.date: 06/17/2025
77
online version: https://learn.microsoft.com/powershell/module/psreadline/about/about_psreadline_functions?view=powershell-5.1&WT.mc_id=ps-gethelp
88
schema: 2.0.0
99
title: about_PSReadLine_Functions
@@ -980,18 +980,20 @@ pressing the `#` key sends 10 `#` characters (`##########`) to the input line.
980980
Similarly, you can use this with other operations, like `<Delete>` or
981981
`Left-Arrow`.
982982

983-
- Windows mode: `<Alt+0>`, `<Alt+1>`, `<Alt+2>`, `<Alt+3>`, `<Alt+4>`, `<Alt+5>`,
984-
`<Alt+6>`, `<Alt+7>`, `<Alt+8>`, `<Alt+9>`, `<Alt+->`
983+
- Windows mode: `<Alt+0>`, `<Alt+1>`, `<Alt+2>`, `<Alt+3>`, `<Alt+4>`,
984+
`<Alt+5>`, `<Alt+6>`, `<Alt+7>`, `<Alt+8>`, `<Alt+9>`, `<Alt+->`
985985
- Emacs mode: `<Alt+0>`, `<Alt+1>`, `<Alt+2>`, `<Alt+3>`, `<Alt+4>`, `<Alt+5>`,
986986
`<Alt+6>`, `<Alt+7>`, `<Alt+8>`, `<Alt+9>`, `<Alt+->`
987987
- Vi command mode: `<0>`, `<1>`, `<2>`, `<3>`, `<4>`, `<5>`, `<6>`, `<7>`,
988988
`<8>`, `<9>`
989989

990990
### InvokePrompt
991991

992-
Erases the current prompt and calls the prompt function to redisplay the
993-
prompt. Useful for custom key handlers that change state. For example, change
994-
the current directory.
992+
Attempts to erase the current prompt and call the prompt function to redisplay
993+
the prompt. Useful for custom key handlers that change state. For example,
994+
change the current directory. This method can't overwrite a prompt that has
995+
left the screen buffer. Calls to `InvokePrompt` with no `Y` position argument
996+
return immediately if the prompt can't be overwritten.
995997

996998
- Function is unbound.
997999

reference/7.4/Microsoft.PowerShell.Core/About/about_Classes_Constructors.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
description: Describes how to define constructors for PowerShell classes.
33
Locale: en-US
4-
ms.date: 10/13/2025
4+
ms.date: 10/22/2025
55
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_classes_constructors?view=powershell-7.4&WT.mc_id=ps-gethelp
66
schema: 2.0.0
77
title: about_Classes_Constructors
@@ -392,8 +392,11 @@ For classes that don't inherit from another class, the ordering is:
392392

393393
For derived classes that inherit from another class, the ordering is:
394394

395-
1. The static constructor for the base class.
396-
1. The static constructor for the derived class.
395+
1. If the static constructor of the derived class doesn't depend on the base
396+
class, the static constructor of the derived class is called first.
397+
1. If the static constructor of the derived class depends on the base class,
398+
the static constructor of the base class is called before executing the line
399+
of code in the derived class that depends on base.
397400
1. If the derived class constructor explicitly calls a base constructor
398401
overload, it runs that constructor for the base class. If it doesn't
399402
explicitly call a base constructor, it runs the default constructor for the

reference/7.5/Microsoft.PowerShell.Core/About/about_Classes_Constructors.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
description: Describes how to define constructors for PowerShell classes.
33
Locale: en-US
4-
ms.date: 10/13/2025
4+
ms.date: 10/22/2025
55
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_classes_constructors?view=powershell-7.5&WT.mc_id=ps-gethelp
66
schema: 2.0.0
77
title: about_Classes_Constructors
@@ -392,8 +392,11 @@ For classes that don't inherit from another class, the ordering is:
392392

393393
For derived classes that inherit from another class, the ordering is:
394394

395-
1. The static constructor for the base class.
396-
1. The static constructor for the derived class.
395+
1. If the static constructor of the derived class doesn't depend on the base
396+
class, the static constructor of the derived class is called first.
397+
1. If the static constructor of the derived class depends on the base class,
398+
the static constructor of the base class is called before executing the line
399+
of code in the derived class that depends on base.
397400
1. If the derived class constructor explicitly calls a base constructor
398401
overload, it runs that constructor for the base class. If it doesn't
399402
explicitly call a base constructor, it runs the default constructor for the

reference/7.6/Microsoft.PowerShell.Core/About/about_Classes_Constructors.md

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
description: Describes how to define constructors for PowerShell classes.
33
Locale: en-US
4-
ms.date: 10/13/2025
4+
ms.date: 10/22/2025
55
online version: https://learn.microsoft.com/powershell/module/microsoft.powershell.core/about/about_classes_constructors?view=powershell-7.6&WT.mc_id=ps-gethelp
66
schema: 2.0.0
77
title: about_Classes_Constructors
@@ -392,8 +392,11 @@ For classes that don't inherit from another class, the ordering is:
392392

393393
For derived classes that inherit from another class, the ordering is:
394394

395-
1. The static constructor for the base class.
396-
1. The static constructor for the derived class.
395+
1. If the static constructor of the derived class doesn't depend on the base
396+
class, the static constructor of the derived class is called first.
397+
1. If the static constructor of the derived class depends on the base class,
398+
the static constructor of the base class is called before executing the line
399+
of code in the derived class that depends on base.
397400
1. If the derived class constructor explicitly calls a base constructor
398401
overload, it runs that constructor for the base class. If it doesn't
399402
explicitly call a base constructor, it runs the default constructor for the

0 commit comments

Comments
 (0)