unparser 0.2.4 → 0.2.5

Sign up to get free protection for your applications and to get access to all the features.
Files changed (97) hide show
  1. checksums.yaml +4 -4
  2. data/Changelog.md +7 -0
  3. data/Gemfile +1 -7
  4. data/README.md +6 -1
  5. data/Rakefile +11 -2
  6. data/bin/unparser +0 -2
  7. data/config/devtools.yml +1 -1
  8. data/config/flay.yml +1 -1
  9. data/config/flog.yml +1 -1
  10. data/config/reek.yml +4 -1
  11. data/config/rubocop.yml +0 -4
  12. data/lib/unparser.rb +1 -2
  13. data/lib/unparser/ast.rb +0 -2
  14. data/lib/unparser/ast/local_variable_scope.rb +0 -2
  15. data/lib/unparser/buffer.rb +0 -2
  16. data/lib/unparser/cli.rb +3 -4
  17. data/lib/unparser/cli/color.rb +0 -2
  18. data/lib/unparser/cli/differ.rb +0 -2
  19. data/lib/unparser/cli/source.rb +1 -3
  20. data/lib/unparser/comments.rb +0 -2
  21. data/lib/unparser/constants.rb +0 -2
  22. data/lib/unparser/emitter.rb +4 -3
  23. data/lib/unparser/emitter/alias.rb +0 -2
  24. data/lib/unparser/emitter/argument.rb +0 -2
  25. data/lib/unparser/emitter/assignment.rb +0 -2
  26. data/lib/unparser/emitter/begin.rb +1 -3
  27. data/lib/unparser/emitter/binary.rb +0 -2
  28. data/lib/unparser/emitter/block.rb +0 -2
  29. data/lib/unparser/emitter/case.rb +0 -2
  30. data/lib/unparser/emitter/cbase.rb +0 -2
  31. data/lib/unparser/emitter/class.rb +1 -3
  32. data/lib/unparser/emitter/def.rb +0 -2
  33. data/lib/unparser/emitter/defined.rb +0 -2
  34. data/lib/unparser/emitter/empty.rb +0 -2
  35. data/lib/unparser/emitter/ensure.rb +0 -2
  36. data/lib/unparser/emitter/flipflop.rb +0 -2
  37. data/lib/unparser/emitter/flow_modifier.rb +0 -2
  38. data/lib/unparser/emitter/for.rb +0 -2
  39. data/lib/unparser/emitter/hookexe.rb +0 -2
  40. data/lib/unparser/emitter/if.rb +0 -2
  41. data/lib/unparser/emitter/literal.rb +0 -2
  42. data/lib/unparser/emitter/literal/array.rb +0 -2
  43. data/lib/unparser/emitter/literal/dynamic.rb +2 -43
  44. data/lib/unparser/emitter/literal/dynamic_body.rb +0 -6
  45. data/lib/unparser/emitter/literal/execute_string.rb +0 -2
  46. data/lib/unparser/emitter/literal/hash.rb +1 -3
  47. data/lib/unparser/emitter/literal/primitive.rb +0 -2
  48. data/lib/unparser/emitter/literal/range.rb +0 -2
  49. data/lib/unparser/emitter/literal/regexp.rb +0 -2
  50. data/lib/unparser/emitter/literal/singleton.rb +0 -2
  51. data/lib/unparser/emitter/match.rb +0 -2
  52. data/lib/unparser/emitter/module.rb +0 -2
  53. data/lib/unparser/emitter/op_assign.rb +0 -2
  54. data/lib/unparser/emitter/redo.rb +0 -2
  55. data/lib/unparser/emitter/repetition.rb +0 -2
  56. data/lib/unparser/emitter/resbody.rb +0 -2
  57. data/lib/unparser/emitter/rescue.rb +0 -2
  58. data/lib/unparser/emitter/retry.rb +0 -2
  59. data/lib/unparser/emitter/root.rb +0 -2
  60. data/lib/unparser/emitter/send.rb +0 -2
  61. data/lib/unparser/emitter/send/arguments.rb +0 -2
  62. data/lib/unparser/emitter/send/attribute_assignment.rb +0 -2
  63. data/lib/unparser/emitter/send/binary.rb +0 -2
  64. data/lib/unparser/emitter/send/conditional.rb +38 -0
  65. data/lib/unparser/emitter/send/index.rb +0 -2
  66. data/lib/unparser/emitter/send/regular.rb +0 -2
  67. data/lib/unparser/emitter/send/unary.rb +3 -2
  68. data/lib/unparser/emitter/splat.rb +0 -2
  69. data/lib/unparser/emitter/super.rb +0 -2
  70. data/lib/unparser/emitter/undef.rb +0 -2
  71. data/lib/unparser/emitter/variable.rb +0 -2
  72. data/lib/unparser/emitter/yield.rb +0 -2
  73. data/lib/unparser/finalize.rb +0 -2
  74. data/lib/unparser/node_helpers.rb +0 -2
  75. data/lib/unparser/preprocessor.rb +3 -80
  76. data/spec/integration/unparser/corpus_spec.rb +3 -16
  77. data/spec/integrations.yml +10 -11
  78. data/spec/spec_helper.rb +0 -2
  79. data/spec/unit/unparser/buffer/append_spec.rb +0 -2
  80. data/spec/unit/unparser/buffer/append_without_prefix_spec.rb +0 -2
  81. data/spec/unit/unparser/buffer/capture_content_spec.rb +0 -2
  82. data/spec/unit/unparser/buffer/content_spec.rb +0 -2
  83. data/spec/unit/unparser/buffer/fresh_line_spec.rb +0 -2
  84. data/spec/unit/unparser/buffer/indent_spec.rb +0 -2
  85. data/spec/unit/unparser/buffer/nl_spec.rb +0 -2
  86. data/spec/unit/unparser/buffer/unindent_spec.rb +0 -2
  87. data/spec/unit/unparser/comments/consume_spec.rb +0 -2
  88. data/spec/unit/unparser/comments/take_all_spec.rb +0 -2
  89. data/spec/unit/unparser/comments/take_before_spec.rb +0 -2
  90. data/spec/unit/unparser/comments/take_eol_comments_spec.rb +0 -2
  91. data/spec/unit/unparser/emitter/class_methods/handle_spec.rb +1 -3
  92. data/spec/unit/unparser_spec.rb +47 -71
  93. data/unparser.gemspec +20 -17
  94. metadata +69 -28
  95. data/.travis.yml +0 -20
  96. data/Guardfile +0 -20
  97. data/TODO +0 -4
@@ -1,20 +0,0 @@
1
- sudo: false
2
- language: ruby
3
- script: 'bundle exec rake ci'
4
- rvm:
5
- - '2.0'
6
- - '2.1'
7
- - '2.2'
8
- - rbx-2
9
- matrix:
10
- include:
11
- - rvm: jruby
12
- env: JRUBY_OPTS="$JRUBY_OPTS --debug --2.0" # for simplecov
13
- allow_failures:
14
- - rvm: rbx-2
15
- notifications:
16
- irc:
17
- channels:
18
- - irc.freenode.org#mutant
19
- on_success: never
20
- on_failure: change
data/Guardfile DELETED
@@ -1,20 +0,0 @@
1
- # encoding: utf-8
2
-
3
- ENV['GUARD'] = '1'
4
-
5
- guard :bundler do
6
- watch('Gemfile')
7
- end
8
-
9
- guard :rspec, :all_on_start => false, :all_after_pass => false, :cmd => 'bundle exec rspec --fail-fast --seed 1' do
10
- # run all specs if the spec_helper or supporting files files are modified
11
- watch('spec/spec_helper.rb') { 'spec/unit' }
12
- watch(%r{\Aspec/(?:lib|support|shared)/.+\.rb\z}) { 'spec/unit' }
13
-
14
- # run unit specs if associated lib code is modified
15
- watch(%r{\Alib/(.+)\.rb\z}) { 'spec' }
16
- watch("lib/#{File.basename(File.expand_path('../', __FILE__))}.rb") { 'spec' }
17
-
18
- # run a spec if it is modified
19
- watch(%r{\Aspec/(?:unit|integration)/.+_spec\.rb\z})
20
- end
data/TODO DELETED
@@ -1,4 +0,0 @@
1
- * Create an AST preprocessor that creates virtual nodes,
2
- removing the need for explicit backreferencing and special cases in the emitter
3
- classes.
4
- * Remove duplicated logic with empty or non empty bodies