Skip to content

Sets.cartesianProduct.contains' complexity depended on now-removed optimization in Android version #3873

Closed

Description

This was almost certainly my fault, but as I look at the implementation of Sets.cartesianProduct, I think its contains method made the assumption that ImmutableSet.asList().indexOf was O(1), which is no longer the case for Android. It should probably get a specific contains implementation that actually is O(sets), not O(sets*setSize).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions