farleyknight-ionize 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (98) hide show
  1. data/README.rdoc +59 -0
  2. data/Rakefile +5 -0
  3. data/bin/ionize +47 -0
  4. data/lib/ionize.rb +75 -0
  5. data/lib/ionize/environment.rb +56 -0
  6. data/lib/ionize/environment/application.rb +58 -0
  7. data/lib/ionize/environment/php_array.rb +95 -0
  8. data/lib/ionize/parser.rb +272 -0
  9. data/lib/ionize/tokenizer.rb +544 -0
  10. data/lib/ionize/translate.rb +34 -0
  11. data/lib/ionize/translate/composite_string_statements.rb +79 -0
  12. data/lib/ionize/translate/debug.rb +16 -0
  13. data/lib/ionize/translate/ext.rb +47 -0
  14. data/lib/ionize/translate/function_args.rb +132 -0
  15. data/lib/ionize/translate/if_statements.rb +42 -0
  16. data/lib/ionize/translate/multiple_statements.rb +22 -0
  17. data/lib/ionize/translate/php_to_ruby.rb +40 -0
  18. data/lib/ionize/translate/rails_for_php.rb +191 -0
  19. data/lib/ionize/translate/rewritable.rb +133 -0
  20. data/lib/ionize/translate/rewrites.rb +51 -0
  21. data/lib/ionize/translate/statements.rb +622 -0
  22. data/lib/ionize/translate/switch_case_statements.rb +52 -0
  23. data/lib/ionize/translate/term_statements.rb +76 -0
  24. data/lib/ionize/translate/translator.rb +52 -0
  25. data/lib/ionize/version.rb +9 -0
  26. data/spec/fixtures/array_lookup.php +10 -0
  27. data/spec/fixtures/boolean_operators.php +5 -0
  28. data/spec/fixtures/boolean_operators.rb +6 -0
  29. data/spec/fixtures/class_def.php +34 -0
  30. data/spec/fixtures/class_def.rb +34 -0
  31. data/spec/fixtures/dangling_else.php +8 -0
  32. data/spec/fixtures/dangling_else.rb +12 -0
  33. data/spec/fixtures/drupal_1.php +663 -0
  34. data/spec/fixtures/drupal_2.php +1152 -0
  35. data/spec/fixtures/empty_string.php +12 -0
  36. data/spec/fixtures/for_loop.php +17 -0
  37. data/spec/fixtures/for_loop2.php +13 -0
  38. data/spec/fixtures/for_loop3.php +16 -0
  39. data/spec/fixtures/for_loop3.rb +17 -0
  40. data/spec/fixtures/for_loop4.php +5 -0
  41. data/spec/fixtures/for_loop4.rb +6 -0
  42. data/spec/fixtures/foreach.php +9 -0
  43. data/spec/fixtures/foreach2.php +8 -0
  44. data/spec/fixtures/foreach3.php +7 -0
  45. data/spec/fixtures/foreach3.rb +7 -0
  46. data/spec/fixtures/fun_def.php +9 -0
  47. data/spec/fixtures/fun_def2.php +30 -0
  48. data/spec/fixtures/fun_def2.rb +30 -0
  49. data/spec/fixtures/fun_def3.php +33 -0
  50. data/spec/fixtures/fun_def4.php +43 -0
  51. data/spec/fixtures/fun_def4.rb +37 -0
  52. data/spec/fixtures/fun_def5.php +36 -0
  53. data/spec/fixtures/fun_with_if.php +6 -0
  54. data/spec/fixtures/fun_with_if.rb +6 -0
  55. data/spec/fixtures/fun_with_ifs.php +12 -0
  56. data/spec/fixtures/fun_with_ifs.rb +14 -0
  57. data/spec/fixtures/hello_world.php +6 -0
  58. data/spec/fixtures/heredoc.php +6 -0
  59. data/spec/fixtures/heredoc.rb +5 -0
  60. data/spec/fixtures/if.php +6 -0
  61. data/spec/fixtures/if.rb +7 -0
  62. data/spec/fixtures/if_boolean.php +5 -0
  63. data/spec/fixtures/if_boolean.rb +5 -0
  64. data/spec/fixtures/if_else.php +11 -0
  65. data/spec/fixtures/if_else1.php +17 -0
  66. data/spec/fixtures/if_else2.php +8 -0
  67. data/spec/fixtures/if_else3.php +15 -0
  68. data/spec/fixtures/if_else_nested.php +14 -0
  69. data/spec/fixtures/if_else_nested.rb +15 -0
  70. data/spec/fixtures/if_else_series.php +12 -0
  71. data/spec/fixtures/if_else_series.rb +12 -0
  72. data/spec/fixtures/if_not.php +5 -0
  73. data/spec/fixtures/if_not.rb +5 -0
  74. data/spec/fixtures/if_with_brackets.php +7 -0
  75. data/spec/fixtures/if_with_brackets.rb +7 -0
  76. data/spec/fixtures/long_if_else.php +10 -0
  77. data/spec/fixtures/long_if_else.rb +9 -0
  78. data/spec/fixtures/oo.php +16 -0
  79. data/spec/fixtures/php_nuke/sql_layer.php +527 -0
  80. data/spec/fixtures/postop.php +3 -0
  81. data/spec/fixtures/preop.php +7 -0
  82. data/spec/fixtures/simple_fun_def.php +4 -0
  83. data/spec/fixtures/switch_case.php +13 -0
  84. data/spec/fixtures/switch_case.rb +14 -0
  85. data/spec/fixtures/switch_case2.php +25 -0
  86. data/spec/fixtures/switch_case3.php +40 -0
  87. data/spec/fixtures/switch_case3.rb +42 -0
  88. data/spec/fixtures/switch_case4.php +56 -0
  89. data/spec/fixtures/switch_case5.php +71 -0
  90. data/spec/fixtures/switch_case_with_rescue_nil.php +43 -0
  91. data/spec/fixtures/switch_case_with_rescue_nil.rb +35 -0
  92. data/spec/fixtures/tertiary.php +3 -0
  93. data/spec/helper.rb +17 -0
  94. data/spec/php_environment_spec.rb +83 -0
  95. data/spec/php_parser_spec.rb +121 -0
  96. data/spec/php_translator_spec.rb +358 -0
  97. data/spec/rails_for_php_spec.rb +303 -0
  98. metadata +191 -0
@@ -0,0 +1,303 @@
1
+
2
+ require 'spec'
3
+ require 'spec/helper'
4
+ require 'lib/ionize'
5
+
6
+ describe "Transforms Php based on railsforphp.com for strings" do
7
+ include Ionize::Php::Environment, SpecHelperMethods
8
+
9
+ it "rewrites rtrim" do
10
+ php_ast(%Q{ $result = rtrim("hello world \n"); }).should ==
11
+ ruby_ast(%Q{ result = "hello world \n".rstrip })
12
+ end
13
+
14
+ it "rewrites rtrim with a second argument" do
15
+ php_ast(%Q{ $result = rtrim("/Users/joe/work/ ", " /"); }).should ==
16
+ ruby_ast(%Q{ result = "/Users/joe/work/ ".gsub(/[ \\/]+$/, '') })
17
+ end
18
+
19
+ it "rewrites ltrim" do
20
+ php_ast(%Q{ $result = ltrim(" \nhello world \n"); }).should ==
21
+ ruby_ast(%Q{ result = " \nhello world \n".lstrip })
22
+ end
23
+
24
+ it "rewrites ltrim with a second argument" do
25
+ php_ast(%Q{ $result = ltrim(" /Users/joe/work/", "/ "); }).should ==
26
+ ruby_ast(%Q{ result = " /Users/joe/work/".gsub(/^[\\/ ]+/, '') })
27
+ end
28
+
29
+ it "rewrites trim" do
30
+ php_ast(%Q{ $result = trim(" \nhello world \n"); }).should ==
31
+ ruby_ast(%Q{ result = " \nhello world \n".strip })
32
+ end
33
+
34
+ it "rewrites trim with a second argument" do
35
+ php_ast(%Q{ $result = trim(" /Users/joe/work/ ", " /"); }).should ==
36
+ ruby_ast(%Q{ result = " /Users/joe/work/ ".gsub(/^[ \\/]+|[ \\/]+$/, '') })
37
+ end
38
+
39
+ it "rewrites ucfirst" do
40
+ php_ast(%Q{ ucfirst("hello world"); }).should ==
41
+ ruby_ast(%Q{ "hello world".capitalize })
42
+ end
43
+
44
+ it "rewrites strtolower" do
45
+ php_ast(%Q{ strtolower('Hey World'); }).should ==
46
+ ruby_ast(%Q{ "Hey World".downcase })
47
+ end
48
+
49
+ it "rewrites strtoupper" do
50
+ php_ast(%Q{ strtoupper('Hey World'); }).should ==
51
+ ruby_ast(%Q{ "Hey World".upcase })
52
+ end
53
+
54
+ it "rewrites strrev" do
55
+ php_ast(%Q{ $reversed = strrev('my string'); }).should ==
56
+ ruby_ast(%Q{ reversed = 'my string'.reverse })
57
+ end
58
+
59
+ it "rewrites stripslashes" do
60
+ php_ast(%Q{ $result = stripslashes('I can\\\'t'); }).should ==
61
+ ruby_ast(%Q{ result = "I can\\\\\'t".gsub("\\\\", "") })
62
+ end
63
+
64
+ it "rewrites strlen" do
65
+ php_ast(%Q{ strlen('hello world'); }).should ==
66
+ ruby_ast(%Q{ 'hello world'.length })
67
+ end
68
+
69
+ it "rewrites strpos" do
70
+ php_ast(%Q{ strpos("hello world", "wo"); }).should ==
71
+ ruby_ast(%Q{ "hello world".index("wo") })
72
+ end
73
+
74
+ it "rewrites strrpos" do
75
+ php_ast(%Q{ strrpos("hello world", "o"); }).should ==
76
+ ruby_ast(%Q{ "hello world".rindex("o") })
77
+ end
78
+
79
+ it "rewrites substr" do
80
+ php_ast(%Q{ substr("hello world", 0, 5); }).should ==
81
+ ruby_ast(%Q{ "hello world".slice(0, 5) })
82
+ end
83
+
84
+ it "rewrites substr with 2 args" do
85
+ php_ast(%Q{ substr("hello world", 3); }).should ==
86
+ ruby_ast(%Q{ "hello world".slice(3..-1) })
87
+ end
88
+
89
+ it "rewrites substr with a negative arg" do
90
+ php_ast(%Q{ substr("hello world", -5); }).should ==
91
+ ruby_ast(%Q{ "hello world".slice(-5, 5) })
92
+ end
93
+
94
+ it "rewrites substr_replace" do
95
+ php_ast(%Q{ substr_replace("hello world", "hey", 0, 5); }).should ==
96
+ ruby_ast(%Q{ "hello world"[0, 5] = "hey" })
97
+ end
98
+
99
+ it "rewrites substr_replace with 3 args" do
100
+ php_ast(%Q{ substr_replace("hello world", "p", 3); }).should ==
101
+ ruby_ast(%Q{ "hello world"[3..-1] = "p" })
102
+ end
103
+
104
+ it "rewrites str_replace" do
105
+ php_ast(%Q{ str_replace('Hello', 'Hi', 'Hello world'); }).should ==
106
+ ruby_ast(%Q{ "Hello world".gsub("Hello", "Hi") })
107
+ end
108
+
109
+ it "rewrites_str_ireplace" do
110
+ php_ast(%Q{ str_ireplace('hello', 'Hi', 'Hello world'); }).should ==
111
+ ruby_ast(%Q{ "Hello world".gsub(/hello/i, "Hi") })
112
+ end
113
+
114
+ it "rewrites strtr" do
115
+ php_ast(%Q{ $result = strtr("cat", "abc", "zyx"); }).should ==
116
+ ruby_ast(%Q{ result = "cat".tr("abc", "zyx") })
117
+ end
118
+
119
+ it "rewrites md5" do
120
+ php_ast(%Q{ $result = md5("my string"); }).should ==
121
+ ruby_ast(%Q{ result = Digest::MD5.hexdigest("my string") })
122
+ end
123
+
124
+ it "rewrites md5_file" do
125
+ php_ast(%Q{ md5_file("my_file.jpg"); }).should ==
126
+ ruby_ast(%Q{ Digest::MD5.hexdigest(File.read("my_file.jpg")) })
127
+ end
128
+
129
+ it "rewrites sha1" do
130
+ php_ast(%Q{ $result = sha1("my string"); }).should ==
131
+ ruby_ast(%Q{ result = Digest::SHA1.hexdigest("my string") })
132
+ end
133
+
134
+ it "rewrites sha1_file" do
135
+ php_ast(%Q{ $result = sha1_file("my_file.jpg"); }).should ==
136
+ ruby_ast(%Q{ result = Digest::SHA1.hexdigest(File.read("my_file.jpg")) })
137
+ end
138
+
139
+ it "rewrites explode" do
140
+ php_ast(%Q{ explode("; ", "derek@example.com; mike@example.com"); }).should ==
141
+ ruby_ast(%Q{ "derek@example.com; mike@example.com".split("; ") })
142
+ end
143
+ end
144
+
145
+ describe "Transforms Php based on railsforphp.com for pcre" do
146
+ include Ionize::Php::Environment, SpecHelperMethods
147
+
148
+ # http://railsforphp.com/reference/pcre/preg_replace
149
+ it "rewrites preg_replace" do
150
+ php_ast(%Q{
151
+ $string = 'joe@example.com; walter@example.org';
152
+ $result = preg_replace('/@([a-z0-9-]+)/', '@foo', $string);
153
+ }).should ==
154
+ ruby_ast(%Q{
155
+ string = 'joe@example.com; walter@example.org'
156
+ result = string.gsub(/@([a-z0-9-]+)/, '@foo')
157
+ })
158
+ end
159
+
160
+ # http://railsforphp.com/reference/pcre/preg_match
161
+ it "rewrites preg_match with a destructing bind" do
162
+ php_ast(%Q{
163
+ $string = 'joe@example.com; walter@example.org';
164
+ $result = preg_match('/([a-z0-9_.-]+)@([a-z0-9-]+)\.([a-z.]+)/i', $string, $matches);
165
+ }).should ==
166
+ ruby_ast(%Q{
167
+ string = 'joe@example.com; walter@example.org'
168
+ result, matches = string.preg_match(/([a-z0-9_.-]+)@([a-z0-9-]+)\.([a-z.]+)/i)
169
+ })
170
+ end
171
+
172
+ # http://railsforphp.com/reference/pcre/preg_match_all
173
+ it "rewrites preg_match_all with a destructing bind" do
174
+ php_ast(%Q{
175
+ $string = 'joe@example.com; walter@example.org';
176
+ $result = preg_match_all('/([a-z0-9_.-]+)@([a-z0-9-]+)\.[a-z.]+/i', $string, $matches);
177
+ }).should ==
178
+ ruby_ast(%Q{
179
+ string = 'joe@example.com; walter@example.org'
180
+ result, matches = string.preg_match_all(/([a-z0-9_.-]+)@([a-z0-9-]+)\.[a-z.]+/i)
181
+ })
182
+ end
183
+
184
+ # http://railsforphp.com/reference/pcre/preg_match
185
+ it "fills the array passed by reference" do
186
+ php_to_ruby_eval(%Q{
187
+ $string = 'joe@example.com; walter@example.org';
188
+ $result = preg_match('/([a-z0-9_.-]+)@([a-z0-9-]+)\.([a-z.]+)/i', $string, $matches);
189
+ $matches;
190
+ }).should == ["joe@example.com", "joe", "example", "com"]
191
+ end
192
+
193
+ # http://railsforphp.com/reference/pcre/preg_match_all
194
+ it "rewrites preg_match_all with destructuring bind" do
195
+ php_to_ruby_eval(%Q{
196
+ $string = 'joe@example.com; walter@example.org';
197
+ $result = preg_match_all('/([a-z0-9_.-]+)@([a-z0-9-]+)\.[a-z.]+/i', $string, $matches);
198
+ $matches;
199
+ }).should == [["joe@example.com", "walter@example.org"], ["joe", "walter"], ["example", "example"]]
200
+ end
201
+
202
+ # http://railsforphp.com/reference/pcre/preg_split
203
+ it "rewrites preg_split" do
204
+ php_ast(%Q{ preg_split('/;\s?/', 'joe@example.com; walter@example.org'); }).should ==
205
+ ruby_ast(%Q{ 'joe@example.com; walter@example.org'.split(/;\s?/) })
206
+ end
207
+ end
208
+
209
+ describe "Transforms Php based on railsforphp.com for arrays" do
210
+ include Ionize::Php::Environment, SpecHelperMethods
211
+
212
+ it "rewrites count" do
213
+ php_ast(%Q{ $numbers = array(1, 2, 3); print count($numbers); }).should ==
214
+ ruby_ast(%Q{ numbers = array(1, 2, 3); print numbers.length })
215
+ end
216
+
217
+ it "preserves php array length as a hash would" do
218
+ php_to_ruby_eval(%Q{ $numbers = array(1, 2); $numbers[10] = 3; count($numbers); }).should == 3
219
+ end
220
+
221
+ it "rewrites implode" do
222
+ php_ast(%Q{ implode('; ', array('derek@example.com', 'mike@example.com')); }).should ==
223
+ ruby_ast(%Q{ array('derek@example.com', 'mike@example.com').join("; ") })
224
+ end
225
+
226
+ it "implodes a PhpArray" do
227
+ php_to_ruby_eval(%Q{ implode('; ', array('derek@example.com', 'mike@example.com')); }).should ==
228
+ "derek@example.com; mike@example.com"
229
+ end
230
+
231
+ it "rewrites in_array, given the last arguement is true" do
232
+ php_ast(%Q{
233
+ $fruit = array('apple', 'banana', 'kiwi');
234
+ $result = in_array('apple', $fruit, true);
235
+
236
+ }).should ==
237
+ ruby_ast(%Q{
238
+ fruit = array("apple", "banana", "kiwi")
239
+ result = fruit.include?("apple")
240
+ })
241
+ end
242
+
243
+ it "rewrites array_combine" do
244
+ php_ast(%Q{
245
+ $make = array('VW', 'Ford');
246
+ $model = array('Jetta', 'Explorer');
247
+ $result = array_combine($make, $model);
248
+ }).should == ruby_ast(%Q{
249
+ make = array('VW', 'Ford')
250
+ model = array('Jetta', 'Explorer')
251
+ result = make.combine(model)
252
+ })
253
+ end
254
+
255
+ it "rewrites array_merge" do
256
+ php_ast(%Q{
257
+ $first = array('first');
258
+ $second = array('second', 'third');
259
+ $result = array_merge($first, $second);
260
+ }).should == ruby_ast(%Q{
261
+ first = array("first")
262
+ second = array("second", "third")
263
+ result = first.merge(second)
264
+ })
265
+ end
266
+
267
+ it "merges two php arrays acting as ruby arrays" do
268
+ php_to_ruby_eval(%Q{
269
+ $first = array('first');
270
+ $second = array('second', 'third');
271
+ $result = array_merge($first, $second);
272
+ $result;
273
+ }).should == array("first", "second", "third")
274
+ end
275
+
276
+ it "merges to php arrays acting as ruby hashes" do
277
+ php_to_ruby_eval(%Q{
278
+ $person = array('name' => 'Walter', 'weight' => 184);
279
+ $updates = array('weight' => 200, 'age' => 42);
280
+ $result = array_merge($person, $updates);
281
+ $result;
282
+ }).should == array('name' => 'Walter', 'weight' => 200, 'age' => 42)
283
+ end
284
+
285
+ it "combines two php arrays" do
286
+ php_to_ruby_eval(%Q{
287
+ $make = array('VW', 'Ford');
288
+ $model = array('Jetta', 'Explorer');
289
+ $result = array_combine($make, $model);
290
+ $result;
291
+ }).should == array("VW"=>"Jetta", "Ford"=>"Explorer")
292
+ end
293
+ end
294
+
295
+
296
+ describe "Transforms Php based on railsforphp.com for files" do
297
+ include Ionize::Php::Environment, SpecHelperMethods
298
+
299
+ it "rewrites file" do
300
+ php_ast(%Q{ file('/path/to/foobar'); }).should ==
301
+ ruby_ast(%Q{ File.readlines('/path/to/foobar') })
302
+ end
303
+ end
metadata ADDED
@@ -0,0 +1,191 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: farleyknight-ionize
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
5
+ platform: ruby
6
+ authors:
7
+ - Farley Knight
8
+ autorequire:
9
+ bindir: bin
10
+ cert_chain: []
11
+
12
+ date: 2008-08-13 00:00:00 -07:00
13
+ default_executable:
14
+ dependencies:
15
+ - !ruby/object:Gem::Dependency
16
+ name: Dhaka
17
+ version_requirement:
18
+ version_requirements: !ruby/object:Gem::Requirement
19
+ requirements:
20
+ - - "="
21
+ - !ruby/object:Gem::Version
22
+ version: 2.2.1
23
+ version:
24
+ - !ruby/object:Gem::Dependency
25
+ name: ParseTree
26
+ version_requirement:
27
+ version_requirements: !ruby/object:Gem::Requirement
28
+ requirements:
29
+ - - "="
30
+ - !ruby/object:Gem::Version
31
+ version: 2.2.0
32
+ version:
33
+ - !ruby/object:Gem::Dependency
34
+ name: ruby2ruby
35
+ version_requirement:
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - "="
39
+ - !ruby/object:Gem::Version
40
+ version: 1.1.9
41
+ version:
42
+ - !ruby/object:Gem::Dependency
43
+ name: rack
44
+ version_requirement:
45
+ version_requirements: !ruby/object:Gem::Requirement
46
+ requirements:
47
+ - - "="
48
+ - !ruby/object:Gem::Version
49
+ version: 0.3.0
50
+ version:
51
+ description: Ionize parses and translates Php scripts into Ruby code, which can be run from it's Rack based webserver
52
+ email: farleyknight@gmail.com
53
+ executables:
54
+ - ionize
55
+ extensions: []
56
+
57
+ extra_rdoc_files:
58
+ - README.rdoc
59
+ files:
60
+ - README
61
+ - Rakefile
62
+ - bin/ionize
63
+ - spec/php_parser_spec.rb
64
+ - spec/fixtures
65
+ - spec/fixtures/postop.php
66
+ - spec/fixtures/switch_case.php
67
+ - spec/fixtures/foreach2.php
68
+ - spec/fixtures/if_with_brackets.rb
69
+ - spec/fixtures/switch_case3.rb
70
+ - spec/fixtures/fun_def3.php
71
+ - spec/fixtures/drupal_2.php
72
+ - spec/fixtures/for_loop.php
73
+ - spec/fixtures/if_not.rb
74
+ - spec/fixtures/switch_case4.php
75
+ - spec/fixtures/switch_case3.php
76
+ - spec/fixtures/drupal_1.php
77
+ - spec/fixtures/oo.php
78
+ - spec/fixtures/long_if_else.php
79
+ - spec/fixtures/switch_case5.php
80
+ - spec/fixtures/for_loop2.php
81
+ - spec/fixtures/fun_def4.rb
82
+ - spec/fixtures/class_def.php
83
+ - spec/fixtures/simple_fun_def.php
84
+ - spec/fixtures/if_else_series.rb
85
+ - spec/fixtures/fun_with_ifs.php
86
+ - spec/fixtures/fun_def5.php
87
+ - spec/fixtures/if.rb
88
+ - spec/fixtures/long_if_else.rb
89
+ - spec/fixtures/empty_string.php
90
+ - spec/fixtures/fun_def2.php
91
+ - spec/fixtures/fun_with_if.php
92
+ - spec/fixtures/switch_case.rb
93
+ - spec/fixtures/for_loop4.rb
94
+ - spec/fixtures/foreach3.php
95
+ - spec/fixtures/switch_case_with_rescue_nil.php
96
+ - spec/fixtures/if_else_nested.php
97
+ - spec/fixtures/fun_def4.php
98
+ - spec/fixtures/if_with_brackets.php
99
+ - spec/fixtures/fun_with_if.rb
100
+ - spec/fixtures/if_else1.php
101
+ - spec/fixtures/if.php
102
+ - spec/fixtures/fun_with_ifs.rb
103
+ - spec/fixtures/foreach3.rb
104
+ - spec/fixtures/if_else_series.php
105
+ - spec/fixtures/boolean_operators.rb
106
+ - spec/fixtures/php_nuke
107
+ - spec/fixtures/php_nuke/sql_layer.php
108
+ - spec/fixtures/for_loop4.php
109
+ - spec/fixtures/if_else.php
110
+ - spec/fixtures/fun_def.php
111
+ - spec/fixtures/if_else2.php
112
+ - spec/fixtures/if_not.php
113
+ - spec/fixtures/heredoc.rb
114
+ - spec/fixtures/foreach.php
115
+ - spec/fixtures/if_else_nested.rb
116
+ - spec/fixtures/array_lookup.php
117
+ - spec/fixtures/dangling_else.php
118
+ - spec/fixtures/heredoc.php
119
+ - spec/fixtures/switch_case_with_rescue_nil.rb
120
+ - spec/fixtures/if_else3.php
121
+ - spec/fixtures/fun_def2.rb
122
+ - spec/fixtures/preop.php
123
+ - spec/fixtures/if_boolean.rb
124
+ - spec/fixtures/for_loop3.php
125
+ - spec/fixtures/class_def.rb
126
+ - spec/fixtures/hello_world.php
127
+ - spec/fixtures/tertiary.php
128
+ - spec/fixtures/boolean_operators.php
129
+ - spec/fixtures/switch_case2.php
130
+ - spec/fixtures/if_boolean.php
131
+ - spec/fixtures/for_loop3.rb
132
+ - spec/fixtures/dangling_else.rb
133
+ - spec/rails_for_php_spec.rb
134
+ - spec/php_environment_spec.rb
135
+ - spec/helper.rb
136
+ - spec/php_translator_spec.rb
137
+ - lib/ionize
138
+ - lib/ionize/translate
139
+ - lib/ionize/translate/switch_case_statements.rb
140
+ - lib/ionize/translate/php_to_ruby.rb
141
+ - lib/ionize/translate/if_statements.rb
142
+ - lib/ionize/translate/rewrites.rb
143
+ - lib/ionize/translate/composite_string_statements.rb
144
+ - lib/ionize/translate/rails_for_php.rb
145
+ - lib/ionize/translate/rewritable.rb
146
+ - lib/ionize/translate/term_statements.rb
147
+ - lib/ionize/translate/statements.rb
148
+ - lib/ionize/translate/ext.rb
149
+ - lib/ionize/translate/multiple_statements.rb
150
+ - lib/ionize/translate/debug.rb
151
+ - lib/ionize/translate/function_args.rb
152
+ - lib/ionize/translate/translator.rb
153
+ - lib/ionize/parser.rb
154
+ - lib/ionize/environment
155
+ - lib/ionize/environment/application.rb
156
+ - lib/ionize/environment/php_array.rb
157
+ - lib/ionize/environment.rb
158
+ - lib/ionize/ast.rb
159
+ - lib/ionize/tokenizer.rb
160
+ - lib/ionize/version.rb
161
+ - lib/ionize/translate.rb
162
+ - lib/ionize.rb
163
+ - README.rdoc
164
+ has_rdoc: true
165
+ homepage: http://ionize.farleyknight.com
166
+ post_install_message:
167
+ rdoc_options: []
168
+
169
+ require_paths:
170
+ - lib
171
+ required_ruby_version: !ruby/object:Gem::Requirement
172
+ requirements:
173
+ - - ">="
174
+ - !ruby/object:Gem::Version
175
+ version: "0"
176
+ version:
177
+ required_rubygems_version: !ruby/object:Gem::Requirement
178
+ requirements:
179
+ - - ">="
180
+ - !ruby/object:Gem::Version
181
+ version: "0"
182
+ version:
183
+ requirements: []
184
+
185
+ rubyforge_project:
186
+ rubygems_version: 1.2.0
187
+ signing_key:
188
+ specification_version: 2
189
+ summary: Transform Php to Ruby
190
+ test_files: []
191
+