summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorMasataka Pocke Kuwabara <[email protected]>2021-02-01 14:01:47 +0900
committerGitHub <[email protected]>2021-02-01 14:01:47 +0900
commit23a833ee67dcc2d285082103deb79741ed147961 (patch)
tree1e7eedca1c4826155ed8baaab036273dcae70a8c /doc
parente4ef5791262c482f77fc9f7786ea70e49de1bb68 (diff)
Add File.absolute_path? to NEWS-2.7.0 [ci skip]
`File.absolute_path?` has been added since Ruby 2.7.0, but it isn't mentioned in the NEWS. So this patch adds a NEWS entry. ref: https://bugs.ruby-lang.org/issues/15868 Co-authored-by: nagachika <[email protected]>
Notes
Notes: Merged: https://github.com/ruby/ruby/pull/4139 Merged-By: nobu <[email protected]>
Diffstat (limited to 'doc')
-rw-r--r--doc/NEWS-2.7.09
1 files changed, 9 insertions, 0 deletions
diff --git a/doc/NEWS-2.7.0 b/doc/NEWS-2.7.0
index 3e6b98c1fd..184b47fb8b 100644
--- a/doc/NEWS-2.7.0
+++ b/doc/NEWS-2.7.0
@@ -366,6 +366,15 @@ See also Warning in {Core classes updates}[#label-Core+classes+updates+-28outsta
[File]
+ [New method]
+
+ * Added File.absolute_path? to check whether a path is absolute or
+ not in a portable way. [Feature #15868]
+
+ File.absolute_path?("/foo") # => true (on *nix)
+ File.absolute_path?("C:/foo") # => true (on Windows)
+ File.absolute_path?("foo") # => false
+
[Modified method]
* File.extname now returns a dot string for names ending with a dot on