Github user marmbrus commented on the pull request:
https://github.com/apache/spark/pull/2109#issuecomment-53467276
> What if we just override equals in Attribute?
This is actually how things were implemented originally. However, its
really weird when `AttributeReference("a"...) == AttrributeReference("b",
...)`. It breaks tests, and also makes doing transformations hard (we always
try keep older trees instead of new ones when the transformation was a no-op).
> Does AttributeSet provide anything that Scala's Set doesn't provide?
No, it is actually a subset, this class is just encapsulating a very common
pattern where you create sets that contain expression ids. Furthermore, since
an AttributeSet is not a Set[Attribute] you get nice type errors in many cases
where you are trying to do semantically invalid things.
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]