From b8fa3637106860a9f293dfbbf06290a1e91f80d2 Mon Sep 17 00:00:00 2001
From: Emilie Marchandise <emilie.marchandise@uclouvain.be>
Date: Wed, 11 May 2011 07:58:06 +0000
Subject: [PATCH]

---
 CMakeLists.txt           | 1 +
 Common/gmshpy.i          | 3 +++
 Geo/GModel.cpp           | 2 +-
 benchmarks/2d/square.geo | 2 +-
 4 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 0b9aabcff5..744fe3695d 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1183,3 +1183,4 @@ message("")
 
 mark_as_advanced(BISON FLEX GMP_LIB GMSH_EXTRA_VERSION HDF5_LIB MAKEINFO 
                  MED_LIB OCC_INC SZ_LIB TAUCS_LIB ACIS_LIB TEXI2PDF)
+
diff --git a/Common/gmshpy.i b/Common/gmshpy.i
index 871c892a9c..f54d09e2d3 100644
--- a/Common/gmshpy.i
+++ b/Common/gmshpy.i
@@ -3,6 +3,7 @@
 %include std_string.i
 %include std_vector.i
 %include std_list.i
+%include cpointer.i 
 
 %{
   #include "GmshConfig.h"
@@ -72,6 +73,8 @@
   GmshInitialize();
 %}
 
+%pointer_functions(double,doublep)
+%pointer_functions(int,intp)
 namespace std {
    %template(IntVector) vector<int>;
    %template(DoubleVector) vector<double, std::allocator<double> >;
diff --git a/Geo/GModel.cpp b/Geo/GModel.cpp
index fa0a02771c..089d39d276 100644
--- a/Geo/GModel.cpp
+++ b/Geo/GModel.cpp
@@ -266,7 +266,7 @@ std::vector<int> GModel::getEdgesByStringTag(const std::string tag)
     nums.push_back(ge->tag());
   }
 
-  printf("edges size = %d \n", nums.size());
+  return nums;
 }
 
 void GModel::remove(GRegion *r)
diff --git a/benchmarks/2d/square.geo b/benchmarks/2d/square.geo
index 6fd3ccf526..048c15c3f2 100644
--- a/benchmarks/2d/square.geo
+++ b/benchmarks/2d/square.geo
@@ -28,7 +28,7 @@ Plane Surface(10) = {5};
 //Compound Surface(100)={10};
 
 Physical Surface(100)={10};
-//Physical Line(200)={10};
+Physical Line(200)={1,2,3,4};
 
 
 
-- 
GitLab