Skip to content

Commit

Permalink
Mesh: fix compilation with USE_MESH=OFF
Browse files Browse the repository at this point in the history
  • Loading branch information
a-a-danilov committed May 26, 2016
1 parent 0a33c22 commit cf1303c
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 2 deletions.
4 changes: 3 additions & 1 deletion Examples/CMakeLists.txt
@@ -1,10 +1,12 @@
#add_subdirectory(DrawGrid)
if(USE_MESH)
add_subdirectory(OldDrawGrid)
add_subdirectory(GridGen)
endif(USE_MESH)
if(USE_SOLVER)
add_subdirectory(DrawMatrix)
add_subdirectory(MatSolve)
endif(USE_SOLVER)
add_subdirectory(GridGen)
if(USE_SOLVER AND USE_MESH)
add_subdirectory(FVDiscr)
add_subdirectory(Solver)
Expand Down
2 changes: 1 addition & 1 deletion Examples/DrawMatrix/main.cpp
Expand Up @@ -170,7 +170,7 @@ class Reorder_ARMS
}
INMOST_DATA_ENUM_TYPE GetOrder(INMOST_DATA_ENUM_TYPE ind)
{
return static_cast<Storage::enumerator>(neighbours[ind].size());
return static_cast<INMOST_DATA_ENUM_TYPE>(neighbours[ind].size());
INMOST_DATA_ENUM_TYPE ret = 0, k;
for (k = 0; k < neighbours[ind].size(); k++)
if (!markers[neighbours[ind][k]])
Expand Down
4 changes: 4 additions & 0 deletions Source/Headers/inmost_xml.h
Expand Up @@ -137,14 +137,18 @@ namespace INMOST
void SplitValueMultiplier(std::string expression, std::string & value, std::string & multiplier);
bool ParseBool(std::string word);
void ParseCommaSeparated(std::string word, std::vector<std::string> & parsed, char symbol = ',');
#if defined(USE_MESH)
void ParseReal(std::string word, std::vector<INMOST::Storage::real> & Vector, int & Repeat, int SetSize);
#if defined(USE_AUTODIFF)
void ParseVariable(std::string word, std::vector<INMOST::Storage::var> & Vector, int & Repeat, int SetSize);
#endif
void ParseInteger(std::string word, std::vector<INMOST::Storage::integer> & Vector, int & Repeat, int SetSize);
#endif
void ParseBulk(std::string word, std::string & Vector, int & Repeat, int SetSize);
#if defined(USE_MESH)
void ParseReference(std::string word, std::vector<std::pair<INMOST::ElementType,int> > & Vector, int & Repeat, int SetSize);
void ParseRemoteReference(std::string word, std::vector< std::pair<std::string,std::pair<INMOST::ElementType,int> > > & Vector, int & Repeat, int SetSize);
#endif

/// Structure for xml attribute.
struct XMLAttrib
Expand Down
4 changes: 4 additions & 0 deletions Source/Misc/xml.cpp
Expand Up @@ -1228,6 +1228,7 @@ namespace INMOST
} while( comma != std::string::npos );
}

#if defined(USE_MESH)
void XMLReader::ParseReal(std::string word, std::vector<INMOST::Storage::real> & Vector, int & Repeat, int SetSize)
{
//const char * debug = word.c_str();
Expand Down Expand Up @@ -1301,6 +1302,7 @@ namespace INMOST

Repeat = ConvertMultiplier(multiplier,SetSize);
}
#endif

void XMLReader::ParseBulk(std::string word, std::string & Vector, int & Repeat, int SetSize)
{
Expand Down Expand Up @@ -1335,6 +1337,7 @@ namespace INMOST
Repeat = ConvertMultiplier(multiplier,SetSize);
}

#if defined(USE_MESH)
void XMLReader::ParseReference(std::string word, std::vector<std::pair<INMOST::ElementType,int> > & Vector, int & Repeat, int SetSize)
{
std::string value, multiplier;
Expand Down Expand Up @@ -1398,6 +1401,7 @@ namespace INMOST

Repeat = ConvertMultiplier(multiplier,SetSize);
}
#endif



Expand Down

0 comments on commit cf1303c

Please sign in to comment.