[#106355] [Ruby master Bug#18373] RBS build failure: '/include/x86_64-linux/ruby/config.h', needed by 'constants.o'. — "vo.x (Vit Ondruch)" <noreply@...>
Issue #18373 has been reported by vo.x (Vit Ondruch).
28 messages
2021/12/01
[ruby-core:106605] [Ruby master Feature#16978] Ruby should not use realpath for __FILE__
From:
"vo.x (Vit Ondruch)" <noreply@...>
Date:
2021-12-09 16:46:05 UTC
List:
ruby-core #106605
Issue #16978 has been updated by vo.x (Vit Ondruch). I wonder what is the situation here given that the #17885 seems to be resolved? ---------------------------------------- Feature #16978: Ruby should not use realpath for __FILE__ https://bugs.ruby-lang.org/issues/16978#change-95274 * Author: vo.x (Vit Ondruch) * Status: Open * Priority: Normal * Assignee: nobu (Nobuyoshi Nakada) ---------------------------------------- This is the simplest test case: ~~~ $ mkdir a $ echo "puts __FILE__" > a/test.rb $ ln -s a b $ ruby -Ib -e "require 'test'" /builddir/a/test.rb ~~~ This behavior is problematic, because Ruby should not know nothing about the `a` directory. It was not instructed to use it. I should always refer to the file using the original path and do not dig into the underlying details, otherwise depending on file system setup, one might be forced to used `File.realpath` everywhere trying to use `__FILE__`. -- https://bugs.ruby-lang.org/ Unsubscribe: <mailto:ruby-core-request@ruby-lang.org?subject=unsubscribe> <http://lists.ruby-lang.org/cgi-bin/mailman/options/ruby-core>