COIN-OR::LEMON - Graph Library

Ticket #35: 3d9971265677.patch

File 3d9971265677.patch, 1.4 KB (added by Balazs Dezso, 16 years ago)
  • lemon/lgf_reader.h

    # HG changeset patch
    # User Balazs Dezso <deba@inf.elte.hu>
    # Date 1213633147 -7200
    # Node ID c94a80f38d7fcde5fb63e26409be118d0afbefe4
    # Parent  02f4d5d9bfd743e5737320a9f40fa964332bf953
    Clarifying the usage of skipSection
    
    diff -r 02f4d5d9bfd7 -r c94a80f38d7f lemon/lgf_reader.h
    a b  
    11391139
    11401140      line_num = 0;     
    11411141      readLine();
     1142      skipSection();
    11421143
    11431144      while (readSuccess()) {
    1144         skipSection();
    11451145        try {
    11461146          char c;
    11471147          std::string section, caption;
     
    11781178            if (it != _sections.end()) {
    11791179              extra_sections.insert(section);
    11801180              it->second->process(*_is, line_num);
    1181               readLine();
    1182             } else {
    1183               readLine();
    1184               skipSection();
    11851181            }
     1182            readLine();
     1183            skipSection();
    11861184          }
    11871185        } catch (DataFormatError& error) {
    11881186          error.line(line_num);
     
    19811979
    19821980      line_num = 0;     
    19831981      readLine();
     1982      skipSection();
    19841983
    19851984      while (readSuccess()) {
    1986         skipSection();
    19871985        try {
    19881986          char c;
    19891987          std::string section, caption;
     
    20202018            if (it != _sections.end()) {
    20212019              extra_sections.insert(section);
    20222020              it->second->process(*_is, line_num);
    2023               readLine();
    2024             } else {
    2025               readLine();
    2026               skipSection();
    20272021            }
     2022            readLine();
     2023            skipSection();
    20282024          }
    20292025        } catch (DataFormatError& error) {
    20302026          error.line(line_num);