Changeset 3020 for trunk/src/Locator.tcc
- Timestamp:
- 12/15/14 17:26:43 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/Locator.tcc
r2732 r3020 11 11 // 12 12 #include <assert.h> 13 #include <iostream> 14 #include <stdexcept> 13 15 14 16 #include "Locator.h" … … 57 59 x_ = v; 58 60 } 61 assert(n_ > 0); 62 if (n_ == 0) { 63 throw std::runtime_error("Input array length is 0."); 64 } 59 65 ascending_ = (x_[0] <= x_[n_-1]); 60 66 }
Note: See TracChangeset
for help on using the changeset viewer.