Skip to content

Unsupported types raise Protocol.Undefined#187

Open
nhudson3SA wants to merge 1 commit intoedgurgel:mainfrom
nhudson3SA:feat/raise-protocol-not-impl
Open

Unsupported types raise Protocol.Undefined#187
nhudson3SA wants to merge 1 commit intoedgurgel:mainfrom
nhudson3SA:feat/raise-protocol-not-impl

Conversation

@nhudson3SA
Copy link

@nhudson3SA nhudson3SA commented Dec 29, 2025

PR for implementation of #185

{Issue was made under personal account)


def match(_, _), do: {:error, :not_found}
def match(data, _) do
raise Protocol.UndefinedError,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If you want to raise, you must at least check that strict mode is on.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah we might want to return a different error tuple here and use Context.put_errors to add a new error IF strict_variables=true. If not true we just ignore

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants