Tíquete #21040

Array#choiceの廃止

: 2010-03-10 17:48 Última Atualização: 2010-09-20 12:26

Relator:
Dono:
Estado:
Fechado
Componente:
(Nenhum)
Prioridade:
5 - Medium
Gravidade:
5 - Medium
Resolução:
Nenhum
Arquivo:
Nenhum

Details

Array#choiceを廃止し、Array#sampleで統一する

  1. case
  2. when RUBY_VERSION >= '1.9.1'
  3. # nothing
  4. when RUBY_VERSION == '1.8.7'
  5. class << Array
  6. def sample
  7. self.choice
  8. end
  9. end
  10. else
  11. raise 'not support Ruby version'
  12. end

Ticket History (3/3 Histories)

2010-03-10 17:48 Updated by: parrot
  • New Ticket "Array#choiceの廃止" created
2010-04-12 11:28 Updated by: parrot
Comentário

逆に、Ruby1.9系への対応としてArray#choiceを加える方向で対応する

現状、Ruby1.9系に対するExerbレベルでのexe化が存在しないため

2010-09-20 12:26 Updated by: parrot
  • Estado Update from Aberto to Fechado
  • Ticket Close date is changed to 2010-09-20 12:26
Comentário

Ruby1.9系の場合、Array#choiceを追加定義する方向で修正完了

Attachment File List

No attachments

Editar

You are not logged in. I you are not logged in, your comment will be treated as an anonymous post. » Login