From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Charles C. Berry" Subject: Re: [babel] [bug] inline src_R breaks downstream src block Date: Mon, 22 Aug 2011 10:32:39 -0700 Message-ID: References: <87ty9d3tj5.fsf@gnu.org> <87pqjya9yw.fsf@gmail.com> <87ei0ea5ab.fsf@gmail.com> <87zkj18qvy.fsf@gmail.com> Mime-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Return-path: Received: from eggs.gnu.org ([140.186.70.92]:54944) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QvYMo-00041R-Cp for emacs-orgmode@gnu.org; Mon, 22 Aug 2011 13:33:01 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1QvYMh-000825-Ne for emacs-orgmode@gnu.org; Mon, 22 Aug 2011 13:32:54 -0400 Received: from iport-c2-out.ucsd.edu ([132.239.0.119]:23654) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1QvYMh-00081o-7w for emacs-orgmode@gnu.org; Mon, 22 Aug 2011 13:32:47 -0400 In-Reply-To: <87zkj18qvy.fsf@gmail.com> List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: Eric Schulte Cc: Bastien , emacs-orgmode On Mon, 22 Aug 2011, Eric Schulte wrote: > Hi Chuck, > > I just pushed up another fix, after which your example exports cleanly > on my system. Please give this another try and let me know if it is now > working for you as well. Org-mode version 7.7 (release_7.7.170.gcaaad.dirty) works fine on the example. Thanks, Chuck > > Thanks -- Eric > > "Charles C. Berry" writes: > >> On Sun, 21 Aug 2011, Eric Schulte wrote: >> >>> I've just pushed up a change to org-exp-blocks which should fix Charles' >>> original problem related to conflict between inline and regular code >>> blocks. Please let me know if this problem persists in the latest git >>> HEAD. >> >> Just updated to >> >> Org-mode version 7.7 (release_7.7.167.gfceb.dirty) >> >> And I get >> >> [...] >> Code block evaluation complete. >> if: Args out of range: -1, -1 >> >> after typing C-c C-e A RET y >> >> :-( >> >> Chuck >> >>> >>> Thanks -- Eric >>> >>> Eric Schulte writes: >>> >>>> Bastien writes: >>>> >>>>> Hi Charles, >>>>> >>>>> yes, there are some problems with parsing inline source blocks. >>>>> Stephen also reported that these colon lines >>>>> >>>>> : were $\beta_2$ = src_R{round(out3$coef[3], 4)} >>>>> : and $\beta_3$ = src_R{round(out3$coef[4], 4)} >>>>> >>>>> where not exporting correctly... Eric, can you have a look at >>>>> these problems? >>>>> >>>>> Thanks! >>>>> >>>> >>>> It will probably be a couple of days before I have sufficient time to >>>> address these issues, but rest assured it is only my TODO list. >>>> >>>> Thanks -- Eric >>>> >>>>> >>>>> "Charles C. Berry" writes: >>>>> >>>>>> ,---- >>>>>> | | * inline code block example >>>>>> | | | AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA >>>>>> | blah blah src_R[:results output]{cat(rnorm(2))} >>>>>> | CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC >>>>>> | #+begin_src R :eval never :exports none >>>>>> | 1+2 >>>>>> | a <- b + c >>>>>> | xyz >>>>>> | #+end_src >>>>>> | DDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDD >>>>>> `---- >>>>>> >>>>>> >>>>>> When I run C-c C-e A y, I get a buffer that misses the 'DDD...' line. >>>>>> >>>>>> When I run C-c C-e L y, I get a buffer that ends like this: >>>>>> >>>>>> ---- >>>>>> | AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA >>>>>> | blah blah \texttt{-1.172165 -0.5324113} >>>>>> | CCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCCC >>>>>> | \begin{src}R DDDDDDDDDDDDDDDDDDDDDDDDDDD >>>>>> | | \end{document} >>>>>> `---- >>>>>> >>>>>> More complicated examples exhibit other problems, I speculate that >>>>>> parsing the inline src_R and setting up to find the next >>>>>> #+begin_src...#+end_src instance is what has gone wrong. >>>>>> >>>>>> FWIW, changing the :exports header to 'code' seems to give correct >>>>>> results >>>>>> >>>>>> Also, placing a dummy example like this: >>>>>> >>>>>> ,---- >>>>>> | #+begin_example >>>>>> | #+end_example >>>>>> `---- >>>>>> >>>>>> after the src_R line produces correct results. >>>>>> >>>>>> Chuck >>>>>> >>>>>> >>>>>> Charles C. Berry Dept of Family/Preventive Medicine >>>>>> cberry@tajo.ucsd.edu UC San Diego >>>>>> http://famprevmed.ucsd.edu/faculty/cberry/ La Jolla, San Diego 92093-0901 >>>>>> >>>>>> >>>>>> >>>>>> >>> >>> -- >>> Eric Schulte >>> http://cs.unm.edu/~eschulte/ >>> >> >> Charles C. Berry Dept of Family/Preventive Medicine >> cberry@tajo.ucsd.edu UC San Diego >> http://famprevmed.ucsd.edu/faculty/cberry/ La Jolla, San Diego 92093-0901 >> >> > > -- > Eric Schulte > http://cs.unm.edu/~eschulte/ > Charles C. Berry Dept of Family/Preventive Medicine cberry@tajo.ucsd.edu UC San Diego http://famprevmed.ucsd.edu/faculty/cberry/ La Jolla, San Diego 92093-0901