Title: PowerShell classes still can't create value types · Issue #10669 · PowerShell/PowerShell · GitHub
Open Graph Title: PowerShell classes still can't create value types · Issue #10669 · PowerShell/PowerShell
X Title: PowerShell classes still can't create value types · Issue #10669 · PowerShell/PowerShell
Description: Steps to reproduce Try to implement any interfaces that is intended to be implemented in terms of yourself, E.g. IEquatable, IComparable: class ServerName : Object, System.IEquatable[ServerName] { [string]$ComputerName [bool] Equals([Ser...
Open Graph Description: Steps to reproduce Try to implement any interfaces that is intended to be implemented in terms of yourself, E.g. IEquatable, IComparable: class ServerName : Object, System.IEquatable[ServerName] { ...
X Description: Steps to reproduce Try to implement any interfaces that is intended to be implemented in terms of yourself, E.g. IEquatable, IComparable: class ServerName : Object, System.IEquatable[ServerName] { ...
Opengraph URL: https://github.com/PowerShell/PowerShell/issues/10669
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"PowerShell classes still can't create value types","articleBody":"# Steps to reproduce\r\n\r\nTry to implement any interfaces that is intended to be implemented in terms of yourself, E.g. IEquatable, IComparable:\r\n\r\n```powershell\r\nclass ServerName : Object, System.IEquatable[ServerName] {\r\n [string]$ComputerName\r\n [bool] Equals([ServerName]$other) {\r\n return $this.ComputerName.Equals($other.ComputerName);\r\n }\r\n}\r\n```\r\n\r\n# Expected behavior\r\n\r\n```none\r\nI should be able to write IEquatable\u003cT> and IComparable\u003cT> classes \r\n```\r\n\r\n# Actual behavior\r\nA runtime compile error:\r\n```none\r\nAn error occurred while creating the pipeline.\r\n+ CategoryInfo : NotSpecified: (:) [], ParentContainsErrorRecordException + FullyQualifiedErrorId : RuntimeException \r\n```\r\n\r\n# Environment data\r\n\r\nAny version of PowerShell since classes were introduced, up to and including 7 Pre 4","author":{"url":"https://github.com/Jaykul","@type":"Person","name":"Jaykul"},"datePublished":"2019-10-01T19:49:58Z","url":"https://github.com/PowerShell/PowerShell/issues/10669"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:a593e045-9ded-e4b7-c21e-f0f512b7eb05 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | 8244:1316A0:7FB90C:B37499:6AFDC4B5 |
| html-safe-nonce | b082ff48d3193b2a875a2bc6745c6c63993cd182220636cb03399d86f682dc69 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI4MjQ0OjEzMTZBMDo3RkI5MEM6QjM3NDk5OjZBRkRDNEI1IiwidmlzaXRvcl9pZCI6IjQ5MjUyNDU2MzA5OTQ4MjY0MjEiLCJyZWdpb25fZWRnZSI6ImlhZCIsInJlZ2lvbl9yZW5kZXIiOiJpYWQifQ== |
| visitor-hmac | f77fa2ad1d182e74e22240d13f1c43a8570fe1c6f68cf04383a895195e7ef166 |
| hovercard-subject-tag | issue:501109147 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/PowerShell/PowerShell/10669/issue_layout |
| twitter:image | https://opengraph.githubassets.com/2d3d9152c4c3b78ab95557e82e5a13363c37565d112349f2c54856048a743c75/PowerShell/PowerShell/issues/10669 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/2d3d9152c4c3b78ab95557e82e5a13363c37565d112349f2c54856048a743c75/PowerShell/PowerShell/issues/10669 |
| og:image:alt | Steps to reproduce Try to implement any interfaces that is intended to be implemented in terms of yourself, E.g. IEquatable, IComparable: class ServerName : Object, System.IEquatable[ServerName] { ... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | Jaykul |
| hostname | github.com |
| expected-hostname | github.com |
| None | 9ab00cc3b4fa90bbd3da70765dd38efc23cfa9d9b0930e41feea2bf67f60ecaf |
| turbo-cache-control | no-preview |
| go-import | github.com/PowerShell/PowerShell git https://github.com/PowerShell/PowerShell.git |
| octolytics-dimension-user_id | 11524380 |
| octolytics-dimension-user_login | PowerShell |
| octolytics-dimension-repository_id | 49609581 |
| octolytics-dimension-repository_nwo | PowerShell/PowerShell |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 49609581 |
| octolytics-dimension-repository_network_root_nwo | PowerShell/PowerShell |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 1b795ba060b92691fc16c5a12cf2bf95e83432b4 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
Viewport: width=device-width