Bacon template

For discussions about programming, programming questions/advice, and projects that don't really have anything to do with Puppy.
Post Reply
Message
Author
PaulR
Posts: 249
Joined: Wed 04 May 2005, 18:45
Location: UK

Bacon template

#1 Post by PaulR »

Hello,

It's been a while since I used Puppy (last log in here 2006!) and have to say it's now a well-polished OS (Slacko 5.5 - amazing on my old Thinkpad T42!).

Anyway, I'm just taking a look at Bacon and it looks like fun; however, being the lazy type and not sure if Geany or whatever will do auto capitalization of Bacon keywords, a little browsing shows that using the -j option when building along with a bunch of #defines will make life easy, for example...

#define print PRINT
#define for FOR
#define to TO
#define next NEXT
... etc

for loop=0 to 10
print "Puppy ";
next


..will compile nicely.

Therefore, I intend to make an include file with just these #defines and use it as a template in all projects... UNLESS someone has already done this (if so please point me at the file :D ).

If anyone else would like a copy of the file I'll post it here when it's cooked.

Paul

PaulR
Posts: 249
Joined: Wed 04 May 2005, 18:45
Location: UK

#2 Post by PaulR »

Slight problem with this idea - the first include and the first define would have to be upper case anyway :oops:

Could always make a pre-pre-processor that converts keywords to uppercase before compiling but that would upset any regular text (strings, comments or variable name for example!) within the source file lol.

Probably best to shelve this idea! :roll:

Post Reply