From mboxrd@z Thu Jan 1 00:00:00 1970 From: Rick Frankel Subject: Re: [PATCH] Process hlines in imported tables Date: Sun, 31 Mar 2013 08:29:00 -0400 Message-ID: <20130331122900.GA57939@BigDog.local> References: <20130329014615.GA49671@BigDog.local> <87wqsq6yd1.fsf@gmail.com> <20130329214238.GA53401@BigDog.local> <87r4ixah7y.fsf@gmail.com> <20130330234151.GA53721@BigDog.local> <87mwtkqtzh.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Return-path: Received: from eggs.gnu.org ([208.118.235.92]:58515) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UMHNh-00079W-20 for emacs-orgmode@gnu.org; Sun, 31 Mar 2013 08:29:11 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UMHNc-000492-3I for emacs-orgmode@gnu.org; Sun, 31 Mar 2013 08:29:05 -0400 Received: from [204.62.15.78] (port=39472 helo=mail.rickster.com) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UMHNc-00048w-0P for emacs-orgmode@gnu.org; Sun, 31 Mar 2013 08:29:00 -0400 Content-Disposition: inline In-Reply-To: <87mwtkqtzh.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: emacs-orgmode@gnu.org On Sat, Mar 30, 2013 at 06:43:30PM -0600, Eric Schulte wrote: > Rick Frankel writes: > > *Note* =wrap= and =raw= give same results > > #+begin_src perl :results raw > > q[|c1|c2| > > |- > > |a|1| > > |b|2|]; > > #+end_src > > > > #+results: > > | | c1 | c2 | > > | | - | | > > | | a | 1 | > > | | b | 2 | > > > > This is a problem in the results returned by ob-perl, not in the results > insertion mechanism. Given what is actually being returned by that code > block the results make sense. > > #+name: perl-example > #+begin_src perl :results raw > q[|c1|c2| > |- > |a|1| > |b|2|]; > #+end_src > If we add verbatim (which inhibits interpretation as a value, which can > often result in a list or table result), then we get what I assume you > expect. > #+name: perl-example > #+begin_src perl :results verbatim raw > q[|c1|c2| > |- > |a|1| > |b|2|]; > #+end_src > > #+RESULTS: perl-example > | c1 | c2 | > |----+----| > | a | 1 | > | b | 2 | > Missed verbatim. Thanks for the pointer, it works, but i think that perl is double-processing returned values. If we do the same things in elisp i get (my) expected results: #+begin_src elisp :results raw "|c1|c2| |- |a|1| |b|2|"; #+end_src #+results: | c1 | c2 | |----+----| | a | 1 | | b | 2 | *NOTE* this will not properly clean-up the results, but keep inserting more copies. #+begin_src elisp :results raw verbatim "|c1|c2| |- |a|1| |b|2|"; #+end_src #+results: "|c1|c2| |- |a|1| |b|2|" > > #+begin_src perl :results raw output > > print q[|c1|c2| > > |- > > |a|1| > > |b|2| > > ]; Yes, this was included to show the inconsistency between value and output returns. BTW, "raw output" and "raw output verbatim" generate the same results. > > Footnotes: > [1] http://orgmode.org/worg/org-contrib/babel/header-args.html I will take a look and see if i come up with anything else. In general, what I have found with babel processing is that there is major inconsistency between the results processing in different languages. Somehow, I would think that the same output (modulo sytnactic diferences) should generate the same results regardless of language. rick