The template:
#cache This is a cached region. $voom #end cache
The output:
This is a cached region. Voom!
The generated code:
1 ## START CACHE REGION: at line, col (1, 1) in the source.
2 RECACHE = True
3 if not self._cacheData.has_key('23711421'):
4 pass
5 else:
6 RECACHE = False
7 if RECACHE:
8 orig_trans = trans
9 trans = cacheCollector = DummyTransaction()
10 write = cacheCollector.response().write
11 write('This is a cached region. ')
12 write(filter(VFS(SL,"voom",1))) # generated from '$voom' at line 2,
# col 27.
13 write('\n')
14 trans = orig_trans
15 write = trans.response().write
16 self._cacheData['23711421'] = cacheCollector.response().getvalue()
17 del cacheCollector
18 write(self._cacheData['23711421'])
19 ## END CACHE REGION
This is the same as the $*voom example, except that the plain text
around the placeholder is inside the second if-block.