Dag Sverre Seljebotn, 02.02.2010 10:45:
> What I'm wondering about is whether we can start having namespaces in 
> Cython/Includes. Especially since math is already a module, and I think 
> "c.math" is clearer than inventing "cmath".
> 
> So I propose:
> 
> from c.math cimport sqrt, acos, cos, sin, round
> from c.stdio cimport fopen

I'm fine with namespaces, although I find "math" a particularly bad
example. I'd like to be able to do this one day:

    from math cimport sin

and have it use the C library's sin() function. But I guess that just an
orthogonal feature.

I also wonder if "c" isn't a bit short for an unambiguous namespace. I
doubt that it's already in use by any sensible code (exactly for that
reason), but I'd like to make sure we keep the risk of naming collisions
low, *exactly because* we start using packaged names here.

Stefan

_______________________________________________
Cython-dev mailing list
[email protected]
http://codespeak.net/mailman/listinfo/cython-dev

Reply via email to