P
Pau Garcia i Quiles
--nextPart4600703.AyXPV3I928
Content-Type: text/plain;
charset="iso-8859-15"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline
Hello,
Am I the only one who finds beautiful this syntax for conditional modifiers?
@playlist=3D source[
laylist] if source[
laylist].instance_of?(XSPF:
lay=
list)=20
else raise TypeError "The playlist must be an instance of XSPF:
laylist"
It reads like a book even if you don't know Ruby: "@playlist is X if this o=
r Y=20
if not"
PS: It's beautiful but it doesn't work :-/
=2D-=20
Pau Garcia i Quiles
http://www.elpauer.org
(Due to the amount of work, I usually need 10 days to answer)
--nextPart4600703.AyXPV3I928
Content-Type: application/pgp-signature
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.2 (GNU/Linux)
iD8DBQBFOpCI/DzYv9iGJzsRAkH2AKCxQn31cRODF6v9I8jvh49nGv8b1QCfXNwr
kJVsIsXJZPHZDTtkbzOx0Mg=
=yaZe
-----END PGP SIGNATURE-----
--nextPart4600703.AyXPV3I928--
Content-Type: text/plain;
charset="iso-8859-15"
Content-Transfer-Encoding: quoted-printable
Content-Disposition: inline
Hello,
Am I the only one who finds beautiful this syntax for conditional modifiers?
@playlist=3D source[
list)=20
else raise TypeError "The playlist must be an instance of XSPF:
It reads like a book even if you don't know Ruby: "@playlist is X if this o=
r Y=20
if not"
PS: It's beautiful but it doesn't work :-/
=2D-=20
Pau Garcia i Quiles
http://www.elpauer.org
(Due to the amount of work, I usually need 10 days to answer)
--nextPart4600703.AyXPV3I928
Content-Type: application/pgp-signature
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.2.2 (GNU/Linux)
iD8DBQBFOpCI/DzYv9iGJzsRAkH2AKCxQn31cRODF6v9I8jvh49nGv8b1QCfXNwr
kJVsIsXJZPHZDTtkbzOx0Mg=
=yaZe
-----END PGP SIGNATURE-----
--nextPart4600703.AyXPV3I928--