X-Authentication-Warning: delorie.com: mail set sender to geda-user-bounces using -f X-Recipient: geda-user AT delorie DOT com X-Proofpoint-Virus-Version: vendor=fsecure engine=2.50.10432:5.13.68,1.0.33,0.0.0000 definitions=2015-02-08_03:2015-02-08,2015-02-08,1970-01-01 signatures=0 X-Proofpoint-Spam-Details: rule=notspam policy=default score=0 spamscore=0 suspectscore=3 phishscore=0 adultscore=0 bulkscore=0 classifier=spam adjust=0 reason=mlx scancount=1 engine=7.0.1-1412110000 definitions=main-1502080183 From: Chris Smith Content-type: multipart/alternative; boundary=Apple-Mail-050E9DE3-A9C8-451C-982C-203DAFCC913A Content-transfer-encoding: 7bit MIME-version: 1.0 (1.0) Subject: Re: [geda-user] Using Lua to safely read configuration and layout files (program attached) Message-id: Date: Sun, 08 Feb 2015 16:48:58 +0000 References: <3635158 DOT z6Jv0Z2n4b AT jasum> <5275BECE-FDDD-4BB2-A94D-05EB647C8145 AT icloud DOT com> <4098476 DOT cgi0cjUt5u AT jasum> In-reply-to: <4098476.cgi0cjUt5u@jasum> To: "geda-user AT delorie DOT com" X-Mailer: iPad Mail (12B466) Reply-To: geda-user AT delorie DOT com Errors-To: nobody AT delorie DOT com X-Mailing-List: geda-user AT delorie DOT com X-Unsubscribes-To: listserv AT delorie DOT com Precedence: bulk --Apple-Mail-050E9DE3-A9C8-451C-982C-203DAFCC913A Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: quoted-printable > On 8 Feb 2015, at 13:41, Christian Riggenbach wr= ote: >=20 >> On Sunday 08 February 2015 13.27:12 you wrote: >> It might be enough to simply allow an attribute: >> script=3D"=3D". >=20 > Then we wouldn't have straight lua anymore, as it requieres another pass w= ith=20 > the parser. I didn't explain myself fully. When writing the data file gschem would take a= ny script attributes and write the value as an additional attribute, so the o= bject would have: script=3D"=3D" =3D The second would be evaluated on a subsequent load and the former would pres= erve the source expression, particularly if visible serving to document how t= he value was calculated. This would require no additional GUI support from g= schem. Chris= --Apple-Mail-050E9DE3-A9C8-451C-982C-203DAFCC913A Content-Type: text/html; charset=utf-8 Content-Transfer-Encoding: quoted-printable

On 8 Feb 2015, at 13:41= , Christian Riggenbach <crigge= nbach AT magahugu DOT ch> wrote:

On Sunday 08 February 2015 13.27:12 you wrote:
It might be enough to simply allow an attribute:
script=3D"<attribute>=3D= <expression>".

Then we w= ouldn't have straight lua anymore, as it requieres another pass with =
the parser.

I didn't explain= myself fully. When writing the data file gschem would take any script attri= butes and write the value as an additional attribute, so the object would ha= ve:

script=3D"<att= ribute>=3D<expression>"
<attribute>=3D<expressi= on>

The second would be evaluated on a subsequent load and the former w= ould preserve the source expression, particularly if visible serving to docu= ment how the value was calculated. This would require no additional GUI supp= ort from gschem.

Chris
= --Apple-Mail-050E9DE3-A9C8-451C-982C-203DAFCC913A--