Skip to content

Commit

Permalink
upb: make :wire internal headers private
Browse files Browse the repository at this point in the history
PiperOrigin-RevId: 594337191
  • Loading branch information
ericsalo authored and copybara-github committed Dec 29, 2023
1 parent 1597bf4 commit 1fc0e72
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 9 deletions.
3 changes: 1 addition & 2 deletions upb/message/promote.c
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,6 @@
#include "upb/mini_table/sub.h"
#include "upb/wire/decode.h"
#include "upb/wire/eps_copy_input_stream.h"
#include "upb/wire/internal/constants.h"
#include "upb/wire/reader.h"

// Must be last.
Expand Down Expand Up @@ -118,7 +117,7 @@ static upb_FindUnknownRet upb_FindUnknownRet_ParseError(void) {
upb_FindUnknownRet upb_Message_FindUnknown(const upb_Message* msg,
uint32_t field_number,
int depth_limit) {
depth_limit = depth_limit ? depth_limit : kUpb_WireFormat_DefaultDepthLimit;
depth_limit = depth_limit ? depth_limit : 100;

size_t size;
upb_FindUnknownRet ret;
Expand Down
4 changes: 2 additions & 2 deletions upb/wire/BUILD
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,13 @@ cc_library(
srcs = [
"decode.c",
"encode.c",
"internal/constants.h",
"internal/decode_fast.c",
"internal/decoder.h",
],
hdrs = [
"decode.h",
"encode.h",
"internal/constants.h",
"internal/decode.h",
"internal/decode_fast.h",
],
copts = UPB_DEFAULT_COPTS,
Expand Down
2 changes: 1 addition & 1 deletion upb/wire/decode.c
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@
#include "upb/wire/encode.h"
#include "upb/wire/eps_copy_input_stream.h"
#include "upb/wire/internal/constants.h"
#include "upb/wire/internal/decode.h"
#include "upb/wire/internal/decoder.h"
#include "upb/wire/internal/endian.h"
#include "upb/wire/reader.h"

Expand Down
2 changes: 1 addition & 1 deletion upb/wire/internal/decode_fast.c
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
#include "upb/message/internal/array.h"
#include "upb/message/internal/types.h"
#include "upb/mini_table/sub.h"
#include "upb/wire/internal/decode.h"
#include "upb/wire/internal/decoder.h"

// Must be last.
#include "upb/port/def.inc"
Expand Down
6 changes: 3 additions & 3 deletions upb/wire/internal/decode.h → upb/wire/internal/decoder.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,8 @@
* decode.c and decode_fast.c.
*/

#ifndef UPB_WIRE_INTERNAL_DECODE_H_
#define UPB_WIRE_INTERNAL_DECODE_H_
#ifndef UPB_WIRE_INTERNAL_DECODER_H_
#define UPB_WIRE_INTERNAL_DECODER_H_

#include "upb/mem/internal/arena.h"
#include "upb/message/internal/message.h"
Expand Down Expand Up @@ -124,4 +124,4 @@ UPB_INLINE uint32_t _upb_FastDecoder_LoadTag(const char* ptr) {

#include "upb/port/undef.inc"

#endif /* UPB_WIRE_INTERNAL_DECODE_H_ */
#endif /* UPB_WIRE_INTERNAL_DECODER_H_ */

0 comments on commit 1fc0e72

Please sign in to comment.