October 30, 2012 [Issue 8839] MmFile do not use Range | ||||
---|---|---|---|---|
| ||||
Posted in reply to bioinfornatics | http://d.puremagic.com/issues/show_bug.cgi?id=8839 --- Comment #10 from Jonathan M Davis <jmdavisProg@gmx.com> 2012-10-30 16:31:46 PDT --- Then save the range as a variable and use UFCS on that, or this would probably work: (cast(ubyte[])_file[_currentPosition .. _file.length]).countUntil!(a => isWhite(a))(); I really don't see not being able to use UFCS on the slice directly as a big deal. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
October 30, 2012 [Issue 8839] MmFile do not use Range | ||||
---|---|---|---|---|
| ||||
Posted in reply to bioinfornatics | http://d.puremagic.com/issues/show_bug.cgi?id=8839 --- Comment #11 from bioinfornatics <bioinfornatics@gmail.com> 2012-10-30 16:40:25 PDT --- for me that is ok but for new developer it could be little confused since in first it will try the common ufcs approach. It will get a strange template error about as void[] is used as return type. It will spent some time before fond a way as in this special case he need to cast it. So for me is ok but for others maybe add a little example with a ufcs approach to help him ;-) -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- |
Copyright © 1999-2021 by the D Language Foundation