yourdsl 0.7.0 → 0.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/lib/yourdsl.rb +2 -8
- metadata +1 -1
data/lib/yourdsl.rb
CHANGED
@@ -1,16 +1,10 @@
|
|
1
1
|
module YourDSL
|
2
|
+
VERSION = '0.7.1'
|
3
|
+
|
2
4
|
class Scope < Struct.new(:expressions); end
|
3
5
|
class Expression < Struct.new(:symbol, :args, :lineno, :proc, :scope); end
|
4
6
|
class Output < Struct.new(:file, :expressions); end
|
5
7
|
|
6
|
-
VERSION = '0.7.0'
|
7
|
-
|
8
|
-
METHODS_TO_KEEP = /^__/, /class/, /instance_/, /method_missing/, /object_id/
|
9
|
-
|
10
|
-
instance_methods.each do |m|
|
11
|
-
undef_method m unless METHODS_TO_KEEP.find { |r| r.match m }
|
12
|
-
end
|
13
|
-
|
14
8
|
def record_your_dsl(opts = {})
|
15
9
|
@@remember_blocks_starting_with = Array(opts[:retain_blocks_for])
|
16
10
|
@@only = Array(opts[:only])
|