This is a compiler which compile less
code to css
code. I just write it in C
for a try to SeedCup2015.
- Output as a css file(it just output a variable tree now).
- improve my code style and structure.
- Delete notes like
//some notes
- Variable rule(
int
,float
,pixel
,string
,color
) - Calculate rule(include color, pixel, numbers, and inserting string)
- Nest rule
- Scope rule
After compiling this code, you can just type ./less_compiler src_less des_css
to make it run.
Because it's just a demo and supports just a little features, I'm sure there is many bugs though I have tested a lot.