components/stdcxx/patches/058-NO_INT_TRAPS.cpp.patch
changeset 402 94ae4d75524c
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/components/stdcxx/patches/058-NO_INT_TRAPS.cpp.patch	Thu Jul 14 11:26:11 2011 -0700
@@ -0,0 +1,28 @@
+--- stdcxx-4.2.1/etc/config/src/NO_INT_TRAPS.cpp	2008-04-24 20:25:44.000000000 -0400
++++ stdcxx-4.2.1/etc/config/src/NO_INT_TRAPS.cpp	2011-01-11 21:21:17.842689459 -0500
+@@ -43,12 +43,15 @@
+     // test expects to be called with no command line arguments
+     // i.e., (argc < 2) is expected to hold
+ 
++	int result[2];
++
++#if defined(__SUNPRO_CC)
++	result[0] = result[1] = 1;
++#else
+     // argc used to try to foil optimizers
+     int_zero = get_int (argc);
+     int_one  = get_int (argc);
+ 
+-    int result [2];
+-
+     TRY {
+         // use both division and modulo to try to foil optimizers
+         result [0] = int_one / int_zero;
+@@ -57,6 +60,7 @@
+     EXCEPT (1) {
+         return 1;
+     }
++#endif
+ 
+     // NEGATIVE test: successful exit status indicates a failure
+     return argc < 2 ? result [0] : result [1];