mirror of
https://github.com/idris-lang/Idris2.git
synced 2024-11-24 15:07:37 +03:00
Normalise to / in generating interface names
In practice, this is only for consistency in the tests. Is this the right way?
This commit is contained in:
parent
6a53e0177c
commit
3794b20d0c
@ -26,9 +26,16 @@ import Data.NameMap
|
||||
|
||||
%default covering
|
||||
|
||||
replaceSep : String -> String
|
||||
replaceSep = pack . map toForward . unpack
|
||||
where
|
||||
toForward : Char -> Char
|
||||
toForward '\\' = '/'
|
||||
toForward x = x
|
||||
|
||||
mkImpl : FC -> Name -> List RawImp -> Name
|
||||
mkImpl fc n ps
|
||||
= DN (show n ++ " implementation at " ++ show fc)
|
||||
= DN (show n ++ " implementation at " ++ replaceSep (show fc))
|
||||
(UN ("__Impl_" ++ show n ++ "_" ++
|
||||
showSep "_" (map show ps)))
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user