coderJeff's Home Page

Main

My FB Stuff

Extern links

Information

SMACKRO v0.5b

This is some kind of string expansion macro language I came up with after writing the LISP library.

If you have ever seen a makefile before, this will look somewhat familiar. But it's not really the same, so please check out the readme.txt.

$(variable)
$(function[ ,arg[,args...]])

Also using some help macros (in the freebasic header file) it is possible to easily add new custom functions in a few lines of code:

DEFINE_MACRO_FUNC( myfunc )
  print "Function = "; args(0)
  print "First arg = "; args(1)
END_MACRO_FUNC

BIND_MACRO_FUNC( myfunc )

Which then allows evaluating $(myfunc arg1,arg2,...,argn). See readme.txt in the download for more details.

This single module and header should compile with just about any version of FreeBASIC 0.15 or higher and in any of the dialects fb, qb, or deprecated.

Download

smackro-v0.5b-src.zip 15 K


For a simple implementaton if LISP using FreeBASIC see my LISP Evaluator for FreeBASIC.