Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Behavior of default implementations #3186

Open
schillic opened this issue Nov 4, 2022 · 0 comments
Open

Behavior of default implementations #3186

schillic opened this issue Nov 4, 2022 · 0 comments
Labels
discussion 🗣️ Requires human input

Comments

@schillic
Copy link
Member

schillic commented Nov 4, 2022

There are three ways we define fallback functions without implementation. I think we should use the same way consistently.

  1. Sometimes we just declare a function:

function σ end

  1. Sometimes we throw an error:

function isoperationtype(X::Type{<:ConvexSet})
error("`isoperationtype` is not implemented for type $X")
end

  1. Sometimes we return false as conservative answer (of course this only applies to functions that return true/false):

isconvextype(X::Type{<:LazySet}) = false

@schillic schillic added the discussion 🗣️ Requires human input label Nov 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discussion 🗣️ Requires human input
Projects
None yet
Development

No branches or pull requests

1 participant