Build fix: changed abs() -> fabs() (or std::abs?) to be built with G++ 7.1.0#49
Merged
ngeiswei merged 1 commit intoopencog:masterfrom Aug 10, 2017
Merged
Build fix: changed abs() -> fabs() (or std::abs?) to be built with G++ 7.1.0#49ngeiswei merged 1 commit intoopencog:masterfrom
ngeiswei merged 1 commit intoopencog:masterfrom
Conversation
Member
|
Thanks. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
MOSES build with newer(?) G++ fails with the following error:
home/mhatta/work/Debian/opencog/opencog-moses/opencog-moses-3.6.10
git20170807.git20170807.a3a37c9/moses/comboreduct/combo/similarity.cc:220:26: error: call of overloadeda3a37c9/moses/comboreduct/combo/similarity.cc: In function ‘size_t opencog::comb
o::tree_similarity(const tree_branch_vector&, const tree_branch_vector&)’:
/home/mhatta/work/Debian/opencog/opencog-moses/opencog-moses-3.6.10
‘abs(size_t)’ is ambiguous dist += abs(acnt - bcnt);
^
Changing abs() to fabs() fixes this. Or std::abs instead of fabs?
A include file in cogutils needs to be fixed too.