wrapture 0.4.0 → 0.4.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.
- checksums.yaml +4 -4
- data/lib/wrapture/function_spec.rb +9 -9
- data/lib/wrapture/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6a5516a3af955bee34acada560a1c0f67e4a7f6b07772e0fc27accf82103377e
|
4
|
+
data.tar.gz: ddba6f0862fcde505a9f7501b95ddf22acdffc6f9b4fed15a8fc5b0d3afdcf42
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c770a67468d131f448a1640a9f2f76ce7e089bbf42980443cd70ce9388d581d1066e6c4435419bda81c442f4e09a838a52986f6661cf52791ca57cda88ddbb66
|
7
|
+
data.tar.gz: 27fc54ad64f8375c6815fb9b3263050f551d5a180089c1aa733833ef8a1d80bc3a9e625be74e990645dbd3db9fe78fac466bf90599a80c140e9d88bf05a1e2da
|
@@ -185,12 +185,17 @@ module Wrapture
|
|
185
185
|
# Calls return_expression on the return type of this function. +func_name+
|
186
186
|
# is passed to return_expression if provided.
|
187
187
|
def return_expression(func_name: name)
|
188
|
-
|
188
|
+
if @constructor || @destructor
|
189
|
+
signature(func_name: func_name)
|
190
|
+
else
|
191
|
+
resolved_return.return_expression(self, func_name: func_name)
|
192
|
+
end
|
189
193
|
end
|
190
194
|
|
191
|
-
# The signature of the function.
|
192
|
-
|
193
|
-
|
195
|
+
# The signature of the function. +func_name+ can be used to override the
|
196
|
+
# function name if needed, for example if a class name qualifier is needed.
|
197
|
+
def signature(func_name: name)
|
198
|
+
"#{func_name}( #{param_list} )"
|
194
199
|
end
|
195
200
|
|
196
201
|
# Yields each line of the declaration of the function, including any
|
@@ -198,11 +203,6 @@ module Wrapture
|
|
198
203
|
def declaration
|
199
204
|
doc.format_as_doxygen(max_line_length: 76) { |line| yield line }
|
200
205
|
|
201
|
-
if @constructor || @destructor
|
202
|
-
yield "#{signature};"
|
203
|
-
return
|
204
|
-
end
|
205
|
-
|
206
206
|
modifier_prefix = if @spec['static']
|
207
207
|
'static '
|
208
208
|
elsif virtual?
|
data/lib/wrapture/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: wrapture
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.4.
|
4
|
+
version: 0.4.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Joel Anderson
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-04-
|
11
|
+
date: 2020-04-24 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|