[Numpy-discussion] MapIter api

Nathaniel Smith njs at pobox.com
Tue Apr 16 09:54:13 EDT 2013


On Mon, Apr 15, 2013 at 5:29 PM, Sebastian Berg
<sebastian at sipsolutions.net> wrote:
> Hey,
>
> the MapIter API has only been made public in master right? So it is no
> problem at all to change at least the mapiter struct, right?
>
> I got annoyed at all those special cases that make things difficult to
> get an idea where to put i.e. to fix the boolean array-like stuff. So
> actually started rewriting it (and I already got one big function that
> does all index preparation -- ok it is untested but its basically
> there).
>
> I would guess it is not really a big problem even if it was public for
> longer, since you shouldn't do those direct struct access probably? But
> just checking.

Why don't we just make the struct opaque, i.e., just declare it in the
public header file and move the actual definition to an internal
header file?

If it's too annoying I guess we could even make it non-public, at
least in 1.8 -- IIRC it's only there so we can use it in umath, and
IIRC the patch to use it hasn't landed yet. Or we could just merge
umath and multiarray into a single .so, that would save a *lot* of
annoying fiddling with the public API that doesn't actually serve any
purpose.

-n



More information about the NumPy-Discussion mailing list