diff options
| -rw-r--r-- | src/tests/mmparse.cpp | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/tests/mmparse.cpp b/src/tests/mmparse.cpp new file mode 100644 index 0000000..af0c19c --- /dev/null +++ b/src/tests/mmparse.cpp | |||
| @@ -0,0 +1,22 @@ | |||
| 1 | /* | ||
| 2 | * Copyright (C) 2007 Xagasoft, All rights reserved. | ||
| 3 | * | ||
| 4 | * This file is part of the libbu++ library and is released under the | ||
| 5 | * terms of the license contained in the file LICENSE. | ||
| 6 | */ | ||
| 7 | |||
| 8 | #include "bu/minimacro.h" | ||
| 9 | #include "bu/fstring.h" | ||
| 10 | |||
| 11 | int main( int argc, char *argv[] ) | ||
| 12 | { | ||
| 13 | Bu::MiniMacro mm; | ||
| 14 | |||
| 15 | mm.addVar("name", "Mike"); | ||
| 16 | mm.addVar("age", "no"); | ||
| 17 | |||
| 18 | printf("%s\n", mm.parse("Hey there {=name:toupper():tolower()}, how are you?").getStr() ); | ||
| 19 | |||
| 20 | return 0; | ||
| 21 | } | ||
| 22 | |||
