Re: Walter's Guide to Translating Code From One Language to Another

2018-09-22 Thread Patrick Schluter via Digitalmars-d
On Friday, 21 September 2018 at 06:24:14 UTC, Peter Alexander wrote: On Friday, 21 September 2018 at 06:00:33 UTC, Walter Bright wrote: I've learned this the hard way, and I've had to learn it several times because I am a slow learner. I've posted this before, and repeat it because bears

Re: Walter's Guide to Translating Code From One Language to Another

2018-09-21 Thread rjframe via Digitalmars-d
On Thu, 20 Sep 2018 23:00:33 -0700, Walter Bright wrote: > The procedure is: > ... > 4. translate the code with as few edits as practical. Do not > reformat the code. Do not refactor it. Do not fix anything, no matter > how tempting. Reproduce the behavior of the original as much as > possible.

Re: Walter's Guide to Translating Code From One Language to Another

2018-09-21 Thread Peter Alexander via Digitalmars-d
On Friday, 21 September 2018 at 06:00:33 UTC, Walter Bright wrote: I've learned this the hard way, and I've had to learn it several times because I am a slow learner. I've posted this before, and repeat it because bears repeating. I find this is a great procedure for any sort of large

Walter's Guide to Translating Code From One Language to Another

2018-09-21 Thread Walter Bright via Digitalmars-d
I've learned this the hard way, and I've had to learn it several times because I am a slow learner. I've posted this before, and repeat it because bears repeating. The procedure is: 1. pass the test suite 2. prep the file for conversion, i.e. try to minimize the use of idioms that won't