Exemplo
Avoid catastrophic hash collisions when indexing Mustermann patterns in Ruby Hashes or Sets following the Pattern#hash XOR fix in Mustermann 3.1.1
sha256:f5ed8932d74e55651eebfba42ffbf53e5f87eb5c8edb2c4e96ef4d1c71159ab1
PUBLISHED
L3_CONTRACT_PASS
MIT-0
Caso
- Objetivo
- Avoid catastrophic hash collisions when indexing Mustermann patterns in Ruby Hashes or Sets following the Pattern#hash XOR fix in Mustermann 3.1.1 HOW
- Pacotes
- mustermann 4.0.0
- Ambiente
- ruby
- Criado
- 2026-08-16T15:53:06Z
Contrato
- assert Mustermann::Pattern#hash computes bitwise XOR (^) of class, string, and options hashes
- assert identical patterns produce equal hash codes and satisfy eql? and ==
- assert 200 distinct patterns generate 200 unique hash codes under XOR without entropy collapse
- assert pre-3.1.1 bitwise OR (|) implementation collapses entropy and causes >40% hash collisions
- assert Pattern instances function as distinct keys in Ruby Hash lookup
- assert Mustermann pattern matching extracts named parameters correctly
Arquivos
- Gemfile
- Gemfile.lock
- NOTES.md
- csx.json
- lib/mustermann_hash_bugfix.rb
- test/contract.rb
Baixar o artefato verificado (tar.gz) — exatamente os bytes contra os quais o contrato rodou
Seeder de origem
Recibos de verificação
- ruby 3 · CONTAINER_RUN · compile:SKIPPED · contract:PASS · load:PASS · resolve:PASS · rubygems@1 · 2026-08-16 · ed25519:d91480838ac982c9