diff options
author | Rafael G. Martins <rafael@rafaelmartins.eng.br> | 2016-07-03 03:25:12 +0200 |
---|---|---|
committer | Rafael G. Martins <rafael@rafaelmartins.eng.br> | 2016-07-03 03:25:12 +0200 |
commit | 9acb03e669e20180b9bc95ca02b21460761fef87 (patch) | |
tree | 376d2c46c207daaf5b6c1939c805e4191f02a036 /src/template-parser.h | |
parent | 82995655dca72297155c5632029284dacbcccc87 (diff) | |
download | blogc-9acb03e669e20180b9bc95ca02b21460761fef87.tar.gz blogc-9acb03e669e20180b9bc95ca02b21460761fef87.tar.bz2 blogc-9acb03e669e20180b9bc95ca02b21460761fef87.zip |
template-parser: renderer: implemented 'else' support in templates
yeah, this is stupid. after more than 320 commits and 26 releases, we
finally support the 'else' statement in the template engine. I don't
know if I'm dumb or what, but it took me that long to find a "simple"
solution to this basic issue. yep, no more
`{% ifdef FOO %}...{% endif %}{% ifndef FOO %}...{% endif %}` blocks.
but seriously, who cares?! :/
Diffstat (limited to 'src/template-parser.h')
-rw-r--r-- | src/template-parser.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/template-parser.h b/src/template-parser.h index 46223ec..fe2721e 100644 --- a/src/template-parser.h +++ b/src/template-parser.h @@ -21,6 +21,7 @@ typedef enum { BLOGC_TEMPLATE_IFDEF_STMT = 1, BLOGC_TEMPLATE_IFNDEF_STMT, BLOGC_TEMPLATE_IF_STMT, + BLOGC_TEMPLATE_ELSE_STMT, BLOGC_TEMPLATE_ENDIF_STMT, BLOGC_TEMPLATE_FOREACH_STMT, BLOGC_TEMPLATE_ENDFOREACH_STMT, |