Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 30 Oct 2020 19:33:39 +0100
From:      Stefan Esser <se@freebsd.org>
To:        "Julian H. Stacey" <jhs@berklix.com>
Cc:        Diane Bruce <db@db.net>, Greg Balfour <greg.bal4@gmail.com>, freebsd-stable <freebsd-stable@freebsd.org>
Subject:   Re: calendar (1) - patch to correct error description
Message-ID:  <60d7c6ac-7e03-2daa-fd1d-000be6b5ace8@freebsd.org>
In-Reply-To: <202010292348.09TNmXiX022948@fire.js.berklix.net>
References:  <202010292348.09TNmXiX022948@fire.js.berklix.net>

next in thread | previous in thread | raw e-mail | index | archive | help
This is an OpenPGP/MIME signed message (RFC 4880 and 3156)
--WVdDpY4grSrrJXNrG23bRSJlyUO5qdgqR
Content-Type: multipart/mixed; boundary="qUcUdhluoUuOUzwl1B5NyIRbmxbbTXM1S";
 protected-headers="v1"
From: Stefan Esser <se@freebsd.org>
To: "Julian H. Stacey" <jhs@berklix.com>
Cc: Diane Bruce <db@db.net>, Greg Balfour <greg.bal4@gmail.com>,
 freebsd-stable <freebsd-stable@freebsd.org>
Message-ID: <60d7c6ac-7e03-2daa-fd1d-000be6b5ace8@freebsd.org>
Subject: Re: calendar (1) - patch to correct error description
References: <202010292348.09TNmXiX022948@fire.js.berklix.net>
In-Reply-To: <202010292348.09TNmXiX022948@fire.js.berklix.net>

--qUcUdhluoUuOUzwl1B5NyIRbmxbbTXM1S
Content-Type: multipart/mixed;
 boundary="------------952E8770B933A1E93F81BF29"
Content-Language: en-US

This is a multi-part message in MIME format.
--------------952E8770B933A1E93F81BF29
Content-Type: text/plain; charset=windows-1252; format=flowed
Content-Transfer-Encoding: quoted-printable

Am 30.10.20 um 00:48 schrieb Julian H. Stacey:
> Here's another 2 calendar errors, presumably cpp, that manifest in 12.2=
-STABLE,
> that 9.2-RELEASE gets right.
>=20
> Man calendar:
> 	Empty lines and lines protected by the C commenting syntax
> 	(/* ...  */) are ignored.
>=20
> --- Input ~/.calendar/calendar
> friday	fish
> /*
>   * Oct 21	AAA
>   */
> friday	and chips
> ---12.2-STABLE output
> Oct 30*	and chips
> Oct 30 	AAA
> Oct 30*	fish
> Oct 31 	AAA
> ---9.2-RELEASE output
> Oct 30*	and chips
> Oct 30*	fish
> ---
>=20
> Error 1:	Why does it emit AAA ?

The version you used does only support /* ... */ on a single line.
The "*" in front of "Oct" seems to have been parsed as a wild-card,
but I have not checked why it lead to be interpreted as "Oct 30".

This is fixed with the comment processing that I have added to the
internal pre-processor.

> Error 2:	Why twice ?

No idea and I do not consider this relevant now that the issue is
fixed.

> Puzzle: 	Doesnt happen if you change Oct above to Aug inside the commen=
t.

Feel free to solve this puzzle, I really do not have the time to
waste on this question ;-)

> (PS both do a nasty stack unstack, which may look familiar to us
> programmers, but looks silly to normal peopler, inverting fish & chips)=


Yes, a linked list that got built-up be putting the new element at
the head and the previously added values into the "next" field of
that element.


Please check the calendar version in -CURRENT or the deskutil/calendar
port version 0.6. Both issues should be fixed there.

Regards, STefan

--------------952E8770B933A1E93F81BF29--

--qUcUdhluoUuOUzwl1B5NyIRbmxbbTXM1S--

--WVdDpY4grSrrJXNrG23bRSJlyUO5qdgqR
Content-Type: application/pgp-signature; name="OpenPGP_signature.asc"
Content-Description: OpenPGP digital signature
Content-Disposition: attachment; filename="OpenPGP_signature"

-----BEGIN PGP SIGNATURE-----

wsB5BAABCAAjFiEEo3HqZZwL7MgrcVMTR+u171r99UQFAl+cXIMFAwAAAAAACgkQR+u171r99USi
AwgAnfGQy4FDglTewJx5ow0gndPtV01j53dMgYTCtTZub897tYP+zrYxFVgsuLRy6rakLukF52IE
7ddEiR6BZpNu6PzKNp3W40V8OWzOtb6DNbEpWiHlZa2U3dMDb2AAcxjAeuBf/2uhclesAgVA9kE9
sGZZsHPPPjYYe0pwxOb1TgZmX2WzuM/cBLsdPmGbhUBwB8MHywTz1K4Eqf+cXkXwieBOlpru7qRd
7uuDKjXQOwxcPX5p10nNKyXTTLm98HYLkmIVm2rnd9/zxs8Xexcgrrmp5kEXdBYO4gzySIOD+jdn
IEJZM7ApE1SUrjzO5NRYn57IS5ls7bTwZvyTnKFOPg==
=TEtC
-----END PGP SIGNATURE-----

--WVdDpY4grSrrJXNrG23bRSJlyUO5qdgqR--



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?60d7c6ac-7e03-2daa-fd1d-000be6b5ace8>