Sha256: 699ce148057bcc89c66cee75ded2f182c6a72fff398672621a503e084e0d28c8
Contents?: true
Size: 1.08 KB
Versions: 5
Compression:
Stored size: 1.08 KB
Contents
# frozen_string_literal: true class Code class Object class IdentifierList < List def call(**args) code_operator = args.fetch(:operator, nil).to_code code_arguments = args.fetch(:arguments, []).to_code code_context = args.fetch(:context).to_code code_value = code_arguments.code_first case code_operator.to_s when /=$/ sig(args) { Object } code_context = code_context.code_lookup!(raw.first) code_context = raw[..-2].reduce(code_context) do |code_context, code_identifier| code_context.code_fetch(code_identifier) end code_context.code_set( raw.last, if code_operator.to_s == "=" code_value else code_context.fetch(raw.last).call( **args, operator: code_operator.to_s.chop, arguments: [code_value] ) end ) code_context.code_fetch(raw.last) else super end end end end end
Version data entries
5 entries across 5 versions & 1 rubygems