From mboxrd@z Thu Jan 1 00:00:00 1970 From: aditya siram Subject: Re: [SOLVED] [org-babel] References Not Expanding Date: Sun, 22 Aug 2010 16:32:28 -0500 Message-ID: References: Mime-Version: 1.0 Content-Type: multipart/mixed; boundary=001636418711cdf7a9048e7044a2 Return-path: Received: from [140.186.70.92] (port=59484 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OnI9X-0007Uz-7r for emacs-orgmode@gnu.org; Sun, 22 Aug 2010 17:32:32 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OnI9V-0006YF-V7 for emacs-orgmode@gnu.org; Sun, 22 Aug 2010 17:32:31 -0400 Received: from mail-wy0-f169.google.com ([74.125.82.169]:35198) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OnI9V-0006YA-O2 for emacs-orgmode@gnu.org; Sun, 22 Aug 2010 17:32:29 -0400 Received: by wyg36 with SMTP id 36so6626073wyg.0 for ; Sun, 22 Aug 2010 14:32:28 -0700 (PDT) In-Reply-To: List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org --001636418711cdf7a9048e7044a2 Content-Type: multipart/alternative; boundary=001636418711cdf799048e7044a0 --001636418711cdf799048e7044a0 Content-Type: text/plain; charset=ISO-8859-1 The last patch is formatted for email. Here's the correct one. Sorry. -deech On Sun, Aug 22, 2010 at 4:21 PM, aditya siram wrote: > The function that loads the code block into the interpreter > org-babel-load-in-session does not do noweb reference expansion. > > I have included a git patch that adds that functionality. > > -deech > > > On Sat, Aug 21, 2010 at 4:42 PM, aditya siram wrote: > >> Hi all, >> I have the development version of org-mode and org-babel noweb style >> references are not expanding during evaluation, they are instead copied >> literally into the temp file. They seem to expand fine when tangling. Here >> is file that is failing: >> * Root >> #+begin_src haskell :noweb yes :tangle Main.hs >> <> >> <> >> main = print $ test [1,2,3] >> #+end_src >> >> * Imports >> #+srcname: Imports >> #+begin_src haskell >> import Control.Monad.State >> #+end_src >> >> * Append Function >> #+srcname: Test >> #+begin_src haskell >> test = length >> #+end_src >> >> I have tried unsuccessfully to make "Imports" and "Append Function" >> children of "Root". >> >> Thanks! >> -deech >> > > --001636418711cdf799048e7044a0 Content-Type: text/html; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable The last patch is formatted for email. Here's the correct one. Sorry.-deech

On Sun, Aug 22, 2010 at 4:21 PM,= aditya siram <aditya.siram@gmail.com> wrote:
The function that= loads the code block into the interpreter org-babel-load-in-session does n= ot do noweb reference expansion.

I have included a git patch that adds that functionality.

-deech=


On Sat, Aug 21, 2010 at 4:42 PM, aditya siram <aditya.siram@gmail.com= > wrote:
Hi all,
I have the development version of org-mode and org-babel noweb = style references are not expanding during evaluation, they are instead copi= ed literally into the temp file. They seem to expand fine when tangling. He= re is file that is failing:
* Root
#+begin_src haskell :noweb yes :tangle Main.hs
=A0 <<Imp= orts>>
=A0 <<Test>>
=A0 main =3D print $ test [1,2,= 3]
#+end_src

* Imports
#+srcname: Imports
#+begin_src haske= ll
=A0 import Control.Monad.State
#+end_src

* Append Function
#+= srcname: Test
#+begin_src haskell
=A0 test =3D length
#+end_src
I have tried unsuccessfully to make "Imports" and "App= end Function" children of "Root".

Thanks!
-deech


--001636418711cdf799048e7044a0-- --001636418711cdf7a9048e7044a2 Content-Type: text/x-diff; charset=US-ASCII; name="noweb_references_expand_on_session_load.patch" Content-Disposition: attachment; filename="noweb_references_expand_on_session_load.patch" Content-Transfer-Encoding: base64 X-Attachment-Id: f_gd6eyy6u1 Y29tbWl0IGVlZWVjZTI2YmU0NDM0MzgzMjViYjk4NTQ4OGJkZGM3ODQ0MzJlOTcKQXV0aG9yOiBB ZGl0eWEgU2lyYW0gPGFkaXR5YS5zaXJhbUBnbWFpbC5jb20+CkRhdGU6ICAgU3VuIEF1ZyAyMiAx NjoxMjoxNyAyMDEwIC0wNTAwCgogICAgTm93ZWIgc3R5bGUgcmVmZXJlbmNlcyBhcmUgbm93IGV4 cGFuZGVkIHdpdGggbG9hZGluZyBhIGNvZGUgYmxvY2sgaW4gYSBzZXNzaW9uLgoKZGlmZiAtLWdp dCBhL2xpc3Avb2IuZWwgYi9saXNwL29iLmVsCmluZGV4IDg1NTdmMDkuLjJlY2MxZGIgMTAwNjQ0 Ci0tLSBhL2xpc3Avb2IuZWwKKysrIGIvbGlzcC9vYi5lbApAQCAtNDIxLDggKzQyMSwxMiBAQCBz ZXNzaW9uLiIKICAgKGludGVyYWN0aXZlKQogICAobGV0KiAoKGluZm8gKG9yIGluZm8gKG9yZy1i YWJlbC1nZXQtc3JjLWJsb2NrLWluZm8pKSkKICAgICAgICAgIChsYW5nIChudGggMCBpbmZvKSkK LSAgICAgICAgIChib2R5IChudGggMSBpbmZvKSkKICAgICAgICAgIChwYXJhbXMgKG50aCAyIGlu Zm8pKQorICAgICAgICAgKGJvZHkgKHNldGYgKG50aCAxIGluZm8pCisJCSAgICAgKGlmIChhbmQg KGNkciAoYXNzb2MgOm5vd2ViIHBhcmFtcykpCisgICAgICAgICAgICAgICAgICAgICAgICAgICAg ICAoc3RyaW5nPSAieWVzIiAoY2RyIChhc3NvYyA6bm93ZWIgcGFyYW1zKSkpKQorICAgICAgICAg ICAgICAgICAgICAgICAgIChvcmctYmFiZWwtZXhwYW5kLW5vd2ViLXJlZmVyZW5jZXMgaW5mbykK KwkJICAgICAgIChudGggMSBpbmZvKSkpKQogICAgICAgICAgKHNlc3Npb24gKGNkciAoYXNzb2Mg OnNlc3Npb24gcGFyYW1zKSkpCiAJIChkaXIgKGNkciAoYXNzb2MgOmRpciBwYXJhbXMpKSkKIAkg KGRlZmF1bHQtZGlyZWN0b3J5Cg== --001636418711cdf7a9048e7044a2 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-orgmode mailing list Please use `Reply All' to send replies to the list. Emacs-orgmode@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-orgmode --001636418711cdf7a9048e7044a2--