package fmlib_browser

  1. Overview
  2. Docs

Source file url.ml

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
module Local =
struct
    type t

    let string (_: t): string =
        assert false (* nyi *)
end


type t =
    | Raw of string
    | Local of Local.t


let parse (str: string): t option =
    Some (Raw str)


let string: t -> string =
    function
    | Raw str ->
        str
    | Local loc ->
        Local.string loc

let is_page: t -> bool = function
    | Raw _ ->
        true (* MISSING!!! assert false *)
    | Local _ ->
        true
OCaml

Innovation. Community. Security.