-
Notifications
You must be signed in to change notification settings - Fork 8.2k
Get-Member should show extension methods #11798
Copy link
Copy link
Closed
Labels
Issue-Enhancementthe issue is more of a feature request than a bugthe issue is more of a feature request than a bugResolution-No ActivityIssue has had no activity for 6 months or moreIssue has had no activity for 6 months or moreWG-Cmdlets-Utilitycmdlets in the Microsoft.PowerShell.Utility modulecmdlets in the Microsoft.PowerShell.Utility module
Metadata
Metadata
Assignees
Labels
Issue-Enhancementthe issue is more of a feature request than a bugthe issue is more of a feature request than a bugResolution-No ActivityIssue has had no activity for 6 months or moreIssue has had no activity for 6 months or moreWG-Cmdlets-Utilitycmdlets in the Microsoft.PowerShell.Utility modulecmdlets in the Microsoft.PowerShell.Utility module
Summary of the new feature/enhancement
PowerShell engine adds
.Whereand.ForEachextension methods to IEnumerable collections. There is code to support tab completion, but when a user inspects an object viaGet-Member, they don't show up.Proposed technical implementation details (optional)
Since we know these extension methods are available on IEnumerable collections, we should just expose them via
Get-Memberand call the MemberTypeExtensionMethod. Formatting would need to increase the column width by 1 to accommodate.Also return the overload definitions like other methods: