summaryrefslogtreecommitdiff
path: root/parse.y
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-09-12 04:38:15 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2011-09-12 04:38:15 +0000
commit4705fcc3c0df0d4f389aff690852356b8d2fd317 (patch)
treeb17a35aa40f3209dc2bed6d046b0443581170ec0 /parse.y
parent821ae88259f349909ae2e956b09c4d8bf35e1792 (diff)
* README.EXT, README.EXT.ja (2.2.2), parse.y (rb_check_id): add
documents for rb_check_id(). git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33255 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'parse.y')
-rw-r--r--parse.y11
1 files changed, 11 insertions, 0 deletions
diff --git a/parse.y b/parse.y
index ada62e70a6..73aaaabf33 100644
--- a/parse.y
+++ b/parse.y
@@ -10112,6 +10112,17 @@ rb_is_junk_id(ID id)
return is_junk_id(id);
}
+/**
+ * Returns ID for the given name if it is interned already, or 0.
+ *
+ * \param namep the pointer to the name object
+ * \return the ID for *namep
+ * \pre the object referred by \p namep must be a Symbol or
+ * a String, or possible to convert with to_str method.
+ * \post the object referred by \p namep is a Symbol or a
+ * String if non-zero value is returned, or is a String
+ * if 0 is returned.
+ */
ID
rb_check_id(volatile VALUE *namep)
{