diff options
author | Joshua Haberman <joshua@reverberate.org> | 2011-02-05 18:53:32 -0800 |
---|---|---|
committer | Joshua Haberman <joshua@reverberate.org> | 2011-02-05 18:53:32 -0800 |
commit | 3affb319260263efc3cee502896d9f981186c7da (patch) | |
tree | 6d519e32a23dc1d3b03c3da0791fd2ea00f154f4 /stream/upb_strstream.h | |
parent | e170259e4ababf39829fa9339fdf0817e38c949e (diff) |
Tons of work: we're close to passing test_vs_proto2 again.
Diffstat (limited to 'stream/upb_strstream.h')
-rw-r--r-- | stream/upb_strstream.h | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/stream/upb_strstream.h b/stream/upb_strstream.h index d01d21f..1a8792b 100644 --- a/stream/upb_strstream.h +++ b/stream/upb_strstream.h @@ -18,12 +18,16 @@ extern "C" { /* upb_stringsrc **************************************************************/ -struct upb_stringsrc; -typedef struct upb_stringsrc upb_stringsrc; +struct _upb_stringsrc { + upb_bytesrc bytesrc; + upb_string *str; + upb_strlen_t offset; +}; +typedef struct _upb_stringsrc upb_stringsrc; // Create/free a stringsrc. -upb_stringsrc *upb_stringsrc_new(); -void upb_stringsrc_free(upb_stringsrc *s); +void upb_stringsrc_init(upb_stringsrc *s); +void upb_stringsrc_uninit(upb_stringsrc *s); // Resets the stringsrc to a state where it will vend the given string. The // stringsrc will take a reference on the string, so the caller need not ensure |