U:RDoc::AnyMethod[iI"[]=:ETI" Hash#[]=;TF: publico:RDoc::Markup::Document: @parts[ S:RDoc::Markup::Heading: leveli: textI"Element Assignment;To:RDoc::Markup::BlankLineo:RDoc::Markup::Paragraph; [I"GAssociates the value given by +value+ with the key given by +key+.;T@ o:RDoc::Markup::Verbatim; [ I"$h = { "a" => 100, "b" => 200 } ;TI"h["a"] = 9 ;TI"h["c"] = 4 ;TI"(h #=> {"a"=>9, "b"=>200, "c"=>4} ;TI"h.store("d", 42) #=> 42 ;TI"1h #=> {"a"=>9, "b"=>200, "c"=>4, "d"=>42} ;T: @format0o;; [I"M+key+ should not have its value changed while it is in use as a key (an ;TI"Munfrozen String passed as a key will be duplicated and frozen).;T@ o;; [ I" a = "a" ;TI"b = "b".freeze ;TI" h = { a => 100, b => 200 } ;TI"#h.key(100).equal? a #=> false ;TI"!h.key(200).equal? b #=> true;T;0: @fileI" hash.c;T:0@omit_headings_from_table_of_contents_below0I"%hsh[key] = value -> value;T0[I" (p1, p2);T@$FI" Hash;TcRDoc::NormalClass00