Hi!

Has anyone added special syntax to allow writing numeric literals with
physical units? So you can write 12m + 34cm, and would get 12.34m.

My question is how would you modify the BNF the most sensible way to
allow for this? The above example is simple, but think of 42 km/h.

(For my purposes, modifying the BNF is perfectly reasonable, but if you
can depict a good, and convenient!, way that would not result in
modifying it, I'd like to hear it, too.)

Thanks in advance for your input,

  -T.

_______________________________________________
Python-Dev mailing list
Python-Dev@python.org
http://mail.python.org/mailman/listinfo/python-dev
Unsubscribe: 
http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com

Reply via email to