| 119 | /* polymake -> singular */ |
| 120 | |
| 121 | int PmInteger2Int(const polymake::Integer& pi, bool &ok) |
| 122 | { |
| 123 | int i=0; |
| 124 | try |
| 125 | { |
| 126 | #if POLYMAKE_VERSION >= 301 /* 3.1 */ |
| 127 | i=int(pi); |
| 128 | #else |
| 129 | i = pi.to_int(); |
| 130 | #endif |
| 131 | } |
| 132 | catch (const std::exception& ex) |
| 133 | { |
| 134 | WerrorS("ERROR: "); WerrorS(ex.what()); WerrorS("\n"); |
| 135 | ok = false; |
| 136 | } |
| 137 | return i; |
| 138 | } |
| 139 | |
| 140 | number PmInteger2Number (const polymake::Integer& pi) |
| 141 | { |
no test coverage detected