diff --git a/alib2algo/src/automaton/transform/Compaction.cpp b/alib2algo/src/automaton/transform/Compaction.cpp index 3e61aac160eca3f9d0ce34f0e9000d2e1043ec83..534814a7b9c696ae6b57ac253b3978e38ad006fb 100644 --- a/alib2algo/src/automaton/transform/Compaction.cpp +++ b/alib2algo/src/automaton/transform/Compaction.cpp @@ -53,7 +53,7 @@ automaton::CompactNFA Compaction::convert(const automaton::DFA& automaton) { std::map<std::pair<automaton::State, alphabet::Symbol>, automaton::State> transitions; // only 1 child and nonfinal - while((transitions = std::move(automaton.getTransitionsFromState(q))).size() == 1 && automaton.getFinalStates().count(q) == 0) { + while((transitions = automaton.getTransitionsFromState(q)).size() == 1 && automaton.getFinalStates().count(q) == 0) { const std::pair<std::pair<automaton::State, alphabet::Symbol>, automaton::State>& transition = * transitions.begin(); path.appendSymbol(transition.first.second); q = transition.second; diff --git a/alib2data/src/automaton/Automaton.cpp b/alib2data/src/automaton/Automaton.cpp index 44c46338bac171d8bb295f07867aeaec6e787993..e9a7fc7a4231f5a4de17690426ab97d41f7263b5 100644 --- a/alib2data/src/automaton/Automaton.cpp +++ b/alib2data/src/automaton/Automaton.cpp @@ -17,7 +17,7 @@ State createUniqueState(State nextState, const std::set<State>& other) { do { nextState.getName().inc(); if(other.count(nextState) == 0) - return std::move(nextState); + return nextState; } while(++i < INT_MAX); throw AutomatonException("Could not create unique state." );