testsuite/libgomp.c/appendix-a/a.33.3.c

Go to the documentation of this file.
00001 /* { dg-do compile } */
00002 
00003 #include <stdio.h>
00004 #include <stdlib.h>
00005 #include <omp.h>
00006 omp_lock_t *
00007 new_lock ()
00008 {
00009   omp_lock_t *lock_ptr;
00010 #pragma omp single copyprivate(lock_ptr)
00011   {
00012     lock_ptr = (omp_lock_t *) malloc (sizeof (omp_lock_t));
00013     omp_init_lock (lock_ptr);
00014   }
00015   return lock_ptr;
00016 }

Generated on Fri Apr 5 05:38:10 2013 for Libgomp by  doxygen 1.4.7