種類
- 文書 (36)
- 定数 (12)
- インスタンスメソッド (12)
- クラス (12)
ライブラリ
-
rdoc
/ markup (24)
クラス
-
RDoc
:: Markup (12) -
RDoc
:: Options (12)
キーワード
-
1
. 6 . 8から1 . 8 . 0への変更点(まとめ) (12) - Markup (12)
-
NEWS for Ruby 2
. 6 . 0 (7) -
NEWS for Ruby 3
. 0 . 0 (5) -
add
_ special (12) - クラス/メソッドの定義 (12)
検索結果
先頭5件
-
RDoc
:: Options :: SPECIAL -> [String] (18202.0) -
--write-options を指定した際に .rdoc_options ファイルに保存されないオプ ションの一覧を返します。
--write-options を指定した際に .rdoc_options ファイルに保存されないオプ
ションの一覧を返します。 -
RDoc
:: Markup # add _ special(pattern , name) -> () (6137.0) -
pattern で指定した正規表現にマッチする文字列をフォーマットの対象にしま す。
...s WikiHtml < SM::ToHtml
def handle_special_WIKIWORD(special)
"<font color=red>" + special.text + "</font>"
end
end
m = SM::SimpleMarkup.new
m.add_special(/\b([A-Z][a-z]+[A-Z]\w+)/, :WIKIWORD)
h = WikiHtml.new
puts m.convert(input_string, h)
変換時に実際にフォー......マットを行うには SM::ToHtml#accept_special_<name で指定した名前>
のように、フォーマッタ側でも操作を行う必要があります。... -
1
. 6 . 8から1 . 8 . 0への変更点(まとめ) (678.0) -
1.6.8から1.8.0への変更点(まとめ) * ((<1.6.8から1.8.0への変更点(まとめ)/インタプリタの変更>)) * ((<1.6.8から1.8.0への変更点(まとめ)/追加されたクラス/モジュール>)) * ((<1.6.8から1.8.0への変更点(まとめ)/追加されたメソッド>)) * ((<1.6.8から1.8.0への変更点(まとめ)/追加された定数>)) * ((<1.6.8から1.8.0への変更点(まとめ)/拡張されたクラス/メソッド(互換性のある変更)>)) * ((<1.6.8から1.8.0への変更点(まとめ)/変更されたクラス/メソッド(互換性のない変更)>)) * ((<1.6.8から1.8.0への変更点(まとめ)/文法の変更>)) * ((<1.6.8から1.8.0への変更点(まとめ)/正規表現>)) * ((<1.6.8から1.8.0への変更点(まとめ)/Marshal>)) * ((<1.6.8から1.8.0への変更点(まとめ)/Windows 対応>)) * ((<1.6.8から1.8.0への変更点(まとめ)/廃止された(される予定の)機能>)) * ((<1.6.8から1.8.0への変更点(まとめ)/ライブラリ>)) * ((<1.6.8から1.8.0への変更点(まとめ)/拡張ライブラリAPI>)) * ((<1.6.8から1.8.0への変更点(まとめ)/バグ修正>)) * ((<1.6.8から1.8.0への変更点(まとめ)/サポートプラットフォームの追加>))
...fix として 0d が追加されました。
8進リテラルの prefix として 0 以外に 0o が追加されました。
Integer(), String#to_i、String#oct もこの prefix を認識します。
: ((<メソッド引数の & 修飾|メソッド呼び出し/イテレータ>)) [compat]
: ((<......を抜け、n が yield の戻り値になります。
: to_str [compat]
to_str を定義したオブジェクトはより広範囲にStringとして振舞うように
なりました。
文字列を引数に取るほとんどの組み込みメソッドは、to_str による暗黙の......重代入 [change]
多重代入の規則を見直しました。
# # derived from sample/test.rb
# a = *[]; p a # special case
# def f; yield; end; f {|a| p a} # add (warning)
# def r; return; end; a = r(); p a
# a = nil; p a
# def f; yield nil; e... -
NEWS for Ruby 3
. 0 . 0 (264.0) -
NEWS for Ruby 3.0.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。
...", "f", 3]
in [*pre, String => x, String => y, *post]
p pre #=> ["a", 1]
p x #=> "b"
p y #=> "c"
p post #=> [2, "d", "e", "f", 3]
end
//}
* Endless method definition is added. [EXPERIMENTAL]
16746
//emlist{
def square(x) = x * x
//}
* Interpolated String literals are no lo......nger frozen when
`# frozen-string-literal: true` is used. 17104
* Magic comment `shareable_constant_value` added to freeze constants.
See {Magic Comments}[rdoc-ref:doc/syntax/comments.rdoc@Magic+Comments] for more details.
17273
* A {static analysis}[rdoc-label:label-Static+analysis]......them on with `-W:deprecated` (or with `-w` to show other warnings too).
16345
* `$SAFE` and `$KCODE` are now normal global variables with no special behavior.
C-API methods related to `$SAFE` have been removed.
16131 17136
* yield in singleton class definitions in methods is now a Sy... -
NEWS for Ruby 2
. 6 . 0 (66.0) -
NEWS for Ruby 2.6.0 このドキュメントは前回リリース以降のバグ修正を除くユーザーに影響のある機能の変更のリストです。
...りました。
* Regexp/String
* Unicode のバージョンを 10.0.0 から 11.0.0 に更新しました。 14802
これは書記素クラスタ (/\X/) アルゴリズムの書き換えと String#downcase での
Georgian MTAVRULI の special-casing を含みます。......"require(feature)" で読み込むファイルを
特定します。 [実験的] 15230
* String
* String#crypt は非推奨になりました。 14915
* 新機能
* String#split はブロックが渡されていたら部分文字列ごとに呼び出すようになりまし......くつかの XPath 実装を改善:
* concat() 関数: 結合前に全ての引数を文字列化
* string() 関数: コンテキストノードをサポート
* string() 関数: 処理命令 (PI) ノードをサポート
* XPath 2.0 で"*:#{ELEMENT_NAME}" 記法をサポー... -
RDoc
:: Markup (30.0) -
RDoc 形式のドキュメントを目的の形式に変換するためのクラスです。
...put_string)
独自のフォーマットを行うようにパーサを拡張する事もできます。
例:
require 'rdoc/markup'
require 'rdoc/markup/to_html'
class WikiHtml < RDoc::Markup::ToHtml
# WikiWord のフォントを赤く表示。
def handle_special_WIKIWORD(special)...... special.text + "</font>"
end
end
m = RDoc::Markup.new
# { 〜 } までを :STRIKE でフォーマットする。
m.add_word_pair("{", "}", :STRIKE)
# <no> 〜 </no> までを :STRIKE でフォーマットする。
m.add_html("no", :STRIKE)
# WikiWord を追加。
m.add_special... -
クラス/メソッドの定義 (12.0)
-
クラス/メソッドの定義 * クラス/メソッドの定義: * class * singleton_class * module * method * operator * nest_method * eval_method * singleton_method * class_method * limit * 定義に関する操作: * alias * undef * defined
...ray を明示的に指定しても同じ)
class Foo
def bar
end
end
# 間違ったスーパークラスを指定するとエラー
class Foo < String
end
# => superclass mismatch for class Foo (TypeError)
//}
クラス定義式の中は self がそのクラスであることと、
limitのデ......ド定義式は、メソッド名を Symbol にしたオブジェクトを返します。
@see https://magazine.rubyist.net/articles/0041/0041-200Special-kwarg.html
====[a:operator] 演算子式の定義
spec/operatorにおいて、「再定義可能な演算子」に分類された演算子の...