On May 20, 2015 10:55:54 PM GMT+07:00, Kenneth Heafield <[email protected]> 
wrote:
>On 05/19/2015 11:50 PM, Jeroen Vermeulen wrote:
>> 
>>>>> Also, how would you feel if I changed it to be FakeIFStream with
>>>>> operator>> extraction, at least for integer/float types?
>>>>
>>>> Sorry, I haven't looked into FakeIFStream at all yet, and I may not
>>>> fully understand the question.
>>>
>>> It doesn't exist yet.  I am contemplating refactoring FilePiece to
>have
>>> operator>> and renaming it to FakeIFStream.
>> 
>> Any ideas on how you would map the different ways of reading into a
>> stream-style API?  By adding manipulators?  One thing I don't like
>about
>> those is that they require you to track and understand more stream
>state
>> to understand exactly what a piece of code does.
>> 
>> I do think turning the class into a stream will make code easier to
>> follow generally.  On the flip side, it may make it harder to find
>out
>> which function is being called where.  That matters when debugging
>the
>> finer points, as I've been doing with this carriage-return issue.
>
>Let's take this off-list.  I don't like manipulators either.  Just
>thinking it would have getline and operator>> for built-in types.  And
>other methods for more specialized types of reading.
>_______________________________________________
>Moses-support mailing list
>[email protected]
>http://mailman.mit.edu/mailman/listinfo/moses-support

Sure.  So the  main  thing  is  the  field  conversions?  That  does  sound  
very  stream-like.


Jeroen
_______________________________________________
Moses-support mailing list
[email protected]
http://mailman.mit.edu/mailman/listinfo/moses-support

Reply via email to