Changeset 1068:e8afd887d706 in lemon
- Timestamp:
- 08/04/11 21:12:46 (12 years ago)
- Branch:
- 1.0
- Parents:
- 1008:b7ed95cd94a3 (diff), 1067:54464584b157 (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the (diff) links above to see all the changes relative to each parent. - Phase:
- public
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
lemon/lgf_reader.h
r519 r1068 3 3 * This file is a part of LEMON, a generic C++ optimization library. 4 4 * 5 * Copyright (C) 2003-20 085 * Copyright (C) 2003-2011 6 6 * Egervary Jeno Kombinatorikus Optimalizalasi Kutatocsoport 7 7 * (Egervary Research Group on Combinatorial Optimization, EGRES). … … 966 966 int index = 0; 967 967 while (_reader_bits::readToken(line, map)) { 968 if(map == "-") { 969 if(index!=0) 970 throw FormatError("'-' is not allowed as a map name"); 971 else if (line >> std::ws >> c) 972 throw FormatError("Extra character at the end of line"); 973 else break; 974 } 968 975 if (maps.find(map) != maps.end()) { 969 976 std::ostringstream msg; … … 1808 1815 int index = 0; 1809 1816 while (_reader_bits::readToken(line, map)) { 1817 if(map == "-") { 1818 if(index!=0) 1819 throw FormatError("'-' is not allowed as a map name"); 1820 else if (line >> std::ws >> c) 1821 throw FormatError("Extra character at the end of line"); 1822 else break; 1823 } 1810 1824 if (maps.find(map) != maps.end()) { 1811 1825 std::ostringstream msg; -
lemon/lgf_reader.h
r1067 r1068 848 848 readLine(); 849 849 } 850 line.putback(c); 850 if (readSuccess()) { 851 line.putback(c); 852 } 851 853 } 852 854 … … 1695 1697 readLine(); 1696 1698 } 1697 line.putback(c); 1699 if (readSuccess()) { 1700 line.putback(c); 1701 } 1698 1702 } 1699 1703 … … 2259 2263 readLine(); 2260 2264 } 2261 line.putback(c); 2265 if (readSuccess()) { 2266 line.putback(c); 2267 } 2262 2268 } 2263 2269 … … 2600 2606 readLine(); 2601 2607 } 2602 line.putback(c); 2608 if (readSuccess()) { 2609 line.putback(c); 2610 } 2603 2611 } 2604 2612
Note: See TracChangeset
for help on using the changeset viewer.