Revision 72747d91 test/hs/Test/Ganeti/Common.hs

b/test/hs/Test/Ganeti/Common.hs
83 83
            -> c
84 84
passFailOpt defaults failfn passfn
85 85
              (opt@(GetOpt.Option _ longs _ _, _), bad, good) =
86
  let prefix = "--" ++ head longs ++ "="
86
  let first_opt = case longs of
87
                    [] -> error "no long options?"
88
                    x:_ -> x
89
      prefix = "--" ++ first_opt ++ "="
87 90
      good_cmd = prefix ++ good
88 91
      bad_cmd = prefix ++ bad in
89 92
  case (parseOptsInner defaults [bad_cmd]  "prog" [opt] [],

Also available in: Unified diff