Top Level Namespace
Defined Under Namespace
Modules: ActiveRecord, Dolzenko, Dummy, IncludableWithOptions, IoInterceptor, Kernel, MyStuff, Net, NeverTooDry, SafeInterpolate, ShellOut, SystemWithTweaks, TryBlock
Classes: AndQ, BinaryQ, C, Class, Exception, F, Module, NilClass, NonExistingException, NotQ, Object, OrQ, Q, TestBlockTry, UnaryQ, User
Instance Method Summary
collapse
Instance Method Details
159
|
# File 'lib/dolzenko/error_print.rb', line 159
def bar; foo; end
|
159
|
# File 'lib/dolzenko/error_print.rb', line 159
def baz; foo; end
|
#F(attr_name) ⇒ Object
69
70
71
|
# File 'lib/dolzenko/django_f_object.rb', line 69
def F(attr_name)
F.new(attr_name)
end
|
puts (0..20).map { |i| “def f#i() f#i+1(); end”}.join(“n”)
134
|
# File 'lib/dolzenko/error_print.rb', line 134
def f0() f1(); end
|
135
|
# File 'lib/dolzenko/error_print.rb', line 135
def f1() f2(); end
|
144
|
# File 'lib/dolzenko/error_print.rb', line 144
def f10() f11(); end
|
145
|
# File 'lib/dolzenko/error_print.rb', line 145
def f11() f12(); end
|
146
|
# File 'lib/dolzenko/error_print.rb', line 146
def f12() f13(); end
|
147
|
# File 'lib/dolzenko/error_print.rb', line 147
def f13() f14(); end
|
148
|
# File 'lib/dolzenko/error_print.rb', line 148
def f14() f15(); end
|
149
|
# File 'lib/dolzenko/error_print.rb', line 149
def f15() f16(); end
|
150
|
# File 'lib/dolzenko/error_print.rb', line 150
def f16() f17(); end
|
151
|
# File 'lib/dolzenko/error_print.rb', line 151
def f17() f18(); end
|
152
|
# File 'lib/dolzenko/error_print.rb', line 152
def f18() f19(); end
|
153
|
# File 'lib/dolzenko/error_print.rb', line 153
def f19() f20(); end
|
136
|
# File 'lib/dolzenko/error_print.rb', line 136
def f2() f3(); end
|
154
155
156
|
# File 'lib/dolzenko/error_print.rb', line 154
def f20
raise(ArgumentError, "multi\nline\nerror")
end
|
137
|
# File 'lib/dolzenko/error_print.rb', line 137
def f3() f4(); end
|
138
|
# File 'lib/dolzenko/error_print.rb', line 138
def f4() f5(); end
|
139
|
# File 'lib/dolzenko/error_print.rb', line 139
def f5() f6(); end
|
140
|
# File 'lib/dolzenko/error_print.rb', line 140
def f6() f7(); end
|
141
|
# File 'lib/dolzenko/error_print.rb', line 141
def f7() f8(); end
|
142
|
# File 'lib/dolzenko/error_print.rb', line 142
def f8() f9(); end
|
143
|
# File 'lib/dolzenko/error_print.rb', line 143
def f9() f10(); end
|
159
|
# File 'lib/dolzenko/error_print.rb', line 159
def foo; bar; end
|
#IncludableWithOptions(options = {}) ⇒ Object
91
92
93
|
# File 'lib/dolzenko/django_q_object.rb', line 91
def Q(*args)
UnaryQ.new(*args)
end
|
#raise_empty_message ⇒ Object
113
114
115
|
# File 'lib/dolzenko/error_print.rb', line 113
def raise_empty_message
raise ArgumentError, ""
end
|
#raise_multiline ⇒ Object
109
110
111
|
# File 'lib/dolzenko/error_print.rb', line 109
def raise_multiline
raise "qwe\nasd\nzxc"
end
|
#raise_non_empty_message ⇒ Object
117
118
119
|
# File 'lib/dolzenko/error_print.rb', line 117
def raise_non_empty_message
raise ArgumentError, "qwe"
end
|
#raise_normal ⇒ Object
105
106
107
|
# File 'lib/dolzenko/error_print.rb', line 105
def raise_normal
f10
end
|
#raise_runtime_empty ⇒ Object
121
122
123
|
# File 'lib/dolzenko/error_print.rb', line 121
def raise_runtime_empty
raise
end
|
#raise_runtime_non_empty ⇒ Object
125
126
127
|
# File 'lib/dolzenko/error_print.rb', line 125
def raise_runtime_non_empty
raise RuntimeError, "runtime non empty"
end
|
#raise_sys_stack ⇒ Object
129
130
131
|
# File 'lib/dolzenko/error_print.rb', line 129
def raise_sys_stack
baz
end
|
#TryBlock(&block) ⇒ Object
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
|
# File 'lib/dolzenko/try_block.rb', line 36
def TryBlock(&block)
raise ArgumentError, "should be given block" unless block
return if self.nil?
caller_size = caller.size
if RUBY_PLATFORM =~ /\bjava\b/ && caller[-1] == ":1"
caller_size -= 1
end
begin
yield
rescue NoMethodError => e
if e.backtrace.size - caller_size == 2 &&
e.message =~ /^undefined method.+for nil:NilClass$/
return nil
end
raise
end
end
|