summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGravatar Adam Chlipala <adam@chlipala.net>2010-12-14 10:59:17 -0500
committerGravatar Adam Chlipala <adam@chlipala.net>2010-12-14 10:59:17 -0500
commit8b95e4da5cc8932be6d1f1b57d432be1b6a0b56b (patch)
treee58c74a7acf2c78745ccfabc861a79ca2841609a
parentcdeea4f04e511003a977eea732297c93a9680a22 (diff)
Allow use of path variables in strings with no slashes
-rw-r--r--src/compiler.sml9
1 files changed, 3 insertions, 6 deletions
diff --git a/src/compiler.sml b/src/compiler.sml
index e8da379c..9a25902a 100644
--- a/src/compiler.sml
+++ b/src/compiler.sml
@@ -391,12 +391,9 @@ fun parseUrp' accLibs fname =
val fname' = Substring.extract (fname, 1, NONE)
val (befor, after) = Substring.splitl (fn ch => ch <> #"/") fname'
in
- if Substring.isEmpty after then
- fname
- else
- case M.find (!pathmap, Substring.string befor) of
- NONE => fname
- | SOME rep => rep ^ Substring.string after
+ case M.find (!pathmap, Substring.string befor) of
+ NONE => fname
+ | SOME rep => rep ^ Substring.string after
end
else
fname