Parser, Remove tabs before check empty lines
theludovyc opened this issue · 3 comments
theludovyc commented
If you are in this case
menu menu_test:
"Test option 1" > test_option_1
"Test option 2"
"Test option 3" > test_option_3
<= tab here
test_option_1:
You gonna have this error
Parser: Error on line: X, it is not a choice !
This happen because parser check empty line before remove tabulations
theludovyc commented
I was thinking to remove all spaces or tabs at begin of a line. So user can indent with spaces or tabs.
Choices for now are only things check indent level to go out from menu state. Maybe I have a solution to no do that, I need to do a test.
Finaly, the user can indent his code like he want.
What do you think about it ? @Jeremi360
Jeremi360 commented
@theludovyc If the new solution does not spoil compatibility with the current RakuScript syntax,
then yes change it.
theludovyc commented
Okay, I will do it in #220