From 74f8e24232e0d67ab79419130b5bf3a5a875593d Mon Sep 17 00:00:00 2001 From: Erik Benoist Date: Tue, 26 Jun 2018 22:24:24 -0500 Subject: Adds a base class for all explicitly raised TypeErrors (#4255) * This allows for ruby code to catch and handle Protobuf TypeErrors separately from the standard Ruby TypeError * Maintains backwards compatibility by having the new Google::Protobuf::TypeError inherit from the base TypeError. Any code that was catching TypeError should continue to work. --- ruby/ext/google/protobuf_c/protobuf.h | 1 + 1 file changed, 1 insertion(+) (limited to 'ruby/ext/google/protobuf_c/protobuf.h') diff --git a/ruby/ext/google/protobuf_c/protobuf.h b/ruby/ext/google/protobuf_c/protobuf.h index 5266aa8d..3e5c0520 100644 --- a/ruby/ext/google/protobuf_c/protobuf.h +++ b/ruby/ext/google/protobuf_c/protobuf.h @@ -161,6 +161,7 @@ extern VALUE cBuilder; extern VALUE cError; extern VALUE cParseError; +extern VALUE cTypeError; // We forward-declare all of the Ruby method implementations here because we // sometimes call the methods directly across .c files, rather than going -- cgit v1.2.3