るりまサーチ

最速Rubyリファレンスマニュアル検索!
37件ヒット [1-37件を表示] (0.086秒)
トップページ > クエリ:I[x] > クエリ:abbrev[x]

別のキーワード

  1. _builtin to_i
  2. fiddle to_i
  3. matrix elements_to_i
  4. matrix i
  5. csv to_i

ライブラリ

クラス

モジュール

キーワード

検索結果

Abbrev.#abbrev(words, pattern = nil) -> Hash (35237.0)

文字列の配列から一意に決まる短縮形を計算し、 短縮形をキー、元の文字列を値とするハッシュを返します。

...exp か String を指定します。

@return 短縮形をキー、元の文字列を値とするハッシュを返します。

require 'abbrev'

# words に同じ文字列が含まれている場合は
# 以下のようにその文字列しか返しません。
pp Abbrev.abbrev(%w[ruby r...
...pp Abbrev.abbrev(['ru by']).sort
# => [["r", "ru by"],
# ["ru", "ru by"],
# ["ru ", "ru by"],
# ["ru b", "ru by"],
# ["ru by", "ru by"]]
# sort していない例
p %w[ruby rubyist].abbrev
#=> {"ruby" => "ruby",
# "rubyi" => "rubyist...
...",
# "rubyis" => "rubyist",
# "rubyist" => "rubyist"}...

Array#abbrev(pattern = nil) -> Hash (26237.0)

self が文字列の配列の場合、self から一意に決まる短縮形を計算し、 短縮形をキー、元の文字列を値とするハッシュを返します。

...

Abbrev
.#abbrev(self, pattern) と同じです。

@param pattern Regexp か String を指定します。


require 'abbrev'
p %w[ruby rubyist].abbrev
#=> {"ruby" => "ruby",
# "rubyi" => "rubyist",
# "rubyis" => "rubyist",
# "rubyist" => "rubyist"}

@see Abbrev.#abbrev...

Gem::Indexer#abbreviate(spec) -> Gem::Specification (12200.0)

ダウンロードを速くするために与えられた Gem::Specification の持つデータを 小さくします。

...ダウンロードを速くするために与えられた Gem::Specification の持つデータを
小さくします。

@param spec Gem::Specification を指定します。...

NEWS for Ruby 3.0.0 (12.0)

NEWS for Ruby 3.0.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。

...positional arguments.
Code that resulted in deprecation warnings in Ruby 2.7 will now
result in ArgumentError or different behavior. 14183
* Procs accepting a single rest argument and keywords are no longer
subject to autosplatting. This now matches the behavior of Procs
accepting...
...single rest argument and no keywords.
16166

//emlist[][ruby]{
pr = proc{|*a, **kw| [a, kw]}

pr.call([1])
# 2.7 => [[1], {}]
# 3.0 => [[[1]], {}]

pr.call([1, {a: 1}])
# 2.7 => [[1], {:a=>1}] # and deprecation warning
# 3.0 => a=>1}, {}]
//}

* Arguments forwarding (`...`) now supports leadin...
...pen`. Call `URI.open` directly or `use URI#open` instead. 15893
* SortedSet has been removed for dependency and performance reasons.

== Stdlib compatibility issues

* Default gems
* The following libraries are promoted to default gems from stdlib.
* English
* abbrev
* base...