construct 0.1.5 → 0.1.6

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.
Files changed (2) hide show
  1. data/lib/construct.rb +6 -1
  2. metadata +2 -2
@@ -3,7 +3,7 @@ class Construct
3
3
  # Ruby and humans with text editors.
4
4
 
5
5
  APP_NAME = 'Construct'
6
- APP_VERSION = '0.1.5'
6
+ APP_VERSION = '0.1.6'
7
7
  APP_AUTHOR = 'Kyle Kingsbury'
8
8
  APP_EMAIL = 'aphyr@aphyr.com'
9
9
  APP_URL = 'http://aphyr.com'
@@ -103,6 +103,11 @@ class Construct
103
103
  @data.delete key
104
104
  end
105
105
 
106
+ # A deep (not shallow!) clone of this construct.
107
+ def dup
108
+ Marshal.load(Marshal.dump(self))
109
+ end
110
+
106
111
  # Like enumerable#each. Operates on each key.
107
112
  def each
108
113
  keys.each do |key|
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: construct
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.5
4
+ version: 0.1.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kyle Kingsbury
@@ -9,7 +9,7 @@ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
11
 
12
- date: 2009-11-16 00:00:00 -08:00
12
+ date: 2010-01-23 00:00:00 -08:00
13
13
  default_executable:
14
14
  dependencies: []
15
15