[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[GSoC 2020] Coding starts

From: Kai Torben Ohlhus
Subject: [GSoC 2020] Coding starts
Date: Mon, 1 Jun 2020 16:51:08 +0900
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.8.0

Dear Abdallah,

Again, thank you for your last blog post.  Your timeline looks great.

Your code example was nice to play around with and to fresh up my memory
about RapidJSON.  One thing I noticed was, that you avoided range-based
for loops (C++11) [1].  E.g.

  for (Value::ConstMemberIterator itr = d1.MemberBegin ();
       itr != d1.MemberEnd () ; ++itr)
      if (! itr->value.IsNumber ())
        error ("values must be numbers");


  for (const auto& itr : d1.GetObject ())
      if (! itr.value.IsNumber ())
        error ("values must be numbers");

Since about 2016 [2] Octave uses C++11.  Some features, as shown above,
make the code more readable and less error prone.  But looking at Andy's
implementation, maybe we will not get too deep into it.

Another small but important remark is to not copy any text, code,
anything from Matlab.

> "My goal here is to make the test suite covers all cases that
> jsonencode and jsondecode cover in the official documentation of
> MATLAB [...]"

Some modifications should be made.

Are you going to push the code for your test suite in your GitHub repo
[3]?  I want to check regularly about the progress.

Good luck with your exams.  After they are finished, we can have another
video chat, if you don't like to talk before that.

Happy hacking,

[1] https://rapidjson.org/md_doc_tutorial.html#autotoc_md47
[3] https://github.com/Abdallah-Elshamy/octave

reply via email to

[Prev in Thread] Current Thread [Next in Thread]