summaryrefslogtreecommitdiff
path: root/ghc/compiler/main/DriverUtil.hs
diff options
context:
space:
mode:
Diffstat (limited to 'ghc/compiler/main/DriverUtil.hs')
-rw-r--r--ghc/compiler/main/DriverUtil.hs5
1 files changed, 4 insertions, 1 deletions
diff --git a/ghc/compiler/main/DriverUtil.hs b/ghc/compiler/main/DriverUtil.hs
index fd0bcafbf6..0a25f76c89 100644
--- a/ghc/compiler/main/DriverUtil.hs
+++ b/ghc/compiler/main/DriverUtil.hs
@@ -1,5 +1,5 @@
-----------------------------------------------------------------------------
--- $Id: DriverUtil.hs,v 1.20 2001/04/26 14:33:44 simonmar Exp $
+-- $Id: DriverUtil.hs,v 1.21 2001/05/08 10:58:48 simonmar Exp $
--
-- Utils for the driver
--
@@ -125,6 +125,9 @@ addNoDups var x = do
splitFilename :: String -> (String,String)
splitFilename f = split_longest_prefix f '.'
+getFileSuffix :: String -> String
+getFileSuffix f = drop_longest_prefix f '.'
+
-- "foo/bar/xyzzy.ext" -> ("foo/bar", "xyzzy", ".ext")
splitFilename3 :: String -> (String,String,String)
splitFilename3 str