るりまサーチ

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

別のキーワード

  1. uri regexp
  2. _builtin regexp
  3. regexp match
  4. regexp last_match
  5. etc sc_regexp

ライブラリ

クラス

モジュール

検索結果

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

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

...ern Regexp か String を指定します。

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

require 'abbrev'

# words に同じ文字列が含まれている場合は
# 以下のようにその文字列しか返しません。
pp Abbrev.abbrev(%w...
...適切に処理します。
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",...

Array#abbrev(pattern = nil) -> Hash (26143.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...

NEWS for Ruby 3.0.0 (24.0)

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

...ingScanner
* Update to StringScanner 3.0.0
* This version is Ractor compatible.

== Compatibility issues

Excluding feature bug fixes.

* Regexp literals and all Range objects are frozen. 8948 16377 15504

//emlist[][ruby]{
/foo/.frozen? #=> true
(42...).frozen? # => true
//}

* EXPERIME...
...ined.
* Integer#zero? overrides Numeric#zero? for optimization. 16961
* Enumerable#grep and Enumerable#grep_v when passed a Regexp and no block no longer modify Regexp.last_match. 17030
* Requiring 'open-uri' no longer redefines `Kernel#open`. Call `URI.open` directly or `use URI#open` instea...
....

== Stdlib compatibility issues

* Default gems
* The following libraries are promoted to default gems from stdlib.
* English
* abbrev
* base64
* drb
* debug
* erb
* find
* net-ftp
* net-http
* net-imap
* net-protocol
*...