On Sun, 22 Oct 2006 04:00:37 -0700, Martin Albrecht <[EMAIL PROTECTED]> wrote: >> It turns out that pyrex is run from the top level directory like this: >> >> >> pyrexc -I/Volumes/HOME/s/devel/sage-main2 sage/rings/integer_mod.pyx >> >> Thus the source filename is given as sage/rings/integer_mod.pyx, from >> which >> the full module name is easy to reconstruct. > >> I did a bunch of work on the compiler, and now it all works nicely, >> automatically, >> and with no need for a command line option. Yeah!
> Congratulations. But there is something that bothers me with this > approach: Am > I right that using this idea > > pyrexc -I I/Volumes/HOME/s/devel/sage-main2 sage/rings/integer_mod.pyx > > returns a different result than > > cd sage/rings > pyrexc -I I/Volumes/HOME/s/devel/sage-main2 integer_mod.pyx > > ? Also symbolic links etc. would return in different results. Even > though I > understand that this can be dealt with by the user - especially our > setup.py > I think it's an odd behavior for a compiler to react to these side > effects. You are correct. But pyrexc should only get run from setup.py (ideally automatically by distutils), which only gets run from the correctly place. It wouldn't be difficult to put the command line option to explicitly specify the module name back in. We can discuss more what to do. I've put my new version of pyrex here so you can try it: http://sage.math.washington.edu/tmp/pyrex-20061021.spkg >> When I was an undergrad one of our semester-long course projects was to >> write and modify an interpreter (that was written in C). I'm beginning >> to >> appreciate that course more (it was one of my favorites at the time). > > Did you do a cs course or do math majors take compiler courses in the US? A CS course. I was a CS major for a couple years before switching to math. William --~--~---------~--~----~------------~-------~--~----~ To post to this group, send email to sage-devel@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/sage-devel URLs: http://sage.scipy.org/sage/ and http://modular.math.washington.edu/sage/ -~----------~----~----~----~------~----~------~--~---