| 346 | |
| 347 | |
| 348 | bool parse_TABLE( |
| 349 | const vector<string>& list, |
| 350 | DdTableResults * table) |
| 351 | { |
| 352 | if (list.size() != 21) |
| 353 | { |
| 354 | cout << "Table list does not have 21 elements: " << list.size() << endl; |
| 355 | return false; |
| 356 | } |
| 357 | |
| 358 | if (! get_head_element(list[0], "TABLE")) |
| 359 | return false; |
| 360 | |
| 361 | for (unsigned suit = 0; suit < DDS_STRAINS; suit++) |
| 362 | { |
| 363 | for (unsigned pl = 0; pl < DDS_HANDS; pl++) |
| 364 | { |
| 365 | if (! get_int_element(list[DDS_HANDS * suit + pl + 1], |
| 366 | table->res_table[suit][pl], "TABLE entry")) |
| 367 | return false; |
| 368 | } |
| 369 | } |
| 370 | |
| 371 | return true; |
| 372 | } |
| 373 | |
| 374 | |
| 375 | bool parse_PAR( |
no test coverage detected