Skip to content

Commit

Permalink
Fix compile error in src/ops/conformer.cpp & add virtual destructors in
Browse files Browse the repository at this point in the history
include/openbabel/conformersearch.h with empty implementation.
  • Loading branch information
timvdm committed Aug 27, 2012
1 parent d68bfcb commit 2086cff
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 4 deletions.
2 changes: 2 additions & 0 deletions include/openbabel/conformersearch.h
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,7 @@ namespace OpenBabel {
* @return True if the conformer passes the filter.
*/
virtual bool IsGood(const OBMol &mol, const RotorKey &key, double *coords) = 0;
virtual ~OBConformerFilter() {}
};

/**
Expand Down Expand Up @@ -139,6 +140,7 @@ namespace OpenBabel {
class OBAPI OBConformerScore
{
public:
virtual ~OBConformerScore() {}
/**
* Conformer scores can be preferably high or low.
*/
Expand Down
8 changes: 4 additions & 4 deletions src/ops/conformer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -159,10 +159,10 @@ namespace OpenBabel
OBConformerSearch cs;
if (score == "energy")
cs.SetScore(new OBEnergyConformerScore);
else if (score.find("mine") != std::string::npos)
cs.SetScore(new OBMinimizingEnergyConformerScore);
else if (score.find("minr") != std::string::npos)
cs.SetScore(new OBMinimizingRMSDConformerScore);
//else if (score.find("mine") != std::string::npos)
// cs.SetScore(new OBMinimizingEnergyConformerScore);
//else if (score.find("minr") != std::string::npos)
// cs.SetScore(new OBMinimizingRMSDConformerScore);

if (cs.Setup(*pmol, numConformers, numChildren, mutability, convergence)) {
cs.Search();
Expand Down

0 comments on commit 2086cff

Please sign in to comment.