Ezhil-Language-Foundation / Ezhil-Lang

எழில் - ஒரு தமிழ் நிரலாக்க மொழி; தமிழ் மாணவர்களுக்கு இது முதல்முறை கணிப்பொறி நிரல் ஏழுத உதவும் (Ezhil, is a fun Tamil programming language for K-12).
http://ezhillang.org/
GNU General Public License v3.0
171 stars 46 forks source link

Support native Tamil digits in Ezhil #204

Open arcturusannamalai opened 6 years ago

arcturusannamalai commented 6 years ago

சில நேரங்களில் தமிழ் எண் குறியீடுகளை கொண்டு உணரும் நிரல் எழில் வழி செய்யலாம்.

தமிழ் எண் இலக்குகள் இங்கே:

௧ ௨ ௩ ௪ ௫ ௬ ௭ ௮ ௯ ௰ ௱ ௲ 1 2 3 4 5 6 7 8 9 10 100 1000

அணுகுமுறை இதற்கு வெறும் lexer / lexical analyzer அளவில் மட்டுமே மாற்றங்கள் செய்தல் வேண்டும்.

பயன் பொதுவாக சொல்லவரும் எண்கள் 1000-இக்கும் உட்பட்டவை என்பதால் இந்த குறியீடை பிடித்தவர்கள் பயன்படுத்தலாம்.

msathia commented 6 years ago

Can I try to implement this? one question the 1 here in Tamil is it in a special unicode space of the same as க?

arcturusannamalai commented 6 years ago

Sathia : Thanks for offering; you can take a stab at it! Unicode for Tamil numeral 1 is different from agaram க. The relevant files are ezhil/scanner.py ezhil/ezhil_scanner.py

You should just create a NUMERIC token from the scanner, then everything else should follow.

CICDSimplified commented 6 years ago

௧ ௨ ௩ ௪ ௫ ௬ ௭ ௮ ௯ ௰ ௱ ௲ These are not actual tamil digits. They are sanskrit digits. ௧ comes from yegam, ௨ for dua, ௫ is the fifth letter in sanskrit alphabets and so on. The original tamizh digits are ஒ இ மு நா ஐ அ ஏ எ தொ அல், please refer to https://en.wikipedia.org/wiki/Tamil_numerals

arcturusannamalai commented 6 years ago

Thanks for information @CICDSimplified.