superscript 0.10.0 → 0.11.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 985880499b7960ca7ce77fd0b1d04b8e214079100dc85cbd875ac05fc36d8301
4
- data.tar.gz: 26b71fdd07f5ce9ec9ddf9673b03c03ce9c909cf6e70782589b39c798d1cfdf8
3
+ metadata.gz: b19663dfb05a7fbb830364787958acddcd1b3775b34602037859dbb68a760478
4
+ data.tar.gz: 6e5629534d4f07dfc6e66700d70ac3822ca981989b8e5c2e428e8a03139dc227
5
5
  SHA512:
6
- metadata.gz: 8edd895405c1e8bcb48dda3647207ad4c36206027ef4073d38dcf89c8cb6803e28bbaad46df41af780d6111b4acfd781587e5512d1e67ffea562f5ff39d8bce3
7
- data.tar.gz: 131c83897b35170fa1636dcc107302fdd85fb7424e97c2bd39b339cbccec05296a42efee3a138d58745cbe68eed9298db2f653b6876f06c1e7fd6b1418ec5c82
6
+ metadata.gz: 03abe4121ccef1debd13a861b7c78eab5217390a8fe2a3c9be73b7be4508bb3e961bb66c5c87d7d876772ed084ad5596af7f826eba68bc3117f491712db1f867
7
+ data.tar.gz: 90369ee7481e75cacf420ea3b756ecd7dc1f47c276164649c3e7f695ec0a92e5d94ec37898e5145f811a4c72a33e6a16f6391e675158fb6bb230cf7fdf482d6e
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- superscript (0.10.0)
4
+ superscript (0.11.0)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
@@ -30,6 +30,10 @@ class Go < Superscript::Dsl
30
30
  asdf
31
31
  end
32
32
 
33
+ def raise!
34
+ raise "raising!"
35
+ end
36
+
33
37
  def exit
34
38
  Kernel.exit
35
39
  end
@@ -1,2 +1,4 @@
1
1
  a = struct
2
2
  go a.name
3
+
4
+ raise!
@@ -18,27 +18,26 @@ module Superscript
18
18
 
19
19
  def error!(where, *args)
20
20
  puts "-- [ superscript error ] --"
21
- error_message = ""
22
- case where
21
+ exception, error_message = case where
23
22
  when :exception
24
- exception = args.first
25
- error_message = exception
23
+ ex = args.first
24
+ [ex.class, ex]
26
25
  when :tp_call_superscript, :tp_call_superscript_global
27
- error_message = "Can't touch this"
26
+ [:internal, "Can't touch this"]
28
27
  when :ctx_method_missing, :tp_singleton_method_added, :tp_command_not_found
29
- error_message = args.first
28
+ [:internal, args.first]
30
29
  when :tp_class_define, :tp_module_define
31
- error_message = args.first
30
+ [:internal, args.first]
32
31
  else
33
32
  pp [:unknown_where, where, args]
34
- error_message = args.join(" ")
33
+ [:uknown, args.join(" ")]
35
34
  end
36
35
 
37
- puts error_message
36
+ puts "#{exception}: #{error_message}"
38
37
 
39
- caller.each do |c|
40
- puts c
41
- end
38
+ # caller.each do |c|
39
+ # puts c
40
+ # end
42
41
  system @on_error_exec, error_message if @on_error_exec
43
42
 
44
43
  exit 1 unless @path == "<interactive>"
@@ -1,3 +1,3 @@
1
1
  module Superscript
2
- VERSION = "0.10.0"
2
+ VERSION = "0.11.0"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: superscript
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.10.0
4
+ version: 0.11.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Matti Paksula