summaryrefslogtreecommitdiff
path: root/upb/bytestream.h
diff options
context:
space:
mode:
authorJoshua Haberman <jhaberman@gmail.com>2011-07-29 17:49:59 -0700
committerJoshua Haberman <jhaberman@gmail.com>2011-07-29 17:49:59 -0700
commit56984e8db8e1c43687535cc77fb6ce43df0b3d1f (patch)
treedc8c85d1311458a68408ff4c43d009b6193ac221 /upb/bytestream.h
parent92b4c38fa5f137cbcf835ad359bed8711c1c9c51 (diff)
Significant work on Lua extension.
Also changes in core library to accommodate.
Diffstat (limited to 'upb/bytestream.h')
-rw-r--r--upb/bytestream.h13
1 files changed, 7 insertions, 6 deletions
diff --git a/upb/bytestream.h b/upb/bytestream.h
index 2a6f7d2..6090d6a 100644
--- a/upb/bytestream.h
+++ b/upb/bytestream.h
@@ -119,16 +119,17 @@ typedef struct _upb_strref {
// the actual pointers).
const char *ptr;
- // Bytesrc from which this string data comes. This is only guaranteed to be
- // alive from inside the callback; however if the handler knows more about
- // its type and how to prolong its life, it may do so.
- upb_bytesrc *bytesrc;
+ // Length of the string.
+ uint32_t len;
// Offset in the bytesrc that represents the beginning of this string.
uint32_t stream_offset;
- // Length of the string.
- uint32_t len;
+ // Bytesrc from which this string data comes. May be NULL if ptr is set. If
+ // non-NULL, the bytesrc is only guaranteed to be alive from inside the
+ // callback; however if the handler knows more about its type and how to
+ // prolong its life, it may do so.
+ upb_bytesrc *bytesrc;
// Possibly add optional members here like start_line, start_column, etc.
} upb_strref;
generated by cgit on debian on lair
contact matthew@masot.net with questions or feedback