[Top][All Lists]

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

Re: [PATCH] Re: feature-request / doc-actualization (right-margin)

From: Michael Käppler
Subject: Re: [PATCH] Re: feature-request / doc-actualization (right-margin)
Date: Wed, 12 Aug 2009 01:38:48 +0200
User-agent: Thunderbird (X11/20071114)

Neil Puttock wrote:
This and the following docstring lines are too long.
Is there a common line length for docstrings? This should also be mentioned in the CG, I think.
+  Real paper_width = scm_to_double (lookup_variable (ly_symbol2scm

+  Real left_margin_default = scm_to_double (lookup_variable
(ly_symbol2scm ("left-margin-default")));

+  Real right_margin_default = scm_to_double (lookup_variable
(ly_symbol2scm ("right-margin-default")));

These are unsafe, since they return SCM_UNSPECIFIED instead of a Real
if the paper variables aren't defined; using robust_scm2double () here
will ensure a default is returned.

You can see the consequences of variable lookup failure by running 
 This snippet also fails to get a sane value for paper-height in
Ok, thanks, I will have a closer look tomorrow.


reply via email to

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