This Site Runs on Fox, a language

 
Written By Sanjir Habib On Dec-4th, 2017

Another language?

It started with me trying to write some code in C. Obviously got tired of all those manual memory management and wanted to use a simple Garbage Collector.

Once I got the GC working, next task was to make strings a little bit more user friendly. Or better say web friendly.

Came up with heredoc style multi line strings embedded within C source. And converted to correct C expression before compilation. Plus embedded variables in string. Like: $var or $(1+var/2).

To make it all work, I had to write a simple C parser and lexer.

After all these, wanted some simple library functions for maps and vectors. Then inline JSON. Why not?

By this time, it was getting more like a different language.

Note that none of the GC, lexer, parser depends on 3rd party library.

Show me the code!

You can find the fox source of this entire web site here

sanjir.fox

And the generated C source here.

sanjir.c

The above two files change every time I update this site.

And source of the rest in this github repo

Fox Language