More robust eol handling for Sequence::load_fasta
authorDiane Trout <diane@caltech.edu>
Fri, 9 Jun 2006 21:35:07 +0000 (21:35 +0000)
committerDiane Trout <diane@caltech.edu>
Fri, 9 Jun 2006 21:35:07 +0000 (21:35 +0000)
commitf75652f23387cc56ed7e436dd994da2441f40c08
treeb43f69093131026f0ca087ed0607c07b4d12abc5
parent53e101526b30a3f5b6bff8dd37681a00a4746d98
More robust eol handling for Sequence::load_fasta
The load_fasta code used getline() which only uses "native" end of line
conventions. Unfortunately for me OS X has "native" and "backwards
compatible" eol conventions (which aren't compatible). So this patch
will accept  CR, CR-LF, LF, and because I was lazy LF-CR.

I also unit tested that which required breaking load_fasta into a
function that  handles loading from a file name and one that works
from an iostream.
alg/sequence.cpp
alg/sequence.hpp
alg/test/test_sequence.cpp
mussa_exceptions.hpp