CakeML/cakeml

Add contains to Char module

Offen

#1.433 geöffnet am 18.07.2026

 (0 Kommentare) (0 Reaktionen) (0 zugewiesene Personen)Standard ML (98 Forks)auto 404
basis extensionsgood first issuelow effort

Repository-Metriken

Stars
 (1.169 Sterne)
PR-Merge-Metriken
 (PR-Metriken ausstehend)

Beschreibung

It would be useful to have Char.contains in part of the basis. One simple implementation is the following:

fun contains s c = List.member c (String.explode s)

However, I would suspect that it would be better to avoid the explode and iterate over the string instead for the definition that ends up being translated. It might be neat to prove a theorem of equivalence between them, though.

Contributor Guide