class Pry::Command::WatchExpression::Expression

def changed?

(causes too few)
as this avoids problems with dup (causes too many differences) and ==
We use the pretty-printed string represenation to detect differences

Has the value of the expression changed?
def changed?
  (value != previous_value)
end

def eval!

def eval!
  @previous_value = value
  @value = Pry::ColorPrinter.pp(target_eval(target, source), ''.dup)
end

def initialize(pry_instance, target, source)

def initialize(pry_instance, target, source)
  @pry_instance = pry_instance
  @target = target
  @source = Code.new(source).strip
end

def target_eval(target, source)

def target_eval(target, source)
  target.eval(source)
rescue StandardError => e
  e
end

def to_s

def to_s
  "#{Code.new(source).highlighted.strip} => #{value}"
end