[OpenSCAD] Reverse chr()?

MichaelAtOz oz.at.michael at gmail.com
Sat May 23 21:13:52 EDT 2015


No.

But  nophead
<http://forum.openscad.org/How-to-detect-chr-0-tp12351p12418.html>   wrote
one:

function asc(c, n = 0) = c == chr(n) ? n : asc(c, n + 1);

Remember this is unicode not ASCII. Check what happens > 7F.

Also chr() IS  documented
<https://en.wikibooks.org/wiki/OpenSCAD_User_Manual/String_Functions#chr>  .



-----
Unless specifically shown otherwise above, my contribution is in the Public Domain; To the extent possible under law, I have waived all copyright and related or neighbouring rights to this work. This work is published globally via the internet. :) Inclusion of works of previous authors is not included in the above.

The TPP is no simple “trade agreement.”   Fight it! http://www.ourfairdeal.org/
--
View this message in context: http://forum.openscad.org/Reverse-chr-tp12735p12736.html
Sent from the OpenSCAD mailing list archive at Nabble.com.




More information about the Discuss mailing list