ruby_contracts 0.2.1 → 0.2.2
Sign up to get free protection for your applications and to get access to all the features.
- data/lib/ruby_contracts.rb +2 -2
- data/lib/ruby_contracts/version.rb +1 -1
- metadata +1 -1
data/lib/ruby_contracts.rb
CHANGED
@@ -94,7 +94,7 @@ module Contracts
|
|
94
94
|
|
95
95
|
code << "if !#{contract_method_name}(*__args) then\n"
|
96
96
|
code << " self.class.__contract_failure!('#{name}', \"invalid precondition: #{args[0]}\", nil, *__args)\n"
|
97
|
-
code << "end"
|
97
|
+
code << "end\n"
|
98
98
|
code
|
99
99
|
else
|
100
100
|
code
|
@@ -116,7 +116,7 @@ module Contracts
|
|
116
116
|
|
117
117
|
code << "if !#{contract_method_name}(result, *__args) then\n"
|
118
118
|
code << " self.class.__contract_failure!('#{name}', \"invalid postcondition: #{args[0]}\", result, *__args)\n"
|
119
|
-
code << "end"
|
119
|
+
code << "end\n"
|
120
120
|
code
|
121
121
|
else
|
122
122
|
code
|