def strftime(format)
      raise ArgumentError, 'format must be specified' unless format

      if_timezone_offset do |o|
        abbreviation = nil

        format = format.gsub(/%(%*)Z/) do
          if $1.length.odd?
            # Return %%Z so the real strftime treats it as a literal %Z too.
            "#$1%Z"
          else
            "#$1#{abbreviation ||= o.abbreviation.gsub(/%/, '%%')}"
          end
        end
      end

      super
    end
def strftime(format)
      raise ArgumentError, 'format must be specified' unless format

      if_timezone_offset do |o|
        abbreviation = nil

        format = format.gsub(/%(%*)Z/) do
          if $1.length.odd?
            # Return %%Z so the real strftime treats it as a literal %Z too.
            "#$1%Z"
          else
            "#$1#{abbreviation ||= o.abbreviation.gsub(/%/, '%%')}"
          end
        end
      end

      super
    end
Overrides the `Time`, `DateTime` or {Timestamp} version of `strftime`,
 replacing `%Z` with the {TimezoneOffset#abbreviation abbreviation} of the
 associated {TimezoneOffset}. If there is no associated offset, `%Z` is
 expanded by the base class instead.

 All the format directives handled by the base class are supported.

 @param format [String] the format string.
 @return [String] the formatted time.
 @raise [ArgumentError] if `format` is `nil`.