lilypond-devel
[Top][All Lists]
Advanced

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

flower: Get rid of libc-extension (issue 553740043 by address@hidden)


From: jonas . hahnfeld
Subject: flower: Get rid of libc-extension (issue 553740043 by address@hidden)
Date: Tue, 17 Mar 2020 14:06:42 -0700

Reviewers: ,


https://codereview.appspot.com/553740043/diff/547780043/input/regression/tie-single-manual.ly
File input/regression/tie-single-manual.ly (right):

https://codereview.appspot.com/553740043/diff/547780043/input/regression/tie-single-manual.ly#newcode19
input/regression/tie-single-manual.ly:19: \override Tie.staff-position =
#-7.4
I'm not really happy about tweaking this test like this. It relies on
rounding halfway always up (my_round) instead of away from zero
(std::round). I think this is a coincidence, but if we want to retain
this I need to go through all replacements of my_round -> std::round and
check if the argument could be negative...

Description:
flower: Get rid of libc-extension

Individual commits:
1) Remove unused includes of libc-extension.hh

2) flower: Replace my_round with std::round

This affects only a single regression test, tie-single-manual.ly:
It relies upon the weird rounding of my_round for negative numbers,
for exmaple -7.5 -> -7.0. Instead std::round moves halfway cases away
from zero, -7.5 -> -8.0.

While passing by, move some system headers last (this helps avoid issues
that one of LilyPond's headers depends on other system headers being
loaded first) and add them if apparently used in the file.

3) Rewrite String_convert::to_upper, ::to_lower via std::transform

Please review this at https://codereview.appspot.com/553740043/

Affected files (+71, -145 lines):
  D flower/include/libc-extension.hh
  D flower/libc-extension.cc
  M flower/rational.cc
  M flower/string-convert.cc
  M input/regression/tie-single-manual.ly
  M lily/beam-quanting.cc
  M lily/bezier.cc
  M lily/general-scheme.cc
  M lily/lily-guile.cc
  M lily/midi-cc-announcer.cc
  M lily/midi-item.cc
  M lily/pango-select.cc
  M lily/paper-def.cc
  M lily/simple-spacer.cc
  M lily/slur-configuration.cc
  M lily/slur-scoring.cc
  M lily/spanner.cc
  M lily/staff-symbol-referencer.cc
  M lily/staff-symbol-referencer-scheme.cc
  M lily/stencil-scheme.cc
  M lily/tie-formatting-problem.cc
  M lily/tie-specification.cc





reply via email to

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