| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
| |
- Also updates the documentation with a bit more information.
|
|\
| |
| | |
Fix sign-comparison warnings and add a test for that.
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| | |
grpc build treates them as errors and such issues (protobuf change
breaks grpc) has been reported repeatedly. For example:
https://github.com/google/protobuf/issues/1813
Change-Id: I077c4557cf3effd5195f88802c38999b884edc30
|
|/
|
|
|
| |
- Fixes memory issue where the pointer to the StringPiece would be allocated on the stack, and would mangle the output.
- Fixes length of the file name when parsing the comma separated files.
|
|\
| |
| | |
Versioning Java GeneratedMessage class
|
| |
| |
| |
| | |
Change-Id: Ib2bb5042deaabdf452d5be2ad1ce40d739ad8d1b
|
| | |
|
| | |
|
|/ |
|
|\
| |
| | |
JavaScript: segregate references to binary functionality
|
| | |
|
| |
| |
| |
| |
| |
| | |
This change will help us separate binary support into
separate files, because we only refer to binary serialization
functions in the actual binary serialization paths.
|
|\ \
| |/
|/| |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Currently some public API methods are defined in GenreatedMessage.java
and they have a generric return type:
class GeneratedMessage {
class Builder<BuilderType extends Builder<BuilderType>> {
public BuilderType setField(...);
public BuilderType setExtension(...);
}
}
With these definitions, the compiled byte code of a callsite will have
a direct reference to GeneratedMessage. For example:
fooBuilder.setField(...);
becomes:
##: invokevirtual // Method Builder.setField:(...)LGeneratedMessage.Builder
##: checkcast // class Builder
This will prevent us from updating generated classes to subclass a
different versioned GeneratedMessageV3 class in the future (we can't do
it in a binary compatible way).
This change addresses the problem by overriding these methods directly
in the generated class:
class Foo {
class Builder extends GeneratedMessage.Builder<Builder> {
public Builder setField(...) {
return super.setField(...);
}
}
}
After this, fooBuilder.setField(...) will be compiled to:
##: invokevirtual // Method Builder.setField:(...)LFoo.Builder
The callsites will no longer reference GeneratedMessage directly and we
can change Foo to subclass GeneratedMessageV3 without breaking binary
compatiblity.
The downside of this change is:
1. It increases generated code size (though it saves some instructions
on the callsites).
2. We can never stop generating these overrides because doing that
will break binary compatibility.
Change-Id: I879afbbc1325a66324a51565e017143489b06e97
|
| | |
|
| | |
|
| | |
|
| | |
|
|/
|
|
|
|
|
|
| |
When building into frameworks, the generated code doesn't always have direct
access to the proto internals. Instead of opening up the access, just use the
public method to fetch the correct oneof.
Fixes https://github.com/google/protobuf/issues/1789
|
|\
| |
| | |
Change placement of DebuggerNonUserCodeAttribute
|
| |
| |
| |
| |
| |
| | |
This does not affect the generated code.
If we decide we want to apply attributes to generated types, we should start by
just reverting this change.
|
| |
| |
| |
| |
| |
| |
| |
| |
| | |
I think this has caught everything.
I've left a stub for attributes to be applied to the types themselves, but we don't currently need anything.
Follow-up commit will include the changes to generated code itself.
Fixes #1671.
|
| | |
|
|\ \
| | |
| | | |
Fix problems detected when integrating the code to our internal repo.
|
| | | |
|
| |/ |
|
| | |
|
|/ |
|
|\
| |
| | |
Add JsonParseOptions to ignore unknown fields
|
| |
| |
| |
| |
| | |
- add JsonParseOptions for JsonToBinaryString allow unknown fields
- rename current JsonOptions to JsonPrintOptions
|
| |
| |
| |
| | |
Change-Id: Ibf7d1df850f4b497303f9f617751be98327898ef
|
|/
|
|
| |
This includes all internal changes from around May 20 to now.
|
|\
| |
| | |
JS: import well-known types from google-protobuf package.
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
- Better docs in the generator for the different options that can be passed
during an invoke of protoc.
- Add named_framework_to_proto_path_mappings_path to pass the path to a file
containing mappings of frameworks for different proto files.
- Update the generation to use the mapping to change the #import directives
it creates.
Note: the changes in helpers is mostly moving code within the fine, and then
a small change to expose the parsing so a passed on class can consume the line.
Fixes https://github.com/google/protobuf/issues/1457
|
| | |
|
|/
|
|
|
|
|
| |
constructor, and instead create an _internal_only getter
that gets the needed information. This is a workaround for
a deficiency in gcc-4.4 that does not properly support
templated friend classes.
|
|
|
|
|
|
|
|
|
|
| |
- Add a protoc objc option (generate_for_named_framework) to set the name of
the framework all generated sources will be in.
- Tweak some comments/naming to make it clear what is the Protobuf framework
vs. the framework for generated code.
- Update the objc README to document the new generation option to protoc.
This is working towards https://github.com/google/protobuf/issues/1457.
|
|\
| |
| | |
protoc: support '=' in --proto_path arguments
|
| | |
|
| | |
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Working on https://github.com/google/protobuf/issues/1599, specifically:
- Turn on more warnings that the Xcode UI calls out with individual controls.
- Manually add:
-Wundef
-Wswitch-enum
- Manually add and then diable in the unittests because of XCTest's headers:
-Wreserved-id-macro
-Wdocumentation-unknown-command
- Manually add -Wdirect-ivar-access, but disable it for the unittests and in
the library code (via #pragmas to suppress it). This is done so proto users
can enable the warning.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
- Add generator constant for the default framework name.
- Add generator api for making the CPP symbol from the name.
- Add generator api to see if it is a bundled proto file.
- Output a CPP conditional and two imports for the core library headers.
- Add helper for generating the #import for file headers to deal with the
framework imports.
- Add a reference from the unittests to a WKT to use that to inspect how
imports generate.
- Update the podspec to define the CPP symbol and require pods 1.0 (or later).
Fixes https://github.com/google/protobuf/issues/1457
|
|\ \
| | |
| | | |
Export class Arena to shared library.
|
| | |
| | |
| | |
| | |
| | | |
This got broken in commit 6ef984af4b0c63c1c33127a12dcfc8e6359f0c9e
which integrated changes from internal branch.
|
|\ \ \
| | | |
| | | | |
Fix #include in js_generator.cc
|
| |/ /
| | |
| | |
| | |
| | | |
The commit 3b3c8abb9635eb3ea078a821a99c9ef29d66dff7 has replaced the <>
with "" in #include statement in js_generator.cc
|