summaryrefslogtreecommitdiffhomepage
path: root/mrbgems/mruby-symbol-ext
diff options
context:
space:
mode:
authorSeba Gamboa <[email protected]>2015-10-14 14:37:47 -0300
committerSeba Gamboa <[email protected]>2015-10-20 12:16:47 -0300
commit5cdcce8dbddd94ecb9503a0a1d47370c4ef97177 (patch)
tree07dae36bc4e2762a8d420fbea2e67b4a087ea260 /mrbgems/mruby-symbol-ext
parent84b70886cd9827593810264bf1f068044d5c6986 (diff)
downloadmruby-5cdcce8dbddd94ecb9503a0a1d47370c4ef97177.tar.gz
mruby-5cdcce8dbddd94ecb9503a0a1d47370c4ef97177.zip
Mark core gems with mrbgem tag
Diffstat (limited to 'mrbgems/mruby-symbol-ext')
-rw-r--r--mrbgems/mruby-symbol-ext/mrblib/symbol.rb16
-rw-r--r--mrbgems/mruby-symbol-ext/src/symbol.c4
2 files changed, 15 insertions, 5 deletions
diff --git a/mrbgems/mruby-symbol-ext/mrblib/symbol.rb b/mrbgems/mruby-symbol-ext/mrblib/symbol.rb
index 1e3d24b80..9e45f0acd 100644
--- a/mrbgems/mruby-symbol-ext/mrblib/symbol.rb
+++ b/mrbgems/mruby-symbol-ext/mrblib/symbol.rb
@@ -1,6 +1,7 @@
class Symbol
include Comparable
+ # @mrbgem mruby-symbol-ext
alias intern to_sym
def to_proc
@@ -14,7 +15,8 @@ class Symbol
# sym.capitalize -> symbol
#
# Same as <code>sym.to_s.capitalize.intern</code>.
-
+ #
+ # @mrbgem mruby-symbol-ext
def capitalize
(self.to_s.capitalize! || self).to_sym
end
@@ -24,7 +26,8 @@ class Symbol
# sym.downcase -> symbol
#
# Same as <code>sym.to_s.downcase.intern</code>.
-
+ #
+ # @mrbgem mruby-symbol-ext
def downcase
(self.to_s.downcase! || self).to_sym
end
@@ -34,7 +37,8 @@ class Symbol
# sym.upcase -> symbol
#
# Same as <code>sym.to_s.upcase.intern</code>.
-
+ #
+ # @mrbgem mruby-symbol-ext
def upcase
(self.to_s.upcase! || self).to_sym
end
@@ -44,7 +48,8 @@ class Symbol
# sym.casecmp(other) -> -1, 0, +1 or nil
#
# Case-insensitive version of <code>Symbol#<=></code>.
-
+ #
+ # @mrbgem mruby-symbol-ext
def casecmp(other)
return nil unless other.kind_of?(Symbol)
lhs = self.to_s; lhs.upcase!
@@ -57,7 +62,8 @@ class Symbol
# sym.empty? -> true or false
#
# Returns that _sym_ is :"" or not.
-
+ #
+ # @mrbgem mruby-symbol-ext
def empty?
self.length == 0
end
diff --git a/mrbgems/mruby-symbol-ext/src/symbol.c b/mrbgems/mruby-symbol-ext/src/symbol.c
index a96c4017f..ea4cd9efa 100644
--- a/mrbgems/mruby-symbol-ext/src/symbol.c
+++ b/mrbgems/mruby-symbol-ext/src/symbol.c
@@ -21,6 +21,8 @@ typedef struct symbol_name {
* :default_proc, :compact, :extend,
* :Tms, :getwd, :$=, :ThreadGroup,
* :wait2, :$>]
+ *
+ * @mrbgem mruby-symbol-ext
*/
static mrb_value
mrb_sym_all_symbols(mrb_state *mrb, mrb_value self)
@@ -40,6 +42,8 @@ mrb_sym_all_symbols(mrb_state *mrb, mrb_value self)
* sym.length -> integer
*
* Same as <code>sym.to_s.length</code>.
+ *
+ * @mrbgem mruby-symbol-ext
*/
static mrb_value
mrb_sym_length(mrb_state *mrb, mrb_value self)