hi Bertrand,

(I'm not a grand-master, :( )

good that you caught the problem with hole in usable-duration-logs, but,
I think, that makes more comment necessary, see below.

all reviewers: is there a convention about using assertions in C++ code?


http://codereview.appspot.com/4536068/diff/55001/lily/multi-measure-rest.cc
File lily/multi-measure-rest.cc (right):

http://codereview.appspot.com/4536068/diff/55001/lily/multi-measure-rest.cc#newcode255
lily/multi-measure-rest.cc:255: find the longest usable rest fitting
into l:
fitting into measure_count

http://codereview.appspot.com/4536068/diff/55001/lily/multi-measure-rest.cc#newcode257
lily/multi-measure-rest.cc:257: length is its duration (in mdl units)
append to the comment something like

      note: if length were zero on exit, the while-loop wouldn't
terminate,
      but this shouldn't happen since mdl is known to be in
duration_logs_list

and perhaps (what is LP convention?) add an

    assert(length > 0);

after the for-loop.

http://codereview.appspot.com/4536068/

_______________________________________________
lilypond-devel mailing list
lilypond-devel@gnu.org
https://lists.gnu.org/mailman/listinfo/lilypond-devel

Reply via email to