Re: [Cython] RFC: an inline_ function that dumps c/c++ code to the code emitter

2016-08-23 Thread Jason Newton
Just trying and improve the state of the art. Yea maybe we have to add some tricks to separate the two grammar wise, so they can play together. Besides, I didn't start with that complexity, it evolved into seeing if that was a viable path forward. On Tue, Aug 23, 2016 at 5:15 AM, Alex S. wrote:

Re: [Cython] RFC: an inline_ function that dumps c/c++ code to the code emitter

2016-08-23 Thread Jason Newton
> > > I have another idea/iteration to run by you then. One of your chief > > quibbles, although I don't think it's your underlying one, is Cython must > > understand what's going on. So how about we support a block of C/C++ > code > > as a proper construct. Same name but now, I guess braces may

Re: [Cython] RFC: an inline_ function that dumps c/c++ code to the code emitter

2016-08-22 Thread Jason Newton
On Mon, Aug 22, 2016 at 3:26 PM, Robert Bradshaw wrote: > > To clarify, I'm coming from the case where I > > didn't read the whole tutorial/docs before being faced with pyx in the > > projects I previously mentioned, while on tight turn around time - I was > not > > able to grok in that context.

Re: [Cython] RFC: an inline_ function that dumps c/c++ code to the code emitter

2016-08-21 Thread Jason Newton
On Sun, Aug 21, 2016 at 5:30 AM, Robert Bradshaw wrote: > > In my experience Cython has generally been fairly easy to pick up for > people who already know Python. And Python often easy to pick up for > people who already know C/C++. Of course for many wrappings it often > takes non-trivial knowl

Re: [Cython] RFC: an inline_ function that dumps c/c++ code to the code emitter

2016-08-21 Thread Jason Newton
On Sun, Aug 21, 2016 at 1:36 AM, Ian Henriksen < insertinterestingnameh...@gmail.com> wrote: > >> Remember - cython is "the way" that comes up for how to glue C/C++ into >> python these days, not just the program in cish python frontend for speed. >> >> > There's some truth to the issues you raise

Re: [Cython] RFC: an inline_ function that dumps c/c++ code to the code emitter

2016-08-21 Thread Jason Newton
Stefan Behnel wrote: > Robert Bradshaw schrieb am 21.08.2016 um 11:11: > > On Fri, Aug 19, 2016 at 12:32 PM, Jason Newton wrote: > >> PyInline's last news update was in 2004 where the author gives a "Hats > of[f] > >> to PyRex", prior to that only a few blog en

Re: [Cython] RFC: an inline_ function that dumps c/c++ code to the code emitter

2016-08-20 Thread Jason Newton
On Sat, Aug 20, 2016 at 1:19 AM, Stefan Behnel wrote: > > Especially with respect to C++, we've always tried to make things safe and > helpful that Cython can support directly, and to make things possible that > are too complex to handle safely. But I agree with Robert that allowing > arbitrary C

Re: [Cython] RFC: an inline_ function that dumps c/c++ code to the code emitter

2016-08-19 Thread Jason Newton
On Fri, Aug 19, 2016 at 3:19 PM, William Stein wrote: > On Fri, Aug 19, 2016 at 8:19 AM, Jason Newton wrote: > > You must realize that almost any other python driven way to compile > c-code > > in the spirit these projects do is deprecated/dead. Cython has absorbed > all &

Re: [Cython] RFC: an inline_ function that dumps c/c++ code to the code emitter

2016-08-19 Thread Jason Newton
On Fri, Aug 19, 2016 at 5:36 AM, Robert Bradshaw wrote: > On Thu, Aug 18, 2016 at 12:05 PM, Jason Newton wrote: > > Accidentally posted to an already-opened tab for the cython-users ML > > yesterday, moving to here. Following up from a github opened issue here: > > > >

[Cython] RFC: an inline_ function that dumps c/c++ code to the code emitter

2016-08-18 Thread Jason Newton
Accidentally posted to an already-opened tab for the cython-users ML yesterday, moving to here. Following up from a github opened issue here: https://github.com/cython/cython/issues/1440 I was hoping we could give a way to drop straight into C/C++ inside of Cython pyx files. Why? -It [helps] av

[Cython] Any way to embed C/C++ in a single source compilation of a pyx file?

2016-08-15 Thread Jason Newton
I just added inline_module's and submitted a PR today here: https://github.com/cython/cython/pull/555 My intent was something like OpenCL's JIT/AOC compilation (PyCUDA/PyOpenCL also work this way) which is simple and high performance, and I saw cython had this capability and just needed a little b