mirror of
https://github.com/roc-lang/roc.git
synced 2025-09-28 22:34:45 +00:00
16 lines
296 B
Text
16 lines
296 B
Text
interface Path
|
|
exposes [ Path, fromStr, toStr ]
|
|
imports []
|
|
|
|
|
|
Path : [ @Path Str ]
|
|
|
|
|
|
fromStr : Str -> Result Path [ MalformedPath ]*
|
|
fromStr = \str ->
|
|
# TODO actually validate the path - may want a Parser for this!
|
|
Ok (@Path str)
|
|
|
|
toStr : Path -> Str
|
|
toStr = \@Path str ->
|
|
str
|