Loading ...
Sorry, an error occurred while loading the content.

"ocaml_beginners"::[] Re: Pattern matching and polymorphic variants

Expand Messages
  • johan.mazel
    ... Thanks a lot for all your help. It s now working. Johan Mazel
    Message 1 of 6 , Dec 8, 2009
    • 0 Attachment
      --- In ocaml_beginners@yahoogroups.com, Richard Jones <rich@...> wrote:
      >
      > On Tue, Dec 08, 2009 at 04:21:33PM -0000, johan.mazel wrote:
      > > Actually my code looks like:
      > > let icmp = ICMP.Icmp.unmarshal ip#data_env in
      > > match icmp with
      > > | (`EchoReply : ICMP.Icmp.o) ->
      >
      > Again, the type assertion isn't necessary and is probably a syntax
      > error. But the main thing is you're missing the required argument to
      > `EchoReply. If you don't care about the argument, try:
      >
      > | `EchoReply _ ->
      >
      > Rich.
      >
      > --
      > Richard Jones
      > Red Hat
      >
      Thanks a lot for all your help.
      It's now working.
      Johan Mazel
    Your message has been successfully submitted and would be delivered to recipients shortly.