[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Xen-devel] [Xen-API] [PATCH 04 of 15] libxl: ocaml: fix code intended to output comments before definitions



> # HG changeset patch
> # User Ian Campbell <ijc@xxxxxxxxxxxxxx> # Date 1353432141 0 # Node ID
> be294b1cdd00dac5d3a1b42faf06656902b99e5b
> # Parent  739989dcd108c6dac61aa9c87be2a75feafb9871
> libxl: ocaml: fix code intended to output comments before definitions
> 
> I'm not sure how useful these comments actually are but erred on the side
> of fixing rather than removing.
> 
> Signed-off-by: Ian Campbell <ian.campbell@xxxxxxxxxx>

Acked-by: Rob Hoes <rob.hoes@xxxxxxxxxx>

> diff -r 739989dcd108 -r be294b1cdd00 tools/ocaml/libs/xl/genwrap.py
> --- a/tools/ocaml/libs/xl/genwrap.py  Tue Nov 20 17:22:21 2012 +0000
> +++ b/tools/ocaml/libs/xl/genwrap.py  Tue Nov 20 17:22:21 2012 +0000
> @@ -79,12 +79,14 @@ def gen_ocaml_ml(ty, interface, indent="
>          s = ("""(* %s interface *)\n""" % ty.typename)
>      else:
>          s = ("""(* %s implementation *)\n""" % ty.typename)
> +
>      if isinstance(ty, idl.Enumeration):
> -        s = "type %s = \n" % ty.rawname
> +        s += "type %s = \n" % ty.rawname
>          for v in ty.values:
>              s += "\t | %s\n" % v.rawname
>      elif isinstance(ty, idl.Aggregate):
> -        s = ""
> +        s += ""
> +
>          if ty.typename is None:
>              raise NotImplementedError("%s has no typename" % type(ty))
>          else:
> 
> _______________________________________________
> Xen-api mailing list
> Xen-api@xxxxxxxxxxxxx
> http://lists.xen.org/cgi-bin/mailman/listinfo/xen-api

_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxx
http://lists.xen.org/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.