gleam-lang/gleam

Allow function literals in constants

Open

#3.942 aberto em 2 de dez. de 2024

Ver no GitHub
 (2 comments) (2 reactions) (0 assignees)Rust (960 forks)batch import
help wanted

Métricas do repositório

Stars
 (21.417 stars)
Métricas de merge de PR
 (Mesclagem média 10d 19h) (69 fundiu PRs em 30d)

Description

The ability to do something like this would be nice:

type FunctionWrapper {
  FunctionWrapper(fn(String) -> Int)
}
const my_function = FunctionWrapper(fn(something) { 0 })

Guia do colaborador