aboutsummaryrefslogtreecommitdiffstats
path: root/string.c
Commit message (Collapse)AuthorAgeFilesLines
* [DOC] Move the documentations of moved Symbol methodsNobuyoshi Nakada2022-04-141-45/+2
|
* [DOC] Enhanced RDoc for Symbol (#5796)Burdette Lamar2022-04-131-41/+31
| | | | | | | | | | | | | | | Treats: #[] #length #empty? #upcase #downcase #capitalize #swapcase #start_with? #end_with? #encoding ::all_symbols
* Enforce literals on the second argumentsNobuyoshi Nakada2022-04-131-1/+1
|
* Enhanced RDoc for Symbol (#5795)Burdette Lamar2022-04-121-92/+80
| | | | | | | | | | | | | | | | | | | Treats: #== #inspect #name #to_s #to_sym #to_proc #succ #<=> #casecmp #casecmp? #=~ #match #match?
* Fix some RDoc links (#5778)Burdette Lamar2022-04-081-11/+11
|
* All-in-one RDoc for class String (#5777)Burdette Lamar2022-04-071-416/+0
|
* [DOC] Enhanced RDoc for string slices (#5769)Burdette Lamar2022-04-061-107/+35
| | | Creates file doc/string/slices.rdoc that the string slicing methods can link to.
* Enhanced RDoc for String#index (#5759)Burdette Lamar2022-04-041-30/+1
|
* [DOC] Enhanced RDoc for String (#5753)Burdette Lamar2022-04-031-12/+2
| | | | | | | Treats: #length #bytesize
* [DOC] Enhanced RDoc for String (#5751)Burdette Lamar2022-04-021-3/+1
| | | | | | Adds to doc for String.new, also making it compliant with documentation_guide.rdoc. Fixes some broken links in io.c (that I failed to correct yesterday).
* [DOC] Enhanced RDoc for String (#5742)Burdette Lamar2022-03-311-69/+42
| | | | | | | | | | | | Treats: #force_encoding #b #valid_encoding? #ascii_only? #scrub #scrub! #unicode_normalized? Plus a couple of minor tweaks.
* Repaired What's Here sections for Range, String, Symbol, Struct (#5735)Burdette Lamar2022-03-301-184/+185
| | | Repaired What's Here sections for Range, String, Symbol, Struct.
* [DOC] Enhanced RDoc for String (#5730)Burdette Lamar2022-03-291-34/+14
| | | | | | | | | | | | Treats: #start_with? #end_with? #delete_prefix #delete_prefix! #delete_suffix #delete_suffix!
* [DOC] Enhanced RDoc for String (#5726)Burdette Lamar2022-03-281-54/+16
| | | | | | | | | | | Treats: #ljust #rjust #center #partition #rpartition
* [DOC] Enhanced RDoc for String (#5724)Burdette Lamar2022-03-271-46/+57
| | | | | | | | | | | | Treats: #scan #hex #oct #crypt #ord #sum
* [DOC] Fix references to unary operatorNobuyoshi Nakada2022-03-271-4/+4
|
* Enhanced RDoc for String (#5723)Burdette Lamar2022-03-261-47/+57
| | | | | | | | | | | | | Treats: #lstrip #lstrip! #rstrip #rstrip! #strip #strip! Adds section Whitespace in Strings.
* [DOC] Use simple references to operator methodsNobuyoshi Nakada2022-03-261-6/+5
| | | | | | | Method references is not only able to be marked up as code, also reflects `--show-hash` option. The bug that prevented the old rdoc from correctly parsing these methods was fixed last month.
* [DOC] Enhanced RDoc for String (#5707)Burdette Lamar2022-03-241-38/+15
| | | | | | | | | | Treated: #chomp #chomp! #chop #chop!
* [DOC] Enhanced RDoc for String (#5685)Burdette Lamar2022-03-221-59/+25
| | | | | | | | | | | | | Treats: #chars #codepoints #each_char #each_codepoint #each_grapheme_cluster #grapheme_clusters Also, corrects a passage in #unicode_normalize that mentioned module UnicodeNormalize, whose doc (:nodoc:, actually) says not to mention it.
* [DOC] Use RDoc inclusions in string.c (#5683)Burdette Lamar2022-03-211-5/+42
| | | | | | | | | | | | | | | | | | As @peterzhu2118 and @duerst have pointed out, putting string method's RDoc into doc/ (which allows non-ASCII in examples) makes the "click to toggle source" feature not work for that method. This PR moves the primary method doc back into string.c, then includes RDoc from doc/string/*.rdoc, and also removes doc/string.rdoc. The affected methods are: ::new #bytes #each_byte #each_line #split The call-seq is in string.c because it works there; it did not work when the call-seq is in doc/string/*.rdoc. This PR also updates the relevant guidance in doc/documentation_guide.rdoc.
* [DOC] Enhanced RDoc for String (#5675)Burdette Lamar2022-03-181-86/+7
| | | | | | | | | | Treats: #split #each_line #lines #each_byte #bytes
* Add String#bytespliceShugo Maeda2022-03-181-0/+71
|
* [DOC] Enhanced RDoc for String#split (#5644)Burdette Lamar2022-03-161-52/+1
| | | | | | | | | | | * Enhanced RDoc for String#split * Enhanced RDoc for String#split * Enhanced RDoc for String#split * Enhanced RDoc for String#split * Enhanced RDoc for String#split
* Initialize mutex for crypt(3) staticallyNobuyoshi Nakada2022-03-161-24/+1
| | | | | Assuming that all platforms, where only `crypt` is available but not `crypt_r`, are POSIX-base.
* [DOC] Enhanced RDoc for String (#5635)Burdette Lamar2022-03-091-25/+24
| | | | | | | | | | | | | Treats: #count #delete #delete! #squeeze #squeeze! Adds section "Multiple Character Selectors" to doc/character_selectors.rdoc. Co-authored-by: Peter Zhu <peter@peterzhu.ca>
* [DOC] Enhanced RDoc for String (#5633)Burdette Lamar2022-03-091-38/+32
| | | | | | | | | | | Treats: #tr (revised to link to "Character Selectors" document) #tr! #tr_s #tr_s! Also renames doc/character_selector.rdoc to match its title.
* [DOC] Fix default offset of String#byterindexKazuhiro NISHIYAMA2022-03-091-2/+2
|
* [DOC] Enhanced RDoc for String #tr and #tr! (#5626)Burdette Lamar2022-03-071-27/+41
|
* [DOC] mark `rb_str_init` as `:nodoc:`Nobuyoshi Nakada2022-03-031-0/+1
| | | | | Otherwise, an empty entry will be generated as `String::new` along with the one from doc/string.rb.
* [DOC] Fix String#getbyte docMau Magnaguagno2022-03-011-5/+6
| | | | | | | * String#getbyte returns `nil` if `index` is out of range. * Add String#getbyte example with nil output. * Modify String#getbyte example to use negative index.
* [DOC] Move String.new to allow non US-ASCII charactersNobuyoshi Nakada2022-02-261-46/+0
|
* [DOC] Enhanced RDoc for some encoding methods (#5598)Burdette Lamar2022-02-251-40/+80
| | | | | | | | | | | | | | In String, treats: #b #scrub #scrub! #unicode_normalize #unicode_normalize! #encode #encode! Also adds a note to IO.new (suggested by @jeremyevans).
* Rename the wrong variable name `beg` to `len`Shugo Maeda2022-02-231-3/+3
|
* rb_debug_rstring_null_ptr: add newlines in the message [ci skip]Nobuyoshi Nakada2022-02-211-2/+2
| | | | | The message should end with a newline, and break the long paragraph.
* Add String#byteindex, String#byterindex, and MatchData#byteoffset (#5518)Shugo Maeda2022-02-191-9/+251
| | | | | | * Add String#byteindex, String#byterindex, and MatchData#byteoffset [Feature #13110] Co-authored-by: NARUSE, Yui <naruse@airemix.jp>
* [DOC] Remove unnecessary `rdoc-ref:` schemesNobuyoshi Nakada2022-02-121-11/+11
|
* [DOC] Simplify operator method referencesNobuyoshi Nakada2022-02-121-10/+12
|
* Remove extraneous "." in String#+@ documentationPaarth Madan2022-02-081-1/+1
|
* [DOC] Fix broken links to operator methodsNobuyoshi Nakada2022-02-081-1/+1
| | | | | Once https://github.com/ruby/rdoc/pull/865 is merged, these hacks are no longer needed.
* [DOC] Fix broken links to case_mapping.rdocNobuyoshi Nakada2022-02-081-11/+11
|
* [DOC] Fix broken links to literals.rdocNobuyoshi Nakada2022-02-081-4/+4
|
* [DOC] Simplify links to global methodsNobuyoshi Nakada2022-02-081-1/+1
|
* [DOC] Use RDoc link style for links in the same class/modulePeter Zhu2022-02-071-15/+15
| | | | | | | | | | I used this regex: (?<=\[)#(?:class|module)-([A-Za-z]+)-label-([A-Za-z0-9\-\+]+) And performed a global find & replace for this: rdoc-ref:$1@$2
* [DOC] Use RDoc link style for links to other classes/modulesPeter Zhu2022-02-071-4/+4
| | | | | | | | | | I used this regex: ([A-Za-z]+)\.html#(?:class|module)-[A-Za-z]+-label-([A-Za-z0-9\-\+]+) And performed a global find & replace for this: rdoc-ref:$1@$2
* Improve links to labels in string.c and struct.c (#5531)Burdette Lamar2022-02-061-8/+5
|
* Change termlen when changing encoding during concatenationPeter Zhu2022-01-071-0/+1
| | | | After changing the encoding, we should update the terminator length.
* [DOC] Fix typos in a doxygen comment [ci skip]Nobuyoshi Nakada2022-01-071-1/+1
|
* Revert "Set encoding before concatenating to string"Peter Zhu2022-01-061-1/+1
| | | | This reverts commit 44368b5f8bc21e19fa06a0fc0625923fc41293e6.
* Set correct termlen for frozen stringsPeter Zhu2022-01-061-2/+3
| | | | | Frozen strings should have the same termlen as the original string when copy_encoding is true.