Hacktoberfest 2026: as issues que os mantenedores marcaram para outubro, abertas e boas para iniciantes. Ver issues do Hacktoberfest

Use `typeuse` in text format?

Aberta
#144 4 comentários 0 reações 0 responsáveis Ver no GitHub

Ninguém assumiu esta issue ainda.

Avaliação

Dificuldade
5/5
Tempo estimado
Mais de uma semana
Facilidade para iniciantes
35/100
Tipo de issue
Funcionalidade
Clareza
Razoavelmente clara
Status de atividade
Pouca atividade
Stack de tecnologia
wasm
Domínio
compilers

Direção de pesquisa

Start by reviewing the current text-format grammar for continuation type definitions and the existing typeuse production referenced in the issue. Compare the proposed forms, including the abbreviated examples, with the current (cont $f) syntax. Done means the proposal's text-format behavior and compatibility implications have been resolved and documented.

Escrita pelo modelo de indexação a partir do texto da issue.

Descrição

The current explainer does not explicitly explain the text format for this proposal, but I propose that the text format for continuation type definitions be updated to this:

comptype_I ::= ... | '(' 'cont' (x,I'):typeuse_I ')' => (cont x), I'

Using the existing typeuse production and its abbreviation would allow all of these to be well-formed and valid:

(module
  (type $f (func (param i32) (result i32))
  (type $k1 (cont (type $f)))
  (type $k2 (cont (type $f) (param i32) (result i32))) ;; Same as $k1
  (type $k3 (cont (param i32) (result i32))) ;; Same as $k1 and $k2
  (type $k4 (cont (param i64) (result i64))) ;; Implicitly defines a new function type
  (type $k5 (cont)) ;; Implicitly defines a new function type
)

Notably the current text format (type $k (cont $f)) would no longer be correct, but the advantage would be that writing tests would become much simpler because the function types would not need to be separately defined. (This is about the text format only; the function type definition would still be separate in the binary format and abstract syntax.)

Linguagem predominante
WebAssembly
Estrelas
218
Forks
19
Métricas de merge de PRs
Nenhum PR com merge em 30d

Preparar o ambiente

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Mais de WebAssembly/stack-switching

Todas as issues de WebAssembly/stack-switching

Issues semelhantes

Mais issues de Compilers

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.