Those pesky incomprehensible if statements
Theodore Papadopoulo
Theodore.Papadopoulo@sophia.inria.fr
Mon Feb 19 11:49:00 GMT 2001
zackw@stanford.edu said:
> But I still had to stare at it for, oh, thirty seconds before I could
> see what it does, because it's buried under all the verbiage. And I
> said to myself, what we need here is some syntactic sugar. Something
> like
> if (match_p (set, '(set (stack_pointer_rtx)
> (plus (stack_pointer_rtx) (const_int)))))
> Isn't that so much easier to read?
> Of course, I have not the slightest notion how to implement such a
> thing such that the minilanguage has a sensible grammar and the
> implementation doesn't slow the compiler to a crawl.
Um, um... A special preprocessor ;-)
Ugly... definitely, but clearly an improved readability !!!
Of course, the sensible grammar problem remains...
--------------------------------------------------------------------
Theodore Papadopoulo
Email: Theodore.Papadopoulo@sophia.inria.fr Tel: (33) 04 92 38 76 01
--------------------------------------------------------------------
--
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.4 (GNU/Linux)
Comment: Exmh version 2.2 06/23/2000
iD8DBQE6kXiYIzTj8qrxOU4RAqhDAKCzfCznlILf7cEvEPYlo84jyN0WywCcC6jP
k53A7ahqcxCBjWoBDYVWIcs=
=vC6L
-----END PGP SIGNATURE-----
More information about the Gcc
mailing list