fix error message on missing absolute base path
This commit is contained in:
parent
79cffc5011
commit
58f96abe8c
@ -122,7 +122,7 @@ B path_rel(B base, B rel, char* name) {
|
|||||||
if (!isStr(rel)) thrF("%U: Path must be a list of characters", name);
|
if (!isStr(rel)) thrF("%U: Path must be a list of characters", name);
|
||||||
usz ria = IA(rel);
|
usz ria = IA(rel);
|
||||||
if (ria>0 && isAbsolutePath(rel)) return rel;
|
if (ria>0 && isAbsolutePath(rel)) return rel;
|
||||||
if (q_N(base)) thrM("%U: Using relative path with no absolute base path known");
|
if (q_N(base)) thrF("%U: Using relative path with no absolute base path known", name);
|
||||||
if (ria==0) { dec(rel); return incG(base); }
|
if (ria==0) { dec(rel); return incG(base); }
|
||||||
usz bia = IA(base);
|
usz bia = IA(base);
|
||||||
if (bia==0) return rel;
|
if (bia==0) return rel;
|
||||||
|
|||||||
@ -25,6 +25,7 @@
|
|||||||
!"Failed to resolve ""path that doesn't exist"": No such file or directory" % ⟨"path that doesn't exist"⟩•BQN"•path"
|
!"Failed to resolve ""path that doesn't exist"": No such file or directory" % ⟨"path that doesn't exist"⟩•BQN"•path"
|
||||||
!"Failed to resolve ""path that doesn't exist"": No such file or directory" % ⟨"path that doesn't exist"⟩•BQN"•state"
|
!"Failed to resolve ""path that doesn't exist"": No such file or directory" % ⟨"path that doesn't exist"⟩•BQN"•state"
|
||||||
⟨"path that doesn't exist"⟩•BQN"2+2" %% 4
|
⟨"path that doesn't exist"⟩•BQN"2+2" %% 4
|
||||||
|
!"•file.Chars: Using relative path with no absolute base path known" % f←•BQN"•FChars" ⋄ F "a"
|
||||||
|
|
||||||
# •ReBQN
|
# •ReBQN
|
||||||
!"REPL: Filename must be a string" % f←•ReBQN{⇐} ⋄ ⟨•path, 1‿2⟩ F "2+2"
|
!"REPL: Filename must be a string" % f←•ReBQN{⇐} ⋄ ⟨•path, 1‿2⟩ F "2+2"
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user