Sha256: 7e958c2c5a1a019231fdbef28c838246c4e452786ae0ac6c85171020ff2e2065
Contents?: true
Size: 1.67 KB
Versions: 16
Compression:
Stored size: 1.67 KB
Contents
o:$YARD::CodeObjects::MethodObject: @name:<=>:@docstringIC:YARD::Docstring"�Compares <code>File::Stat</code> objects by comparing their respective modification times. f1 = File.new("f1", "w") sleep 1 f2 = File.new("f2", "w") f1.stat <=> f2.stat #=> -1 :@objectu:YARD::StubProxyFile::Stat#<=>: @summary0: @all"�Compares <code>File::Stat</code> objects by comparing their respective modification times. f1 = File.new("f1", "w") sleep 1 f2 = File.new("f2", "w") f1.stat <=> f2.stat #=> -1 @overload <=>(other_stat) @return [-1, 0, 1]:@ref_tags[: @tags[o:YARD::Tags::OverloadTag ; u;File::Stat#<=>;;;IC; " ; u;File::Stat#<=>;0; "@return [-1, 0, 1];[;[o:YARD::Tags::Tag ; 0;0:@types["-1"0"1: @text":@tag_name"return;0:@parameters[[:other_stat0;0:@signature"<=>(other_stat);" overload:@current_file_has_commentsF:@scope: instance;[:@docstring_extra0:@files[["file.c0:@namespaceu;File::Stat: @path"File::Stat#<=>;[:@visibility:public:@source"�/* * call-seq: * stat <=> other_stat => -1, 0, 1 * * Compares <code>File::Stat</code> objects by comparing their * respective modification times. * * f1 = File.new("f1", "w") * sleep 1 * f2 = File.new("f2", "w") * f1.stat <=> f2.stat #=> -1 */ static VALUE rb_stat_cmp(self, other) VALUE self, other; { if (rb_obj_is_kind_of(other, rb_obj_class(self))) { time_t t1 = get_stat(self)->st_mtime; time_t t2 = get_stat(other)->st_mtime; if (t1 == t2) return INT2FIX(0); else if (t1 < t2) return INT2FIX(-1); else return INT2FIX(1); } return Qnil; }:@source_type:c
Version data entries
16 entries across 16 versions & 2 rubygems