[Bf-blender-cvs] SVN commit: /data/svn/bf-blender [55389] trunk/blender/source/blender/ blenkernel/intern/node.c: fix for build error: " #pragma GCC diagnostic not allowed inside functions"
Dalai Felinto
dfelinto at gmail.com
Mon Mar 18 22:16:05 CET 2013
Revision: 55389
http://projects.blender.org/scm/viewvc.php?view=rev&root=bf-blender&revision=55389
Author: dfelinto
Date: 2013-03-18 21:16:04 +0000 (Mon, 18 Mar 2013)
Log Message:
-----------
fix for build error: "#pragma GCC diagnostic not allowed inside functions"
It works in a newest gcc (e.g. 4.6.3) but fails here:
i686-apple-darwin11-llvm-gcc-4.2 (GCC) 4.2.1 (Based on Apple Inc. build
5658) (LLVM build 2336.11.00)
Modified Paths:
--------------
trunk/blender/source/blender/blenkernel/intern/node.c
Modified: trunk/blender/source/blender/blenkernel/intern/node.c
===================================================================
--- trunk/blender/source/blender/blenkernel/intern/node.c 2013-03-18 20:32:30 UTC (rev 55388)
+++ trunk/blender/source/blender/blenkernel/intern/node.c 2013-03-18 21:16:04 UTC (rev 55389)
@@ -1974,6 +1974,17 @@
/* ************ NODE TREE INTERFACE *************** */
+#ifdef USE_NODE_COMPAT_CUSTOMNODES
+#ifdef __GNUC__
+# pragma GCC diagnostic push
+# pragma GCC diagnostic ignored "-Wdeprecated-declarations"
+#endif
+
+#ifdef __GNUC__
+# pragma GCC diagnostic pop
+#endif
+#endif /* USE_NODE_COMPAT_CUSTOMNODES */
+
static bNodeSocket *make_socket_template(bNodeTree *ntree, int in_out,
const char *idname, const char *name)
{
@@ -2006,17 +2017,8 @@
* but reconstructing own_index in writefile.c would require parsing the identifier string.
*/
-#ifdef __GNUC__
-# pragma GCC diagnostic push
-# pragma GCC diagnostic ignored "-Wdeprecated-declarations"
-#endif
-
sock->own_index = own_index;
-#ifdef __GNUC__
-# pragma GCC diagnostic pop
-#endif
-
#endif /* USE_NODE_COMPAT_CUSTOMNODES */
sock->limit = (in_out == SOCK_IN ? 1 : 0xFFF);
More information about the Bf-blender-cvs
mailing list