浏览代码

Merge pull request #186 from ennerf/win32-msvc-fix

MSVC protoc compiler fix
Feng Xiao 10 年之前
父节点
当前提交
a22bc812a4
共有 2 个文件被更改,包括 10 次插入2 次删除
  1. 2 2
      src/google/protobuf/compiler/ruby/ruby_generator.cc
  2. 8 0
      vsprojects/libprotoc.vcproj

+ 2 - 2
src/google/protobuf/compiler/ruby/ruby_generator.cc

@@ -47,7 +47,7 @@ namespace compiler {
 namespace ruby {
 
 // Forward decls.
-std::string IntToString(uint32_t value);
+std::string IntToString(uint32 value);
 std::string StripDotProto(const std::string& proto_file);
 std::string LabelForField(google::protobuf::FieldDescriptor* field);
 std::string TypeName(google::protobuf::FieldDescriptor* field);
@@ -64,7 +64,7 @@ void GenerateEnumAssignment(
     const google::protobuf::EnumDescriptor* en,
     google::protobuf::io::Printer* printer);
 
-std::string IntToString(uint32_t value) {
+std::string IntToString(uint32 value) {
   std::ostringstream os;
   os << value;
   return os.str();

+ 8 - 0
vsprojects/libprotoc.vcproj

@@ -223,6 +223,10 @@
 				RelativePath="..\src\google\protobuf\compiler\cpp\cpp_string_field.h"
 				>
 			</File>
+      <File
+				RelativePath="..\src\google\protobuf\compiler\ruby\ruby_generator.h"
+				>
+			</File>
 			<File
 				RelativePath="..\src\google\protobuf\compiler\java\java_context.h"
 				>
@@ -375,6 +379,10 @@
 				RelativePath="..\src\google\protobuf\compiler\cpp\cpp_string_field.cc"
 				>
 			</File>
+      <File
+				RelativePath="..\src\google\protobuf\compiler\ruby\ruby_generator.cc"
+				>
+			</File>
 			<File
 				RelativePath="..\src\google\protobuf\compiler\java\java_context.cc"
 				>