comment_strip-ruby 0.1.2.1 → 0.2.0
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/README.md +3 -1
- data/lib/comment_strip/language_families/c.rb +159 -137
- data/lib/comment_strip/language_families/hash_line.rb +211 -0
- data/lib/comment_strip/strip.rb +24 -12
- data/lib/comment_strip/version.rb +7 -8
- data/test/unit/{tc_strip.rb → tc_strip_c.rb} +262 -232
- data/test/unit/tc_strip_hash_line.rb +95 -0
- data/test/unit/ts_all.rb +1 -1
- metadata +5 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e320f9b4b49802d9301139fadb06eaa71c7a28f641e31892c60475bca96d78d5
|
4
|
+
data.tar.gz: 055d162fb3675a3ede834009ae775b0704896bab3d7d865545dbdc7de18e6c32
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f4e58fe98de4d8592b565d7e3000f8cf7e53daf07029b0d566bc23c457e203c66f16a6162c8235302bed94b599ed1616722e57a97978096a14688f3fdba2b23c
|
7
|
+
data.tar.gz: d0ac2808f789296db1471688584e11508692578bf36608e577a34455ff3b3aedbb3a3378dca02ecce626f50a2e8ec9843abcc0bef5b31ed5b38e2ea0658c7b99
|
data/README.md
CHANGED
@@ -30,8 +30,10 @@ gem 'comment_strip-ruby'
|
|
30
30
|
|
31
31
|
## Components
|
32
32
|
|
33
|
-
|
33
|
+
Current version supports following language families:
|
34
34
|
|
35
|
+
* `'C'` - C-family languages, recognising `//` line and `/* . . . */` block comments;
|
36
|
+
* `'Hash_Line'` - Generic support for `#` line comments, as found in shell scripts and languages such as **Perl**, **Python**, and **Ruby**. Does _NOT_ (yet) provide any language-specific smarts such as she-bang comments and directive comments;
|
35
37
|
## Examples
|
36
38
|
|
37
39
|
It is as simple as the following:
|
@@ -1,14 +1,14 @@
|
|
1
1
|
# ######################################################################## #
|
2
|
-
# File:
|
2
|
+
# File: comment_strip/language_families/c.rb
|
3
3
|
#
|
4
|
-
# Purpose:
|
4
|
+
# Purpose: Definition of strip() function for C-family languages.
|
5
5
|
#
|
6
|
-
# Created:
|
7
|
-
# Updated:
|
6
|
+
# Created: 14th September 2020
|
7
|
+
# Updated: 31st March 2024
|
8
8
|
#
|
9
|
-
# Home:
|
9
|
+
# Home: http://github.com/synesissoftware/comment_strip.r
|
10
10
|
#
|
11
|
-
# Copyright (c) 2020-
|
11
|
+
# Copyright (c) 2020-2024, Matthew Wilson and Synesis Information Systems
|
12
12
|
# All rights reserved.
|
13
13
|
#
|
14
14
|
# Redistribution and use in source and binary forms, with or without
|
@@ -47,200 +47,222 @@ module LanguageFamilies
|
|
47
47
|
|
48
48
|
module C
|
49
49
|
|
50
|
-
|
50
|
+
def self.strip input, lf, **options
|
51
51
|
|
52
|
-
|
53
|
-
|
52
|
+
return input if input.nil?
|
53
|
+
return input if input.empty?
|
54
54
|
|
55
|
-
|
56
|
-
|
55
|
+
line = 0
|
56
|
+
column = 0
|
57
57
|
|
58
|
-
|
58
|
+
# States:
|
59
|
+
#
|
60
|
+
# - :c_comment - in a C comment, i.e. from immediately after "/*"
|
61
|
+
# - :c_comment_star - in a C comment when just received '*', e.g. from immediately after "/* comment *"
|
62
|
+
# - :cpp_comment - in a C++ comment, i.e. from immediately after "//"
|
63
|
+
# - :dq_string - within a double-quoted string
|
64
|
+
# - :dq_string_escape - within a double-quoted string when just received a '"', e.g. from immediately after '"the next word is quoted \'
|
65
|
+
# - :slash_start - having found a slash (not in a string)
|
66
|
+
# - :sq_string_closing - waiting for final '\'' in a single-quoted string
|
67
|
+
# - :sq_string_escape - within a escaped single-quoted string, i.e. from immediately after "'\"
|
68
|
+
# - :sq_string_open - within a single-quoted string, i.e. from immediately after "'"
|
69
|
+
# - :text - regular part of the code
|
59
70
|
|
60
|
-
|
71
|
+
state = :text
|
61
72
|
|
62
|
-
|
73
|
+
r = ''
|
63
74
|
|
64
|
-
|
75
|
+
cc_lines = 0
|
65
76
|
|
66
|
-
|
67
|
-
when ?\r, ?\n
|
68
|
-
|
69
|
-
line += 1
|
70
|
-
column = 0
|
71
|
-
else
|
72
|
-
|
73
|
-
column += 1
|
74
|
-
end
|
77
|
+
input.each_char do |c|
|
75
78
|
|
76
|
-
|
79
|
+
case c
|
80
|
+
when ?\r, ?\n
|
77
81
|
|
78
|
-
|
79
|
-
|
82
|
+
line += 1
|
83
|
+
column = 0
|
84
|
+
else
|
80
85
|
|
81
|
-
|
82
|
-
|
86
|
+
column += 1
|
87
|
+
end
|
83
88
|
|
84
|
-
|
89
|
+
skip = false
|
85
90
|
|
86
|
-
|
87
|
-
|
91
|
+
case c
|
92
|
+
when ?\r, ?\n
|
88
93
|
|
89
|
-
|
90
|
-
|
94
|
+
case state
|
95
|
+
when :c_comment, :c_comment_star
|
91
96
|
|
92
|
-
|
93
|
-
when :dq_string_escape
|
97
|
+
cc_lines += 1
|
94
98
|
|
95
|
-
|
96
|
-
|
99
|
+
state = :c_comment
|
100
|
+
when :cpp_comment
|
97
101
|
|
98
|
-
|
102
|
+
state = :text
|
103
|
+
when :sq_string_escape, :sq_string_closing
|
99
104
|
|
100
|
-
|
101
|
-
|
102
|
-
else
|
105
|
+
state = :text
|
106
|
+
when :dq_string_escape
|
103
107
|
|
104
|
-
|
105
|
-
|
106
|
-
# - for escaped single/double quote
|
107
|
-
# - for slash-start
|
108
|
-
# - for comment-star
|
108
|
+
state = :dq_string
|
109
|
+
when :slash_start
|
109
110
|
|
110
|
-
|
111
|
-
when :sq_string_open
|
111
|
+
r << '/'
|
112
112
|
|
113
|
-
|
114
|
-
|
113
|
+
state = :text
|
114
|
+
end
|
115
|
+
else
|
115
116
|
|
116
|
-
|
117
|
-
|
117
|
+
# special cases:
|
118
|
+
#
|
119
|
+
# - for escaped single/double quote
|
120
|
+
# - for slash-start
|
121
|
+
# - for comment-star
|
118
122
|
|
119
|
-
|
120
|
-
|
123
|
+
case state
|
124
|
+
when :sq_string_open
|
121
125
|
|
122
|
-
|
123
|
-
|
126
|
+
state = (?\\ == c) ? :sq_string_escape : :sq_string_closing
|
127
|
+
when :sq_string_escape
|
124
128
|
|
125
|
-
|
126
|
-
|
129
|
+
state = :sq_string_closing
|
130
|
+
when :dq_string_escape
|
127
131
|
|
128
|
-
|
129
|
-
|
130
|
-
when '*'
|
132
|
+
state = :dq_string
|
133
|
+
when :c_comment_star
|
131
134
|
|
132
|
-
|
133
|
-
|
135
|
+
case c
|
136
|
+
when ?/
|
134
137
|
|
135
|
-
|
136
|
-
|
137
|
-
else
|
138
|
+
r << ?\n * cc_lines
|
139
|
+
cc_lines = 0
|
138
140
|
|
139
|
-
|
140
|
-
|
141
|
+
state = :text
|
142
|
+
skip = true
|
143
|
+
when '*'
|
141
144
|
|
142
|
-
|
143
|
-
|
144
|
-
else
|
145
|
+
;
|
146
|
+
else
|
145
147
|
|
146
|
-
|
147
|
-
|
148
|
+
state = :c_comment
|
149
|
+
end
|
150
|
+
else
|
148
151
|
|
149
|
-
|
150
|
-
|
152
|
+
if false
|
153
|
+
elsif state == :slash_start && ('/' != c && '*' != c)
|
151
154
|
|
152
|
-
|
153
|
-
|
155
|
+
state = :text
|
156
|
+
r << '/'
|
157
|
+
else
|
154
158
|
|
155
|
-
|
156
|
-
|
159
|
+
case c
|
160
|
+
when '/'
|
157
161
|
|
158
|
-
|
159
|
-
|
162
|
+
case state
|
163
|
+
when :text
|
160
164
|
|
161
|
-
|
162
|
-
|
163
|
-
end
|
164
|
-
when '*'
|
165
|
+
state = :slash_start
|
166
|
+
when :slash_start
|
165
167
|
|
166
|
-
|
167
|
-
|
168
|
+
state = :cpp_comment
|
169
|
+
when :c_comment_star
|
168
170
|
|
169
|
-
|
170
|
-
|
171
|
+
r << ?\n * cc_lines
|
172
|
+
cc_lines = 0
|
171
173
|
|
172
|
-
|
173
|
-
|
174
|
+
state = :text
|
175
|
+
skip = true
|
176
|
+
else
|
174
177
|
|
175
|
-
|
178
|
+
;
|
179
|
+
end
|
180
|
+
when '*'
|
176
181
|
|
177
|
-
|
182
|
+
case state
|
183
|
+
when :slash_start
|
178
184
|
|
179
|
-
|
180
|
-
|
185
|
+
state = :c_comment
|
186
|
+
when :c_comment
|
181
187
|
|
182
|
-
|
183
|
-
|
188
|
+
state = :c_comment_star
|
189
|
+
else
|
184
190
|
|
185
|
-
|
186
|
-
|
191
|
+
;
|
192
|
+
end
|
193
|
+
when ?\'
|
187
194
|
|
188
|
-
|
189
|
-
|
195
|
+
case state
|
196
|
+
when :text
|
190
197
|
|
191
|
-
|
192
|
-
|
198
|
+
state = :sq_string_open
|
199
|
+
when :sq_string_closing
|
193
200
|
|
194
|
-
|
195
|
-
|
201
|
+
state = :text
|
202
|
+
else
|
196
203
|
|
197
|
-
|
198
|
-
|
199
|
-
|
200
|
-
when ?\\
|
204
|
+
;
|
205
|
+
end
|
206
|
+
when '"'
|
201
207
|
|
202
|
-
|
203
|
-
|
208
|
+
case state
|
209
|
+
when :text
|
204
210
|
|
205
|
-
|
206
|
-
|
211
|
+
state = :dq_string
|
212
|
+
when :dq_string
|
207
213
|
|
208
|
-
|
209
|
-
|
214
|
+
state = :text
|
215
|
+
else
|
210
216
|
|
211
|
-
|
212
|
-
|
217
|
+
;
|
218
|
+
end
|
219
|
+
when ?\\
|
213
220
|
|
214
|
-
|
215
|
-
|
221
|
+
case state
|
222
|
+
when :sq_string_open
|
216
223
|
|
217
|
-
|
218
|
-
|
224
|
+
state = :sq_string_escape
|
225
|
+
when :sq_string_escape
|
219
226
|
|
220
|
-
|
221
|
-
|
227
|
+
state = :sq_string_closing
|
228
|
+
when :dq_string
|
222
229
|
|
223
|
-
|
224
|
-
|
225
|
-
end
|
226
|
-
end
|
227
|
-
end
|
230
|
+
state = :dq_string_escape
|
231
|
+
else
|
228
232
|
|
233
|
+
;
|
234
|
+
end
|
235
|
+
else
|
229
236
|
|
230
|
-
|
231
|
-
|
232
|
-
when :cpp_comment
|
233
|
-
when :c_comment
|
234
|
-
when :c_comment_star
|
237
|
+
case state
|
238
|
+
when :sq_string_escape
|
235
239
|
|
236
|
-
|
240
|
+
state = :sq_string_closing
|
241
|
+
else
|
237
242
|
|
238
|
-
|
243
|
+
;
|
244
|
+
end
|
239
245
|
end
|
246
|
+
end
|
240
247
|
end
|
248
|
+
end
|
241
249
|
|
242
|
-
|
250
|
+
|
251
|
+
case state
|
252
|
+
when :slash_start
|
253
|
+
when :cpp_comment
|
254
|
+
when :c_comment
|
255
|
+
when :c_comment_star
|
256
|
+
|
257
|
+
;
|
258
|
+
else
|
259
|
+
|
260
|
+
r << c unless skip
|
261
|
+
end
|
243
262
|
end
|
263
|
+
|
264
|
+
r
|
265
|
+
end
|
244
266
|
end # module C
|
245
267
|
|
246
268
|
end # module LanguageFamilies
|
@@ -0,0 +1,211 @@
|
|
1
|
+
# ######################################################################## #
|
2
|
+
# File: comment_strip/language_families/hash_line.rb
|
3
|
+
#
|
4
|
+
# Purpose: Definition of strip() function for languages that support single
|
5
|
+
# line comments beginning at the # character.
|
6
|
+
#
|
7
|
+
# Created: 1st December 2023
|
8
|
+
# Updated: 31st March 2024
|
9
|
+
#
|
10
|
+
# Home: http://github.com/synesissoftware/comment_strip.r
|
11
|
+
#
|
12
|
+
# Copyright (c) 2023-2024, Matthew Wilson and Synesis Information Systems
|
13
|
+
# All rights reserved.
|
14
|
+
#
|
15
|
+
# Redistribution and use in source and binary forms, with or without
|
16
|
+
# modification, are permitted provided that the following conditions are
|
17
|
+
# met:
|
18
|
+
#
|
19
|
+
# * Redistributions of source code must retain the above copyright notice,
|
20
|
+
# this list of conditions and the following disclaimer.
|
21
|
+
#
|
22
|
+
# * Redistributions in binary form must reproduce the above copyright
|
23
|
+
# notice, this list of conditions and the following disclaimer in the
|
24
|
+
# documentation and/or other materials provided with the distribution.
|
25
|
+
#
|
26
|
+
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS
|
27
|
+
# IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO,
|
28
|
+
# THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
29
|
+
# PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR
|
30
|
+
# CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL,
|
31
|
+
# EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
|
32
|
+
# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR
|
33
|
+
# PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
|
34
|
+
# LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
|
35
|
+
# NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
36
|
+
# SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
37
|
+
#
|
38
|
+
# ######################################################################## #
|
39
|
+
|
40
|
+
|
41
|
+
require 'xqsr3/quality/parameter_checking'
|
42
|
+
|
43
|
+
=begin
|
44
|
+
=end
|
45
|
+
|
46
|
+
module CommentStrip
|
47
|
+
module LanguageFamilies
|
48
|
+
|
49
|
+
module HashLine
|
50
|
+
|
51
|
+
def self.strip input, lf, **options
|
52
|
+
|
53
|
+
return input if input.nil?
|
54
|
+
return input if input.empty?
|
55
|
+
|
56
|
+
line = 0
|
57
|
+
column = 0
|
58
|
+
|
59
|
+
# States:
|
60
|
+
#
|
61
|
+
# - :dq_string - within a double-quoted string
|
62
|
+
# - :dq_string_escape - within a double-quoted string when just received a '"', e.g. from immediately after '"the next word is quoted \'
|
63
|
+
# - :hash_comment - in a #-comment, i.e. from immediately after "#"
|
64
|
+
# - :sq_string_closing - waiting for final '\'' in a single-quoted string
|
65
|
+
# - :sq_string_escape - within a escaped single-quoted string, i.e. from immediately after "'\"
|
66
|
+
# - :sq_string_open - within a single-quoted string, i.e. from immediately after "'"
|
67
|
+
# - :text - regular part of the code
|
68
|
+
|
69
|
+
state = :text
|
70
|
+
|
71
|
+
r = ''
|
72
|
+
|
73
|
+
cc_lines = 0
|
74
|
+
|
75
|
+
input.each_char do |c|
|
76
|
+
|
77
|
+
case c
|
78
|
+
when ?\r, ?\n
|
79
|
+
|
80
|
+
line += 1
|
81
|
+
column = 0
|
82
|
+
else
|
83
|
+
|
84
|
+
column += 1
|
85
|
+
end
|
86
|
+
|
87
|
+
skip = false
|
88
|
+
|
89
|
+
case c
|
90
|
+
when ?\r, ?\n
|
91
|
+
|
92
|
+
case state
|
93
|
+
when :hash_comment
|
94
|
+
|
95
|
+
state = :text
|
96
|
+
when :sq_string_escape, :sq_string_closing
|
97
|
+
|
98
|
+
state = :text
|
99
|
+
when :dq_string_escape
|
100
|
+
|
101
|
+
state = :dq_string
|
102
|
+
when :hash_comment
|
103
|
+
|
104
|
+
state = :text
|
105
|
+
end
|
106
|
+
else
|
107
|
+
|
108
|
+
# special cases:
|
109
|
+
#
|
110
|
+
# - for escaped single/double quote
|
111
|
+
# - for slash-start
|
112
|
+
|
113
|
+
case state
|
114
|
+
when :sq_string_open
|
115
|
+
|
116
|
+
state = (?\\ == c) ? :sq_string_escape : :sq_string_closing
|
117
|
+
when :sq_string_escape
|
118
|
+
|
119
|
+
state = :sq_string_closing
|
120
|
+
when :dq_string_escape
|
121
|
+
|
122
|
+
state = :dq_string
|
123
|
+
else
|
124
|
+
|
125
|
+
case c
|
126
|
+
when '#'
|
127
|
+
|
128
|
+
case state
|
129
|
+
when :text
|
130
|
+
|
131
|
+
state = :hash_comment
|
132
|
+
else
|
133
|
+
|
134
|
+
;
|
135
|
+
end
|
136
|
+
when ?\'
|
137
|
+
|
138
|
+
case state
|
139
|
+
when :text
|
140
|
+
|
141
|
+
state = :sq_string_open
|
142
|
+
when :sq_string_closing
|
143
|
+
|
144
|
+
state = :text
|
145
|
+
else
|
146
|
+
|
147
|
+
;
|
148
|
+
end
|
149
|
+
when '"'
|
150
|
+
|
151
|
+
case state
|
152
|
+
when :text
|
153
|
+
|
154
|
+
state = :dq_string
|
155
|
+
when :dq_string
|
156
|
+
|
157
|
+
state = :text
|
158
|
+
else
|
159
|
+
|
160
|
+
;
|
161
|
+
end
|
162
|
+
when ?\\
|
163
|
+
|
164
|
+
case state
|
165
|
+
when :sq_string_open
|
166
|
+
|
167
|
+
state = :sq_string_escape
|
168
|
+
when :sq_string_escape
|
169
|
+
|
170
|
+
state = :sq_string_closing
|
171
|
+
when :dq_string
|
172
|
+
|
173
|
+
state = :dq_string_escape
|
174
|
+
else
|
175
|
+
|
176
|
+
;
|
177
|
+
end
|
178
|
+
else
|
179
|
+
|
180
|
+
case state
|
181
|
+
when :sq_string_escape
|
182
|
+
|
183
|
+
state = :sq_string_closing
|
184
|
+
else
|
185
|
+
|
186
|
+
;
|
187
|
+
end
|
188
|
+
end
|
189
|
+
end
|
190
|
+
end
|
191
|
+
|
192
|
+
|
193
|
+
case state
|
194
|
+
when :hash_comment
|
195
|
+
|
196
|
+
;
|
197
|
+
else
|
198
|
+
|
199
|
+
r << c unless skip
|
200
|
+
end
|
201
|
+
end
|
202
|
+
|
203
|
+
r
|
204
|
+
end
|
205
|
+
end # module HashLine
|
206
|
+
|
207
|
+
end # module LanguageFamilies
|
208
|
+
end # module CommentStrip
|
209
|
+
|
210
|
+
# ############################## end of file ############################# #
|
211
|
+
|
data/lib/comment_strip/strip.rb
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
# ######################################################################## #
|
2
|
-
# File:
|
2
|
+
# File: comment_strip/strip.rb
|
3
3
|
#
|
4
|
-
# Purpose:
|
4
|
+
# Purpose: Definition of strip() function
|
5
5
|
#
|
6
|
-
# Created:
|
7
|
-
# Updated:
|
6
|
+
# Created: 14th September 2020
|
7
|
+
# Updated: 30th March 2024
|
8
8
|
#
|
9
|
-
# Home:
|
9
|
+
# Home: http://github.com/synesissoftware/comment_strip.r
|
10
10
|
#
|
11
|
-
# Copyright (c) 2020-
|
11
|
+
# Copyright (c) 2020-2024, Matthew Wilson and Synesis Information Systems
|
12
12
|
# All rights reserved.
|
13
13
|
#
|
14
14
|
# Redistribution and use in source and binary forms, with or without
|
@@ -37,7 +37,15 @@
|
|
37
37
|
# ######################################################################## #
|
38
38
|
|
39
39
|
|
40
|
-
|
40
|
+
|
41
|
+
%w{
|
42
|
+
|
43
|
+
c
|
44
|
+
hash_line
|
45
|
+
}.each do |name|
|
46
|
+
|
47
|
+
require File.join(File.dirname(__FILE__), 'language_families', name)
|
48
|
+
end
|
41
49
|
|
42
50
|
require 'xqsr3/quality/parameter_checking'
|
43
51
|
|
@@ -54,16 +62,17 @@ module CommentStrip
|
|
54
62
|
# === Signature
|
55
63
|
#
|
56
64
|
# * *Parameters:*
|
57
|
-
# - +input+ (
|
58
|
-
# - +lf+ (
|
59
|
-
#
|
60
|
-
#
|
65
|
+
# - +input+ (+String+, +nil+) the input source code
|
66
|
+
# - +lf+ (+String+) the name of the language family, which must be one of the following:
|
67
|
+
# - +'C'+
|
68
|
+
# - +'Hash_Line'+
|
69
|
+
# - +options+ (+Hash+) options that moderate the behaviour
|
61
70
|
#
|
62
71
|
# * *Options:*
|
63
72
|
# None currently defined.
|
64
73
|
#
|
65
74
|
# === Signature
|
66
|
-
# (String) The stripped for of the input.
|
75
|
+
# (+String+) The stripped for of the input.
|
67
76
|
def strip input, lf, **options
|
68
77
|
|
69
78
|
check_parameter input, 'input', responds_to: [ :each_char, :empty?, :nil?, ], nil: true
|
@@ -73,6 +82,9 @@ module CommentStrip
|
|
73
82
|
when 'C'
|
74
83
|
|
75
84
|
LanguageFamilies::C.strip input, lf, **options
|
85
|
+
when 'HASH_LINE'
|
86
|
+
|
87
|
+
LanguageFamilies::HashLine.strip input, lf, **options
|
76
88
|
else
|
77
89
|
|
78
90
|
raise "language family '#{lf}' unrecognised or not supported1"
|