X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Flibr2c2%2Ftrackchain.cpp;h=e661ed4902d5389deafda6ff6f2e7830c015595f;hb=dfe3dd563981883f3b7c826102fed33c7ff0d12d;hp=f354c6eac7054fb0d9f6c4c59f30578981e33acf;hpb=1c15570729bbce44f0518373ca5bf8bf41cfa3b3;p=r2c2.git diff --git a/source/libr2c2/trackchain.cpp b/source/libr2c2/trackchain.cpp index f354c6e..e661ed4 100644 --- a/source/libr2c2/trackchain.cpp +++ b/source/libr2c2/trackchain.cpp @@ -150,7 +150,7 @@ TrackIter TrackChain::iter_for(Track &t, Direction d) const TrackIter TrackChain::get_end(unsigned i) const { if(i>=2) - throw invalid_argument("TrackChain::get_end"); + throw out_of_range("TrackChain::get_end"); if(!ends[0]) return TrackIter(); @@ -184,7 +184,7 @@ void operator<<(LexicalConverter &conv, TrackChain::Direction dir) case TrackChain::UNSPECIFIED: conv.result("UNSPECIFIED"); return; case TrackChain::UP: conv.result("UP"); return; case TrackChain::DOWN: conv.result("DOWN"); return; - default: throw lexical_error(format("conversion of Direction(%d) to string", dir)); + default: throw lexical_error(format("conversion of Direction(%d) to string", static_cast(dir))); } }