summaryrefslogtreecommitdiff
path: root/src/upb_textprinter.c
diff options
context:
space:
mode:
authorJoshua Haberman <jhaberman@gmail.com>2011-05-10 21:59:46 -0700
committerJoshua Haberman <jhaberman@gmail.com>2011-05-10 21:59:46 -0700
commit3231fd0fdd64bc6355bce921a988713524726f23 (patch)
tree326d6c6d334d14005db80c448fca485f641ed516 /src/upb_textprinter.c
parentea2a80840e08887e6e5ea59bce1f56a3c69bd38c (diff)
Vastly improved/simplified the upb_handlers API.
Diffstat (limited to 'src/upb_textprinter.c')
-rw-r--r--src/upb_textprinter.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/upb_textprinter.c b/src/upb_textprinter.c
index 2f3a6b5..7d0a9dd 100644
--- a/src/upb_textprinter.c
+++ b/src/upb_textprinter.c
@@ -185,12 +185,13 @@ void upb_textprinter_reset(upb_textprinter *p, upb_bytesink *sink,
p->indent_depth = 0;
}
-void upb_textprinter_reghandlers(upb_handlers *h) {
- upb_register_all(h,
+upb_mhandlers *upb_textprinter_reghandlers(upb_handlers *h, upb_msgdef *m) {
+ upb_handlerset hset = {
NULL, // startmsg
NULL, // endmsg
upb_textprinter_value,
upb_textprinter_startsubmsg,
upb_textprinter_endsubmsg
- );
+ };
+ return upb_handlers_reghandlerset(h, m, &hset);
}
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback