Tiny Programming Langauge in 25 Lines of Code

There are certain kinds of programs that fascinate certain kinds of software hackers. Maybe you are into number crunching, chess programs, operating systems, or artificial intelligence. However, on any significant machine, most of the time those activities will require some sort of language. Sure, we all have some processor we can write hex code for in our head, but you really want at least an assembler if not something sturdier. Writing languages can be addictive, but jumping right into a big system like gcc and trying to make changes is daunting for anyone. If you want a gentle introduction, check …read more

Continue reading Tiny Programming Langauge in 25 Lines of Code

Disrupting The Computer Industry Before it Existed: Rear Admiral Grace Hopper

The feature of being easier to write than assembly is often seen as the biggest advantage of high-level programming languages. The other benefit that comes with them is portability. With high-level languages, algorithms can be developed independently from the underlying hardware. This allows software to live on once the hardware becomes obsolete.

The compiler was a concept that was met with resistance when it was first introduced. This was at a time when computers were custom-built machines bearing individual names like ENIAC, UNIVAC and Mark I. A time when the global demand for computers was estimated to be around five …read more

Continue reading Disrupting The Computer Industry Before it Existed: Rear Admiral Grace Hopper

Building software safely for malware-free distribution

I wrote a program. I want to publish a compiled executable for downloading by the public.

How can I compile and distribute it without contact with my (presumably insecure and infected) operating system? How do software vendors ensure that their software packages are malware-free?

The absence of relevant information on the web is pretty disturbing. It’s as if nobody in the world except me cared about safe and responsible distribution of software. Why are there no clean compilation services on the web? I’m not going to buy a separate computer only to compile and upload one little application.

Continue reading Building software safely for malware-free distribution

Language Parsing with ANTLR

There are many projects that call out for a custom language parser. If you need something standard, you can probably lift the code from someplace on the Internet. If you need something custom, you might consider reading [Federico Tomassetti’s] tutorial on using ANTLR to build a complete parser-based system. [Frederico] also expanded on this material for his book, but there’s still plenty to pick up from the eight blog posts.

His language, Sandy, is complex enough to be a good example, but not too complex to understand. In addition to the posts, you can find the code on GitHub.

The …read more

Continue reading Language Parsing with ANTLR