src/Pure/General/path.ML
changeset 59363 4660b0409096
parent 56533 cd8b6d849b6a
child 61877 276ad4354069
equal deleted inserted replaced
59362:41f1645a4f63 59363:4660b0409096
    21   val append: T -> T -> T
    21   val append: T -> T -> T
    22   val appends: T list -> T
    22   val appends: T list -> T
    23   val make: string list -> T
    23   val make: string list -> T
    24   val implode: T -> string
    24   val implode: T -> string
    25   val explode: string -> T
    25   val explode: string -> T
       
    26   val decode: T XML.Decode.T
    26   val split: string -> T list
    27   val split: string -> T list
    27   val pretty: T -> Pretty.T
    28   val pretty: T -> Pretty.T
    28   val print: T -> string
    29   val print: T -> string
    29   val dir: T -> T
    30   val dir: T -> T
    30   val base: T -> T
    31   val base: T -> T
   158   in Path (norm (rev elems @ roots)) end;
   159   in Path (norm (rev elems @ roots)) end;
   159 
   160 
   160 fun split str =
   161 fun split str =
   161   space_explode ":" str
   162   space_explode ":" str
   162   |> map_filter (fn s => if s = "" then NONE else SOME (explode_path s));
   163   |> map_filter (fn s => if s = "" then NONE else SOME (explode_path s));
       
   164 
       
   165 val decode = XML.Decode.string #> explode_path;
   163 
   166 
   164 
   167 
   165 (* print *)
   168 (* print *)
   166 
   169 
   167 fun pretty path =
   170 fun pretty path =