aboutsummaryrefslogtreecommitdiff
path: root/vcal.c
diff options
context:
space:
mode:
authorHugo Hörnquist <hugo@lysator.liu.se>2019-02-15 18:09:00 +0100
committerHugo Hörnquist <hugo@lysator.liu.se>2019-02-15 20:03:45 +0100
commit05b5d8547f5f98ca4b907bf6a21564e2384740a6 (patch)
treed1a5c0a856f938721b92076e328ef22647fcaddb /vcal.c
parentAdd toggle for node data output. (diff)
downloadcalp-05b5d8547f5f98ca4b907bf6a21564e2384740a6.tar.gz
calp-05b5d8547f5f98ca4b907bf6a21564e2384740a6.tar.xz
Improve FOR macro.
Diffstat (limited to 'vcal.c')
-rw-r--r--vcal.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/vcal.c b/vcal.c
index 7545ccf3..dda509db 100644
--- a/vcal.c
+++ b/vcal.c
@@ -115,15 +115,15 @@ int DEEP_COPY(vcomponent)(vcomponent* a, vcomponent* b) {
FMT_F(vcomponent) {
int seek = 0;
- FOR(int, i, 40) fmtf("_");
+ for (int i = 0; i < 40; i++) fmtf("_");
seek += sprintf(buf + seek, _YELLOW);
seek += sprintf(buf + seek, "\nVComponet (Type := %s)\n", this->type);
seek += sprintf(buf + seek, _RESET);
seek += FMT(TRIE(content_line))(&this->clines, buf + seek);
seek += sprintf(buf + seek, "\nComponents:\n");
- FOR(VECT(vcomponent), i, &this->components) {
- seek += FMT(vcomponent)(GET(VECT(vcomponent))(&this->components, i), buf + seek);
+ FOR(VECT(vcomponent), vcomponent, comp, &this->components) {
+ seek += FMT(vcomponent)(comp, buf + seek);
}
return seek;