[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

[patch] Make definition of AOFF2NUM complete at compile time for swigutil_rb.c

From: Joe Swatosh <joe.swatosh_at_gmail.com>
Date: 2007-04-22 23:31:18 CEST

I'm trying to reduce the noise when building the Ruby bindings. So I
don't get too used to so many warnings.

[[[
Deal with compiler warning for (possible) narrowing conversion

* subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.c
 Make the definition of AOFF2NUM complete at preprocessor time instead of
 run time.
]]]

Index: subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.c
===================================================================
--- subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.c (revision
24695)
+++ subversion/bindings/swig/ruby/libsvn_swig_ruby/swigutil_rb.c (working copy)
@@ -38,8 +38,11 @@
 #include "svn_utf.h"

-#define AOFF2NUM(num) \
- (sizeof(apr_off_t) == SIZEOF_LONG_LONG ? LL2NUM(num) : LONG2NUM(num))
+#if APR_HAS_LARGE_FILES
+# define AOFF2NUM(num) LL2NUM(num)
+#else
+# define AOFF2NUM(num) LONG2NUM(num)
+#endif

 #if SIZEOF_LONG_LONG == 8
 # define AI642NUM(num) LL2NUM(num)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Sun Apr 22 23:31:31 2007

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.