Commit 286ace6f authored by Dave Partyka's avatar Dave Partyka

COMP: Fix for Borland 5.6 wrongly choosing remove(const char *) in stdio...

COMP: Fix for Borland 5.6 wrongly choosing remove(const char *) in stdio instead of the remove stl algorithm, and add borland version check. Thanks Brad King!
parent 874c03b8
......@@ -73,9 +73,18 @@
#include "vtkVertexDegree.h"
#include "vtkViewTheme.h"
#include <vtkstd/algorithm>
/* Fix for BORLAND 5.6 bug where it wrongly chooses remove(const char *) in stdio
instead of the remove stl algorithm. */
#if defined (__BORLANDC__) && (__BORLANDC__ >= 0x0560)
# define remove borland_remove
#endif
/* Include algorithm last so "remove" macro Borland hack does not
affect other headers. */
#include <vtksys/stl/algorithm>
vtkCxxRevisionMacro(vtkRenderedGraphRepresentation, "1.12");
vtkCxxRevisionMacro(vtkRenderedGraphRepresentation, "1.13");
vtkStandardNewMacro(vtkRenderedGraphRepresentation);
vtkRenderedGraphRepresentation::vtkRenderedGraphRepresentation()
......@@ -762,7 +771,7 @@ vtkGraphLayoutStrategy* vtkRenderedGraphRepresentation::GetLayoutStrategy()
void vtkRenderedGraphRepresentation::SetLayoutStrategy(const char* name)
{
vtkstd::string str = name;
vtkstd::transform(str.begin(), str.end(), str.begin(), tolower);
vtksys_stl::transform(str.begin(), str.end(), str.begin(), tolower);
str.erase(vtkstd::remove(str.begin(), str.end(), ' '), str.end());
vtkSmartPointer<vtkGraphLayoutStrategy> strategy =
vtkSmartPointer<vtkPassThroughLayoutStrategy>::New();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment