forked from protocolbuffers/upb
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Brought into compliance with Google open-source policies.
- removed myself from Author headers in source files. - removed copyright notices from source file headers. - added CONTRIBUTING.md
- Loading branch information
Showing
72 changed files
with
375 additions
and
681 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
## <a name="cla"></a> Signing the CLA | ||
|
||
Please sign the [Google Contributor License Agreement | ||
(CLA)](https://cla.developers.google.com/) | ||
before sending pull requests. For any code changes to be | ||
accepted, the CLA must be signed. It's a quick process, I | ||
promise! |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,4 @@ | ||
/* | ||
* upb - a minimalist implementation of protocol buffers. | ||
* | ||
* Copyright (c) 2011 Google Inc. See LICENSE for details. | ||
* Author: Josh Haberman <[email protected]> | ||
* | ||
* Tests for C++ wrappers. | ||
*/ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,3 @@ | ||
// Copyright 2012 Google Inc. All Rights Reserved. | ||
// Author: [email protected] (Josh Haberman) | ||
|
||
#include <stdlib.h> | ||
#ifdef USE_GOOGLE | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,4 @@ | ||
// | ||
// upb - a minimalist implementation of protocol buffers. | ||
// | ||
// Copyright (c) 2011-2012 Google Inc. See LICENSE for details. | ||
// Author: Josh Haberman <[email protected]> | ||
// | ||
|
||
// IMPORTANT NOTE! Inside Google, This file is compiled TWICE, once with | ||
// UPB_GOOGLE3 defined and once without! This allows us to provide | ||
// functionality against proto2 and protobuf opensource both in a single binary | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,7 @@ | ||
// | ||
// upb - a minimalist implementation of protocol buffers. | ||
// | ||
// Copyright (c) 2011-2012 Google Inc. See LICENSE for details. | ||
// Author: Josh Haberman <[email protected]> | ||
// upb::googlepb::DefBuilder | ||
// upb::googlepb::WriteHandlers | ||
// upb::googlepb::CodeCache | ||
// | ||
// This file contains functionality for constructing upb Defs and Handlers | ||
// corresponding to proto2 messages. Using this functionality, you can use upb | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,4 @@ | ||
// | ||
// upb - a minimalist implementation of protocol buffers. | ||
// | ||
// Copyright (c) 2011-2012 Google Inc. See LICENSE for details. | ||
// Author: Josh Haberman <[email protected]> | ||
// | ||
// This set of handlers can write into a proto2::Message whose reflection class | ||
// is _pi::Proto2Reflection (ie. proto1 messages; while slightly confusing, the | ||
// name "Proto2Reflection" indicates that it is a reflection class implementing | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,3 @@ | ||
// | ||
// upb - a minimalist implementation of protocol buffers. | ||
// | ||
// Copyright (c) 2011-2012 Google Inc. See LICENSE for details. | ||
// Author: Josh Haberman <[email protected]> | ||
// | ||
// Support for registering field handlers that can write into a legacy proto1 | ||
// message. This functionality is only needed inside Google. | ||
// | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,4 @@ | ||
// | ||
// upb - a minimalist implementation of protocol buffers. | ||
// | ||
// Copyright (c) 2011-2012 Google Inc. See LICENSE for details. | ||
// Author: Josh Haberman <[email protected]> | ||
// | ||
// Note that we have received an exception from c-style-artiters regarding | ||
// dynamic_cast<> in this file: | ||
// https://groups.google.com/a/google.com/d/msg/c-style/7Zp_XCX0e7s/I6dpzno4l-MJ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,3 @@ | ||
// | ||
// upb - a minimalist implementation of protocol buffers. | ||
// | ||
// Copyright (c) 2011-2012 Google Inc. See LICENSE for details. | ||
// Author: Josh Haberman <[email protected]> | ||
// | ||
// Support for registering field handlers that can write into a proto2 | ||
// message that uses GeneratedMessageReflection (which includes all messages | ||
// generated by the proto2 compiler as well as DynamicMessage). | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,3 @@ | ||
/* | ||
* upb - a minimalist implementation of protocol buffers. | ||
* | ||
* Copyright (c) 2012 Google Inc. See LICENSE for details. | ||
* Author: Josh Haberman <[email protected]> | ||
*/ | ||
|
||
#include <linux/kernel.h> | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,2 @@ | ||
/* | ||
* upb - a minimalist implementation of protocol buffers. | ||
* | ||
* Copyright (c) 2012 Google Inc. See LICENSE for details. | ||
* Author: Josh Haberman <[email protected]> | ||
*/ | ||
|
||
#include <linux/errno.h> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,2 @@ | ||
/* | ||
* upb - a minimalist implementation of protocol buffers. | ||
* | ||
* Copyright (c) 2012 Google Inc. See LICENSE for details. | ||
* Author: Josh Haberman <[email protected]> | ||
*/ | ||
|
||
#include <linux/types.h> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,10 +1,2 @@ | ||
/* | ||
* upb - a minimalist implementation of protocol buffers. | ||
* | ||
* Copyright (c) 2012 Google Inc. See LICENSE for details. | ||
* Author: Josh Haberman <[email protected]> | ||
* | ||
* Linux-kernel implementations of some stdlib.h functions. | ||
*/ | ||
|
||
#include <linux/kernel.h> // For sprintf and friends. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,6 @@ | ||
/* | ||
* upb - a minimalist implementation of protocol buffers. | ||
* | ||
* Copyright (c) 2012 Google Inc. See LICENSE for details. | ||
* Author: Josh Haberman <[email protected]> | ||
* | ||
* Linux-kernel implementations of some stdlib.h functions. | ||
*/ | ||
** Linux-kernel implementations of some stdlib.h functions. | ||
*/ | ||
|
||
#include <linux/slab.h> | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,3 @@ | ||
/* | ||
* upb - a minimalist implementation of protocol buffers. | ||
* | ||
* Copyright (c) 2012 Google Inc. See LICENSE for details. | ||
* Author: Josh Haberman <[email protected]> | ||
*/ | ||
|
||
#ifndef UPB_LINUX_STRING_H_ | ||
#define UPB_LINUX_STRING_H_ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,27 +1,24 @@ | ||
/* | ||
* upb - a minimalist implementation of protocol buffers. | ||
* | ||
* Copyright (c) 2009 Google Inc. See LICENSE for details. | ||
* Author: Josh Haberman <[email protected]> | ||
* | ||
* A Lua extension for upb. Exposes only the core library | ||
* (sub-libraries are exposed in other extensions). | ||
* | ||
* 64-bit woes: Lua can only represent numbers of type lua_Number (which is | ||
* double unless the user specifically overrides this). Doubles can represent | ||
* the entire range of 64-bit integers, but lose precision once the integers are | ||
* greater than 2^53. | ||
* | ||
* Lua 5.3 is adding support for integers, which will allow for 64-bit | ||
* integers (which can be interpreted as signed or unsigned). | ||
* | ||
* LuaJIT supports 64-bit signed and unsigned boxed representations | ||
* through its "cdata" mechanism, but this is not portable to regular Lua. | ||
* | ||
* Hopefully Lua 5.3 will come soon enough that we can either use Lua 5.3 | ||
* integer support or LuaJIT 64-bit cdata for users that need the entire | ||
* domain of [u]int64 values. | ||
*/ | ||
** require("lua") -- A Lua extension for upb. | ||
** | ||
** Exposes only the core library | ||
** (sub-libraries are exposed in other extensions). | ||
** | ||
** 64-bit woes: Lua can only represent numbers of type lua_Number (which is | ||
** double unless the user specifically overrides this). Doubles can represent | ||
** the entire range of 64-bit integers, but lose precision once the integers are | ||
** greater than 2^53. | ||
** | ||
** Lua 5.3 is adding support for integers, which will allow for 64-bit | ||
** integers (which can be interpreted as signed or unsigned). | ||
** | ||
** LuaJIT supports 64-bit signed and unsigned boxed representations | ||
** through its "cdata" mechanism, but this is not portable to regular Lua. | ||
** | ||
** Hopefully Lua 5.3 will come soon enough that we can either use Lua 5.3 | ||
** integer support or LuaJIT 64-bit cdata for users that need the entire | ||
** domain of [u]int64 values. | ||
*/ | ||
|
||
#include <float.h> | ||
#include <math.h> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,6 @@ | ||
/* | ||
* upb - a minimalist implementation of protocol buffers. | ||
* | ||
* Copyright (c) 2012 Google Inc. See LICENSE for details. | ||
* Author: Josh Haberman <[email protected]> | ||
* | ||
* Shared definitions for upb Lua modules. | ||
*/ | ||
** Shared definitions for upb Lua modules. | ||
*/ | ||
|
||
#ifndef UPB_LUA_UPB_H_ | ||
#define UPB_LUA_UPB_H_ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,9 @@ | ||
/* | ||
* upb - a minimalist implementation of protocol buffers. | ||
* | ||
* Copyright (c) 2014 Google Inc. See LICENSE for details. | ||
* Author: Josh Haberman <[email protected]> | ||
* | ||
* A Lua extension for upb.pb. | ||
* | ||
* Exposes all the types defined in upb/pb/{*}.h | ||
* Also defines a few convenience functions on top. | ||
*/ | ||
** require("upb.pb") -- A Lua extension for upb.pb. | ||
** | ||
** Exposes all the types defined in upb/pb/{*}.h | ||
** Also defines a few convenience functions on top. | ||
*/ | ||
|
||
#include "upb/bindings/lua/upb.h" | ||
#include "upb/pb/decoder.h" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,21 +1,17 @@ | ||
/* | ||
* upb - a minimalist implementation of protocol buffers. | ||
* | ||
* Copyright (c) 2012 Google Inc. See LICENSE for details. | ||
* Author: Josh Haberman <[email protected]> | ||
* | ||
* Lua extension that provides access to upb_table. This is an internal-only | ||
* interface and exists for the sole purpose of writing a C code generator in | ||
* Lua that can dump a upb_table as static C initializers. This lets us use | ||
* Lua for convenient string manipulation while saving us from re-implementing | ||
* the upb_table hash function and hash table layout / collision strategy in | ||
* Lua. | ||
* | ||
* Since this is used only as part of the toolchain (and not part of the | ||
* runtime) we do not hold this module to the same stringent requirements as | ||
* the main Lua modules (for example that misbehaving Lua programs cannot | ||
* crash the interpreter). | ||
*/ | ||
** require("upb.table") -- a Lua extension for accessing upb_table | ||
** | ||
** This is an internal-only interface and exists for the sole purpose of | ||
** writing a C code generator in Lua that can dump a upb_table as static C | ||
** initializers. This lets us use Lua for convenient string manipulation while | ||
** saving us from re-implementing the upb_table hash function and hash table | ||
** layout / collision strategy in Lua. | ||
** | ||
** Since this is used only as part of the toolchain (and not part of the | ||
** runtime) we do not hold this module to the same stringent requirements as | ||
** the main Lua modules (for example that misbehaving Lua programs cannot | ||
** crash the interpreter). | ||
*/ | ||
|
||
#include <float.h> | ||
#include <math.h> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,7 @@ | ||
/* | ||
* upb - a minimalist implementation of protocol buffers. | ||
* | ||
* Copyright (c) 2009 Google Inc. See LICENSE for details. | ||
* Author: Josh Haberman <[email protected]> | ||
* | ||
* Python extension exposing the core of upb: definitions, handlers, | ||
* and a message type. | ||
*/ | ||
** Python extension exposing the core of upb: definitions, handlers, | ||
** and a message type. | ||
**/ | ||
|
||
#include <stddef.h> | ||
#include <Python.h> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,6 @@ | ||
/* | ||
* upb - a minimalist implementation of protocol buffers. | ||
* | ||
* Copyright (c) 2014 Google Inc. See LICENSE for details. | ||
* Author: Josh Haberman <[email protected]> | ||
* | ||
* upb (prototype) extension for Ruby. | ||
*/ | ||
** upb (prototype) extension for Ruby. | ||
*/ | ||
|
||
#include "ruby/ruby.h" | ||
#include "ruby/vm.h" | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,3 @@ | ||
// Copyright 2014 Google Inc. All Rights Reserved. | ||
// Author: [email protected] (Josh Haberman) | ||
// | ||
// upb - a minimalist implementation of protocol buffers. | ||
|
||
#ifndef UPB_STDCPP_H_ | ||
#define UPB_STDCPP_H_ | ||
|
Oops, something went wrong.