From 4cb8b49d41f76d0a2e95cecbd4fdd700d77c5098 Mon Sep 17 00:00:00 2001 From: MSP-Greg Date: Sun, 31 May 2020 09:06:07 -0500 Subject: [DOC] relative filename `Kernel#.require` and `Kernel#.load` [ci skip] --- load.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'load.c') diff --git a/load.c b/load.c index 22f30c6822..91c9b31667 100644 --- a/load.c +++ b/load.c @@ -683,6 +683,7 @@ rb_load_protect(VALUE fname, int wrap, int *pstate) * If the filename neither resolves to an absolute path nor starts with * './' or '../', the file will be searched for in the library * directories listed in $LOAD_PATH ($:). + * If the filename starts with './' or '../', resolution is based on Dir.pwd. * * If the optional _wrap_ parameter is +true+, the loaded script will * be executed under an anonymous module, protecting the calling @@ -789,6 +790,7 @@ load_unlock(const char *ftptr, int done) * If the filename neither resolves to an absolute path nor starts with * './' or '../', the file will be searched for in the library * directories listed in $LOAD_PATH ($:). + * If the filename starts with './' or '../', resolution is based on Dir.pwd. * * If the filename has the extension ".rb", it is loaded as a source file; if * the extension is ".so", ".o", or ".dll", or the default shared library -- cgit v1.2.3