diff --git a/Common/DefaultOptions.h b/Common/DefaultOptions.h index 46857b35d0e7b036ee5e414d059940006bac9a8b..f78e398c2b95cdced6157ca3eaa01104d52ad4bb 100644 --- a/Common/DefaultOptions.h +++ b/Common/DefaultOptions.h @@ -83,7 +83,7 @@ StringXString GeneralOptions_String[] = { #elif defined(__APPLE__) "open -t %s" , #else - "sensible-editor '%s' &" , + "sensible-editor '%s'" , #endif "System command to launch a text editor" }, { F|S, "TmpFileName" , opt_general_tmp_filename , ".gmsh-tmp" , @@ -95,7 +95,7 @@ StringXString GeneralOptions_String[] = { #elif defined(__APPLE__) "open %s" , #else - "sensible-browser %s &" , + "sensible-browser %s" , #endif "System command to launch a web browser" }, diff --git a/Common/GmshSocket.h b/Common/GmshSocket.h index cc697879cffe3a9d3e868d6743a1f9d5cca6267b..9cf007fa6a1649d0605b552daaf10f30364d9c8a 100644 --- a/Common/GmshSocket.h +++ b/Common/GmshSocket.h @@ -318,7 +318,7 @@ class GmshServer : public GmshSocket{ public: GmshServer() : GmshSocket(), _portno(-1) {} virtual ~GmshServer(){} - virtual int SystemCall(const char *str) = 0; + virtual int NonBlockingSystemCall(const char *str) = 0; virtual int NonBlockingWait(int socket, double waitint, double timeout) = 0; int Start(const char *command, const char *sockname, double timeout) { @@ -389,10 +389,7 @@ class GmshServer : public GmshSocket{ // we assume that the command line always ends with the socket name std::string cmd(command); cmd += " " + _sockname; -#if !defined(WIN32) - cmd += " &"; -#endif - SystemCall(cmd.c_str()); // start the solver + NonBlockingSystemCall(cmd.c_str()); // start the solver } else{ timeout = 0.; // no command launched: don't set a timeout diff --git a/Common/OS.cpp b/Common/OS.cpp index 81502524d3e30c23bbbb5fcc88c6b460b00ec1e3..e073e8927d89994290021aa9755edbd15591795b 100644 --- a/Common/OS.cpp +++ b/Common/OS.cpp @@ -141,7 +141,7 @@ std::string GetHostName() return std::string(host); } -int UnlinkFile(std::string fileName) +int UnlinkFile(const std::string &fileName) { #if !defined(WIN32) || defined(__CYGWIN__) return unlink(fileName.c_str()); @@ -150,7 +150,7 @@ int UnlinkFile(std::string fileName) #endif } -int StatFile(std::string fileName) +int StatFile(const std::string &fileName) { #if !defined(WIN32) || defined(__CYGWIN__) struct stat buf; @@ -176,7 +176,7 @@ int KillProcess(int pid) return 1; } -int SystemCall(std::string command) +int SystemCall(const std::string &command, bool blocking) { #if defined(WIN32) STARTUPINFO suInfo; @@ -184,17 +184,30 @@ int SystemCall(std::string command) memset(&suInfo, 0, sizeof(suInfo)); suInfo.cb = sizeof(suInfo); Msg::Info("Calling '%s'", command.c_str()); - CreateProcess(NULL, (char*)command.c_str(), NULL, NULL, FALSE, - NORMAL_PRIORITY_CLASS|DETACHED_PROCESS, NULL, NULL, - &suInfo, &prInfo); + if(blocking){ + CreateProcess(NULL, (char*)command.c_str(), NULL, NULL, FALSE, + NORMAL_PRIORITY_CLASS, NULL, NULL, + &suInfo, &prInfo); + // wait until child process exits. + WaitForSingleObject(prInfo.hProcess, INFINITE); + // close process and thread handles. + CloseHandle(prInfo.hProcess); + CloseHandle(prInfo.hThread); + } + else{ + CreateProcess(NULL, (char*)command.c_str(), NULL, NULL, FALSE, + NORMAL_PRIORITY_CLASS|DETACHED_PROCESS, NULL, NULL, + &suInfo, &prInfo); + } return 0; #else if(!system(NULL)) { Msg::Error("Could not find /bin/sh: aborting system call"); return 1; } - Msg::Info("Calling '%s'", command.c_str()); - return system(command.c_str()); + std::string cmd(command); + if(!blocking) cmd += " &"; + Msg::Info("Calling '%s'", cmd.c_str()); + return system(cmd.c_str()); #endif } - diff --git a/Common/OS.h b/Common/OS.h index 6998aafcd34b80d36d76c38a764c652f60d60049..6a17031a58deee69d69386fda8017645b29bfb43 100644 --- a/Common/OS.h +++ b/Common/OS.h @@ -16,9 +16,9 @@ double Cpu(); long GetMemoryUsage(); int GetProcessId(); std::string GetHostName(); -int UnlinkFile(std::string fileName); -int StatFile(std::string fileName); +int UnlinkFile(const std::string &fileName); +int StatFile(const std::string &fileName); int KillProcess(int pid); -int SystemCall(std::string command); +int SystemCall(const std::string &command, bool blocking=false); #endif diff --git a/Common/OpenFile.cpp b/Common/OpenFile.cpp index eba6ade46ba9e219a0ee1c6a268b66f62d491e23..9a309551d38c99ea3e8928d09b288dedf1a3da84 100644 --- a/Common/OpenFile.cpp +++ b/Common/OpenFile.cpp @@ -263,7 +263,7 @@ int MergeFile(std::string fileName, bool warnIfMissing) sstream << "File '"<< fileName << "' is in gzip format.\n\n" << "Do you want to uncompress it?"; if(Msg::GetAnswer(sstream.str().c_str(), 0, "Cancel", "Uncompress")){ - if(SystemCall(std::string("gunzip -c ") + fileName + " > " + noExt)) + if(SystemCall(std::string("gunzip -c ") + fileName + " > " + noExt, true)) Msg::Error("Failed to uncompress `%s': check directory permissions", fileName.c_str()); GModel::current()->setFileName(noExt); @@ -366,7 +366,7 @@ int MergeFile(std::string fileName, bool warnIfMissing) // mesh matcher if(CTX::instance()->geom.matchGeomAndMesh && !GModel::current()->empty()) { GModel* tmp2 = GModel::current(); - GModel* tmp = new GModel(); + GModel* tmp = new GModel(); tmp->readMSH(fileName); status = GeomMeshMatcher::instance()->match(tmp2, tmp); delete tmp; diff --git a/Fltk/onelabWindow.cpp b/Fltk/onelabWindow.cpp index c5e0a7b3cd8a5b7379f6369731d1757bbb753ee9..65cc9815ea9641b68aa0272ff71cd2961dbf5894 100644 --- a/Fltk/onelabWindow.cpp +++ b/Fltk/onelabWindow.cpp @@ -47,7 +47,7 @@ class onelabGmshServer : public GmshServer{ onelabGmshServer(onelab::localNetworkClient *client) : GmshServer(), _client(client) {} ~onelabGmshServer(){} - int SystemCall(const char *str){ return ::SystemCall(str); } + int NonBlockingSystemCall(const char *str){ return SystemCall(str); } int NonBlockingWait(int socket, double waitint, double timeout) { double start = GetTimeInSeconds(); diff --git a/Geo/GModelIO_Mesh.cpp b/Geo/GModelIO_Mesh.cpp index 789084fb7c3abc86cff58c1e841d867d9ce95d32..a0b4e71a509d0d4eeb0280544d493d8bcebf2f37 100644 --- a/Geo/GModelIO_Mesh.cpp +++ b/Geo/GModelIO_Mesh.cpp @@ -66,9 +66,9 @@ static void replaceCommaByDot(const std::string name) { char myCommand[1000], myCommand2[1000]; sprintf(myCommand, "sed 's/,/./g' %s > temp.txt", name.c_str()); - SystemCall(myCommand); + SystemCall(myCommand, true); sprintf(myCommand2, "mv temp.txt %s ", name.c_str()); - SystemCall(myCommand2); + SystemCall(myCommand2, true); } static bool getVertices(int num, int *indices, std::map<int, MVertex*> &map, @@ -170,7 +170,7 @@ static bool getElementsByNum(int elemNum[], std::map<int, std::vector<MElement*> bool erase, MElement *elems[], int nbElem = 1) { int i = 0; - std::map<int, std::vector<MElement*> >::iterator it = elements.begin(); + std::map<int, std::vector<MElement*> >::iterator it = elements.begin(); for(; it != elements.end(); ++it) { std::vector<MElement*>::iterator itE = it->second.begin(); for(; itE != it->second.end(); itE++) { @@ -1692,7 +1692,7 @@ int GModel::readUNV(const std::string &name) if(!CTX::instance()->mesh.switchElementTags) { if(sscanf(buffer, "%d %d %d %d %d %d", &num, &type, &elementary, &physical, &color, &numNodes) != 6) break; - } + } else { if(sscanf(buffer, "%d %d %d %d %d %d", &num, &type, &physical, &elementary, &color, &numNodes) != 6) break; @@ -2168,7 +2168,7 @@ int GModel::writeMAIL(const std::string &name, bool saveAll, double scalingFacto } } } - + // TODO write edges (with signs) for(fiter it = firstFace(); it != lastFace(); ++it){ if(saveAll || (*it)->physicals.size()){ @@ -2194,7 +2194,7 @@ int GModel::readGEOM(const std::string &name) } int numNodes, numElements, dummy; - if(fscanf(fp, "%d %d %d", &numNodes, &numElements, &dummy) != 3) + if(fscanf(fp, "%d %d %d", &numNodes, &numElements, &dummy) != 3) return 0; if(!numNodes || !numElements){ @@ -2896,7 +2896,7 @@ int GModel::readVTK(const std::string &name, bool bigEndian) if(fscanf(fp, "%s %s", buffer, buffer2) != 2) return 0; bool unstructured = false; - if(!strcmp(buffer, "DATASET") && !strcmp(buffer2, "UNSTRUCTURED_GRID")) + if(!strcmp(buffer, "DATASET") && !strcmp(buffer2, "UNSTRUCTURED_GRID")) unstructured = true; if((strcmp(buffer, "DATASET") && strcmp(buffer2, "UNSTRUCTURED_GRID")) || @@ -3087,13 +3087,13 @@ int GModel::readDIFF(const std::string &name) std::map<int, std::map<int, std::string> > physicals[4]; std::map<int, MVertex*> vertexMap; std::vector<MVertex*> vertexVector; - + { while(strstr(str, "Number of space dim. =") == NULL){ if(!fgets(str, sizeof(str), fp) || feof(fp)) break; } - + int dim; if(sscanf(str, "%*s %*s %*s %*s %*s %d", &dim) != 1) return 0; Msg::Info("dimension %d", dim); @@ -3128,9 +3128,9 @@ int GModel::readDIFF(const std::string &name) bool several_subdomains; if(!fgets(str, sizeof(str), fp) || feof(fp)) return 0; - if(!strncmp(&str[2], "Only one material", 17) || + if(!strncmp(&str[2], "Only one material", 17) || !strncmp(&str[2], "Only one subdomain", 18)){ - if(!strncmp(&str[37], "dpTRUE", 6) || !strncmp(&str[37], "true", 4) || + if(!strncmp(&str[37], "dpTRUE", 6) || !strncmp(&str[37], "true", 4) || !strncmp(&str[36], "dpTRUE", 6) || !strncmp(&str[36], "true", 4)){ several_subdomains = false; } @@ -3139,7 +3139,7 @@ int GModel::readDIFF(const std::string &name) } Msg::Info("several_subdomains %x %s", several_subdomains, str); } - + int nbi; std::vector<int> bi; if(!fgets(str, sizeof(str), fp) || feof(fp)) return 0; @@ -3163,7 +3163,7 @@ int GModel::readDIFF(const std::string &name) if(sscanf(str, format_read_bi.c_str(), &bi[i]) != 1) return 0; Msg::Info("bi[%d]=%d", i, bi[i]); } - + while(str[0] != '#'){ if(!fgets(str, sizeof(str), fp) || feof(fp)) break; @@ -3179,7 +3179,7 @@ int GModel::readDIFF(const std::string &name) if(!fgets(str, sizeof(str), fp)) return 0; double xyz[3]; int tmp; - if(sscanf(str, "%d ( %lf , %lf , %lf ) [%d]", &num, + if(sscanf(str, "%d ( %lf , %lf , %lf ) [%d]", &num, &xyz[0], &xyz[1], &xyz[2], &tmp) != 5) return 0; elementary[i].resize(tmp + 1); elementary[i][0] = tmp; @@ -3189,16 +3189,16 @@ int GModel::readDIFF(const std::string &name) Msg::Warning("Skipping duplicate vertex %d", num); else vertexMap[num] = new MVertex(xyz[0], xyz[1], xyz[2], 0, num); - if(numVertices > 100000) + if(numVertices > 100000) Msg::ProgressMeter(i + 1, numVertices, "Reading nodes"); // If the vertex numbering is dense, tranfer the map into a // vector to speed up element creation - if((int)vertexMap.size() == numVertices && + if((int)vertexMap.size() == numVertices && ((minVertex == 1 && maxVertex == numVertices) || (minVertex == 0 && maxVertex == numVertices - 1))){ Msg::Info("Vertex numbering is dense"); vertexVector.resize(vertexMap.size() + 1); - if(minVertex == 1) + if(minVertex == 1) vertexVector[0] = 0; else vertexVector[numVertices] = 0; @@ -3207,7 +3207,7 @@ int GModel::readDIFF(const std::string &name) vertexVector[it->first] = it->second; vertexMap.clear(); } - Msg::Info("%d ( %lf , %lf , %lf ) [%d]",i, xyz[0], xyz[1], xyz[2], + Msg::Info("%d ( %lf , %lf , %lf ) [%d]",i, xyz[0], xyz[1], xyz[2], elementary[i][0]); std::string format_read_bi = "%*d ( %*lf , %*lf , %*lf ) [%*d]"; for(int j = 0; j < elementary[i][0]; j++){ @@ -3243,31 +3243,31 @@ int GModel::readDIFF(const std::string &name) eleType = std::string(eleTypec); int k2; // local number for the element int NoVertices; // number of vertices per element - if(eleType == "ElmT3n2D"){ + if(eleType == "ElmT3n2D"){ NoVertices = 3; static int map[3] = {0, 1, 2}; // identical to gmsh mapping=std::vector<int>(map, map + sizeof(map) / sizeof(int)); type = MSH_TRI_3; } - else if(eleType == "ElmT6n2D"){ + else if(eleType == "ElmT6n2D"){ NoVertices = 6; static int map[6] = {0, 1, 2, 3, 4, 5}; // identical to gmsh mapping = std::vector<int>(map, map + sizeof(map) / sizeof(int)); type = MSH_TRI_6; } - else if(eleType == "ElmB4n2D"){ + else if(eleType == "ElmB4n2D"){ NoVertices = 4; static int map[4] = {0, 1, 3, 2}; // local numbering mapping = std::vector<int>(map, map + sizeof(map) / sizeof(int)); type = MSH_QUA_4; } - else if(eleType == "ElmB8n2D"){ + else if(eleType == "ElmB8n2D"){ NoVertices = 8; static int map[8] = {0, 1, 3, 2, 4, 6, 7, 5}; // local numbering mapping = std::vector<int>(map, map + sizeof(map) / sizeof(int)); type = MSH_QUA_8; } - else if(eleType == "ElmB9n2D"){ + else if(eleType == "ElmB9n2D"){ NoVertices = 9; static int map[9] = {0, 4, 1, 7, 8, 5, 3, 6, 2}; // local numbering mapping = std::vector<int>(map, map + sizeof(map) / sizeof(int)); @@ -3278,8 +3278,8 @@ int GModel::readDIFF(const std::string &name) static int map[4] = {0, 1, 2, 3}; // identical to gmsh mapping = std::vector<int>(map, map + sizeof(map) / sizeof(int)); type = MSH_TET_4; - } - else if(eleType == "ElmT10n3D"){ + } + else if(eleType == "ElmT10n3D"){ NoVertices = 10; static int map[10] = {0, 1, 2, 3, 4, 5, 6, 7, 8, 9}; // local numbering mapping = std::vector<int>(map, map + sizeof(map) / sizeof(int)); @@ -3290,21 +3290,21 @@ int GModel::readDIFF(const std::string &name) static int map[8] = {4, 5, 0, 1, 7, 6, 3, 2}; mapping = std::vector<int>(map, map + sizeof(map) / sizeof(int)); type = MSH_HEX_8; - } + } else if(eleType == "ElmB20n3D"){ NoVertices = 20; - static int map[20] = {4, 5, 0, 1, 7, 6, 3, 2, 16, 8, 19, 13, 15, 12, + static int map[20] = {4, 5, 0, 1, 7, 6, 3, 2, 16, 8, 19, 13, 15, 12, 14, 17, 18, 9, 11}; mapping = std::vector<int>(map, map + sizeof(map) / sizeof(int)); type = MSH_HEX_20; - } + } else if(eleType == "ElmB27n3D"){ NoVertices = 27; - static int map[27] = {4, 16, 5, 10, 21, 12, 0, 8, 1, 17, 25, 18, 22, + static int map[27] = {4, 16, 5, 10, 21, 12, 0, 8, 1, 17, 25, 18, 22, 26, 23, 9, 20, 11, 7, 19, 6, 15, 24, 14, 3, 13, 2}; mapping = std::vector<int>(map, map + sizeof(map) / sizeof(int)); type = MSH_HEX_27; - } + } else{ return 0; } @@ -3313,7 +3313,7 @@ int GModel::readDIFF(const std::string &name) if(format_read_vertices[format_read_vertices.size()-2] != '*') { format_read_vertices[format_read_vertices.size()-1] = '*'; format_read_vertices += "d %d"; - } + } else format_read_vertices += " %d"; k2 = mapping[k]; @@ -3325,21 +3325,21 @@ int GModel::readDIFF(const std::string &name) indices[j] = ElementsNodes[i - 1][j]; std::vector<MVertex*> vertices; if(vertexVector.size()){ - if(!getVertices(numVerticesPerElement, indices, vertexVector, vertices)) + if(!getVertices(numVerticesPerElement, indices, vertexVector, vertices)) return 0; } else{ - if(!getVertices(numVerticesPerElement, indices, vertexMap, vertices)) + if(!getVertices(numVerticesPerElement, indices, vertexMap, vertices)) return 0; } - createElementMSH(this, num, type, physical, elementary[i-1][1], partition, - vertices, elements, physicals); + createElementMSH(this, num, type, physical, elementary[i-1][1], partition, + vertices, elements, physicals); // trouble if elementary[i-1][0]>1 nodal post-processing needed ? - if(numElements > 100000) + if(numElements > 100000) Msg::ProgressMeter(i + 1, numElements, "Reading elements"); } } - + // store the elements in their associated elementary entity. If the // entity does not exist, create a new (discrete) one. for(int i = 0; i < (int)(sizeof(elements) / sizeof(elements[0])); i++) @@ -3375,7 +3375,7 @@ int GModel::writeDIFF(const std::string &name, bool binary, bool saveAll, Msg::Error("Unable to open file '%s'", name.c_str()); return 0; } - + if(noPhysicalGroups()) saveAll = true; // get the number of vertices and index the vertices in a continuous @@ -3421,7 +3421,7 @@ int GModel::writeDIFF(const std::string &name, bool binary, bool saveAll, if(entities[i]->physicals.size() || saveAll) for(unsigned int j = 0; j < entities[i]->getNumMeshElements(); j++) dim = std::max(dim, entities[i]->getMeshElement(j)->getDim()); - + // loop over all elements we need to save int numElements = 0, maxNumNodesPerElement = 0; for(unsigned int i = 0; i < entities.size(); i++){ @@ -3449,7 +3449,7 @@ int GModel::writeDIFF(const std::string &name, bool binary, bool saveAll, for(std::list<int>::iterator it = boundaryIndicators.begin(); it != boundaryIndicators.end(); it++) fprintf(fp, " %d", *it); - + fprintf(fp, "\n\n\n"); fprintf(fp," Nodal coordinates and nodal boundary indicators,\n"); fprintf(fp," the columns contain:\n"); @@ -3458,7 +3458,7 @@ int GModel::writeDIFF(const std::string &name, bool binary, bool saveAll, fprintf(fp," - no of boundary indicators that are set (ON)\n"); fprintf(fp," - the boundary indicators that are set (ON) if any.\n"); fprintf(fp,"#\n"); - + // write mesh vertices for(unsigned int i = 0; i < entities.size(); i++){ for(unsigned int j = 0; j < entities[i]->mesh_vertices.size(); j++){ @@ -3473,7 +3473,7 @@ int GModel::writeDIFF(const std::string &name, bool binary, bool saveAll, } } } - + fprintf(fp, "\n"); fprintf(fp, "\n"); fprintf(fp, " Element types and connectivity\n"); @@ -3496,7 +3496,7 @@ int GModel::writeDIFF(const std::string &name, bool binary, bool saveAll, } } fprintf(fp, "\n"); - + fclose(fp); return 1; } @@ -3511,7 +3511,7 @@ static void writeElementsINP(FILE *fp, GEntity *ge, std::vector<T*> &elements, int np = (saveAll ? 1 : ge->physicals.size()); for(int p = 0; p < np; p++){ int part = (saveAll ? ge->tag() : ge->physicals[p]); - const char *str = (ge->dim() == 3) ? "VOLUME" : (ge->dim() == 2) ? + const char *str = (ge->dim() == 3) ? "VOLUME" : (ge->dim() == 2) ? "SURFACE" : (ge->dim() == 1) ? "CURVE" : "POINT"; fprintf(fp, "*Element, type=%s, ELSET=%s%d\n", typ, str, part); for(unsigned int i = 0; i < elements.size(); i++) diff --git a/Parser/Gmsh.tab.cpp b/Parser/Gmsh.tab.cpp index fa42fd9f454b474950123159d3e3135ef204fe92..3c9c021b753474be600752b475ba11eeb9103d4e 100644 --- a/Parser/Gmsh.tab.cpp +++ b/Parser/Gmsh.tab.cpp @@ -1,8 +1,9 @@ -/* A Bison parser, made by GNU Bison 2.5. */ +/* A Bison parser, made by GNU Bison 2.4.3. */ -/* Bison implementation for Yacc-like parsers in C +/* Skeleton implementation for Bison's Yacc-like parsers in C - Copyright (C) 1984, 1989-1990, 2000-2011 Free Software Foundation, Inc. + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006, + 2009, 2010 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -44,7 +45,7 @@ #define YYBISON 1 /* Bison version. */ -#define YYBISON_VERSION "2.5" +#define YYBISON_VERSION "2.4.3" /* Skeleton name. */ #define YYSKELETON_NAME "yacc.c" @@ -73,7 +74,7 @@ /* Copy the first part of user declarations. */ -/* Line 268 of yacc.c */ +/* Line 189 of yacc.c */ #line 1 "Gmsh.y" // Gmsh - Copyright (C) 1997-2012 C. Geuzaine, J.-F. Remacle @@ -161,8 +162,8 @@ int PrintListOfDouble(char *format, List_T *list, char *buffer); fullMatrix<double> ListOfListOfDouble2Matrix(List_T *list); -/* Line 268 of yacc.c */ -#line 166 "Gmsh.tab.cpp" +/* Line 189 of yacc.c */ +#line 167 "Gmsh.tab.cpp" /* Enabling traces. */ #ifndef YYDEBUG @@ -333,7 +334,7 @@ fullMatrix<double> ListOfListOfDouble2Matrix(List_T *list); typedef union YYSTYPE { -/* Line 293 of yacc.c */ +/* Line 214 of yacc.c */ #line 87 "Gmsh.y" char *c; @@ -346,8 +347,8 @@ typedef union YYSTYPE -/* Line 293 of yacc.c */ -#line 351 "Gmsh.tab.cpp" +/* Line 214 of yacc.c */ +#line 352 "Gmsh.tab.cpp" } YYSTYPE; # define YYSTYPE_IS_TRIVIAL 1 # define yystype YYSTYPE /* obsolescent; will be withdrawn */ @@ -358,8 +359,8 @@ typedef union YYSTYPE /* Copy the second part of user declarations. */ -/* Line 343 of yacc.c */ -#line 363 "Gmsh.tab.cpp" +/* Line 264 of yacc.c */ +#line 364 "Gmsh.tab.cpp" #ifdef short # undef short @@ -462,11 +463,11 @@ YYID (yyi) # define alloca _alloca # else # define YYSTACK_ALLOC alloca -# if ! defined _ALLOCA_H && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ +# if ! defined _ALLOCA_H && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */ -# ifndef EXIT_SUCCESS -# define EXIT_SUCCESS 0 +# ifndef _STDLIB_H +# define _STDLIB_H 1 # endif # endif # endif @@ -489,24 +490,24 @@ YYID (yyi) # ifndef YYSTACK_ALLOC_MAXIMUM # define YYSTACK_ALLOC_MAXIMUM YYSIZE_MAXIMUM # endif -# if (defined __cplusplus && ! defined EXIT_SUCCESS \ +# if (defined __cplusplus && ! defined _STDLIB_H \ && ! ((defined YYMALLOC || defined malloc) \ && (defined YYFREE || defined free))) # include <stdlib.h> /* INFRINGES ON USER NAME SPACE */ -# ifndef EXIT_SUCCESS -# define EXIT_SUCCESS 0 +# ifndef _STDLIB_H +# define _STDLIB_H 1 # endif # endif # ifndef YYMALLOC # define YYMALLOC malloc -# if ! defined malloc && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ +# if ! defined malloc && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) void *malloc (YYSIZE_T); /* INFRINGES ON USER NAME SPACE */ # endif # endif # ifndef YYFREE # define YYFREE free -# if ! defined free && ! defined EXIT_SUCCESS && (defined __STDC__ || defined __C99__FUNC__ \ +# if ! defined free && ! defined _STDLIB_H && (defined __STDC__ || defined __C99__FUNC__ \ || defined __cplusplus || defined _MSC_VER) void free (void *); /* INFRINGES ON USER NAME SPACE */ # endif @@ -535,7 +536,23 @@ union yyalloc ((N) * (sizeof (yytype_int16) + sizeof (YYSTYPE)) \ + YYSTACK_GAP_MAXIMUM) -# define YYCOPY_NEEDED 1 +/* Copy COUNT objects from FROM to TO. The source and destination do + not overlap. */ +# ifndef YYCOPY +# if defined __GNUC__ && 1 < __GNUC__ +# define YYCOPY(To, From, Count) \ + __builtin_memcpy (To, From, (Count) * sizeof (*(From))) +# else +# define YYCOPY(To, From, Count) \ + do \ + { \ + YYSIZE_T yyi; \ + for (yyi = 0; yyi < (Count); yyi++) \ + (To)[yyi] = (From)[yyi]; \ + } \ + while (YYID (0)) +# endif +# endif /* Relocate STACK from its old location to the new one. The local variables YYSIZE and YYSTACKSIZE give the old and new number of @@ -555,26 +572,6 @@ union yyalloc #endif -#if defined YYCOPY_NEEDED && YYCOPY_NEEDED -/* Copy COUNT objects from FROM to TO. The source and destination do - not overlap. */ -# ifndef YYCOPY -# if defined __GNUC__ && 1 < __GNUC__ -# define YYCOPY(To, From, Count) \ - __builtin_memcpy (To, From, (Count) * sizeof (*(From))) -# else -# define YYCOPY(To, From, Count) \ - do \ - { \ - YYSIZE_T yyi; \ - for (yyi = 0; yyi < (Count); yyi++) \ - (To)[yyi] = (From)[yyi]; \ - } \ - while (YYID (0)) -# endif -# endif -#endif /* !YYCOPY_NEEDED */ - /* YYFINAL -- State number of the termination state. */ #define YYFINAL 5 /* YYLAST -- Last index in YYTABLE. */ @@ -949,31 +946,31 @@ static const yytype_uint16 yyrline[] = 1773, 1778, 1783, 1788, 1793, 1816, 1822, 1833, 1834, 1839, 1842, 1846, 1869, 1892, 1915, 1943, 1964, 1987, 2008, 2030, 2050, 2162, 2181, 2219, 2328, 2337, 2343, 2358, 2386, 2403, - 2417, 2423, 2429, 2438, 2452, 2495, 2512, 2527, 2546, 2558, - 2582, 2586, 2593, 2599, 2604, 2610, 2614, 2618, 2628, 2645, - 2662, 2683, 2704, 2739, 2747, 2753, 2760, 2764, 2773, 2781, - 2789, 2798, 2797, 2811, 2810, 2824, 2823, 2837, 2836, 2849, - 2856, 2863, 2870, 2877, 2884, 2891, 2898, 2905, 2913, 2912, - 2925, 2924, 2937, 2936, 2949, 2948, 2961, 2960, 2973, 2972, - 2985, 2984, 2997, 2996, 3009, 3008, 3024, 3027, 3033, 3042, - 3062, 3085, 3089, 3093, 3097, 3101, 3105, 3124, 3137, 3140, - 3156, 3159, 3172, 3175, 3181, 3184, 3191, 3247, 3317, 3322, - 3389, 3425, 3468, 3493, 3520, 3564, 3587, 3610, 3613, 3622, - 3626, 3636, 3671, 3672, 3676, 3681, 3692, 3714, 3715, 3716, - 3717, 3718, 3719, 3720, 3721, 3722, 3729, 3730, 3731, 3732, - 3733, 3734, 3735, 3736, 3737, 3738, 3739, 3740, 3741, 3742, - 3743, 3744, 3745, 3746, 3747, 3748, 3749, 3750, 3751, 3752, - 3753, 3754, 3755, 3756, 3757, 3758, 3759, 3760, 3762, 3763, - 3764, 3765, 3766, 3767, 3768, 3769, 3770, 3771, 3772, 3773, - 3774, 3775, 3776, 3777, 3778, 3779, 3780, 3781, 3782, 3791, - 3792, 3793, 3794, 3795, 3796, 3797, 3801, 3821, 3840, 3858, - 3870, 3887, 3908, 3913, 3918, 3928, 3938, 3946, 3950, 3954, - 3958, 3962, 3969, 3973, 3977, 3981, 3988, 3993, 4000, 4005, - 4009, 4014, 4018, 4026, 4037, 4041, 4053, 4061, 4069, 4076, - 4087, 4107, 4111, 4115, 4119, 4123, 4133, 4143, 4155, 4167, - 4188, 4193, 4197, 4201, 4213, 4217, 4229, 4236, 4246, 4250, - 4265, 4270, 4277, 4281, 4294, 4302, 4313, 4317, 4325, 4333, - 4341, 4349, 4363, 4377, 4381 + 2417, 2423, 2429, 2438, 2452, 2497, 2514, 2529, 2548, 2560, + 2584, 2588, 2595, 2601, 2606, 2612, 2616, 2620, 2630, 2647, + 2664, 2685, 2706, 2741, 2749, 2755, 2762, 2766, 2775, 2783, + 2791, 2800, 2799, 2813, 2812, 2826, 2825, 2839, 2838, 2851, + 2858, 2865, 2872, 2879, 2886, 2893, 2900, 2907, 2915, 2914, + 2927, 2926, 2939, 2938, 2951, 2950, 2963, 2962, 2975, 2974, + 2987, 2986, 2999, 2998, 3011, 3010, 3026, 3029, 3035, 3044, + 3064, 3087, 3091, 3095, 3099, 3103, 3107, 3126, 3139, 3142, + 3158, 3161, 3174, 3177, 3183, 3186, 3193, 3249, 3319, 3324, + 3391, 3427, 3470, 3495, 3522, 3566, 3589, 3612, 3615, 3624, + 3628, 3638, 3673, 3674, 3678, 3683, 3694, 3716, 3717, 3718, + 3719, 3720, 3721, 3722, 3723, 3724, 3731, 3732, 3733, 3734, + 3735, 3736, 3737, 3738, 3739, 3740, 3741, 3742, 3743, 3744, + 3745, 3746, 3747, 3748, 3749, 3750, 3751, 3752, 3753, 3754, + 3755, 3756, 3757, 3758, 3759, 3760, 3761, 3762, 3764, 3765, + 3766, 3767, 3768, 3769, 3770, 3771, 3772, 3773, 3774, 3775, + 3776, 3777, 3778, 3779, 3780, 3781, 3782, 3783, 3784, 3793, + 3794, 3795, 3796, 3797, 3798, 3799, 3803, 3823, 3842, 3860, + 3872, 3889, 3910, 3915, 3920, 3930, 3940, 3948, 3952, 3956, + 3960, 3964, 3971, 3975, 3979, 3983, 3990, 3995, 4002, 4007, + 4011, 4016, 4020, 4028, 4039, 4043, 4055, 4063, 4071, 4078, + 4089, 4109, 4113, 4117, 4121, 4125, 4135, 4145, 4157, 4169, + 4190, 4195, 4199, 4203, 4215, 4219, 4231, 4238, 4248, 4252, + 4267, 4272, 4279, 4283, 4296, 4304, 4315, 4319, 4327, 4335, + 4343, 4351, 4365, 4379, 4383 }; #endif @@ -1147,8 +1144,8 @@ static const yytype_uint8 yyr2[] = 6, 4, 4, 4, 6 }; -/* YYDEFACT[STATE-NAME] -- Default reduction number in state STATE-NUM. - Performed when YYTABLE doesn't specify something else to do. Zero +/* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state + STATE-NUM when YYTABLE doesn't specify something else to do. Zero means the default is an error. */ static const yytype_uint16 yydefact[] = { @@ -1477,7 +1474,8 @@ static const yytype_int16 yypgoto[] = /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If positive, shift that token. If negative, reduce the rule which - number is the opposite. If YYTABLE_NINF, syntax error. */ + number is the opposite. If zero, do what YYDEFACT says. + If YYTABLE_NINF, syntax error. */ #define YYTABLE_NINF -5 static const yytype_int16 yytable[] = { @@ -2243,12 +2241,6 @@ static const yytype_int16 yytable[] = 348, 0, 0, 0, 0, 349 }; -#define yypact_value_is_default(yystate) \ - ((yystate) == (-1059)) - -#define yytable_value_is_error(yytable_value) \ - YYID (0) - static const yytype_int16 yycheck[] = { 6, 399, 400, 205, 6, 1063, 3, 5, 321, 70, @@ -3195,6 +3187,7 @@ do \ { \ yychar = (Token); \ yylval = (Value); \ + yytoken = YYTRANSLATE (yychar); \ YYPOPSTACK (1); \ goto yybackup; \ } \ @@ -3236,10 +3229,19 @@ while (YYID (0)) #endif -/* This macro is provided for backward compatibility. */ +/* YY_LOCATION_PRINT -- Print the location on the stream. + This macro was not mandated originally: define only if we know + we won't break user code: when these are the locations we know. */ #ifndef YY_LOCATION_PRINT -# define YY_LOCATION_PRINT(File, Loc) ((void) 0) +# if defined YYLTYPE_IS_TRIVIAL && YYLTYPE_IS_TRIVIAL +# define YY_LOCATION_PRINT(File, Loc) \ + fprintf (File, "%d.%d-%d.%d", \ + (Loc).first_line, (Loc).first_column, \ + (Loc).last_line, (Loc).last_column) +# else +# define YY_LOCATION_PRINT(File, Loc) ((void) 0) +# endif #endif @@ -3431,6 +3433,7 @@ int yydebug; # define YYMAXDEPTH 10000 #endif + #if YYERROR_VERBOSE @@ -3533,142 +3536,115 @@ yytnamerr (char *yyres, const char *yystr) } # endif -/* Copy into *YYMSG, which is of size *YYMSG_ALLOC, an error message - about the unexpected token YYTOKEN for the state stack whose top is - YYSSP. - - Return 0 if *YYMSG was successfully written. Return 1 if *YYMSG is - not large enough to hold the message. In that case, also set - *YYMSG_ALLOC to the required number of bytes. Return 2 if the - required number of bytes is too large to store. */ -static int -yysyntax_error (YYSIZE_T *yymsg_alloc, char **yymsg, - yytype_int16 *yyssp, int yytoken) +/* Copy into YYRESULT an error message about the unexpected token + YYCHAR while in state YYSTATE. Return the number of bytes copied, + including the terminating null byte. If YYRESULT is null, do not + copy anything; just return the number of bytes that would be + copied. As a special case, return 0 if an ordinary "syntax error" + message will do. Return YYSIZE_MAXIMUM if overflow occurs during + size calculation. */ +static YYSIZE_T +yysyntax_error (char *yyresult, int yystate, int yychar) { - YYSIZE_T yysize0 = yytnamerr (0, yytname[yytoken]); - YYSIZE_T yysize = yysize0; - YYSIZE_T yysize1; - enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; - /* Internationalized format string. */ - const char *yyformat = 0; - /* Arguments of yyformat. */ - char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; - /* Number of reported tokens (one for the "unexpected", one per - "expected"). */ - int yycount = 0; - - /* There are many possibilities here to consider: - - Assume YYFAIL is not used. It's too flawed to consider. See - <http://lists.gnu.org/archive/html/bison-patches/2009-12/msg00024.html> - for details. YYERROR is fine as it does not invoke this - function. - - If this state is a consistent state with a default action, then - the only way this function was invoked is if the default action - is an error action. In that case, don't check for expected - tokens because there are none. - - The only way there can be no lookahead present (in yychar) is if - this state is a consistent state with a default action. Thus, - detecting the absence of a lookahead is sufficient to determine - that there is no unexpected or expected token to report. In that - case, just report a simple "syntax error". - - Don't assume there isn't a lookahead just because this state is a - consistent state with a default action. There might have been a - previous inconsistent state, consistent state with a non-default - action, or user semantic action that manipulated yychar. - - Of course, the expected token list depends on states to have - correct lookahead information, and it depends on the parser not - to perform extra reductions after fetching a lookahead from the - scanner and before detecting a syntax error. Thus, state merging - (from LALR or IELR) and default reductions corrupt the expected - token list. However, the list is correct for canonical LR with - one exception: it will still contain any token that will not be - accepted due to an error action in a later state. - */ - if (yytoken != YYEMPTY) - { - int yyn = yypact[*yyssp]; - yyarg[yycount++] = yytname[yytoken]; - if (!yypact_value_is_default (yyn)) - { - /* Start YYX at -YYN if negative to avoid negative indexes in - YYCHECK. In other words, skip the first -YYN actions for - this state because they are default actions. */ - int yyxbegin = yyn < 0 ? -yyn : 0; - /* Stay within bounds of both yycheck and yytname. */ - int yychecklim = YYLAST - yyn + 1; - int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; - int yyx; - - for (yyx = yyxbegin; yyx < yyxend; ++yyx) - if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR - && !yytable_value_is_error (yytable[yyx + yyn])) - { - if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) - { - yycount = 1; - yysize = yysize0; - break; - } - yyarg[yycount++] = yytname[yyx]; - yysize1 = yysize + yytnamerr (0, yytname[yyx]); - if (! (yysize <= yysize1 - && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) - return 2; - yysize = yysize1; - } - } - } + int yyn = yypact[yystate]; - switch (yycount) - { -# define YYCASE_(N, S) \ - case N: \ - yyformat = S; \ - break - YYCASE_(0, YY_("syntax error")); - YYCASE_(1, YY_("syntax error, unexpected %s")); - YYCASE_(2, YY_("syntax error, unexpected %s, expecting %s")); - YYCASE_(3, YY_("syntax error, unexpected %s, expecting %s or %s")); - YYCASE_(4, YY_("syntax error, unexpected %s, expecting %s or %s or %s")); - YYCASE_(5, YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s")); -# undef YYCASE_ - } + if (! (YYPACT_NINF < yyn && yyn <= YYLAST)) + return 0; + else + { + int yytype = YYTRANSLATE (yychar); + YYSIZE_T yysize0 = yytnamerr (0, yytname[yytype]); + YYSIZE_T yysize = yysize0; + YYSIZE_T yysize1; + int yysize_overflow = 0; + enum { YYERROR_VERBOSE_ARGS_MAXIMUM = 5 }; + char const *yyarg[YYERROR_VERBOSE_ARGS_MAXIMUM]; + int yyx; + +# if 0 + /* This is so xgettext sees the translatable formats that are + constructed on the fly. */ + YY_("syntax error, unexpected %s"); + YY_("syntax error, unexpected %s, expecting %s"); + YY_("syntax error, unexpected %s, expecting %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s"); + YY_("syntax error, unexpected %s, expecting %s or %s or %s or %s"); +# endif + char *yyfmt; + char const *yyf; + static char const yyunexpected[] = "syntax error, unexpected %s"; + static char const yyexpecting[] = ", expecting %s"; + static char const yyor[] = " or %s"; + char yyformat[sizeof yyunexpected + + sizeof yyexpecting - 1 + + ((YYERROR_VERBOSE_ARGS_MAXIMUM - 2) + * (sizeof yyor - 1))]; + char const *yyprefix = yyexpecting; + + /* Start YYX at -YYN if negative to avoid negative indexes in + YYCHECK. */ + int yyxbegin = yyn < 0 ? -yyn : 0; + + /* Stay within bounds of both yycheck and yytname. */ + int yychecklim = YYLAST - yyn + 1; + int yyxend = yychecklim < YYNTOKENS ? yychecklim : YYNTOKENS; + int yycount = 1; + + yyarg[0] = yytname[yytype]; + yyfmt = yystpcpy (yyformat, yyunexpected); + + for (yyx = yyxbegin; yyx < yyxend; ++yyx) + if (yycheck[yyx + yyn] == yyx && yyx != YYTERROR) + { + if (yycount == YYERROR_VERBOSE_ARGS_MAXIMUM) + { + yycount = 1; + yysize = yysize0; + yyformat[sizeof yyunexpected - 1] = '\0'; + break; + } + yyarg[yycount++] = yytname[yyx]; + yysize1 = yysize + yytnamerr (0, yytname[yyx]); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; + yyfmt = yystpcpy (yyfmt, yyprefix); + yyprefix = yyor; + } - yysize1 = yysize + yystrlen (yyformat); - if (! (yysize <= yysize1 && yysize1 <= YYSTACK_ALLOC_MAXIMUM)) - return 2; - yysize = yysize1; + yyf = YY_(yyformat); + yysize1 = yysize + yystrlen (yyf); + yysize_overflow |= (yysize1 < yysize); + yysize = yysize1; - if (*yymsg_alloc < yysize) - { - *yymsg_alloc = 2 * yysize; - if (! (yysize <= *yymsg_alloc - && *yymsg_alloc <= YYSTACK_ALLOC_MAXIMUM)) - *yymsg_alloc = YYSTACK_ALLOC_MAXIMUM; - return 1; - } + if (yysize_overflow) + return YYSIZE_MAXIMUM; - /* Avoid sprintf, as that infringes on the user's name space. - Don't have undefined behavior even if the translation - produced a string with the wrong number of "%s"s. */ - { - char *yyp = *yymsg; - int yyi = 0; - while ((*yyp = *yyformat) != '\0') - if (*yyp == '%' && yyformat[1] == 's' && yyi < yycount) - { - yyp += yytnamerr (yyp, yyarg[yyi++]); - yyformat += 2; - } - else - { - yyp++; - yyformat++; - } - } - return 0; + if (yyresult) + { + /* Avoid sprintf, as that infringes on the user's name space. + Don't have undefined behavior even if the translation + produced a string with the wrong number of "%s"s. */ + char *yyp = yyresult; + int yyi = 0; + while ((*yyp = *yyf) != '\0') + { + if (*yyp == '%' && yyf[1] == 's' && yyi < yycount) + { + yyp += yytnamerr (yyp, yyarg[yyi++]); + yyf += 2; + } + else + { + yyp++; + yyf++; + } + } + } + return yysize; + } } #endif /* YYERROR_VERBOSE */ + /*-----------------------------------------------. | Release the memory associated to this symbol. | @@ -3701,7 +3677,6 @@ yydestruct (yymsg, yytype, yyvaluep) } } - /* Prevent warnings from -Wmissing-prototypes. */ #ifdef YYPARSE_PARAM #if defined __STDC__ || defined __cplusplus @@ -3728,9 +3703,10 @@ YYSTYPE yylval; int yynerrs; -/*----------. -| yyparse. | -`----------*/ + +/*-------------------------. +| yyparse or yypush_parse. | +`-------------------------*/ #ifdef YYPARSE_PARAM #if (defined __STDC__ || defined __C99__FUNC__ \ @@ -3754,6 +3730,8 @@ yyparse () #endif #endif { + + int yystate; /* Number of tokens to shift before error messages enabled. */ int yyerrstatus; @@ -3908,7 +3886,7 @@ yybackup: /* First try to decide what to do without reference to lookahead token. */ yyn = yypact[yystate]; - if (yypact_value_is_default (yyn)) + if (yyn == YYPACT_NINF) goto yydefault; /* Not known => get a lookahead token if don't already have one. */ @@ -3939,8 +3917,8 @@ yybackup: yyn = yytable[yyn]; if (yyn <= 0) { - if (yytable_value_is_error (yyn)) - goto yyerrlab; + if (yyn == 0 || yyn == YYTABLE_NINF) + goto yyerrlab; yyn = -yyn; goto yyreduce; } @@ -3995,161 +3973,161 @@ yyreduce: { case 3: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 159 "Gmsh.y" - { yyerrok; return 1; } + { yyerrok; return 1; ;} break; case 6: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 170 "Gmsh.y" - { return 1; } + { return 1; ;} break; case 7: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 171 "Gmsh.y" - { return 1; } + { return 1; ;} break; case 8: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 172 "Gmsh.y" - { return 1; } + { return 1; ;} break; case 9: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 173 "Gmsh.y" - { return 1; } + { return 1; ;} break; case 10: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 174 "Gmsh.y" - { List_Delete((yyvsp[(1) - (1)].l)); return 1; } + { List_Delete((yyvsp[(1) - (1)].l)); return 1; ;} break; case 11: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 175 "Gmsh.y" - { return 1; } + { return 1; ;} break; case 12: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 176 "Gmsh.y" - { return 1; } + { return 1; ;} break; case 13: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 177 "Gmsh.y" - { return 1; } + { return 1; ;} break; case 14: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 178 "Gmsh.y" - { List_Delete((yyvsp[(1) - (1)].l)); return 1; } + { List_Delete((yyvsp[(1) - (1)].l)); return 1; ;} break; case 15: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 179 "Gmsh.y" - { return 1; } + { return 1; ;} break; case 16: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 180 "Gmsh.y" - { return 1; } + { return 1; ;} break; case 17: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 181 "Gmsh.y" - { return 1; } + { return 1; ;} break; case 18: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 182 "Gmsh.y" - { return 1; } + { return 1; ;} break; case 19: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 183 "Gmsh.y" - { return 1; } + { return 1; ;} break; case 20: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 184 "Gmsh.y" - { return 1; } + { return 1; ;} break; case 21: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 185 "Gmsh.y" - { return 1; } + { return 1; ;} break; case 22: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 186 "Gmsh.y" - { return 1; } + { return 1; ;} break; case 23: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 191 "Gmsh.y" { (yyval.c) = (char*)"w"; - } + ;} break; case 24: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 195 "Gmsh.y" { (yyval.c) = (char*)"a"; - } + ;} break; case 25: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 202 "Gmsh.y" { Msg::Direct((yyvsp[(3) - (5)].c)); Free((yyvsp[(3) - (5)].c)); - } + ;} break; case 26: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 207 "Gmsh.y" { std::string tmp = FixRelativePath(gmsh_yyname, (yyvsp[(6) - (7)].c)); @@ -4163,12 +4141,12 @@ yyreduce: } Free((yyvsp[(3) - (7)].c)); Free((yyvsp[(6) - (7)].c)); - } + ;} break; case 27: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 221 "Gmsh.y" { char tmpstring[1024]; @@ -4181,12 +4159,12 @@ yyreduce: Msg::Direct(tmpstring); Free((yyvsp[(3) - (7)].c)); List_Delete((yyvsp[(5) - (7)].l)); - } + ;} break; case 28: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 234 "Gmsh.y" { char tmpstring[1024]; @@ -4209,12 +4187,12 @@ yyreduce: Free((yyvsp[(3) - (9)].c)); Free((yyvsp[(8) - (9)].c)); List_Delete((yyvsp[(5) - (9)].l)); - } + ;} break; case 29: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 262 "Gmsh.y" { #if defined(HAVE_POST) @@ -4228,12 +4206,12 @@ yyreduce: delete ViewData; #endif Free((yyvsp[(1) - (6)].c)); Free((yyvsp[(2) - (6)].c)); - } + ;} break; case 30: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 276 "Gmsh.y" { #if defined(HAVE_POST) @@ -4244,12 +4222,12 @@ yyreduce: } #endif Free((yyvsp[(2) - (6)].c)); - } + ;} break; case 31: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 287 "Gmsh.y" { #if defined(HAVE_POST) @@ -4260,51 +4238,51 @@ yyreduce: } #endif Free((yyvsp[(2) - (6)].c)); - } + ;} break; case 32: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 301 "Gmsh.y" { #if defined(HAVE_POST) ViewData = new PViewDataList(); #endif - } + ;} break; case 38: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 315 "Gmsh.y" - { ViewCoord.push_back((yyvsp[(1) - (1)].d)); } + { ViewCoord.push_back((yyvsp[(1) - (1)].d)); ;} break; case 39: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 317 "Gmsh.y" - { ViewCoord.push_back((yyvsp[(3) - (3)].d)); } + { ViewCoord.push_back((yyvsp[(3) - (3)].d)); ;} break; case 40: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 322 "Gmsh.y" - { if(ViewValueList) ViewValueList->push_back((yyvsp[(1) - (1)].d)); } + { if(ViewValueList) ViewValueList->push_back((yyvsp[(1) - (1)].d)); ;} break; case 41: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 324 "Gmsh.y" - { if(ViewValueList) ViewValueList->push_back((yyvsp[(3) - (3)].d)); } + { if(ViewValueList) ViewValueList->push_back((yyvsp[(3) - (3)].d)); ;} break; case 42: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 329 "Gmsh.y" { #if defined(HAVE_POST) @@ -4408,12 +4386,12 @@ yyreduce: #endif ViewCoord.clear(); Free((yyvsp[(1) - (1)].c)); - } + ;} break; case 43: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 433 "Gmsh.y" { #if defined(HAVE_POST) @@ -4423,47 +4401,47 @@ yyreduce: ViewValueList->push_back(ViewCoord[3 * j + i]); } #endif - } + ;} break; case 44: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 443 "Gmsh.y" { #if defined(HAVE_POST) if(ViewValueList) (*ViewNumList)++; #endif - } + ;} break; case 45: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 452 "Gmsh.y" { #if defined(HAVE_POST) for(int i = 0; i < (int)strlen((yyvsp[(1) - (1)].c)) + 1; i++) ViewData->T2C.push_back((yyvsp[(1) - (1)].c)[i]); #endif Free((yyvsp[(1) - (1)].c)); - } + ;} break; case 46: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 459 "Gmsh.y" { #if defined(HAVE_POST) for(int i = 0; i < (int)strlen((yyvsp[(3) - (3)].c)) + 1; i++) ViewData->T2C.push_back((yyvsp[(3) - (3)].c)[i]); #endif Free((yyvsp[(3) - (3)].c)); - } + ;} break; case 47: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 469 "Gmsh.y" { #if defined(HAVE_POST) @@ -4472,47 +4450,47 @@ yyreduce: ViewData->T2D.push_back((yyvsp[(7) - (8)].d)); ViewData->T2D.push_back(ViewData->T2C.size()); #endif - } + ;} break; case 48: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 478 "Gmsh.y" { #if defined(HAVE_POST) ViewData->NbT2++; #endif - } + ;} break; case 49: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 487 "Gmsh.y" { #if defined(HAVE_POST) for(int i = 0; i < (int)strlen((yyvsp[(1) - (1)].c)) + 1; i++) ViewData->T3C.push_back((yyvsp[(1) - (1)].c)[i]); #endif Free((yyvsp[(1) - (1)].c)); - } + ;} break; case 50: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 494 "Gmsh.y" { #if defined(HAVE_POST) for(int i = 0; i < (int)strlen((yyvsp[(3) - (3)].c)) + 1; i++) ViewData->T3C.push_back((yyvsp[(3) - (3)].c)[i]); #endif Free((yyvsp[(3) - (3)].c)); - } + ;} break; case 51: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 504 "Gmsh.y" { #if defined(HAVE_POST) @@ -4520,23 +4498,23 @@ yyreduce: ViewData->T3D.push_back((yyvsp[(7) - (10)].d)); ViewData->T3D.push_back((yyvsp[(9) - (10)].d)); ViewData->T3D.push_back(ViewData->T3C.size()); #endif - } + ;} break; case 52: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 512 "Gmsh.y" { #if defined(HAVE_POST) ViewData->NbT3++; #endif - } + ;} break; case 53: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 522 "Gmsh.y" { #if defined(HAVE_POST) @@ -4552,12 +4530,12 @@ yyreduce: ViewData->setInterpolationMatrices(type, ListOfListOfDouble2Matrix((yyvsp[(3) - (8)].l)), ListOfListOfDouble2Matrix((yyvsp[(6) - (8)].l))); #endif - } + ;} break; case 54: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 541 "Gmsh.y" { #if defined(HAVE_POST) @@ -4573,80 +4551,80 @@ yyreduce: ListOfListOfDouble2Matrix((yyvsp[(9) - (14)].l)), ListOfListOfDouble2Matrix((yyvsp[(12) - (14)].l))); #endif - } + ;} break; case 55: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 560 "Gmsh.y" { #if defined(HAVE_POST) ViewValueList = &ViewData->Time; #endif - } + ;} break; case 56: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 566 "Gmsh.y" { - } + ;} break; case 57: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 573 "Gmsh.y" - { (yyval.i) = 0; } + { (yyval.i) = 0; ;} break; case 58: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 574 "Gmsh.y" - { (yyval.i) = 1; } + { (yyval.i) = 1; ;} break; case 59: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 575 "Gmsh.y" - { (yyval.i) = 2; } + { (yyval.i) = 2; ;} break; case 60: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 576 "Gmsh.y" - { (yyval.i) = 3; } + { (yyval.i) = 3; ;} break; case 61: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 577 "Gmsh.y" - { (yyval.i) = 4; } + { (yyval.i) = 4; ;} break; case 62: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 581 "Gmsh.y" - { (yyval.i) = 1; } + { (yyval.i) = 1; ;} break; case 63: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 582 "Gmsh.y" - { (yyval.i) = -1; } + { (yyval.i) = -1; ;} break; case 65: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 591 "Gmsh.y" { if(!gmsh_yysymbols.count((yyvsp[(1) - (4)].c)) && (yyvsp[(2) - (4)].i) && List_Nbr((yyvsp[(3) - (4)].l)) == 1){ @@ -4706,12 +4684,12 @@ yyreduce: } Free((yyvsp[(1) - (4)].c)); List_Delete((yyvsp[(3) - (4)].l)); - } + ;} break; case 66: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 654 "Gmsh.y" { gmsh_yysymbol &s(gmsh_yysymbols[(yyvsp[(1) - (6)].c)]); @@ -4740,12 +4718,12 @@ yyreduce: } Free((yyvsp[(1) - (6)].c)); List_Delete((yyvsp[(5) - (6)].l)); - } + ;} break; case 67: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 684 "Gmsh.y" { int index = (int)(yyvsp[(3) - (7)].d); @@ -4778,12 +4756,12 @@ yyreduce: yymsg(0, "Variable '%s' is not a list", (yyvsp[(1) - (7)].c)); } Free((yyvsp[(1) - (7)].c)); - } + ;} break; case 68: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 717 "Gmsh.y" { if(List_Nbr((yyvsp[(4) - (9)].l)) != List_Nbr((yyvsp[(8) - (9)].l))){ @@ -4829,12 +4807,12 @@ yyreduce: Free((yyvsp[(1) - (9)].c)); List_Delete((yyvsp[(4) - (9)].l)); List_Delete((yyvsp[(8) - (9)].l)); - } + ;} break; case 69: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 763 "Gmsh.y" { if(!gmsh_yysymbols.count((yyvsp[(1) - (3)].c))) @@ -4849,12 +4827,12 @@ yyreduce: yymsg(0, "Variable '%s' is a list", (yyvsp[(1) - (3)].c)); } Free((yyvsp[(1) - (3)].c)); - } + ;} break; case 70: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 778 "Gmsh.y" { if(!gmsh_yysymbols.count((yyvsp[(1) - (6)].c))) @@ -4870,23 +4848,23 @@ yyreduce: yymsg(0, "Variable '%s' is not a list", (yyvsp[(1) - (6)].c)); } Free((yyvsp[(1) - (6)].c)); - } + ;} break; case 71: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 794 "Gmsh.y" { gmsh_yystringsymbols[(yyvsp[(1) - (4)].c)] = std::string((yyvsp[(3) - (4)].c)); Free((yyvsp[(1) - (4)].c)); Free((yyvsp[(3) - (4)].c)); - } + ;} break; case 72: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 803 "Gmsh.y" { std::string tmp((yyvsp[(5) - (6)].c)); @@ -4897,7 +4875,7 @@ yyreduce: case 73: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 809 "Gmsh.y" { std::string tmp((yyvsp[(8) - (9)].c)); @@ -4908,7 +4886,7 @@ yyreduce: case 74: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 818 "Gmsh.y" { double d = 0.; @@ -4926,12 +4904,12 @@ yyreduce: NumberOption(GMSH_SET|GMSH_GUI, (yyvsp[(1) - (6)].c), 0, (yyvsp[(3) - (6)].c), d); } Free((yyvsp[(1) - (6)].c)); Free((yyvsp[(3) - (6)].c)); - } + ;} break; case 75: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 836 "Gmsh.y" { double d = 0.; @@ -4949,12 +4927,12 @@ yyreduce: NumberOption(GMSH_SET|GMSH_GUI, (yyvsp[(1) - (9)].c), (int)(yyvsp[(3) - (9)].d), (yyvsp[(6) - (9)].c), d); } Free((yyvsp[(1) - (9)].c)); Free((yyvsp[(6) - (9)].c)); - } + ;} break; case 76: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 854 "Gmsh.y" { double d = 0.; @@ -4963,12 +4941,12 @@ yyreduce: NumberOption(GMSH_SET|GMSH_GUI, (yyvsp[(1) - (5)].c), 0, (yyvsp[(3) - (5)].c), d); } Free((yyvsp[(1) - (5)].c)); Free((yyvsp[(3) - (5)].c)); - } + ;} break; case 77: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 863 "Gmsh.y" { double d = 0.; @@ -4977,32 +4955,32 @@ yyreduce: NumberOption(GMSH_SET|GMSH_GUI, (yyvsp[(1) - (8)].c), (int)(yyvsp[(3) - (8)].d), (yyvsp[(6) - (8)].c), d); } Free((yyvsp[(1) - (8)].c)); Free((yyvsp[(6) - (8)].c)); - } + ;} break; case 78: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 875 "Gmsh.y" { ColorOption(GMSH_SET|GMSH_GUI, (yyvsp[(1) - (8)].c), 0, (yyvsp[(5) - (8)].c), (yyvsp[(7) - (8)].u)); Free((yyvsp[(1) - (8)].c)); Free((yyvsp[(5) - (8)].c)); - } + ;} break; case 79: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 880 "Gmsh.y" { ColorOption(GMSH_SET|GMSH_GUI, (yyvsp[(1) - (11)].c), (int)(yyvsp[(3) - (11)].d), (yyvsp[(8) - (11)].c), (yyvsp[(10) - (11)].u)); Free((yyvsp[(1) - (11)].c)); Free((yyvsp[(8) - (11)].c)); - } + ;} break; case 80: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 888 "Gmsh.y" { GmshColorTable *ct = GetColorTable(0); @@ -5022,12 +5000,12 @@ yyreduce: } Free((yyvsp[(1) - (6)].c)); List_Delete((yyvsp[(5) - (6)].l)); - } + ;} break; case 81: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 908 "Gmsh.y" { GmshColorTable *ct = GetColorTable((int)(yyvsp[(3) - (9)].d)); @@ -5047,12 +5025,12 @@ yyreduce: } Free((yyvsp[(1) - (9)].c)); List_Delete((yyvsp[(8) - (9)].l)); - } + ;} break; case 82: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 931 "Gmsh.y" { #if defined(HAVE_MESH) @@ -5063,12 +5041,12 @@ yyreduce: else yymsg(0, "Unknown command %s Field", (yyvsp[(1) - (5)].c)); #endif - } + ;} break; case 83: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 942 "Gmsh.y" { #if defined(HAVE_MESH) @@ -5076,12 +5054,12 @@ yyreduce: yymsg(0, "Cannot create field %i of type '%s'", (int)(yyvsp[(3) - (7)].d), (yyvsp[(6) - (7)].c)); #endif Free((yyvsp[(6) - (7)].c)); - } + ;} break; case 84: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 950 "Gmsh.y" { #if defined(HAVE_MESH) @@ -5103,12 +5081,12 @@ yyreduce: yymsg(0, "No field with id %i", (int)(yyvsp[(3) - (9)].d)); #endif Free((yyvsp[(6) - (9)].c)); - } + ;} break; case 85: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 972 "Gmsh.y" { #if defined(HAVE_MESH) @@ -5131,12 +5109,12 @@ yyreduce: #endif Free((yyvsp[(6) - (9)].c)); Free((yyvsp[(8) - (9)].c)); - } + ;} break; case 86: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 995 "Gmsh.y" { #if defined(HAVE_MESH) @@ -5161,12 +5139,12 @@ yyreduce: #endif Free((yyvsp[(6) - (11)].c)); List_Delete((yyvsp[(9) - (11)].l)); - } + ;} break; case 87: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1020 "Gmsh.y" { #if defined(HAVE_MESH) @@ -5184,12 +5162,12 @@ yyreduce: yymsg(0, "No field with id %i", (int)(yyvsp[(3) - (7)].d)); #endif Free((yyvsp[(6) - (7)].c)); - } + ;} break; case 88: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1041 "Gmsh.y" { #if defined(HAVE_PLUGINS) @@ -5201,12 +5179,12 @@ yyreduce: } #endif Free((yyvsp[(3) - (9)].c)); Free((yyvsp[(6) - (9)].c)); - } + ;} break; case 89: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1053 "Gmsh.y" { #if defined(HAVE_PLUGINS) @@ -5218,12 +5196,12 @@ yyreduce: } #endif Free((yyvsp[(3) - (9)].c)); Free((yyvsp[(6) - (9)].c)); Free((yyvsp[(8) - (9)].c)); - } + ;} break; case 93: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1071 "Gmsh.y" { std::string key((yyvsp[(3) - (3)].c)); @@ -5234,12 +5212,12 @@ yyreduce: gmsh_yysymbols[key].value = val; } Free((yyvsp[(3) - (3)].c)); - } + ;} break; case 94: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1082 "Gmsh.y" { std::string key((yyvsp[(3) - (5)].c)); @@ -5250,19 +5228,19 @@ yyreduce: gmsh_yysymbols[key].value = val; } Free((yyvsp[(3) - (5)].c)); - } + ;} break; case 95: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1093 "Gmsh.y" - { floatOptions.clear(); charOptions.clear(); } + { floatOptions.clear(); charOptions.clear(); ;} break; case 96: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1095 "Gmsh.y" { std::string key((yyvsp[(3) - (9)].c)); @@ -5271,12 +5249,12 @@ yyreduce: Msg::ExchangeOnelabParameter(key, val, floatOptions, charOptions); gmsh_yysymbols[key].value = val; } - } + ;} break; case 99: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1111 "Gmsh.y" { std::string key((yyvsp[(2) - (3)].c)); @@ -5287,12 +5265,12 @@ yyreduce: } Free((yyvsp[(2) - (3)].c)); List_Delete((yyvsp[(3) - (3)].l)); - } + ;} break; case 100: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1122 "Gmsh.y" { std::string key((yyvsp[(2) - (3)].c)); @@ -5300,42 +5278,42 @@ yyreduce: charOptions[key].push_back(val); Free((yyvsp[(2) - (3)].c)); Free((yyvsp[(3) - (3)].c)); - } + ;} break; case 101: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1135 "Gmsh.y" { (yyval.i) = (int)(yyvsp[(1) - (1)].d); - } + ;} break; case 102: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1139 "Gmsh.y" { (yyval.i) = GModel::current()->setPhysicalName (std::string((yyvsp[(1) - (1)].c)), curPhysDim, ++GModel::current()->getGEOInternals()->MaxPhysicalNum); Free((yyvsp[(1) - (1)].c)); - } + ;} break; case 103: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1149 "Gmsh.y" { (yyval.l) = 0; - } + ;} break; case 104: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1153 "Gmsh.y" { (yyval.l) = List_Create(1, 1, sizeof(Vertex*)); @@ -5345,30 +5323,30 @@ yyreduce: else{ List_Add((yyval.l), &v); } - } + ;} break; case 105: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1165 "Gmsh.y" { for(int i = 0; i < 4; i++) (yyval.v)[i] = 0.; - } + ;} break; case 106: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1169 "Gmsh.y" { for(int i = 0; i < 4; i++) (yyval.v)[i] = (yyvsp[(2) - (2)].v)[i]; - } + ;} break; case 107: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1179 "Gmsh.y" { int num = (int)(yyvsp[(3) - (7)].d); @@ -5391,21 +5369,21 @@ yyreduce: } (yyval.s).Type = MSH_POINT; (yyval.s).Num = num; - } + ;} break; case 108: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1202 "Gmsh.y" { curPhysDim = 0; - } + ;} break; case 109: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1206 "Gmsh.y" { int num = (int)(yyvsp[(5) - (9)].i); @@ -5421,12 +5399,12 @@ yyreduce: List_Delete((yyvsp[(8) - (9)].l)); (yyval.s).Type = MSH_PHYSICAL_POINT; (yyval.s).Num = num; - } + ;} break; case 110: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1222 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(3) - (6)].l)); i++){ @@ -5445,12 +5423,12 @@ yyreduce: // dummy values (yyval.s).Type = 0; (yyval.s).Num = 0; - } + ;} break; case 111: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1244 "Gmsh.y" { int num = (int)(yyvsp[(3) - (7)].d); @@ -5468,12 +5446,12 @@ yyreduce: List_Delete((yyvsp[(6) - (7)].l)); (yyval.s).Type = MSH_SEGM_LINE; (yyval.s).Num = num; - } + ;} break; case 112: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1262 "Gmsh.y" { for (int i = 0; i < List_Nbr((yyvsp[(3) - (4)].l)); i++){ @@ -5494,12 +5472,12 @@ yyreduce: } } } - } + ;} break; case 113: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1283 "Gmsh.y" { int num = (int)(yyvsp[(3) - (7)].d); @@ -5517,12 +5495,12 @@ yyreduce: List_Delete((yyvsp[(6) - (7)].l)); (yyval.s).Type = MSH_SEGM_SPLN; (yyval.s).Num = num; - } + ;} break; case 114: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1301 "Gmsh.y" { int num = (int)(yyvsp[(3) - (8)].d); @@ -5552,12 +5530,12 @@ yyreduce: List_Delete((yyvsp[(6) - (8)].l)); (yyval.s).Type = MSH_SEGM_CIRC; (yyval.s).Num = num; - } + ;} break; case 115: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1331 "Gmsh.y" { int num = (int)(yyvsp[(3) - (8)].d); @@ -5587,12 +5565,12 @@ yyreduce: List_Delete((yyvsp[(6) - (8)].l)); (yyval.s).Type = MSH_SEGM_ELLI; (yyval.s).Num = num; - } + ;} break; case 116: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1361 "Gmsh.y" { int num = (int)(yyvsp[(3) - (7)].d); @@ -5610,12 +5588,12 @@ yyreduce: List_Delete((yyvsp[(6) - (7)].l)); (yyval.s).Type = MSH_SEGM_BSPLN; (yyval.s).Num = num; - } + ;} break; case 117: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1379 "Gmsh.y" { int num = (int)(yyvsp[(3) - (7)].d); @@ -5633,12 +5611,12 @@ yyreduce: List_Delete((yyvsp[(6) - (7)].l)); (yyval.s).Type = MSH_SEGM_BEZIER; (yyval.s).Num = num; - } + ;} break; case 118: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1397 "Gmsh.y" { int num = (int)(yyvsp[(3) - (11)].d); @@ -5664,12 +5642,12 @@ yyreduce: List_Delete((yyvsp[(8) - (11)].l)); (yyval.s).Type = MSH_SEGM_NURBS; (yyval.s).Num = num; - } + ;} break; case 119: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1423 "Gmsh.y" { int num = (int)(yyvsp[(4) - (8)].d); @@ -5687,12 +5665,12 @@ yyreduce: Free((yyvsp[(2) - (8)].c)); (yyval.s).Type = MSH_SEGM_LOOP; (yyval.s).Num = num; - } + ;} break; case 120: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1441 "Gmsh.y" { int num = (int)(yyvsp[(4) - (8)].d); @@ -5710,21 +5688,21 @@ yyreduce: List_Delete((yyvsp[(7) - (8)].l)); (yyval.s).Type = MSH_SEGM_COMPOUND; (yyval.s).Num = num; - } + ;} break; case 121: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1459 "Gmsh.y" { curPhysDim = 1; - } + ;} break; case 122: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1463 "Gmsh.y" { int num = (int)(yyvsp[(5) - (9)].i); @@ -5740,12 +5718,12 @@ yyreduce: List_Delete((yyvsp[(8) - (9)].l)); (yyval.s).Type = MSH_PHYSICAL_LINE; (yyval.s).Num = num; - } + ;} break; case 123: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1482 "Gmsh.y" { int num = (int)(yyvsp[(4) - (8)].d); @@ -5763,12 +5741,12 @@ yyreduce: List_Delete((yyvsp[(7) - (8)].l)); (yyval.s).Type = MSH_SURF_PLAN; (yyval.s).Num = num; - } + ;} break; case 124: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1500 "Gmsh.y" { int num = (int)(yyvsp[(4) - (9)].d), type = 0; @@ -5807,46 +5785,46 @@ yyreduce: List_Delete((yyvsp[(7) - (9)].l)); (yyval.s).Type = type; (yyval.s).Num = num; - } + ;} break; case 125: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1539 "Gmsh.y" { myGmshSurface = 0; (yyval.s).Type = 0; (yyval.s).Num = 0; - } + ;} break; case 126: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1545 "Gmsh.y" { myGmshSurface = gmshSurface::getSurface((int)(yyvsp[(3) - (4)].d)); (yyval.s).Type = 0; (yyval.s).Num = 0; - } + ;} break; case 127: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1551 "Gmsh.y" { int num = (int)(yyvsp[(4) - (10)].d); myGmshSurface = gmshParametricSurface::NewParametricSurface(num, (yyvsp[(7) - (10)].c), (yyvsp[(8) - (10)].c), (yyvsp[(9) - (10)].c)); (yyval.s).Type = 0; (yyval.s).Num = num; - } + ;} break; case 128: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1558 "Gmsh.y" { int num = (int)(yyvsp[(3) - (7)].d); @@ -5871,12 +5849,12 @@ yyreduce: } (yyval.s).Type = 0; (yyval.s).Num = num; - } + ;} break; case 129: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1583 "Gmsh.y" { int num = (int)(yyvsp[(3) - (7)].d); @@ -5901,12 +5879,12 @@ yyreduce: } (yyval.s).Type = 0; (yyval.s).Num = num; - } + ;} break; case 130: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1608 "Gmsh.y" { int num = (int)(yyvsp[(4) - (8)].d); @@ -5923,12 +5901,12 @@ yyreduce: Free((yyvsp[(2) - (8)].c)); (yyval.s).Type = MSH_SURF_LOOP; (yyval.s).Num = num; - } + ;} break; case 131: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1625 "Gmsh.y" { int num = (int)(yyvsp[(4) - (8)].d); @@ -5945,12 +5923,12 @@ yyreduce: List_Delete((yyvsp[(7) - (8)].l)); (yyval.s).Type = MSH_SURF_COMPOUND; (yyval.s).Num = num; - } + ;} break; case 132: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1643 "Gmsh.y" { int num = (int)(yyvsp[(4) - (12)].d); @@ -5980,21 +5958,21 @@ yyreduce: Free((yyvsp[(8) - (12)].c)); (yyval.s).Type = MSH_SURF_COMPOUND; (yyval.s).Num = num; - } + ;} break; case 133: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1673 "Gmsh.y" { curPhysDim = 2; - } + ;} break; case 134: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1677 "Gmsh.y" { int num = (int)(yyvsp[(5) - (9)].i); @@ -6010,12 +5988,12 @@ yyreduce: List_Delete((yyvsp[(8) - (9)].l)); (yyval.s).Type = MSH_PHYSICAL_SURFACE; (yyval.s).Num = num; - } + ;} break; case 135: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1697 "Gmsh.y" { yymsg(0, "'Complex Volume' command is deprecated: use 'Volume' instead"); @@ -6033,12 +6011,12 @@ yyreduce: List_Delete((yyvsp[(7) - (8)].l)); (yyval.s).Type = MSH_VOLUME; (yyval.s).Num = num; - } + ;} break; case 136: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1715 "Gmsh.y" { int num = (int)(yyvsp[(3) - (7)].d); @@ -6055,12 +6033,12 @@ yyreduce: List_Delete((yyvsp[(6) - (7)].l)); (yyval.s).Type = MSH_VOLUME; (yyval.s).Num = num; - } + ;} break; case 137: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1732 "Gmsh.y" { int num = (int)(yyvsp[(4) - (8)].d); @@ -6076,21 +6054,21 @@ yyreduce: List_Delete((yyvsp[(7) - (8)].l)); (yyval.s).Type = MSH_VOLUME_COMPOUND; (yyval.s).Num = num; - } + ;} break; case 138: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1748 "Gmsh.y" { curPhysDim = 3; - } + ;} break; case 139: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1752 "Gmsh.y" { int num = (int)(yyvsp[(5) - (9)].i); @@ -6106,52 +6084,52 @@ yyreduce: List_Delete((yyvsp[(8) - (9)].l)); (yyval.s).Type = MSH_PHYSICAL_VOLUME; (yyval.s).Num = num; - } + ;} break; case 140: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1774 "Gmsh.y" { TranslateShapes((yyvsp[(2) - (5)].v)[0], (yyvsp[(2) - (5)].v)[1], (yyvsp[(2) - (5)].v)[2], (yyvsp[(4) - (5)].l)); (yyval.l) = (yyvsp[(4) - (5)].l); - } + ;} break; case 141: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1779 "Gmsh.y" { RotateShapes((yyvsp[(3) - (11)].v)[0], (yyvsp[(3) - (11)].v)[1], (yyvsp[(3) - (11)].v)[2], (yyvsp[(5) - (11)].v)[0], (yyvsp[(5) - (11)].v)[1], (yyvsp[(5) - (11)].v)[2], (yyvsp[(7) - (11)].d), (yyvsp[(10) - (11)].l)); (yyval.l) = (yyvsp[(10) - (11)].l); - } + ;} break; case 142: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1784 "Gmsh.y" { SymmetryShapes((yyvsp[(2) - (5)].v)[0], (yyvsp[(2) - (5)].v)[1], (yyvsp[(2) - (5)].v)[2], (yyvsp[(2) - (5)].v)[3], (yyvsp[(4) - (5)].l)); (yyval.l) = (yyvsp[(4) - (5)].l); - } + ;} break; case 143: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1789 "Gmsh.y" { DilatShapes((yyvsp[(3) - (9)].v)[0], (yyvsp[(3) - (9)].v)[1], (yyvsp[(3) - (9)].v)[2], (yyvsp[(5) - (9)].d), (yyvsp[(8) - (9)].l)); (yyval.l) = (yyvsp[(8) - (9)].l); - } + ;} break; case 144: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1794 "Gmsh.y" { (yyval.l) = List_Create(3, 3, sizeof(Shape)); @@ -6174,23 +6152,23 @@ yyreduce: } Free((yyvsp[(1) - (4)].c)); List_Delete((yyvsp[(3) - (4)].l)); - } + ;} break; case 145: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1817 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); IntersectCurvesWithSurface((yyvsp[(4) - (9)].l), (int)(yyvsp[(8) - (9)].d), (yyval.l)); List_Delete((yyvsp[(4) - (9)].l)); - } + ;} break; case 146: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1823 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape*)); @@ -6198,44 +6176,44 @@ yyreduce: List_Delete((yyvsp[(7) - (9)].l)); SplitCurve((int)(yyvsp[(4) - (9)].d), tmp, (yyval.l)); List_Delete(tmp); - } + ;} break; case 147: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1833 "Gmsh.y" - { (yyval.l) = (yyvsp[(1) - (1)].l); } + { (yyval.l) = (yyvsp[(1) - (1)].l); ;} break; case 148: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1834 "Gmsh.y" - { (yyval.l) = (yyvsp[(1) - (1)].l); } + { (yyval.l) = (yyvsp[(1) - (1)].l); ;} break; case 149: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1839 "Gmsh.y" { (yyval.l) = List_Create(3, 3, sizeof(Shape)); - } + ;} break; case 150: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1843 "Gmsh.y" { List_Add((yyval.l), &(yyvsp[(2) - (2)].s)); - } + ;} break; case 151: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1847 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(4) - (6)].l)); i++){ @@ -6258,12 +6236,12 @@ yyreduce: yymsg(1, "Unknown point %d", TheShape.Num); } } - } + ;} break; case 152: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1870 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(4) - (6)].l)); i++){ @@ -6286,12 +6264,12 @@ yyreduce: yymsg(1, "Unknown curve %d", TheShape.Num); } } - } + ;} break; case 153: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1893 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(4) - (6)].l)); i++){ @@ -6314,12 +6292,12 @@ yyreduce: yymsg(1, "Unknown surface %d", TheShape.Num); } } - } + ;} break; case 154: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1916 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(4) - (6)].l)); i++){ @@ -6342,12 +6320,12 @@ yyreduce: yymsg(1, "Unknown volume %d", TheShape.Num); } } - } + ;} break; case 155: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1944 "Gmsh.y" { #if defined(HAVE_DINTEGRATION) @@ -6368,12 +6346,12 @@ yyreduce: else yymsg(0, "Wrong levelset definition (%d)", (yyvsp[(4) - (8)].d)); #endif - } + ;} break; case 156: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1965 "Gmsh.y" { #if defined(HAVE_DINTEGRATION) @@ -6396,12 +6374,12 @@ yyreduce: Tree_Add(GModel::current()->getGEOInternals()->LevelSets, &l); } #endif - } + ;} break; case 157: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 1989 "Gmsh.y" { #if defined(HAVE_DINTEGRATION) @@ -6421,12 +6399,12 @@ yyreduce: else yymsg(0, "Wrong levelset definition (%d)", (yyvsp[(4) - (14)].d)); #endif - } + ;} break; case 158: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 2010 "Gmsh.y" { #if defined(HAVE_DINTEGRATION) @@ -6447,12 +6425,12 @@ yyreduce: else yymsg(0, "Wrong levelset definition (%d)", (yyvsp[(4) - (16)].d)); #endif - } + ;} break; case 159: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 2031 "Gmsh.y" { #if defined(HAVE_DINTEGRATION) @@ -6472,12 +6450,12 @@ yyreduce: else yymsg(0, "Wrong levelset definition (%d)", (yyvsp[(4) - (12)].d)); #endif - } + ;} break; case 160: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 2051 "Gmsh.y" { #if defined(HAVE_DINTEGRATION) @@ -6589,12 +6567,12 @@ yyreduce: yymsg(0, "Wrong levelset definition (%d)", (yyvsp[(4) - (8)].d)); Free((yyvsp[(2) - (8)].c)); #endif - } + ;} break; case 161: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 2163 "Gmsh.y" { #if defined(HAVE_DINTEGRATION) @@ -6613,12 +6591,12 @@ yyreduce: yymsg(0, "Wrong levelset definition"); Free((yyvsp[(2) - (8)].c)); Free((yyvsp[(7) - (8)].c)); #endif - } + ;} break; case 162: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 2182 "Gmsh.y" { #if defined(HAVE_DINTEGRATION) @@ -6656,12 +6634,12 @@ yyreduce: yymsg(0, "Wrong levelset definition"); Free((yyvsp[(2) - (6)].c)); #endif - } + ;} break; case 163: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 2221 "Gmsh.y" { #if defined(HAVE_DINTEGRATION) @@ -6764,12 +6742,12 @@ yyreduce: yymsg(0, "Wrong levelset definition (%d)", (yyvsp[(4) - (14)].d)); Free((yyvsp[(2) - (14)].c)); #endif - } + ;} break; case 164: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 2329 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(3) - (4)].l)); i++){ @@ -6778,23 +6756,23 @@ yyreduce: DeleteShape(TheShape.Type, TheShape.Num); } List_Delete((yyvsp[(3) - (4)].l)); - } + ;} break; case 165: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 2338 "Gmsh.y" { #if defined(HAVE_MESH) GModel::current()->getFields()->deleteField((int)(yyvsp[(4) - (6)].d)); #endif - } + ;} break; case 166: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 2344 "Gmsh.y" { #if defined(HAVE_POST) @@ -6809,12 +6787,12 @@ yyreduce: yymsg(0, "Unknown command 'Delete %s'", (yyvsp[(2) - (6)].c)); #endif Free((yyvsp[(2) - (6)].c)); - } + ;} break; case 167: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 2359 "Gmsh.y" { if(!strcmp((yyvsp[(2) - (3)].c), "Meshes") || !strcmp((yyvsp[(2) - (3)].c), "All")){ @@ -6842,12 +6820,12 @@ yyreduce: yymsg(0, "Unknown object or expression to delete '%s'", (yyvsp[(2) - (3)].c)); } Free((yyvsp[(2) - (3)].c)); - } + ;} break; case 168: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 2387 "Gmsh.y" { #if defined(HAVE_POST) @@ -6859,12 +6837,12 @@ yyreduce: yymsg(0, "Unknown command 'Delete %s %s'", (yyvsp[(2) - (4)].c), (yyvsp[(3) - (4)].c)); #endif Free((yyvsp[(2) - (4)].c)); Free((yyvsp[(3) - (4)].c)); - } + ;} break; case 169: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 2404 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(4) - (5)].l)); i++){ @@ -6873,34 +6851,34 @@ yyreduce: ColorShape(TheShape.Type, TheShape.Num, (yyvsp[(2) - (5)].u)); } List_Delete((yyvsp[(4) - (5)].l)); - } + ;} break; case 170: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 2418 "Gmsh.y" { for(int i = 0; i < 4; i++) VisibilityShape((yyvsp[(2) - (3)].c), i, 1); Free((yyvsp[(2) - (3)].c)); - } + ;} break; case 171: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 2424 "Gmsh.y" { for(int i = 0; i < 4; i++) VisibilityShape((yyvsp[(2) - (3)].c), i, 0); Free((yyvsp[(2) - (3)].c)); - } + ;} break; case 172: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 2430 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(3) - (4)].l)); i++){ @@ -6909,12 +6887,12 @@ yyreduce: VisibilityShape(TheShape.Type, TheShape.Num, 1); } List_Delete((yyvsp[(3) - (4)].l)); - } + ;} break; case 173: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 2439 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(3) - (4)].l)); i++){ @@ -6923,12 +6901,12 @@ yyreduce: VisibilityShape(TheShape.Type, TheShape.Num, 0); } List_Delete((yyvsp[(3) - (4)].l)); - } + ;} break; case 174: -/* Line 1806 of yacc.c */ +/* Line 1464 of yacc.c */ #line 2453 "Gmsh.y" { if(!strcmp((yyvsp[(1) - (3)].c), "Include")){ @@ -6964,20 +6942,22 @@ yyreduce: std::string tmp = FixRelativePath(gmsh_yyname, (yyvsp[(2) - (3)].c)); MergeFile(tmp, true); } - else if(!strcmp((yyvsp[(1) - (3)].c), "System")) + else if(!strcmp((yyvsp[(1) - (3)].c), "NonBlockingSystemCall")) SystemCall((yyvsp[(2) - (3)].c)); + else if(!strcmp((yyvsp[(1) - (3)].c), "System") || !strcmp((yyvsp[(1) - (3)].c), "SystemCall")) + SystemCall((yyvsp[(2) - (3)].c), true); else if(!strcmp((yyvsp[(1) - (3)].c), "SetName")) GModel::current()->setName((yyvsp[(2) - (3)].c)); else yymsg(0, "Unknown command '%s'", (yyvsp[(1) - (3)].c)); Free((yyvsp[(1) - (3)].c)); Free((yyvsp[(2) - (3)].c)); - } + ;} break; case 175: -/* Line 1806 of yacc.c */ -#line 2496 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2498 "Gmsh.y" { #if defined(HAVE_POST) if(!strcmp((yyvsp[(1) - (7)].c), "Save") && !strcmp((yyvsp[(2) - (7)].c), "View")){ @@ -6993,13 +6973,13 @@ yyreduce: yymsg(0, "Unknown command '%s'", (yyvsp[(1) - (7)].c)); #endif Free((yyvsp[(1) - (7)].c)); Free((yyvsp[(2) - (7)].c)); Free((yyvsp[(6) - (7)].c)); - } + ;} break; case 176: -/* Line 1806 of yacc.c */ -#line 2513 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2515 "Gmsh.y" { #if defined(HAVE_POST) && defined(HAVE_MESH) if(!strcmp((yyvsp[(1) - (7)].c), "Background") && !strcmp((yyvsp[(2) - (7)].c), "Mesh") && !strcmp((yyvsp[(3) - (7)].c), "View")){ @@ -7013,13 +6993,13 @@ yyreduce: yymsg(0, "Unknown command '%s'", (yyvsp[(1) - (7)].c)); #endif Free((yyvsp[(1) - (7)].c)); Free((yyvsp[(2) - (7)].c)); Free((yyvsp[(3) - (7)].c)); - } + ;} break; case 177: -/* Line 1806 of yacc.c */ -#line 2528 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2530 "Gmsh.y" { if(!strcmp((yyvsp[(1) - (3)].c), "Sleep")){ SleepInSeconds((yyvsp[(2) - (3)].d)); @@ -7037,13 +7017,13 @@ yyreduce: else yymsg(0, "Unknown command '%s'", (yyvsp[(1) - (3)].c)); Free((yyvsp[(1) - (3)].c)); - } + ;} break; case 178: -/* Line 1806 of yacc.c */ -#line 2547 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2549 "Gmsh.y" { #if defined(HAVE_PLUGINS) try { @@ -7054,13 +7034,13 @@ yyreduce: } #endif Free((yyvsp[(3) - (7)].c)); Free((yyvsp[(6) - (7)].c)); - } + ;} break; case 179: -/* Line 1806 of yacc.c */ -#line 2559 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2561 "Gmsh.y" { #if defined(HAVE_POST) if(!strcmp((yyvsp[(2) - (3)].c), "ElementsFromAllViews")) @@ -7083,94 +7063,94 @@ yyreduce: yymsg(0, "Unknown 'Combine' command"); #endif Free((yyvsp[(2) - (3)].c)); - } + ;} break; case 180: -/* Line 1806 of yacc.c */ -#line 2583 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2585 "Gmsh.y" { exit(0); - } + ;} break; case 181: -/* Line 1806 of yacc.c */ -#line 2587 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2589 "Gmsh.y" { // FIXME: this is a hack to force a transfer from the old DB to // the new DB. This will become unnecessary if/when we fill the // GModel directly during parsing. GModel::current()->importGEOInternals(); - } + ;} break; case 182: -/* Line 1806 of yacc.c */ -#line 2594 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2596 "Gmsh.y" { CTX::instance()->forcedBBox = 0; GModel::current()->importGEOInternals(); SetBoundingBox(); - } + ;} break; case 183: -/* Line 1806 of yacc.c */ -#line 2600 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2602 "Gmsh.y" { CTX::instance()->forcedBBox = 1; SetBoundingBox((yyvsp[(3) - (15)].d), (yyvsp[(5) - (15)].d), (yyvsp[(7) - (15)].d), (yyvsp[(9) - (15)].d), (yyvsp[(11) - (15)].d), (yyvsp[(13) - (15)].d)); - } + ;} break; case 184: -/* Line 1806 of yacc.c */ -#line 2605 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2607 "Gmsh.y" { #if defined(HAVE_OPENGL) drawContext::global()->draw(); #endif - } + ;} break; case 185: -/* Line 1806 of yacc.c */ -#line 2611 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2613 "Gmsh.y" { GModel::current()->createTopologyFromMesh(); - } + ;} break; case 186: -/* Line 1806 of yacc.c */ -#line 2615 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2617 "Gmsh.y" { GModel::current()->createTopologyFromMesh(1); - } + ;} break; case 187: -/* Line 1806 of yacc.c */ -#line 2619 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2621 "Gmsh.y" { GModel::current()->importGEOInternals(); GModel::current()->refineMesh(CTX::instance()->mesh.secondOrderLinear); - } + ;} break; case 188: -/* Line 1806 of yacc.c */ -#line 2629 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2631 "Gmsh.y" { LoopControlVariablesTab[ImbricatedLoop][0] = (yyvsp[(3) - (6)].d); LoopControlVariablesTab[ImbricatedLoop][1] = (yyvsp[(5) - (6)].d); @@ -7186,13 +7166,13 @@ yyreduce: yymsg(0, "Reached maximum number of imbricated loops"); ImbricatedLoop = MAX_RECUR_LOOPS - 1; } - } + ;} break; case 189: -/* Line 1806 of yacc.c */ -#line 2646 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2648 "Gmsh.y" { LoopControlVariablesTab[ImbricatedLoop][0] = (yyvsp[(3) - (8)].d); LoopControlVariablesTab[ImbricatedLoop][1] = (yyvsp[(5) - (8)].d); @@ -7208,13 +7188,13 @@ yyreduce: yymsg(0, "Reached maximum number of imbricated loops"); ImbricatedLoop = MAX_RECUR_LOOPS - 1; } - } + ;} break; case 190: -/* Line 1806 of yacc.c */ -#line 2663 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2665 "Gmsh.y" { LoopControlVariablesTab[ImbricatedLoop][0] = (yyvsp[(5) - (8)].d); LoopControlVariablesTab[ImbricatedLoop][1] = (yyvsp[(7) - (8)].d); @@ -7234,13 +7214,13 @@ yyreduce: yymsg(0, "Reached maximum number of imbricated loops"); ImbricatedLoop = MAX_RECUR_LOOPS - 1; } - } + ;} break; case 191: -/* Line 1806 of yacc.c */ -#line 2684 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2686 "Gmsh.y" { LoopControlVariablesTab[ImbricatedLoop][0] = (yyvsp[(5) - (10)].d); LoopControlVariablesTab[ImbricatedLoop][1] = (yyvsp[(7) - (10)].d); @@ -7260,13 +7240,13 @@ yyreduce: yymsg(0, "Reached maximum number of imbricated loops"); ImbricatedLoop = MAX_RECUR_LOOPS - 1; } - } + ;} break; case 192: -/* Line 1806 of yacc.c */ -#line 2705 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2707 "Gmsh.y" { if(ImbricatedLoop <= 0){ yymsg(0, "Invalid For/EndFor loop"); @@ -7300,518 +7280,518 @@ yyreduce: else ImbricatedLoop--; } - } + ;} break; case 193: -/* Line 1806 of yacc.c */ -#line 2740 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2742 "Gmsh.y" { if(!FunctionManager::Instance()->createFunction ((yyvsp[(2) - (2)].c), gmsh_yyin, gmsh_yyname, gmsh_yylineno)) yymsg(0, "Redefinition of function %s", (yyvsp[(2) - (2)].c)); skip_until(NULL, "Return"); //FIXME: wee leak $2 - } + ;} break; case 194: -/* Line 1806 of yacc.c */ -#line 2748 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2750 "Gmsh.y" { if(!FunctionManager::Instance()->leaveFunction (&gmsh_yyin, gmsh_yyname, gmsh_yylineno)) yymsg(0, "Error while exiting function"); - } + ;} break; case 195: -/* Line 1806 of yacc.c */ -#line 2754 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2756 "Gmsh.y" { if(!FunctionManager::Instance()->enterFunction ((yyvsp[(2) - (3)].c), &gmsh_yyin, gmsh_yyname, gmsh_yylineno)) yymsg(0, "Unknown function %s", (yyvsp[(2) - (3)].c)); //FIXME: wee leak $2 - } + ;} break; case 196: -/* Line 1806 of yacc.c */ -#line 2761 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2763 "Gmsh.y" { if(!(yyvsp[(3) - (4)].d)) skip_until("If", "EndIf"); - } + ;} break; case 197: -/* Line 1806 of yacc.c */ -#line 2765 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2767 "Gmsh.y" { - } + ;} break; case 198: -/* Line 1806 of yacc.c */ -#line 2774 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2776 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShapes(TRANSLATE, (yyvsp[(4) - (5)].l), (yyvsp[(2) - (5)].v)[0], (yyvsp[(2) - (5)].v)[1], (yyvsp[(2) - (5)].v)[2], 0., 0., 0., 0., 0., 0., 0., NULL, (yyval.l)); List_Delete((yyvsp[(4) - (5)].l)); - } + ;} break; case 199: -/* Line 1806 of yacc.c */ -#line 2782 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2784 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShapes(ROTATE, (yyvsp[(10) - (11)].l), 0., 0., 0., (yyvsp[(3) - (11)].v)[0], (yyvsp[(3) - (11)].v)[1], (yyvsp[(3) - (11)].v)[2], (yyvsp[(5) - (11)].v)[0], (yyvsp[(5) - (11)].v)[1], (yyvsp[(5) - (11)].v)[2], (yyvsp[(7) - (11)].d), NULL, (yyval.l)); List_Delete((yyvsp[(10) - (11)].l)); - } + ;} break; case 200: -/* Line 1806 of yacc.c */ -#line 2790 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2792 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShapes(TRANSLATE_ROTATE, (yyvsp[(12) - (13)].l), (yyvsp[(3) - (13)].v)[0], (yyvsp[(3) - (13)].v)[1], (yyvsp[(3) - (13)].v)[2], (yyvsp[(5) - (13)].v)[0], (yyvsp[(5) - (13)].v)[1], (yyvsp[(5) - (13)].v)[2], (yyvsp[(7) - (13)].v)[0], (yyvsp[(7) - (13)].v)[1], (yyvsp[(7) - (13)].v)[2], (yyvsp[(9) - (13)].d), NULL, (yyval.l)); List_Delete((yyvsp[(12) - (13)].l)); - } + ;} break; case 201: -/* Line 1806 of yacc.c */ -#line 2798 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2800 "Gmsh.y" { extr.mesh.ExtrudeMesh = extr.mesh.Recombine = false; extr.mesh.QuadToTri = NO_QUADTRI; - } + ;} break; case 202: -/* Line 1806 of yacc.c */ -#line 2803 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2805 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShapes(TRANSLATE, (yyvsp[(4) - (7)].l), (yyvsp[(2) - (7)].v)[0], (yyvsp[(2) - (7)].v)[1], (yyvsp[(2) - (7)].v)[2], 0., 0., 0., 0., 0., 0., 0., &extr, (yyval.l)); List_Delete((yyvsp[(4) - (7)].l)); - } + ;} break; case 203: -/* Line 1806 of yacc.c */ -#line 2811 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2813 "Gmsh.y" { extr.mesh.ExtrudeMesh = extr.mesh.Recombine = false; extr.mesh.QuadToTri = NO_QUADTRI; - } + ;} break; case 204: -/* Line 1806 of yacc.c */ -#line 2816 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2818 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShapes(ROTATE, (yyvsp[(10) - (13)].l), 0., 0., 0., (yyvsp[(3) - (13)].v)[0], (yyvsp[(3) - (13)].v)[1], (yyvsp[(3) - (13)].v)[2], (yyvsp[(5) - (13)].v)[0], (yyvsp[(5) - (13)].v)[1], (yyvsp[(5) - (13)].v)[2], (yyvsp[(7) - (13)].d), &extr, (yyval.l)); List_Delete((yyvsp[(10) - (13)].l)); - } + ;} break; case 205: -/* Line 1806 of yacc.c */ -#line 2824 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2826 "Gmsh.y" { extr.mesh.ExtrudeMesh = extr.mesh.Recombine = false; extr.mesh.QuadToTri = NO_QUADTRI; - } + ;} break; case 206: -/* Line 1806 of yacc.c */ -#line 2829 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2831 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShapes(TRANSLATE_ROTATE, (yyvsp[(12) - (15)].l), (yyvsp[(3) - (15)].v)[0], (yyvsp[(3) - (15)].v)[1], (yyvsp[(3) - (15)].v)[2], (yyvsp[(5) - (15)].v)[0], (yyvsp[(5) - (15)].v)[1], (yyvsp[(5) - (15)].v)[2], (yyvsp[(7) - (15)].v)[0], (yyvsp[(7) - (15)].v)[1], (yyvsp[(7) - (15)].v)[2], (yyvsp[(9) - (15)].d), &extr, (yyval.l)); List_Delete((yyvsp[(12) - (15)].l)); - } + ;} break; case 207: -/* Line 1806 of yacc.c */ -#line 2837 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2839 "Gmsh.y" { extr.mesh.ExtrudeMesh = extr.mesh.Recombine = false; extr.mesh.QuadToTri = NO_QUADTRI; - } + ;} break; case 208: -/* Line 1806 of yacc.c */ -#line 2842 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2844 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShapes(BOUNDARY_LAYER, (yyvsp[(3) - (6)].l), 0., 0., 0., 0., 0., 0., 0., 0., 0., 0., &extr, (yyval.l)); List_Delete((yyvsp[(3) - (6)].l)); - } + ;} break; case 209: -/* Line 1806 of yacc.c */ -#line 2850 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2852 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(TRANSLATE, MSH_POINT, (int)(yyvsp[(4) - (8)].d), (yyvsp[(6) - (8)].v)[0], (yyvsp[(6) - (8)].v)[1], (yyvsp[(6) - (8)].v)[2], 0., 0., 0., 0., 0., 0., 0., NULL, (yyval.l)); - } + ;} break; case 210: -/* Line 1806 of yacc.c */ -#line 2857 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2859 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(TRANSLATE, MSH_SEGM_LINE, (int)(yyvsp[(4) - (8)].d), (yyvsp[(6) - (8)].v)[0], (yyvsp[(6) - (8)].v)[1], (yyvsp[(6) - (8)].v)[2], 0., 0., 0., 0., 0., 0., 0., NULL, (yyval.l)); - } + ;} break; case 211: -/* Line 1806 of yacc.c */ -#line 2864 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2866 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(TRANSLATE, MSH_SURF_PLAN, (int)(yyvsp[(4) - (8)].d), (yyvsp[(6) - (8)].v)[0], (yyvsp[(6) - (8)].v)[1], (yyvsp[(6) - (8)].v)[2], 0., 0., 0., 0., 0., 0., 0., NULL, (yyval.l)); - } + ;} break; case 212: -/* Line 1806 of yacc.c */ -#line 2871 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2873 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(ROTATE, MSH_POINT, (int)(yyvsp[(4) - (12)].d), 0., 0., 0., (yyvsp[(6) - (12)].v)[0], (yyvsp[(6) - (12)].v)[1], (yyvsp[(6) - (12)].v)[2], (yyvsp[(8) - (12)].v)[0], (yyvsp[(8) - (12)].v)[1], (yyvsp[(8) - (12)].v)[2], (yyvsp[(10) - (12)].d), NULL, (yyval.l)); - } + ;} break; case 213: -/* Line 1806 of yacc.c */ -#line 2878 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2880 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(ROTATE, MSH_SEGM_LINE, (int)(yyvsp[(4) - (12)].d), 0., 0., 0., (yyvsp[(6) - (12)].v)[0], (yyvsp[(6) - (12)].v)[1], (yyvsp[(6) - (12)].v)[2], (yyvsp[(8) - (12)].v)[0], (yyvsp[(8) - (12)].v)[1], (yyvsp[(8) - (12)].v)[2], (yyvsp[(10) - (12)].d), NULL, (yyval.l)); - } + ;} break; case 214: -/* Line 1806 of yacc.c */ -#line 2885 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2887 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(ROTATE, MSH_SURF_PLAN, (int)(yyvsp[(4) - (12)].d), 0., 0., 0., (yyvsp[(6) - (12)].v)[0], (yyvsp[(6) - (12)].v)[1], (yyvsp[(6) - (12)].v)[2], (yyvsp[(8) - (12)].v)[0], (yyvsp[(8) - (12)].v)[1], (yyvsp[(8) - (12)].v)[2], (yyvsp[(10) - (12)].d), NULL, (yyval.l)); - } + ;} break; case 215: -/* Line 1806 of yacc.c */ -#line 2892 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2894 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(TRANSLATE_ROTATE, MSH_POINT, (int)(yyvsp[(4) - (14)].d), (yyvsp[(6) - (14)].v)[0], (yyvsp[(6) - (14)].v)[1], (yyvsp[(6) - (14)].v)[2], (yyvsp[(8) - (14)].v)[0], (yyvsp[(8) - (14)].v)[1], (yyvsp[(8) - (14)].v)[2], (yyvsp[(10) - (14)].v)[0], (yyvsp[(10) - (14)].v)[1], (yyvsp[(10) - (14)].v)[2], (yyvsp[(12) - (14)].d), NULL, (yyval.l)); - } + ;} break; case 216: -/* Line 1806 of yacc.c */ -#line 2899 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2901 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(TRANSLATE_ROTATE, MSH_SEGM_LINE, (int)(yyvsp[(4) - (14)].d), (yyvsp[(6) - (14)].v)[0], (yyvsp[(6) - (14)].v)[1], (yyvsp[(6) - (14)].v)[2], (yyvsp[(8) - (14)].v)[0], (yyvsp[(8) - (14)].v)[1], (yyvsp[(8) - (14)].v)[2], (yyvsp[(10) - (14)].v)[0], (yyvsp[(10) - (14)].v)[1], (yyvsp[(10) - (14)].v)[2], (yyvsp[(12) - (14)].d), NULL, (yyval.l)); - } + ;} break; case 217: -/* Line 1806 of yacc.c */ -#line 2906 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2908 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(TRANSLATE_ROTATE, MSH_SURF_PLAN, (int)(yyvsp[(4) - (14)].d), (yyvsp[(6) - (14)].v)[0], (yyvsp[(6) - (14)].v)[1], (yyvsp[(6) - (14)].v)[2], (yyvsp[(8) - (14)].v)[0], (yyvsp[(8) - (14)].v)[1], (yyvsp[(8) - (14)].v)[2], (yyvsp[(10) - (14)].v)[0], (yyvsp[(10) - (14)].v)[1], (yyvsp[(10) - (14)].v)[2], (yyvsp[(12) - (14)].d), NULL, (yyval.l)); - } + ;} break; case 218: -/* Line 1806 of yacc.c */ -#line 2913 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2915 "Gmsh.y" { extr.mesh.ExtrudeMesh = extr.mesh.Recombine = false; extr.mesh.QuadToTri = NO_QUADTRI; - } + ;} break; case 219: -/* Line 1806 of yacc.c */ -#line 2918 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2920 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(TRANSLATE, MSH_POINT, (int)(yyvsp[(4) - (12)].d), (yyvsp[(6) - (12)].v)[0], (yyvsp[(6) - (12)].v)[1], (yyvsp[(6) - (12)].v)[2], 0., 0., 0., 0., 0., 0., 0., &extr, (yyval.l)); - } + ;} break; case 220: -/* Line 1806 of yacc.c */ -#line 2925 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2927 "Gmsh.y" { extr.mesh.ExtrudeMesh = extr.mesh.Recombine = false; extr.mesh.QuadToTri = NO_QUADTRI; - } + ;} break; case 221: -/* Line 1806 of yacc.c */ -#line 2930 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2932 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(TRANSLATE, MSH_SEGM_LINE, (int)(yyvsp[(4) - (12)].d), (yyvsp[(6) - (12)].v)[0], (yyvsp[(6) - (12)].v)[1], (yyvsp[(6) - (12)].v)[2], 0., 0., 0., 0., 0., 0., 0., &extr, (yyval.l)); - } + ;} break; case 222: -/* Line 1806 of yacc.c */ -#line 2937 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2939 "Gmsh.y" { extr.mesh.ExtrudeMesh = extr.mesh.Recombine = false; extr.mesh.QuadToTri = NO_QUADTRI; - } + ;} break; case 223: -/* Line 1806 of yacc.c */ -#line 2942 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2944 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(TRANSLATE, MSH_SURF_PLAN, (int)(yyvsp[(4) - (12)].d), (yyvsp[(6) - (12)].v)[0], (yyvsp[(6) - (12)].v)[1], (yyvsp[(6) - (12)].v)[2], 0., 0., 0., 0., 0., 0., 0., &extr, (yyval.l)); - } + ;} break; case 224: -/* Line 1806 of yacc.c */ -#line 2949 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2951 "Gmsh.y" { extr.mesh.ExtrudeMesh = extr.mesh.Recombine = false; extr.mesh.QuadToTri = NO_QUADTRI; - } + ;} break; case 225: -/* Line 1806 of yacc.c */ -#line 2954 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2956 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(ROTATE, MSH_POINT, (int)(yyvsp[(4) - (16)].d), 0., 0., 0., (yyvsp[(6) - (16)].v)[0], (yyvsp[(6) - (16)].v)[1], (yyvsp[(6) - (16)].v)[2], (yyvsp[(8) - (16)].v)[0], (yyvsp[(8) - (16)].v)[1], (yyvsp[(8) - (16)].v)[2], (yyvsp[(10) - (16)].d), &extr, (yyval.l)); - } + ;} break; case 226: -/* Line 1806 of yacc.c */ -#line 2961 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2963 "Gmsh.y" { extr.mesh.ExtrudeMesh = extr.mesh.Recombine = false; extr.mesh.QuadToTri = NO_QUADTRI; - } + ;} break; case 227: -/* Line 1806 of yacc.c */ -#line 2966 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2968 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(ROTATE, MSH_SEGM_LINE, (int)(yyvsp[(4) - (16)].d), 0., 0., 0., (yyvsp[(6) - (16)].v)[0], (yyvsp[(6) - (16)].v)[1], (yyvsp[(6) - (16)].v)[2], (yyvsp[(8) - (16)].v)[0], (yyvsp[(8) - (16)].v)[1], (yyvsp[(8) - (16)].v)[2], (yyvsp[(10) - (16)].d), &extr, (yyval.l)); - } + ;} break; case 228: -/* Line 1806 of yacc.c */ -#line 2973 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2975 "Gmsh.y" { extr.mesh.ExtrudeMesh = extr.mesh.Recombine = false; extr.mesh.QuadToTri = NO_QUADTRI; - } + ;} break; case 229: -/* Line 1806 of yacc.c */ -#line 2978 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2980 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(ROTATE, MSH_SURF_PLAN, (int)(yyvsp[(4) - (16)].d), 0., 0., 0., (yyvsp[(6) - (16)].v)[0], (yyvsp[(6) - (16)].v)[1], (yyvsp[(6) - (16)].v)[2], (yyvsp[(8) - (16)].v)[0], (yyvsp[(8) - (16)].v)[1], (yyvsp[(8) - (16)].v)[2], (yyvsp[(10) - (16)].d), &extr, (yyval.l)); - } + ;} break; case 230: -/* Line 1806 of yacc.c */ -#line 2985 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2987 "Gmsh.y" { extr.mesh.ExtrudeMesh = extr.mesh.Recombine = false; extr.mesh.QuadToTri = NO_QUADTRI; - } + ;} break; case 231: -/* Line 1806 of yacc.c */ -#line 2990 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2992 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(TRANSLATE_ROTATE, MSH_POINT, (int)(yyvsp[(4) - (18)].d), (yyvsp[(6) - (18)].v)[0], (yyvsp[(6) - (18)].v)[1], (yyvsp[(6) - (18)].v)[2], (yyvsp[(8) - (18)].v)[0], (yyvsp[(8) - (18)].v)[1], (yyvsp[(8) - (18)].v)[2], (yyvsp[(10) - (18)].v)[0], (yyvsp[(10) - (18)].v)[1], (yyvsp[(10) - (18)].v)[2], (yyvsp[(12) - (18)].d), &extr, (yyval.l)); - } + ;} break; case 232: -/* Line 1806 of yacc.c */ -#line 2997 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 2999 "Gmsh.y" { extr.mesh.ExtrudeMesh = extr.mesh.Recombine = false; extr.mesh.QuadToTri = NO_QUADTRI; - } + ;} break; case 233: -/* Line 1806 of yacc.c */ -#line 3002 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3004 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(TRANSLATE_ROTATE, MSH_SEGM_LINE, (int)(yyvsp[(4) - (18)].d), (yyvsp[(6) - (18)].v)[0], (yyvsp[(6) - (18)].v)[1], (yyvsp[(6) - (18)].v)[2], (yyvsp[(8) - (18)].v)[0], (yyvsp[(8) - (18)].v)[1], (yyvsp[(8) - (18)].v)[2], (yyvsp[(10) - (18)].v)[0], (yyvsp[(10) - (18)].v)[1], (yyvsp[(10) - (18)].v)[2], (yyvsp[(12) - (18)].d), &extr, (yyval.l)); - } + ;} break; case 234: -/* Line 1806 of yacc.c */ -#line 3009 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3011 "Gmsh.y" { extr.mesh.ExtrudeMesh = extr.mesh.Recombine = false; extr.mesh.QuadToTri = NO_QUADTRI; - } + ;} break; case 235: -/* Line 1806 of yacc.c */ -#line 3014 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3016 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(Shape)); ExtrudeShape(TRANSLATE_ROTATE, MSH_SURF_PLAN, (int)(yyvsp[(4) - (18)].d), (yyvsp[(6) - (18)].v)[0], (yyvsp[(6) - (18)].v)[1], (yyvsp[(6) - (18)].v)[2], (yyvsp[(8) - (18)].v)[0], (yyvsp[(8) - (18)].v)[1], (yyvsp[(8) - (18)].v)[2], (yyvsp[(10) - (18)].v)[0], (yyvsp[(10) - (18)].v)[1], (yyvsp[(10) - (18)].v)[2], (yyvsp[(12) - (18)].d), &extr, (yyval.l)); - } + ;} break; case 236: -/* Line 1806 of yacc.c */ -#line 3025 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3027 "Gmsh.y" { - } + ;} break; case 237: -/* Line 1806 of yacc.c */ -#line 3028 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3030 "Gmsh.y" { - } + ;} break; case 238: -/* Line 1806 of yacc.c */ -#line 3034 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3036 "Gmsh.y" { extr.mesh.ExtrudeMesh = true; extr.mesh.NbLayer = 1; @@ -7819,13 +7799,13 @@ yyreduce: extr.mesh.hLayer.clear(); extr.mesh.NbElmLayer.push_back((int)fabs((yyvsp[(3) - (5)].d))); extr.mesh.hLayer.push_back(1.); - } + ;} break; case 239: -/* Line 1806 of yacc.c */ -#line 3043 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3045 "Gmsh.y" { extr.mesh.ExtrudeMesh = true; extr.mesh.NbLayer = List_Nbr((yyvsp[(3) - (7)].l)); @@ -7844,13 +7824,13 @@ yyreduce: yymsg(0, "Wrong layer definition {%d, %d}", List_Nbr((yyvsp[(3) - (7)].l)), List_Nbr((yyvsp[(5) - (7)].l))); List_Delete((yyvsp[(3) - (7)].l)); List_Delete((yyvsp[(5) - (7)].l)); - } + ;} break; case 240: -/* Line 1806 of yacc.c */ -#line 3063 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3065 "Gmsh.y" { yymsg(0, "Explicit region numbers in layers are deprecated"); extr.mesh.ExtrudeMesh = true; @@ -7872,58 +7852,58 @@ yyreduce: List_Delete((yyvsp[(3) - (9)].l)); List_Delete((yyvsp[(5) - (9)].l)); List_Delete((yyvsp[(7) - (9)].l)); - } + ;} break; case 241: -/* Line 1806 of yacc.c */ -#line 3086 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3088 "Gmsh.y" { extr.mesh.Recombine = true; - } + ;} break; case 242: -/* Line 1806 of yacc.c */ -#line 3090 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3092 "Gmsh.y" { extr.mesh.QuadToTri = QUADTRI_DBL_1; - } + ;} break; case 243: -/* Line 1806 of yacc.c */ -#line 3094 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3096 "Gmsh.y" { extr.mesh.QuadToTri = QUADTRI_DBL_1_RECOMB; - } + ;} break; case 244: -/* Line 1806 of yacc.c */ -#line 3098 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3100 "Gmsh.y" { extr.mesh.QuadToTri = QUADTRI_SNGL_1; - } + ;} break; case 245: -/* Line 1806 of yacc.c */ -#line 3102 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3104 "Gmsh.y" { extr.mesh.QuadToTri = QUADTRI_SNGL_1_RECOMB; - } + ;} break; case 246: -/* Line 1806 of yacc.c */ -#line 3106 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3108 "Gmsh.y" { int num = (int)(yyvsp[(3) - (9)].d); if(FindSurface(num)){ @@ -7941,35 +7921,35 @@ yyreduce: } } List_Delete((yyvsp[(6) - (9)].l)); - } + ;} break; case 247: -/* Line 1806 of yacc.c */ -#line 3125 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3127 "Gmsh.y" { if(!strcmp((yyvsp[(2) - (6)].c), "Index")) extr.mesh.BoundaryLayerIndex = (yyvsp[(4) - (6)].d); else if(!strcmp((yyvsp[(2) - (6)].c), "View")) extr.mesh.ViewIndex = (yyvsp[(4) - (6)].d); Free((yyvsp[(2) - (6)].c)); - } + ;} break; case 248: -/* Line 1806 of yacc.c */ -#line 3137 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3139 "Gmsh.y" { (yyval.v)[0] = (yyval.v)[1] = 1.; - } + ;} break; case 249: -/* Line 1806 of yacc.c */ -#line 3141 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3143 "Gmsh.y" { if(!strcmp((yyvsp[(2) - (3)].c), "Progression") || !strcmp((yyvsp[(2) - (3)].c), "Power")) (yyval.v)[0] = 1.; @@ -7981,22 +7961,22 @@ yyreduce: } (yyval.v)[1] = (yyvsp[(3) - (3)].d); Free((yyvsp[(2) - (3)].c)); - } + ;} break; case 250: -/* Line 1806 of yacc.c */ -#line 3156 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3158 "Gmsh.y" { (yyval.i) = -1; // left - } + ;} break; case 251: -/* Line 1806 of yacc.c */ -#line 3160 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3162 "Gmsh.y" { if(!strcmp((yyvsp[(1) - (1)].c), "Right")) (yyval.i) = 1; @@ -8005,49 +7985,49 @@ yyreduce: else // alternated (yyval.i) = 0; Free((yyvsp[(1) - (1)].c)); - } + ;} break; case 252: -/* Line 1806 of yacc.c */ -#line 3172 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3174 "Gmsh.y" { (yyval.l) = List_Create(1, 1, sizeof(double)); - } + ;} break; case 253: -/* Line 1806 of yacc.c */ -#line 3176 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3178 "Gmsh.y" { (yyval.l) = (yyvsp[(2) - (2)].l); - } + ;} break; case 254: -/* Line 1806 of yacc.c */ -#line 3181 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3183 "Gmsh.y" { (yyval.i) = 45; - } + ;} break; case 255: -/* Line 1806 of yacc.c */ -#line 3185 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3187 "Gmsh.y" { (yyval.i) = (int)(yyvsp[(2) - (2)].d); - } + ;} break; case 256: -/* Line 1806 of yacc.c */ -#line 3192 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3194 "Gmsh.y" { int type = (int)(yyvsp[(6) - (7)].v)[0]; double coef = fabs((yyvsp[(6) - (7)].v)[1]); @@ -8102,13 +8082,13 @@ yyreduce: } List_Delete((yyvsp[(3) - (7)].l)); } - } + ;} break; case 257: -/* Line 1806 of yacc.c */ -#line 3248 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3250 "Gmsh.y" { int k = List_Nbr((yyvsp[(4) - (6)].l)); if(k != 0 && k != 3 && k != 4){ @@ -8177,23 +8157,23 @@ yyreduce: } } List_Delete((yyvsp[(4) - (6)].l)); - } + ;} break; case 258: -/* Line 1806 of yacc.c */ -#line 3318 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3320 "Gmsh.y" { yymsg(1, "Elliptic Surface is deprecated: use Transfinite instead (with smoothing)"); List_Delete((yyvsp[(7) - (8)].l)); - } + ;} break; case 259: -/* Line 1806 of yacc.c */ -#line 3323 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3325 "Gmsh.y" { int k = List_Nbr((yyvsp[(4) - (5)].l)); if(k != 0 && k != 6 && k != 8){ @@ -8259,13 +8239,13 @@ yyreduce: } } List_Delete((yyvsp[(4) - (5)].l)); - } + ;} break; case 260: -/* Line 1806 of yacc.c */ -#line 3390 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3392 "Gmsh.y" { if(!(yyvsp[(2) - (3)].l)){ List_T *tmp = Tree2List(GModel::current()->getGEOInternals()->Volumes); @@ -8300,13 +8280,13 @@ yyreduce: } List_Delete((yyvsp[(2) - (3)].l)); } - } + ;} break; case 261: -/* Line 1806 of yacc.c */ -#line 3426 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3428 "Gmsh.y" { if(!(yyvsp[(3) - (5)].l)){ List_T *tmp = Tree2List(GModel::current()->getGEOInternals()->Surfaces); @@ -8348,13 +8328,13 @@ yyreduce: } List_Delete((yyvsp[(3) - (5)].l)); } - } + ;} break; case 262: -/* Line 1806 of yacc.c */ -#line 3469 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3471 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(3) - (6)].l)); i++){ double d; @@ -8373,13 +8353,13 @@ yyreduce: } } List_Delete((yyvsp[(3) - (6)].l)); - } + ;} break; case 263: -/* Line 1806 of yacc.c */ -#line 3494 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3496 "Gmsh.y" { if(List_Nbr((yyvsp[(5) - (6)].l)) != List_Nbr((yyvsp[(3) - (6)].l))){ yymsg(0, "Number of master (%d) different from number of slave (%d) lines", @@ -8405,13 +8385,13 @@ yyreduce: } List_Delete((yyvsp[(3) - (6)].l)); List_Delete((yyvsp[(5) - (6)].l)); - } + ;} break; case 264: -/* Line 1806 of yacc.c */ -#line 3522 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3524 "Gmsh.y" { if (List_Nbr((yyvsp[(5) - (12)].l)) != List_Nbr((yyvsp[(10) - (12)].l))){ yymsg(0, "Number of master surface edges (%d) different from number of " @@ -8446,13 +8426,13 @@ yyreduce: } List_Delete((yyvsp[(5) - (12)].l)); List_Delete((yyvsp[(10) - (12)].l)); - } + ;} break; case 265: -/* Line 1806 of yacc.c */ -#line 3565 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3567 "Gmsh.y" { Surface *s = FindSurface((int)(yyvsp[(8) - (10)].d)); if(s){ @@ -8474,13 +8454,13 @@ yyreduce: else yymsg(0, "Unknown surface %d", (int)(yyvsp[(8) - (10)].d)); } - } + ;} break; case 266: -/* Line 1806 of yacc.c */ -#line 3588 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3590 "Gmsh.y" { Surface *s = FindSurface((int)(yyvsp[(8) - (10)].d)); if(s){ @@ -8502,38 +8482,38 @@ yyreduce: else yymsg(0, "Unknown surface %d", (int)(yyvsp[(8) - (10)].d)); } - } + ;} break; case 267: -/* Line 1806 of yacc.c */ -#line 3611 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3613 "Gmsh.y" { - } + ;} break; case 268: -/* Line 1806 of yacc.c */ -#line 3614 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3616 "Gmsh.y" { - } + ;} break; case 269: -/* Line 1806 of yacc.c */ -#line 3623 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3625 "Gmsh.y" { ReplaceAllDuplicates(); - } + ;} break; case 270: -/* Line 1806 of yacc.c */ -#line 3627 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3629 "Gmsh.y" { if(!strcmp((yyvsp[(2) - (3)].c), "Geometry")) ReplaceAllDuplicates(); @@ -8542,13 +8522,13 @@ yyreduce: else yymsg(0, "Unknown coherence command"); Free((yyvsp[(2) - (3)].c)); - } + ;} break; case 271: -/* Line 1806 of yacc.c */ -#line 3637 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3639 "Gmsh.y" { if(List_Nbr((yyvsp[(4) - (6)].l)) >= 2){ double d; @@ -8577,37 +8557,37 @@ yyreduce: yymsg(0, "Need at least two points to merge"); ReplaceAllDuplicates(); List_Delete((yyvsp[(4) - (6)].l)); - } + ;} break; case 272: -/* Line 1806 of yacc.c */ -#line 3671 "Gmsh.y" - { (yyval.c) = (char*)"Homology"; } +/* Line 1464 of yacc.c */ +#line 3673 "Gmsh.y" + { (yyval.c) = (char*)"Homology"; ;} break; case 273: -/* Line 1806 of yacc.c */ -#line 3672 "Gmsh.y" - { (yyval.c) = (char*)"Cohomology"; } +/* Line 1464 of yacc.c */ +#line 3674 "Gmsh.y" + { (yyval.c) = (char*)"Cohomology"; ;} break; case 274: -/* Line 1806 of yacc.c */ -#line 3677 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3679 "Gmsh.y" { std::vector<int> domain, subdomain; GModel::current()->addHomologyRequest((yyvsp[(1) - (2)].c), domain, subdomain); - } + ;} break; case 275: -/* Line 1806 of yacc.c */ -#line 3682 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3684 "Gmsh.y" { std::vector<int> domain, subdomain; for(int i = 0; i < List_Nbr((yyvsp[(3) - (5)].l)); i++){ @@ -8617,13 +8597,13 @@ yyreduce: } GModel::current()->addHomologyRequest((yyvsp[(1) - (5)].c), domain, subdomain); List_Delete((yyvsp[(3) - (5)].l)); - } + ;} break; case 276: -/* Line 1806 of yacc.c */ -#line 3693 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3695 "Gmsh.y" { std::vector<int> domain, subdomain; for(int i = 0; i < List_Nbr((yyvsp[(3) - (7)].l)); i++){ @@ -8639,501 +8619,501 @@ yyreduce: GModel::current()->addHomologyRequest((yyvsp[(1) - (7)].c), domain, subdomain); List_Delete((yyvsp[(3) - (7)].l)); List_Delete((yyvsp[(5) - (7)].l)); - } + ;} break; case 277: -/* Line 1806 of yacc.c */ -#line 3714 "Gmsh.y" - { (yyval.d) = (yyvsp[(1) - (1)].d); } +/* Line 1464 of yacc.c */ +#line 3716 "Gmsh.y" + { (yyval.d) = (yyvsp[(1) - (1)].d); ;} break; case 278: -/* Line 1806 of yacc.c */ -#line 3715 "Gmsh.y" - { (yyval.d) = (yyvsp[(2) - (3)].d); } +/* Line 1464 of yacc.c */ +#line 3717 "Gmsh.y" + { (yyval.d) = (yyvsp[(2) - (3)].d); ;} break; case 279: -/* Line 1806 of yacc.c */ -#line 3716 "Gmsh.y" - { (yyval.d) = -(yyvsp[(2) - (2)].d); } +/* Line 1464 of yacc.c */ +#line 3718 "Gmsh.y" + { (yyval.d) = -(yyvsp[(2) - (2)].d); ;} break; case 280: -/* Line 1806 of yacc.c */ -#line 3717 "Gmsh.y" - { (yyval.d) = (yyvsp[(2) - (2)].d); } +/* Line 1464 of yacc.c */ +#line 3719 "Gmsh.y" + { (yyval.d) = (yyvsp[(2) - (2)].d); ;} break; case 281: -/* Line 1806 of yacc.c */ -#line 3718 "Gmsh.y" - { (yyval.d) = !(yyvsp[(2) - (2)].d); } +/* Line 1464 of yacc.c */ +#line 3720 "Gmsh.y" + { (yyval.d) = !(yyvsp[(2) - (2)].d); ;} break; case 282: -/* Line 1806 of yacc.c */ -#line 3719 "Gmsh.y" - { (yyval.d) = (yyvsp[(1) - (3)].d) - (yyvsp[(3) - (3)].d); } +/* Line 1464 of yacc.c */ +#line 3721 "Gmsh.y" + { (yyval.d) = (yyvsp[(1) - (3)].d) - (yyvsp[(3) - (3)].d); ;} break; case 283: -/* Line 1806 of yacc.c */ -#line 3720 "Gmsh.y" - { (yyval.d) = (yyvsp[(1) - (3)].d) + (yyvsp[(3) - (3)].d); } +/* Line 1464 of yacc.c */ +#line 3722 "Gmsh.y" + { (yyval.d) = (yyvsp[(1) - (3)].d) + (yyvsp[(3) - (3)].d); ;} break; case 284: -/* Line 1806 of yacc.c */ -#line 3721 "Gmsh.y" - { (yyval.d) = (yyvsp[(1) - (3)].d) * (yyvsp[(3) - (3)].d); } +/* Line 1464 of yacc.c */ +#line 3723 "Gmsh.y" + { (yyval.d) = (yyvsp[(1) - (3)].d) * (yyvsp[(3) - (3)].d); ;} break; case 285: -/* Line 1806 of yacc.c */ -#line 3723 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3725 "Gmsh.y" { if(!(yyvsp[(3) - (3)].d)) yymsg(0, "Division by zero in '%g / %g'", (yyvsp[(1) - (3)].d), (yyvsp[(3) - (3)].d)); else (yyval.d) = (yyvsp[(1) - (3)].d) / (yyvsp[(3) - (3)].d); - } + ;} break; case 286: -/* Line 1806 of yacc.c */ -#line 3729 "Gmsh.y" - { (yyval.d) = (int)(yyvsp[(1) - (3)].d) % (int)(yyvsp[(3) - (3)].d); } +/* Line 1464 of yacc.c */ +#line 3731 "Gmsh.y" + { (yyval.d) = (int)(yyvsp[(1) - (3)].d) % (int)(yyvsp[(3) - (3)].d); ;} break; case 287: -/* Line 1806 of yacc.c */ -#line 3730 "Gmsh.y" - { (yyval.d) = pow((yyvsp[(1) - (3)].d), (yyvsp[(3) - (3)].d)); } +/* Line 1464 of yacc.c */ +#line 3732 "Gmsh.y" + { (yyval.d) = pow((yyvsp[(1) - (3)].d), (yyvsp[(3) - (3)].d)); ;} break; case 288: -/* Line 1806 of yacc.c */ -#line 3731 "Gmsh.y" - { (yyval.d) = (yyvsp[(1) - (3)].d) < (yyvsp[(3) - (3)].d); } +/* Line 1464 of yacc.c */ +#line 3733 "Gmsh.y" + { (yyval.d) = (yyvsp[(1) - (3)].d) < (yyvsp[(3) - (3)].d); ;} break; case 289: -/* Line 1806 of yacc.c */ -#line 3732 "Gmsh.y" - { (yyval.d) = (yyvsp[(1) - (3)].d) > (yyvsp[(3) - (3)].d); } +/* Line 1464 of yacc.c */ +#line 3734 "Gmsh.y" + { (yyval.d) = (yyvsp[(1) - (3)].d) > (yyvsp[(3) - (3)].d); ;} break; case 290: -/* Line 1806 of yacc.c */ -#line 3733 "Gmsh.y" - { (yyval.d) = (yyvsp[(1) - (3)].d) <= (yyvsp[(3) - (3)].d); } +/* Line 1464 of yacc.c */ +#line 3735 "Gmsh.y" + { (yyval.d) = (yyvsp[(1) - (3)].d) <= (yyvsp[(3) - (3)].d); ;} break; case 291: -/* Line 1806 of yacc.c */ -#line 3734 "Gmsh.y" - { (yyval.d) = (yyvsp[(1) - (3)].d) >= (yyvsp[(3) - (3)].d); } +/* Line 1464 of yacc.c */ +#line 3736 "Gmsh.y" + { (yyval.d) = (yyvsp[(1) - (3)].d) >= (yyvsp[(3) - (3)].d); ;} break; case 292: -/* Line 1806 of yacc.c */ -#line 3735 "Gmsh.y" - { (yyval.d) = (yyvsp[(1) - (3)].d) == (yyvsp[(3) - (3)].d); } +/* Line 1464 of yacc.c */ +#line 3737 "Gmsh.y" + { (yyval.d) = (yyvsp[(1) - (3)].d) == (yyvsp[(3) - (3)].d); ;} break; case 293: -/* Line 1806 of yacc.c */ -#line 3736 "Gmsh.y" - { (yyval.d) = (yyvsp[(1) - (3)].d) != (yyvsp[(3) - (3)].d); } +/* Line 1464 of yacc.c */ +#line 3738 "Gmsh.y" + { (yyval.d) = (yyvsp[(1) - (3)].d) != (yyvsp[(3) - (3)].d); ;} break; case 294: -/* Line 1806 of yacc.c */ -#line 3737 "Gmsh.y" - { (yyval.d) = (yyvsp[(1) - (3)].d) && (yyvsp[(3) - (3)].d); } +/* Line 1464 of yacc.c */ +#line 3739 "Gmsh.y" + { (yyval.d) = (yyvsp[(1) - (3)].d) && (yyvsp[(3) - (3)].d); ;} break; case 295: -/* Line 1806 of yacc.c */ -#line 3738 "Gmsh.y" - { (yyval.d) = (yyvsp[(1) - (3)].d) || (yyvsp[(3) - (3)].d); } +/* Line 1464 of yacc.c */ +#line 3740 "Gmsh.y" + { (yyval.d) = (yyvsp[(1) - (3)].d) || (yyvsp[(3) - (3)].d); ;} break; case 296: -/* Line 1806 of yacc.c */ -#line 3739 "Gmsh.y" - { (yyval.d) = (yyvsp[(1) - (5)].d) ? (yyvsp[(3) - (5)].d) : (yyvsp[(5) - (5)].d); } +/* Line 1464 of yacc.c */ +#line 3741 "Gmsh.y" + { (yyval.d) = (yyvsp[(1) - (5)].d) ? (yyvsp[(3) - (5)].d) : (yyvsp[(5) - (5)].d); ;} break; case 297: -/* Line 1806 of yacc.c */ -#line 3740 "Gmsh.y" - { (yyval.d) = exp((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3742 "Gmsh.y" + { (yyval.d) = exp((yyvsp[(3) - (4)].d)); ;} break; case 298: -/* Line 1806 of yacc.c */ -#line 3741 "Gmsh.y" - { (yyval.d) = log((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3743 "Gmsh.y" + { (yyval.d) = log((yyvsp[(3) - (4)].d)); ;} break; case 299: -/* Line 1806 of yacc.c */ -#line 3742 "Gmsh.y" - { (yyval.d) = log10((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3744 "Gmsh.y" + { (yyval.d) = log10((yyvsp[(3) - (4)].d)); ;} break; case 300: -/* Line 1806 of yacc.c */ -#line 3743 "Gmsh.y" - { (yyval.d) = sqrt((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3745 "Gmsh.y" + { (yyval.d) = sqrt((yyvsp[(3) - (4)].d)); ;} break; case 301: -/* Line 1806 of yacc.c */ -#line 3744 "Gmsh.y" - { (yyval.d) = sin((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3746 "Gmsh.y" + { (yyval.d) = sin((yyvsp[(3) - (4)].d)); ;} break; case 302: -/* Line 1806 of yacc.c */ -#line 3745 "Gmsh.y" - { (yyval.d) = asin((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3747 "Gmsh.y" + { (yyval.d) = asin((yyvsp[(3) - (4)].d)); ;} break; case 303: -/* Line 1806 of yacc.c */ -#line 3746 "Gmsh.y" - { (yyval.d) = cos((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3748 "Gmsh.y" + { (yyval.d) = cos((yyvsp[(3) - (4)].d)); ;} break; case 304: -/* Line 1806 of yacc.c */ -#line 3747 "Gmsh.y" - { (yyval.d) = acos((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3749 "Gmsh.y" + { (yyval.d) = acos((yyvsp[(3) - (4)].d)); ;} break; case 305: -/* Line 1806 of yacc.c */ -#line 3748 "Gmsh.y" - { (yyval.d) = tan((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3750 "Gmsh.y" + { (yyval.d) = tan((yyvsp[(3) - (4)].d)); ;} break; case 306: -/* Line 1806 of yacc.c */ -#line 3749 "Gmsh.y" - { (yyval.d) = atan((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3751 "Gmsh.y" + { (yyval.d) = atan((yyvsp[(3) - (4)].d)); ;} break; case 307: -/* Line 1806 of yacc.c */ -#line 3750 "Gmsh.y" - { (yyval.d) = atan2((yyvsp[(3) - (6)].d), (yyvsp[(5) - (6)].d));} +/* Line 1464 of yacc.c */ +#line 3752 "Gmsh.y" + { (yyval.d) = atan2((yyvsp[(3) - (6)].d), (yyvsp[(5) - (6)].d));;} break; case 308: -/* Line 1806 of yacc.c */ -#line 3751 "Gmsh.y" - { (yyval.d) = sinh((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3753 "Gmsh.y" + { (yyval.d) = sinh((yyvsp[(3) - (4)].d)); ;} break; case 309: -/* Line 1806 of yacc.c */ -#line 3752 "Gmsh.y" - { (yyval.d) = cosh((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3754 "Gmsh.y" + { (yyval.d) = cosh((yyvsp[(3) - (4)].d)); ;} break; case 310: -/* Line 1806 of yacc.c */ -#line 3753 "Gmsh.y" - { (yyval.d) = tanh((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3755 "Gmsh.y" + { (yyval.d) = tanh((yyvsp[(3) - (4)].d)); ;} break; case 311: -/* Line 1806 of yacc.c */ -#line 3754 "Gmsh.y" - { (yyval.d) = fabs((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3756 "Gmsh.y" + { (yyval.d) = fabs((yyvsp[(3) - (4)].d)); ;} break; case 312: -/* Line 1806 of yacc.c */ -#line 3755 "Gmsh.y" - { (yyval.d) = floor((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3757 "Gmsh.y" + { (yyval.d) = floor((yyvsp[(3) - (4)].d)); ;} break; case 313: -/* Line 1806 of yacc.c */ -#line 3756 "Gmsh.y" - { (yyval.d) = ceil((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3758 "Gmsh.y" + { (yyval.d) = ceil((yyvsp[(3) - (4)].d)); ;} break; case 314: -/* Line 1806 of yacc.c */ -#line 3757 "Gmsh.y" - { (yyval.d) = fmod((yyvsp[(3) - (6)].d), (yyvsp[(5) - (6)].d)); } +/* Line 1464 of yacc.c */ +#line 3759 "Gmsh.y" + { (yyval.d) = fmod((yyvsp[(3) - (6)].d), (yyvsp[(5) - (6)].d)); ;} break; case 315: -/* Line 1806 of yacc.c */ -#line 3758 "Gmsh.y" - { (yyval.d) = fmod((yyvsp[(3) - (6)].d), (yyvsp[(5) - (6)].d)); } +/* Line 1464 of yacc.c */ +#line 3760 "Gmsh.y" + { (yyval.d) = fmod((yyvsp[(3) - (6)].d), (yyvsp[(5) - (6)].d)); ;} break; case 316: -/* Line 1806 of yacc.c */ -#line 3759 "Gmsh.y" - { (yyval.d) = sqrt((yyvsp[(3) - (6)].d) * (yyvsp[(3) - (6)].d) + (yyvsp[(5) - (6)].d) * (yyvsp[(5) - (6)].d)); } +/* Line 1464 of yacc.c */ +#line 3761 "Gmsh.y" + { (yyval.d) = sqrt((yyvsp[(3) - (6)].d) * (yyvsp[(3) - (6)].d) + (yyvsp[(5) - (6)].d) * (yyvsp[(5) - (6)].d)); ;} break; case 317: -/* Line 1806 of yacc.c */ -#line 3760 "Gmsh.y" - { (yyval.d) = (yyvsp[(3) - (4)].d) * (double)rand() / (double)RAND_MAX; } +/* Line 1464 of yacc.c */ +#line 3762 "Gmsh.y" + { (yyval.d) = (yyvsp[(3) - (4)].d) * (double)rand() / (double)RAND_MAX; ;} break; case 318: -/* Line 1806 of yacc.c */ -#line 3762 "Gmsh.y" - { (yyval.d) = exp((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3764 "Gmsh.y" + { (yyval.d) = exp((yyvsp[(3) - (4)].d)); ;} break; case 319: -/* Line 1806 of yacc.c */ -#line 3763 "Gmsh.y" - { (yyval.d) = log((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3765 "Gmsh.y" + { (yyval.d) = log((yyvsp[(3) - (4)].d)); ;} break; case 320: -/* Line 1806 of yacc.c */ -#line 3764 "Gmsh.y" - { (yyval.d) = log10((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3766 "Gmsh.y" + { (yyval.d) = log10((yyvsp[(3) - (4)].d)); ;} break; case 321: -/* Line 1806 of yacc.c */ -#line 3765 "Gmsh.y" - { (yyval.d) = sqrt((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3767 "Gmsh.y" + { (yyval.d) = sqrt((yyvsp[(3) - (4)].d)); ;} break; case 322: -/* Line 1806 of yacc.c */ -#line 3766 "Gmsh.y" - { (yyval.d) = sin((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3768 "Gmsh.y" + { (yyval.d) = sin((yyvsp[(3) - (4)].d)); ;} break; case 323: -/* Line 1806 of yacc.c */ -#line 3767 "Gmsh.y" - { (yyval.d) = asin((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3769 "Gmsh.y" + { (yyval.d) = asin((yyvsp[(3) - (4)].d)); ;} break; case 324: -/* Line 1806 of yacc.c */ -#line 3768 "Gmsh.y" - { (yyval.d) = cos((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3770 "Gmsh.y" + { (yyval.d) = cos((yyvsp[(3) - (4)].d)); ;} break; case 325: -/* Line 1806 of yacc.c */ -#line 3769 "Gmsh.y" - { (yyval.d) = acos((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3771 "Gmsh.y" + { (yyval.d) = acos((yyvsp[(3) - (4)].d)); ;} break; case 326: -/* Line 1806 of yacc.c */ -#line 3770 "Gmsh.y" - { (yyval.d) = tan((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3772 "Gmsh.y" + { (yyval.d) = tan((yyvsp[(3) - (4)].d)); ;} break; case 327: -/* Line 1806 of yacc.c */ -#line 3771 "Gmsh.y" - { (yyval.d) = atan((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3773 "Gmsh.y" + { (yyval.d) = atan((yyvsp[(3) - (4)].d)); ;} break; case 328: -/* Line 1806 of yacc.c */ -#line 3772 "Gmsh.y" - { (yyval.d) = atan2((yyvsp[(3) - (6)].d), (yyvsp[(5) - (6)].d));} +/* Line 1464 of yacc.c */ +#line 3774 "Gmsh.y" + { (yyval.d) = atan2((yyvsp[(3) - (6)].d), (yyvsp[(5) - (6)].d));;} break; case 329: -/* Line 1806 of yacc.c */ -#line 3773 "Gmsh.y" - { (yyval.d) = sinh((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3775 "Gmsh.y" + { (yyval.d) = sinh((yyvsp[(3) - (4)].d)); ;} break; case 330: -/* Line 1806 of yacc.c */ -#line 3774 "Gmsh.y" - { (yyval.d) = cosh((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3776 "Gmsh.y" + { (yyval.d) = cosh((yyvsp[(3) - (4)].d)); ;} break; case 331: -/* Line 1806 of yacc.c */ -#line 3775 "Gmsh.y" - { (yyval.d) = tanh((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3777 "Gmsh.y" + { (yyval.d) = tanh((yyvsp[(3) - (4)].d)); ;} break; case 332: -/* Line 1806 of yacc.c */ -#line 3776 "Gmsh.y" - { (yyval.d) = fabs((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3778 "Gmsh.y" + { (yyval.d) = fabs((yyvsp[(3) - (4)].d)); ;} break; case 333: -/* Line 1806 of yacc.c */ -#line 3777 "Gmsh.y" - { (yyval.d) = floor((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3779 "Gmsh.y" + { (yyval.d) = floor((yyvsp[(3) - (4)].d)); ;} break; case 334: -/* Line 1806 of yacc.c */ -#line 3778 "Gmsh.y" - { (yyval.d) = ceil((yyvsp[(3) - (4)].d)); } +/* Line 1464 of yacc.c */ +#line 3780 "Gmsh.y" + { (yyval.d) = ceil((yyvsp[(3) - (4)].d)); ;} break; case 335: -/* Line 1806 of yacc.c */ -#line 3779 "Gmsh.y" - { (yyval.d) = fmod((yyvsp[(3) - (6)].d), (yyvsp[(5) - (6)].d)); } +/* Line 1464 of yacc.c */ +#line 3781 "Gmsh.y" + { (yyval.d) = fmod((yyvsp[(3) - (6)].d), (yyvsp[(5) - (6)].d)); ;} break; case 336: -/* Line 1806 of yacc.c */ -#line 3780 "Gmsh.y" - { (yyval.d) = fmod((yyvsp[(3) - (6)].d), (yyvsp[(5) - (6)].d)); } +/* Line 1464 of yacc.c */ +#line 3782 "Gmsh.y" + { (yyval.d) = fmod((yyvsp[(3) - (6)].d), (yyvsp[(5) - (6)].d)); ;} break; case 337: -/* Line 1806 of yacc.c */ -#line 3781 "Gmsh.y" - { (yyval.d) = sqrt((yyvsp[(3) - (6)].d) * (yyvsp[(3) - (6)].d) + (yyvsp[(5) - (6)].d) * (yyvsp[(5) - (6)].d)); } +/* Line 1464 of yacc.c */ +#line 3783 "Gmsh.y" + { (yyval.d) = sqrt((yyvsp[(3) - (6)].d) * (yyvsp[(3) - (6)].d) + (yyvsp[(5) - (6)].d) * (yyvsp[(5) - (6)].d)); ;} break; case 338: -/* Line 1806 of yacc.c */ -#line 3782 "Gmsh.y" - { (yyval.d) = (yyvsp[(3) - (4)].d) * (double)rand() / (double)RAND_MAX; } +/* Line 1464 of yacc.c */ +#line 3784 "Gmsh.y" + { (yyval.d) = (yyvsp[(3) - (4)].d) * (double)rand() / (double)RAND_MAX; ;} break; case 339: -/* Line 1806 of yacc.c */ -#line 3791 "Gmsh.y" - { (yyval.d) = (yyvsp[(1) - (1)].d); } +/* Line 1464 of yacc.c */ +#line 3793 "Gmsh.y" + { (yyval.d) = (yyvsp[(1) - (1)].d); ;} break; case 340: -/* Line 1806 of yacc.c */ -#line 3792 "Gmsh.y" - { (yyval.d) = 3.141592653589793; } +/* Line 1464 of yacc.c */ +#line 3794 "Gmsh.y" + { (yyval.d) = 3.141592653589793; ;} break; case 341: -/* Line 1806 of yacc.c */ -#line 3793 "Gmsh.y" - { (yyval.d) = Msg::GetCommRank(); } +/* Line 1464 of yacc.c */ +#line 3795 "Gmsh.y" + { (yyval.d) = Msg::GetCommRank(); ;} break; case 342: -/* Line 1806 of yacc.c */ -#line 3794 "Gmsh.y" - { (yyval.d) = Msg::GetCommSize(); } +/* Line 1464 of yacc.c */ +#line 3796 "Gmsh.y" + { (yyval.d) = Msg::GetCommSize(); ;} break; case 343: -/* Line 1806 of yacc.c */ -#line 3795 "Gmsh.y" - { (yyval.d) = GetGmshMajorVersion(); } +/* Line 1464 of yacc.c */ +#line 3797 "Gmsh.y" + { (yyval.d) = GetGmshMajorVersion(); ;} break; case 344: -/* Line 1806 of yacc.c */ -#line 3796 "Gmsh.y" - { (yyval.d) = GetGmshMinorVersion(); } +/* Line 1464 of yacc.c */ +#line 3798 "Gmsh.y" + { (yyval.d) = GetGmshMinorVersion(); ;} break; case 345: -/* Line 1806 of yacc.c */ -#line 3797 "Gmsh.y" - { (yyval.d) = GetGmshPatchVersion(); } +/* Line 1464 of yacc.c */ +#line 3799 "Gmsh.y" + { (yyval.d) = GetGmshPatchVersion(); ;} break; case 346: -/* Line 1806 of yacc.c */ -#line 3802 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3804 "Gmsh.y" { if(!gmsh_yysymbols.count((yyvsp[(1) - (1)].c))){ yymsg(0, "Unknown variable '%s'", (yyvsp[(1) - (1)].c)); @@ -9149,13 +9129,13 @@ yyreduce: (yyval.d) = s.value[0]; } Free((yyvsp[(1) - (1)].c)); - } + ;} break; case 347: -/* Line 1806 of yacc.c */ -#line 3822 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3824 "Gmsh.y" { char tmpstring[1024]; sprintf(tmpstring, "%s_%d", (yyvsp[(1) - (5)].c), (int)(yyvsp[(4) - (5)].d)) ; @@ -9173,13 +9153,13 @@ yyreduce: (yyval.d) = s.value[0]; } Free((yyvsp[(1) - (5)].c)); - } + ;} break; case 348: -/* Line 1806 of yacc.c */ -#line 3841 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3843 "Gmsh.y" { int index = (int)(yyvsp[(3) - (4)].d); if(!gmsh_yysymbols.count((yyvsp[(1) - (4)].c))){ @@ -9196,13 +9176,13 @@ yyreduce: (yyval.d) = s.value[index]; } Free((yyvsp[(1) - (4)].c)); - } + ;} break; case 349: -/* Line 1806 of yacc.c */ -#line 3859 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3861 "Gmsh.y" { if(!gmsh_yysymbols.count((yyvsp[(2) - (4)].c))){ yymsg(0, "Unknown variable '%s'", (yyvsp[(2) - (4)].c)); @@ -9213,13 +9193,13 @@ yyreduce: (yyval.d) = s.value.size(); } Free((yyvsp[(2) - (4)].c)); - } + ;} break; case 350: -/* Line 1806 of yacc.c */ -#line 3871 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3873 "Gmsh.y" { if(!gmsh_yysymbols.count((yyvsp[(1) - (2)].c))){ yymsg(0, "Unknown variable '%s'", (yyvsp[(1) - (2)].c)); @@ -9235,13 +9215,13 @@ yyreduce: (yyval.d) = (s.value[0] += (yyvsp[(2) - (2)].i)); } Free((yyvsp[(1) - (2)].c)); - } + ;} break; case 351: -/* Line 1806 of yacc.c */ -#line 3888 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3890 "Gmsh.y" { int index = (int)(yyvsp[(3) - (5)].d); if(!gmsh_yysymbols.count((yyvsp[(1) - (5)].c))){ @@ -9258,33 +9238,33 @@ yyreduce: (yyval.d) = (s.value[index] += (yyvsp[(5) - (5)].i)); } Free((yyvsp[(1) - (5)].c)); - } + ;} break; case 352: -/* Line 1806 of yacc.c */ -#line 3909 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3911 "Gmsh.y" { NumberOption(GMSH_GET, (yyvsp[(1) - (3)].c), 0, (yyvsp[(3) - (3)].c), (yyval.d)); Free((yyvsp[(1) - (3)].c)); Free((yyvsp[(3) - (3)].c)); - } + ;} break; case 353: -/* Line 1806 of yacc.c */ -#line 3914 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3916 "Gmsh.y" { NumberOption(GMSH_GET, (yyvsp[(1) - (6)].c), (int)(yyvsp[(3) - (6)].d), (yyvsp[(6) - (6)].c), (yyval.d)); Free((yyvsp[(1) - (6)].c)); Free((yyvsp[(6) - (6)].c)); - } + ;} break; case 354: -/* Line 1806 of yacc.c */ -#line 3919 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3921 "Gmsh.y" { double d = 0.; if(NumberOption(GMSH_GET, (yyvsp[(1) - (4)].c), 0, (yyvsp[(3) - (4)].c), d)){ @@ -9293,13 +9273,13 @@ yyreduce: (yyval.d) = d; } Free((yyvsp[(1) - (4)].c)); Free((yyvsp[(3) - (4)].c)); - } + ;} break; case 355: -/* Line 1806 of yacc.c */ -#line 3929 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3931 "Gmsh.y" { double d = 0.; if(NumberOption(GMSH_GET, (yyvsp[(1) - (7)].c), (int)(yyvsp[(3) - (7)].d), (yyvsp[(6) - (7)].c), d)){ @@ -9308,196 +9288,196 @@ yyreduce: (yyval.d) = d; } Free((yyvsp[(1) - (7)].c)); Free((yyvsp[(6) - (7)].c)); - } + ;} break; case 356: -/* Line 1806 of yacc.c */ -#line 3939 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3941 "Gmsh.y" { (yyval.d) = Msg::GetValue((yyvsp[(3) - (6)].c), (yyvsp[(5) - (6)].d)); Free((yyvsp[(3) - (6)].c)); - } + ;} break; case 357: -/* Line 1806 of yacc.c */ -#line 3947 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3949 "Gmsh.y" { memcpy((yyval.v), (yyvsp[(1) - (1)].v), 5*sizeof(double)); - } + ;} break; case 358: -/* Line 1806 of yacc.c */ -#line 3951 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3953 "Gmsh.y" { for(int i = 0; i < 5; i++) (yyval.v)[i] = -(yyvsp[(2) - (2)].v)[i]; - } + ;} break; case 359: -/* Line 1806 of yacc.c */ -#line 3955 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3957 "Gmsh.y" { for(int i = 0; i < 5; i++) (yyval.v)[i] = (yyvsp[(2) - (2)].v)[i]; - } + ;} break; case 360: -/* Line 1806 of yacc.c */ -#line 3959 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3961 "Gmsh.y" { for(int i = 0; i < 5; i++) (yyval.v)[i] = (yyvsp[(1) - (3)].v)[i] - (yyvsp[(3) - (3)].v)[i]; - } + ;} break; case 361: -/* Line 1806 of yacc.c */ -#line 3963 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3965 "Gmsh.y" { for(int i = 0; i < 5; i++) (yyval.v)[i] = (yyvsp[(1) - (3)].v)[i] + (yyvsp[(3) - (3)].v)[i]; - } + ;} break; case 362: -/* Line 1806 of yacc.c */ -#line 3970 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3972 "Gmsh.y" { (yyval.v)[0] = (yyvsp[(2) - (11)].d); (yyval.v)[1] = (yyvsp[(4) - (11)].d); (yyval.v)[2] = (yyvsp[(6) - (11)].d); (yyval.v)[3] = (yyvsp[(8) - (11)].d); (yyval.v)[4] = (yyvsp[(10) - (11)].d); - } + ;} break; case 363: -/* Line 1806 of yacc.c */ -#line 3974 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3976 "Gmsh.y" { (yyval.v)[0] = (yyvsp[(2) - (9)].d); (yyval.v)[1] = (yyvsp[(4) - (9)].d); (yyval.v)[2] = (yyvsp[(6) - (9)].d); (yyval.v)[3] = (yyvsp[(8) - (9)].d); (yyval.v)[4] = 1.0; - } + ;} break; case 364: -/* Line 1806 of yacc.c */ -#line 3978 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3980 "Gmsh.y" { (yyval.v)[0] = (yyvsp[(2) - (7)].d); (yyval.v)[1] = (yyvsp[(4) - (7)].d); (yyval.v)[2] = (yyvsp[(6) - (7)].d); (yyval.v)[3] = 0.0; (yyval.v)[4] = 1.0; - } + ;} break; case 365: -/* Line 1806 of yacc.c */ -#line 3982 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3984 "Gmsh.y" { (yyval.v)[0] = (yyvsp[(2) - (7)].d); (yyval.v)[1] = (yyvsp[(4) - (7)].d); (yyval.v)[2] = (yyvsp[(6) - (7)].d); (yyval.v)[3] = 0.0; (yyval.v)[4] = 1.0; - } + ;} break; case 366: -/* Line 1806 of yacc.c */ -#line 3989 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3991 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(List_T*)); List_Add((yyval.l), &((yyvsp[(1) - (1)].l))); - } + ;} break; case 367: -/* Line 1806 of yacc.c */ -#line 3994 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 3996 "Gmsh.y" { List_Add((yyval.l), &((yyvsp[(3) - (3)].l))); - } + ;} break; case 368: -/* Line 1806 of yacc.c */ -#line 4001 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4003 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(double)); List_Add((yyval.l), &((yyvsp[(1) - (1)].d))); - } + ;} break; case 369: -/* Line 1806 of yacc.c */ -#line 4006 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4008 "Gmsh.y" { (yyval.l) = (yyvsp[(1) - (1)].l); - } + ;} break; case 370: -/* Line 1806 of yacc.c */ -#line 4010 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4012 "Gmsh.y" { // creates an empty list (yyval.l) = List_Create(2, 1, sizeof(double)); - } + ;} break; case 371: -/* Line 1806 of yacc.c */ -#line 4015 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4017 "Gmsh.y" { (yyval.l) = (yyvsp[(2) - (3)].l); - } + ;} break; case 372: -/* Line 1806 of yacc.c */ -#line 4019 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4021 "Gmsh.y" { (yyval.l) = (yyvsp[(3) - (4)].l); for(int i = 0; i < List_Nbr((yyval.l)); i++){ double *pd = (double*)List_Pointer((yyval.l), i); (*pd) = - (*pd); } - } + ;} break; case 373: -/* Line 1806 of yacc.c */ -#line 4027 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4029 "Gmsh.y" { (yyval.l) = (yyvsp[(4) - (5)].l); for(int i = 0; i < List_Nbr((yyval.l)); i++){ double *pd = (double*)List_Pointer((yyval.l), i); (*pd) *= (yyvsp[(1) - (5)].d); } - } + ;} break; case 374: -/* Line 1806 of yacc.c */ -#line 4038 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4040 "Gmsh.y" { (yyval.l) = (yyvsp[(1) - (1)].l); - } + ;} break; case 375: -/* Line 1806 of yacc.c */ -#line 4042 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4044 "Gmsh.y" { if(!strcmp((yyvsp[(1) - (1)].c), "*") || !strcmp((yyvsp[(1) - (1)].c), "all")) (yyval.l) = 0; @@ -9505,51 +9485,51 @@ yyreduce: yyerror("Unknown special string for list replacement"); (yyval.l) = List_Create(2, 1, sizeof(double)); } - } + ;} break; case 376: -/* Line 1806 of yacc.c */ -#line 4054 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4056 "Gmsh.y" { (yyval.l) = (yyvsp[(2) - (2)].l); for(int i = 0; i < List_Nbr((yyval.l)); i++){ double *pd = (double*)List_Pointer((yyval.l), i); (*pd) = - (*pd); } - } + ;} break; case 377: -/* Line 1806 of yacc.c */ -#line 4062 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4064 "Gmsh.y" { (yyval.l) = (yyvsp[(3) - (3)].l); for(int i = 0; i < List_Nbr((yyval.l)); i++){ double *pd = (double*)List_Pointer((yyval.l), i); (*pd) *= (yyvsp[(1) - (3)].d); } - } + ;} break; case 378: -/* Line 1806 of yacc.c */ -#line 4070 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4072 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(double)); for(double d = (yyvsp[(1) - (3)].d); ((yyvsp[(1) - (3)].d) < (yyvsp[(3) - (3)].d)) ? (d <= (yyvsp[(3) - (3)].d)) : (d >= (yyvsp[(3) - (3)].d)); ((yyvsp[(1) - (3)].d) < (yyvsp[(3) - (3)].d)) ? (d += 1.) : (d -= 1.)) List_Add((yyval.l), &d); - } + ;} break; case 379: -/* Line 1806 of yacc.c */ -#line 4077 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4079 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(double)); if(!(yyvsp[(5) - (5)].d) || ((yyvsp[(1) - (5)].d) < (yyvsp[(3) - (5)].d) && (yyvsp[(5) - (5)].d) < 0) || ((yyvsp[(1) - (5)].d) > (yyvsp[(3) - (5)].d) && (yyvsp[(5) - (5)].d) > 0)){ @@ -9559,13 +9539,13 @@ yyreduce: else for(double d = (yyvsp[(1) - (5)].d); ((yyvsp[(5) - (5)].d) > 0) ? (d <= (yyvsp[(3) - (5)].d)) : (d >= (yyvsp[(3) - (5)].d)); d += (yyvsp[(5) - (5)].d)) List_Add((yyval.l), &d); - } + ;} break; case 380: -/* Line 1806 of yacc.c */ -#line 4088 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4090 "Gmsh.y" { // Returns the coordinates of a point and fills a list with it. // This allows to ensure e.g. that relative point positions are @@ -9584,49 +9564,49 @@ yyreduce: List_Add((yyval.l), &v->Pos.Y); List_Add((yyval.l), &v->Pos.Z); } - } + ;} break; case 381: -/* Line 1806 of yacc.c */ -#line 4108 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4110 "Gmsh.y" { (yyval.l) = GetAllEntityNumbers(0); - } + ;} break; case 382: -/* Line 1806 of yacc.c */ -#line 4112 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4114 "Gmsh.y" { (yyval.l) = GetAllEntityNumbers(1); - } + ;} break; case 383: -/* Line 1806 of yacc.c */ -#line 4116 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4118 "Gmsh.y" { (yyval.l) = GetAllEntityNumbers(2); - } + ;} break; case 384: -/* Line 1806 of yacc.c */ -#line 4120 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4122 "Gmsh.y" { (yyval.l) = GetAllEntityNumbers(3); - } + ;} break; case 385: -/* Line 1806 of yacc.c */ -#line 4124 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4126 "Gmsh.y" { (yyval.l) = List_Create(List_Nbr((yyvsp[(1) - (1)].l)), 1, sizeof(double)); for(int i = 0; i < List_Nbr((yyvsp[(1) - (1)].l)); i++){ @@ -9635,13 +9615,13 @@ yyreduce: List_Add((yyval.l), &d); } List_Delete((yyvsp[(1) - (1)].l)); - } + ;} break; case 386: -/* Line 1806 of yacc.c */ -#line 4134 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4136 "Gmsh.y" { (yyval.l) = List_Create(List_Nbr((yyvsp[(1) - (1)].l)), 1, sizeof(double)); for(int i = 0; i < List_Nbr((yyvsp[(1) - (1)].l)); i++){ @@ -9650,13 +9630,13 @@ yyreduce: List_Add((yyval.l), &d); } List_Delete((yyvsp[(1) - (1)].l)); - } + ;} break; case 387: -/* Line 1806 of yacc.c */ -#line 4144 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4146 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(double)); if(!gmsh_yysymbols.count((yyvsp[(1) - (3)].c))) @@ -9667,13 +9647,13 @@ yyreduce: List_Add((yyval.l), &s.value[i]); } Free((yyvsp[(1) - (3)].c)); - } + ;} break; case 388: -/* Line 1806 of yacc.c */ -#line 4156 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4158 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(double)); if(!gmsh_yysymbols.count((yyvsp[(3) - (4)].c))) @@ -9684,13 +9664,13 @@ yyreduce: List_Add((yyval.l), &s.value[i]); } Free((yyvsp[(3) - (4)].c)); - } + ;} break; case 389: -/* Line 1806 of yacc.c */ -#line 4168 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4170 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(double)); if(!gmsh_yysymbols.count((yyvsp[(1) - (6)].c))) @@ -9707,41 +9687,41 @@ yyreduce: } Free((yyvsp[(1) - (6)].c)); List_Delete((yyvsp[(4) - (6)].l)); - } + ;} break; case 390: -/* Line 1806 of yacc.c */ -#line 4189 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4191 "Gmsh.y" { (yyval.l) = List_Create(2, 1, sizeof(double)); List_Add((yyval.l), &((yyvsp[(1) - (1)].d))); - } + ;} break; case 391: -/* Line 1806 of yacc.c */ -#line 4194 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4196 "Gmsh.y" { (yyval.l) = (yyvsp[(1) - (1)].l); - } + ;} break; case 392: -/* Line 1806 of yacc.c */ -#line 4198 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4200 "Gmsh.y" { List_Add((yyval.l), &((yyvsp[(3) - (3)].d))); - } + ;} break; case 393: -/* Line 1806 of yacc.c */ -#line 4202 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4204 "Gmsh.y" { for(int i = 0; i < List_Nbr((yyvsp[(3) - (3)].l)); i++){ double d; @@ -9749,64 +9729,64 @@ yyreduce: List_Add((yyval.l), &d); } List_Delete((yyvsp[(3) - (3)].l)); - } + ;} break; case 394: -/* Line 1806 of yacc.c */ -#line 4214 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4216 "Gmsh.y" { (yyval.u) = CTX::instance()->packColor((int)(yyvsp[(2) - (9)].d), (int)(yyvsp[(4) - (9)].d), (int)(yyvsp[(6) - (9)].d), (int)(yyvsp[(8) - (9)].d)); - } + ;} break; case 395: -/* Line 1806 of yacc.c */ -#line 4218 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4220 "Gmsh.y" { (yyval.u) = CTX::instance()->packColor((int)(yyvsp[(2) - (7)].d), (int)(yyvsp[(4) - (7)].d), (int)(yyvsp[(6) - (7)].d), 255); - } + ;} break; case 396: -/* Line 1806 of yacc.c */ -#line 4230 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4232 "Gmsh.y" { int flag; (yyval.u) = GetColorForString(ColorString, -1, (yyvsp[(1) - (1)].c), &flag); if(flag) yymsg(0, "Unknown color '%s'", (yyvsp[(1) - (1)].c)); Free((yyvsp[(1) - (1)].c)); - } + ;} break; case 397: -/* Line 1806 of yacc.c */ -#line 4237 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4239 "Gmsh.y" { unsigned int val = 0; ColorOption(GMSH_GET, (yyvsp[(1) - (5)].c), 0, (yyvsp[(5) - (5)].c), val); (yyval.u) = val; Free((yyvsp[(1) - (5)].c)); Free((yyvsp[(5) - (5)].c)); - } + ;} break; case 398: -/* Line 1806 of yacc.c */ -#line 4247 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4249 "Gmsh.y" { (yyval.l) = (yyvsp[(2) - (3)].l); - } + ;} break; case 399: -/* Line 1806 of yacc.c */ -#line 4251 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4253 "Gmsh.y" { (yyval.l) = List_Create(256, 10, sizeof(unsigned int)); GmshColorTable *ct = GetColorTable((int)(yyvsp[(3) - (6)].d)); @@ -9817,41 +9797,41 @@ yyreduce: List_Add((yyval.l), &ct->table[i]); } Free((yyvsp[(1) - (6)].c)); - } + ;} break; case 400: -/* Line 1806 of yacc.c */ -#line 4266 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4268 "Gmsh.y" { (yyval.l) = List_Create(256, 10, sizeof(unsigned int)); List_Add((yyval.l), &((yyvsp[(1) - (1)].u))); - } + ;} break; case 401: -/* Line 1806 of yacc.c */ -#line 4271 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4273 "Gmsh.y" { List_Add((yyval.l), &((yyvsp[(3) - (3)].u))); - } + ;} break; case 402: -/* Line 1806 of yacc.c */ -#line 4278 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4280 "Gmsh.y" { (yyval.c) = (yyvsp[(1) - (1)].c); - } + ;} break; case 403: -/* Line 1806 of yacc.c */ -#line 4282 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4284 "Gmsh.y" { if(!gmsh_yystringsymbols.count((yyvsp[(1) - (1)].c))){ yymsg(0, "Unknown string variable '%s'", (yyvsp[(1) - (1)].c)); @@ -9863,100 +9843,100 @@ yyreduce: strcpy((yyval.c), val.c_str()); Free((yyvsp[(1) - (1)].c)); } - } + ;} break; case 404: -/* Line 1806 of yacc.c */ -#line 4295 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4297 "Gmsh.y" { std::string out; StringOption(GMSH_GET, (yyvsp[(1) - (3)].c), 0, (yyvsp[(3) - (3)].c), out); (yyval.c) = (char*)Malloc((out.size() + 1) * sizeof(char)); strcpy((yyval.c), out.c_str()); Free((yyvsp[(1) - (3)].c)); Free((yyvsp[(3) - (3)].c)); - } + ;} break; case 405: -/* Line 1806 of yacc.c */ -#line 4303 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4305 "Gmsh.y" { std::string out; StringOption(GMSH_GET, (yyvsp[(1) - (6)].c), (int)(yyvsp[(3) - (6)].d), (yyvsp[(6) - (6)].c), out); (yyval.c) = (char*)Malloc((out.size() + 1) * sizeof(char)); strcpy((yyval.c), out.c_str()); Free((yyvsp[(1) - (6)].c)); Free((yyvsp[(6) - (6)].c)); - } + ;} break; case 406: -/* Line 1806 of yacc.c */ -#line 4314 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4316 "Gmsh.y" { (yyval.c) = (yyvsp[(1) - (1)].c); - } + ;} break; case 407: -/* Line 1806 of yacc.c */ -#line 4318 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4320 "Gmsh.y" { (yyval.c) = (char *)Malloc(32 * sizeof(char)); time_t now; time(&now); strcpy((yyval.c), ctime(&now)); (yyval.c)[strlen((yyval.c)) - 1] = '\0'; - } + ;} break; case 408: -/* Line 1806 of yacc.c */ -#line 4326 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4328 "Gmsh.y" { const char *env = GetEnvironmentVar((yyvsp[(3) - (4)].c)); if(!env) env = ""; (yyval.c) = (char *)Malloc((sizeof(env) + 1) * sizeof(char)); strcpy((yyval.c), env); Free((yyvsp[(3) - (4)].c)); - } + ;} break; case 409: -/* Line 1806 of yacc.c */ -#line 4334 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4336 "Gmsh.y" { std::string s = Msg::GetString((yyvsp[(3) - (6)].c), (yyvsp[(5) - (6)].c)); (yyval.c) = (char *)Malloc((s.size() + 1) * sizeof(char)); strcpy((yyval.c), s.c_str()); Free((yyvsp[(3) - (6)].c)); Free((yyvsp[(5) - (6)].c)); - } + ;} break; case 410: -/* Line 1806 of yacc.c */ -#line 4342 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4344 "Gmsh.y" { (yyval.c) = (char *)Malloc((strlen((yyvsp[(3) - (6)].c)) + strlen((yyvsp[(5) - (6)].c)) + 1) * sizeof(char)); strcpy((yyval.c), (yyvsp[(3) - (6)].c)); strcat((yyval.c), (yyvsp[(5) - (6)].c)); Free((yyvsp[(3) - (6)].c)); Free((yyvsp[(5) - (6)].c)); - } + ;} break; case 411: -/* Line 1806 of yacc.c */ -#line 4350 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4352 "Gmsh.y" { (yyval.c) = (char *)Malloc((strlen((yyvsp[(3) - (4)].c)) + 1) * sizeof(char)); int i; @@ -9969,13 +9949,13 @@ yyreduce: } if(i <= 0) strcpy((yyval.c), (yyvsp[(3) - (4)].c)); Free((yyvsp[(3) - (4)].c)); - } + ;} break; case 412: -/* Line 1806 of yacc.c */ -#line 4364 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4366 "Gmsh.y" { (yyval.c) = (char *)Malloc((strlen((yyvsp[(3) - (4)].c)) + 1) * sizeof(char)); int i; @@ -9988,22 +9968,22 @@ yyreduce: else strcpy((yyval.c), &(yyvsp[(3) - (4)].c)[i+1]); Free((yyvsp[(3) - (4)].c)); - } + ;} break; case 413: -/* Line 1806 of yacc.c */ -#line 4378 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4380 "Gmsh.y" { (yyval.c) = (yyvsp[(3) - (4)].c); - } + ;} break; case 414: -/* Line 1806 of yacc.c */ -#line 4382 "Gmsh.y" +/* Line 1464 of yacc.c */ +#line 4384 "Gmsh.y" { char tmpstring[1024]; int i = PrintListOfDouble((yyvsp[(3) - (6)].c), (yyvsp[(5) - (6)].l), tmpstring); @@ -10021,26 +10001,15 @@ yyreduce: Free((yyvsp[(3) - (6)].c)); } List_Delete((yyvsp[(5) - (6)].l)); - } + ;} break; -/* Line 1806 of yacc.c */ -#line 10031 "Gmsh.tab.cpp" +/* Line 1464 of yacc.c */ +#line 10011 "Gmsh.tab.cpp" default: break; } - /* User semantic actions sometimes alter yychar, and that requires - that yytoken be updated with the new translation. We take the - approach of translating immediately before every use of yytoken. - One alternative is translating here after every semantic action, - but that translation would be missed if the semantic action invokes - YYABORT, YYACCEPT, or YYERROR immediately after altering yychar or - if it invokes YYBACKUP. In the case of YYABORT or YYACCEPT, an - incorrect destructor might then be invoked immediately. In the - case of YYERROR or YYBACKUP, subsequent parser actions might lead - to an incorrect destructor call or verbose syntax error message - before the lookahead is translated. */ YY_SYMBOL_PRINT ("-> $$ =", yyr1[yyn], &yyval, &yyloc); YYPOPSTACK (yylen); @@ -10068,10 +10037,6 @@ yyreduce: | yyerrlab -- here on detecting error | `------------------------------------*/ yyerrlab: - /* Make sure we have latest lookahead translation. See comments at - user semantic actions for why this is necessary. */ - yytoken = yychar == YYEMPTY ? YYEMPTY : YYTRANSLATE (yychar); - /* If not already recovering from an error, report this error. */ if (!yyerrstatus) { @@ -10079,36 +10044,37 @@ yyerrlab: #if ! YYERROR_VERBOSE yyerror (YY_("syntax error")); #else -# define YYSYNTAX_ERROR yysyntax_error (&yymsg_alloc, &yymsg, \ - yyssp, yytoken) { - char const *yymsgp = YY_("syntax error"); - int yysyntax_error_status; - yysyntax_error_status = YYSYNTAX_ERROR; - if (yysyntax_error_status == 0) - yymsgp = yymsg; - else if (yysyntax_error_status == 1) - { - if (yymsg != yymsgbuf) - YYSTACK_FREE (yymsg); - yymsg = (char *) YYSTACK_ALLOC (yymsg_alloc); - if (!yymsg) - { - yymsg = yymsgbuf; - yymsg_alloc = sizeof yymsgbuf; - yysyntax_error_status = 2; - } - else - { - yysyntax_error_status = YYSYNTAX_ERROR; - yymsgp = yymsg; - } - } - yyerror (yymsgp); - if (yysyntax_error_status == 2) - goto yyexhaustedlab; + YYSIZE_T yysize = yysyntax_error (0, yystate, yychar); + if (yymsg_alloc < yysize && yymsg_alloc < YYSTACK_ALLOC_MAXIMUM) + { + YYSIZE_T yyalloc = 2 * yysize; + if (! (yysize <= yyalloc && yyalloc <= YYSTACK_ALLOC_MAXIMUM)) + yyalloc = YYSTACK_ALLOC_MAXIMUM; + if (yymsg != yymsgbuf) + YYSTACK_FREE (yymsg); + yymsg = (char *) YYSTACK_ALLOC (yyalloc); + if (yymsg) + yymsg_alloc = yyalloc; + else + { + yymsg = yymsgbuf; + yymsg_alloc = sizeof yymsgbuf; + } + } + + if (0 < yysize && yysize <= yymsg_alloc) + { + (void) yysyntax_error (yymsg, yystate, yychar); + yyerror (yymsg); + } + else + { + yyerror (YY_("syntax error")); + if (yysize != 0) + goto yyexhaustedlab; + } } -# undef YYSYNTAX_ERROR #endif } @@ -10167,7 +10133,7 @@ yyerrlab1: for (;;) { yyn = yypact[yystate]; - if (!yypact_value_is_default (yyn)) + if (yyn != YYPACT_NINF) { yyn += YYTERROR; if (0 <= yyn && yyn <= YYLAST && yycheck[yyn] == YYTERROR) @@ -10226,13 +10192,8 @@ yyexhaustedlab: yyreturn: if (yychar != YYEMPTY) - { - /* Make sure we have latest lookahead translation. See comments at - user semantic actions for why this is necessary. */ - yytoken = YYTRANSLATE (yychar); - yydestruct ("Cleanup: discarding lookahead", - yytoken, &yylval); - } + yydestruct ("Cleanup: discarding lookahead", + yytoken, &yylval); /* Do not reclaim the symbols of the rule which action triggered this YYABORT or YYACCEPT. */ YYPOPSTACK (yylen); @@ -10257,8 +10218,8 @@ yyreturn: -/* Line 2067 of yacc.c */ -#line 4402 "Gmsh.y" +/* Line 1684 of yacc.c */ +#line 4404 "Gmsh.y" int PrintListOfDouble(char *format, List_T *list, char *buffer) diff --git a/Parser/Gmsh.tab.hpp b/Parser/Gmsh.tab.hpp index dceee60cb62d56ddb3b9e946afb69fb7bde87ba6..74b36e603bcef7a57059b2d4f50b08146d20e118 100644 --- a/Parser/Gmsh.tab.hpp +++ b/Parser/Gmsh.tab.hpp @@ -1,8 +1,9 @@ -/* A Bison parser, made by GNU Bison 2.5. */ +/* A Bison parser, made by GNU Bison 2.4.3. */ -/* Bison interface for Yacc-like parsers in C +/* Skeleton interface for Bison's Yacc-like parsers in C - Copyright (C) 1984, 1989-1990, 2000-2011 Free Software Foundation, Inc. + Copyright (C) 1984, 1989, 1990, 2000, 2001, 2002, 2003, 2004, 2005, 2006, + 2009, 2010 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by @@ -181,7 +182,7 @@ typedef union YYSTYPE { -/* Line 2068 of yacc.c */ +/* Line 1685 of yacc.c */ #line 87 "Gmsh.y" char *c; @@ -194,8 +195,8 @@ typedef union YYSTYPE -/* Line 2068 of yacc.c */ -#line 199 "Gmsh.tab.hpp" +/* Line 1685 of yacc.c */ +#line 200 "Gmsh.tab.hpp" } YYSTYPE; # define YYSTYPE_IS_TRIVIAL 1 # define yystype YYSTYPE /* obsolescent; will be withdrawn */ diff --git a/Parser/Gmsh.y b/Parser/Gmsh.y index 4d4fdfb42a2f893e65af6b2ec848e4e389505a18..285f32a8e1a352c1297f46e38e69b097789cb20e 100644 --- a/Parser/Gmsh.y +++ b/Parser/Gmsh.y @@ -2484,8 +2484,10 @@ Command : std::string tmp = FixRelativePath(gmsh_yyname, $2); MergeFile(tmp, true); } - else if(!strcmp($1, "System")) + else if(!strcmp($1, "NonBlockingSystemCall")) SystemCall($2); + else if(!strcmp($1, "System") || !strcmp($1, "SystemCall")) + SystemCall($2, true); else if(!strcmp($1, "SetName")) GModel::current()->setName($2); else diff --git a/Parser/Gmsh.yy.cpp b/Parser/Gmsh.yy.cpp index 9763f8a6da00bb3a243dc7eeb1ec439127e557f7..e7cc92b77dbe299aff2d692321a8f444b54417c2 100644 --- a/Parser/Gmsh.yy.cpp +++ b/Parser/Gmsh.yy.cpp @@ -172,7 +172,12 @@ typedef unsigned int flex_uint32_t; typedef struct yy_buffer_state *YY_BUFFER_STATE; #endif -extern int gmsh_yyleng; +#ifndef YY_TYPEDEF_YY_SIZE_T +#define YY_TYPEDEF_YY_SIZE_T +typedef size_t yy_size_t; +#endif + +extern yy_size_t gmsh_yyleng; extern FILE *gmsh_yyin, *gmsh_yyout; @@ -198,11 +203,6 @@ extern FILE *gmsh_yyin, *gmsh_yyout; #define unput(c) yyunput( c, (yytext_ptr) ) -#ifndef YY_TYPEDEF_YY_SIZE_T -#define YY_TYPEDEF_YY_SIZE_T -typedef size_t yy_size_t; -#endif - #ifndef YY_STRUCT_YY_BUFFER_STATE #define YY_STRUCT_YY_BUFFER_STATE struct yy_buffer_state @@ -220,7 +220,7 @@ struct yy_buffer_state /* Number of characters read into yy_ch_buf, not including EOB * characters. */ - int yy_n_chars; + yy_size_t yy_n_chars; /* Whether we "own" the buffer - i.e., we know we created it, * and can realloc() it to grow it, and should free() it to @@ -290,8 +290,8 @@ static YY_BUFFER_STATE * yy_buffer_stack = 0; /**< Stack as an array. */ /* yy_hold_char holds the character lost when gmsh_yytext is formed. */ static char yy_hold_char; -static int yy_n_chars; /* number of characters read into yy_ch_buf */ -int gmsh_yyleng; +static yy_size_t yy_n_chars; /* number of characters read into yy_ch_buf */ +yy_size_t gmsh_yyleng; /* Points to current character in buffer. */ static char *yy_c_buf_p = (char *) 0; @@ -319,7 +319,7 @@ static void gmsh_yy_init_buffer (YY_BUFFER_STATE b,FILE *file ); YY_BUFFER_STATE gmsh_yy_scan_buffer (char *base,yy_size_t size ); YY_BUFFER_STATE gmsh_yy_scan_string (yyconst char *yy_str ); -YY_BUFFER_STATE gmsh_yy_scan_bytes (yyconst char *bytes,int len ); +YY_BUFFER_STATE gmsh_yy_scan_bytes (yyconst char *bytes,yy_size_t len ); void *gmsh_yyalloc (yy_size_t ); void *gmsh_yyrealloc (void *,yy_size_t ); @@ -984,7 +984,7 @@ FILE *gmsh_yyget_out (void ); void gmsh_yyset_out (FILE * out_str ); -int gmsh_yyget_leng (void ); +yy_size_t gmsh_yyget_leng (void ); char *gmsh_yyget_text (void ); @@ -1045,7 +1045,7 @@ static int input (void ); if ( YY_CURRENT_BUFFER_LVALUE->yy_is_interactive ) \ { \ int c = '*'; \ - int n; \ + yy_size_t n; \ for ( n = 0; n < max_size && \ (c = getc( gmsh_yyin )) != EOF && c != '\n'; ++n ) \ buf[n] = (char) c; \ @@ -2181,7 +2181,7 @@ static int yy_get_next_buffer (void) else { - int num_to_read = + yy_size_t num_to_read = YY_CURRENT_BUFFER_LVALUE->yy_buf_size - number_to_move - 1; while ( num_to_read <= 0 ) @@ -2195,7 +2195,7 @@ static int yy_get_next_buffer (void) if ( b->yy_is_our_buffer ) { - int new_size = b->yy_buf_size * 2; + yy_size_t new_size = b->yy_buf_size * 2; if ( new_size <= 0 ) b->yy_buf_size += b->yy_buf_size / 8; @@ -2226,7 +2226,7 @@ static int yy_get_next_buffer (void) /* Read in more data. */ YY_INPUT( (&YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[number_to_move]), - (yy_n_chars), (size_t) num_to_read ); + (yy_n_chars), num_to_read ); YY_CURRENT_BUFFER_LVALUE->yy_n_chars = (yy_n_chars); } @@ -2336,7 +2336,7 @@ static int yy_get_next_buffer (void) if ( yy_cp < YY_CURRENT_BUFFER_LVALUE->yy_ch_buf + 2 ) { /* need to shift things up to make room */ /* +2 for EOB chars. */ - register int number_to_move = (yy_n_chars) + 2; + register yy_size_t number_to_move = (yy_n_chars) + 2; register char *dest = &YY_CURRENT_BUFFER_LVALUE->yy_ch_buf[ YY_CURRENT_BUFFER_LVALUE->yy_buf_size + 2]; register char *source = @@ -2385,7 +2385,7 @@ static int yy_get_next_buffer (void) else { /* need more input */ - int offset = (yy_c_buf_p) - (yytext_ptr); + yy_size_t offset = (yy_c_buf_p) - (yytext_ptr); ++(yy_c_buf_p); switch ( yy_get_next_buffer( ) ) @@ -2409,7 +2409,7 @@ static int yy_get_next_buffer (void) case EOB_ACT_END_OF_FILE: { if ( gmsh_yywrap( ) ) - return EOF; + return 0; if ( ! (yy_did_buffer_switch_on_eof) ) YY_NEW_FILE; @@ -2661,7 +2661,7 @@ void gmsh_yypop_buffer_state (void) */ static void gmsh_yyensure_buffer_stack (void) { - int num_to_alloc; + yy_size_t num_to_alloc; if (!(yy_buffer_stack)) { @@ -2758,12 +2758,11 @@ YY_BUFFER_STATE gmsh_yy_scan_string (yyconst char * yystr ) * * @return the newly allocated buffer state object. */ -YY_BUFFER_STATE gmsh_yy_scan_bytes (yyconst char * yybytes, int _yybytes_len ) +YY_BUFFER_STATE gmsh_yy_scan_bytes (yyconst char * yybytes, yy_size_t _yybytes_len ) { YY_BUFFER_STATE b; char *buf; - yy_size_t n; - int i; + yy_size_t n, i; /* Get memory for full buffer, including space for trailing EOB's. */ n = _yybytes_len + 2; @@ -2845,7 +2844,7 @@ FILE *gmsh_yyget_out (void) /** Get the length of the current token. * */ -int gmsh_yyget_leng (void) +yy_size_t gmsh_yyget_leng (void) { return gmsh_yyleng; }