Re: [O] babel C, C++, D enhancement

2014-06-17 Thread Achim Gratz
Thierry Banel writes: You are right, INT_MAX is the C++ constant to compare to. It is defined in limits.h I'm not sure I want to locate limits.h (where is it ? are there several versions ?), and parse it, all from within Emacs-lisp... No, this isn't something you should even try. The only

Re: [O] babel C, C++, D enhancement

2014-06-17 Thread Thierry Banel
Le 17/06/2014 19:16, Achim Gratz a écrit : Thierry Banel writes: You are right, INT_MAX is the C++ constant to compare to. It is defined in limits.h I'm not sure I want to locate limits.h (where is it ? are there several versions ?), and parse it, all from within Emacs-lisp... No, this

Re: [O] babel C, C++, D enhancement

2014-06-16 Thread Achim Gratz
Thierry Banel writes: So Babel C++ may cause problem for large integers. I am not sure how we can fix this in any case. You'd need to know INT_MAX and give an error for larger values or use an integral type that is large enough to handle Emacs' integer (which would most likely be necessary for

Re: [O] babel C, C++, D enhancement

2014-06-16 Thread Thierry Banel
Hi Achim. You are right, INT_MAX is the C++ constant to compare to. It is defined in limits.h I'm not sure I want to locate limits.h (where is it ? are there several versions ?), and parse it, all from within Emacs-lisp... And this will have to be done for all languages (Python, Perl, Java, and

Re: [O] babel C, C++, D enhancement

2014-06-16 Thread Thomas S. Dye
Aloha Thierry, How about a user-customizable variable with a default value of 2147483647? All the best, Tom Thierry Banel tbanelweb...@free.fr writes: Hi Achim. You are right, INT_MAX is the C++ constant to compare to. It is defined in limits.h I'm not sure I want to locate limits.h

Re: [O] babel C, C++, D enhancement

2014-06-16 Thread Nick Dokos
t...@tsdye.com (Thomas S. Dye) writes: Aloha Thierry, How about a user-customizable variable with a default value of 2147483647? All the best, Tom Thierry Banel tbanelweb...@free.fr writes: Hi Achim. You are right, INT_MAX is the C++ constant to compare to. It is defined in limits.h

Re: [O] babel C, C++, D enhancement

2014-06-13 Thread Achim Gratz
Eric Schulte writes: This new patch looks great, and the test suite passes locally. I've just applied it. You also get a warning from the byte-compiler on something that is clearly a bug. I think the fix should be: --8---cut here---start-8--- diff --git

Re: [O] babel C, C++, D enhancement

2014-06-13 Thread Bastien
Hi Eric and Thierry, Eric Schulte schulte.e...@gmail.com writes: This new patch looks great, and the test suite passes locally. I've just applied it. Thanks for applying this -- let me just be boring again and insist on properly rewrite the Changelog when applying patches... in this case,

Re: [O] babel C, C++, D enhancement

2014-06-13 Thread Eric Schulte
Achim Gratz strom...@nexgo.de writes: Eric Schulte writes: This new patch looks great, and the test suite passes locally. I've just applied it. You also get a warning from the byte-compiler on something that is clearly a bug. I think the fix should be: --8---cut

Re: [O] babel C, C++, D enhancement

2014-06-13 Thread Eric Abrahamsen
Bastien b...@gnu.org writes: Hi Eric and Thierry, Eric Schulte schulte.e...@gmail.com writes: This new patch looks great, and the test suite passes locally. I've just applied it. Thanks for applying this -- let me just be boring again and insist on properly rewrite the Changelog when

Re: [O] babel C, C++, D enhancement

2014-06-13 Thread Thierry Banel
Thanks Achim for finding and fixing this bug. I do agree about fuzziness between int and float. My Emacs considers 2305843009213693951 as an integer, 2305843009213693952 too large to be an integer. My C++ compiler sees 4294967295 as an integer, 4294967296 as too large to fit an int. So

Re: [O] babel C, C++, D enhancement

2014-06-09 Thread Thierry Banel
Good ! Now I will update the documentation (worg/org-contrib/babel/languages/ob-doc-C.org) and... that's it. Le 09/06/2014 01:22, Eric Schulte a écrit : Hi Theirry, This new patch looks great, and the test suite passes locally. I've just applied it. Thanks! Eric also, thanks for taking

Re: [O] babel C, C++, D enhancement

2014-06-08 Thread Thierry Banel
Hi Eric, hi All Here is a new patch (do not apply the previous). I added a check in the test suite for the D compiler availability (and for the C++ compiler as well). It silently returns true when the compiler is not found. To run the test suite I did that: - start from an up-to-date org-mode/

Re: [O] babel C, C++, D enhancement

2014-06-08 Thread Eric Schulte
Thierry Banel tbanelweb...@free.fr writes: Hi Eric, hi All Here is a new patch (do not apply the previous). I added a check in the test suite for the D compiler availability (and for the C++ compiler as well). It silently returns true when the compiler is not found. To run the test suite

Re: [O] babel C, C++, D enhancement

2014-06-07 Thread Thierry Banel
Thanks Eric for your feed-back. Bastien told me the same as you about the commit message. So I will take time to clear all those issues. Le 06/06/2014 18:31, Eric Schulte a écrit : Hi Thierry, This looks wonderful, however after applying this patch I get the following errors when running

Re: [O] babel C, C++, D enhancement

2014-06-06 Thread Eric Schulte
Hi Thierry, This looks wonderful, however after applying this patch I get the following errors when running make test-dirty. 10 unexpected results: FAILED ob-C/inhomogeneous_table FAILED ob-D/inhomogeneous_table FAILED ob-D/integer-var FAILED ob-D/list-list-var FAILED

[O] babel C, C++, D enhancement

2014-06-01 Thread Thierry Banel
Hi Bastien, hi all Here is a Babel enhancement for C, C++ and D languages - support for non-homogeneous tables (mixing numerics and strings) - support for table headers - easier iterating over a table - added some error handling - new D support for simple lists and vectors - new unit tests