aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--lib/matrix.rb8
1 files changed, 6 insertions, 2 deletions
diff --git a/lib/matrix.rb b/lib/matrix.rb
index b4d1be33bb..cf1d532693 100644
--- a/lib/matrix.rb
+++ b/lib/matrix.rb
@@ -28,8 +28,12 @@ module ExceptionForMatrix # :nodoc:
end
class ErrNotRegular < StandardError
- def initialize
- super("Not Regular Matrix")
+ def initialize(val = nil)
+ if val
+ super(val)
+ else
+ super("Not Regular Matrix")
+ end
end
end