lib/tapioca.rb in tapioca-0.2.1 vs lib/tapioca.rb in tapioca-0.2.2

- old
+ new

@@ -16,12 +16,19 @@ end class Error < StandardError; end end -T::Configuration.default_checked_level = :never -# Suppresses errors caused by T.cast, T.let, T.must, etc. -T::Configuration.inline_type_error_handler = ->(*) {} -# Suppresses errors caused by incorrect parameter ordering -T::Configuration.sig_validation_error_handler = ->(*) {} +begin + T::Configuration.default_checked_level = :never + # Suppresses errors caused by T.cast, T.let, T.must, etc. + T::Configuration.inline_type_error_handler = ->(*) {} + # Suppresses errors caused by incorrect parameter ordering + T::Configuration.sig_validation_error_handler = ->(*) {} +rescue + # Need this rescue so that if another gem has + # already set the checked level by the time we + # get to it, we don't fail outright. + nil +end loader.eager_load