[PATCH 1 of 7] util: add a macro initializing CPython modules

Gregory Szorc gregory.szorc at gmail.com
Sat May 13 19:26:04 EDT 2017


On Sat, May 13, 2017 at 4:10 PM, Jun Wu <quark at fb.com> wrote:

> Excerpts from Gregory Szorc's message of 2017-05-13 13:48:18 -0700:
> > FWIW, I've been thinking about merging the C modules into a single one.
> IMO
> > there aren't many benefits to having separate C modules other than
> clearer
> > naming. Having all the code in a single compilation unit facilitates more
> > code reuse, more aggressive compiler optimization, etc. It would get a
> > little weird on the pure Python / CFFI side of the world.
>
> Moving C modules to a single file does not solve the Py2 / Py3 duplication
> issue?
>

No. But at least you only have to write the module init code once instead
of N times. That makes it tolerable.


>
> I have sent a V2 which solves the duplication and compiler warning issue.
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://www.mercurial-scm.org/pipermail/mercurial-devel/attachments/20170513/baf17400/attachment.html>


More information about the Mercurial-devel mailing list