nokogiri 1.12.2-arm64-darwin → 1.13.0-arm64-darwin

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of nokogiri might be problematic. Click here for more details.

Files changed (100) hide show
  1. checksums.yaml +4 -4
  2. data/Gemfile +2 -0
  3. data/README.md +9 -7
  4. data/bin/nokogiri +63 -50
  5. data/dependencies.yml +5 -6
  6. data/ext/nokogiri/extconf.rb +51 -35
  7. data/ext/nokogiri/gumbo.c +11 -11
  8. data/ext/nokogiri/html4_element_description.c +1 -1
  9. data/ext/nokogiri/html4_sax_parser_context.c +2 -1
  10. data/ext/nokogiri/include/libxml2/libxml/xmlerror.h +1 -0
  11. data/ext/nokogiri/include/libxslt/xsltconfig.h +1 -1
  12. data/ext/nokogiri/nokogiri.c +1 -1
  13. data/ext/nokogiri/nokogiri.h +3 -0
  14. data/ext/nokogiri/xml_document.c +36 -36
  15. data/ext/nokogiri/xml_document_fragment.c +0 -2
  16. data/ext/nokogiri/xml_dtd.c +2 -2
  17. data/ext/nokogiri/xml_encoding_handler.c +25 -11
  18. data/ext/nokogiri/xml_namespace.c +2 -2
  19. data/ext/nokogiri/xml_node.c +647 -335
  20. data/ext/nokogiri/xml_reader.c +37 -11
  21. data/ext/nokogiri/xml_xpath_context.c +72 -49
  22. data/lib/nokogiri/2.6/nokogiri.bundle +0 -0
  23. data/lib/nokogiri/2.7/nokogiri.bundle +0 -0
  24. data/lib/nokogiri/3.0/nokogiri.bundle +0 -0
  25. data/lib/nokogiri/{2.5 → 3.1}/nokogiri.bundle +0 -0
  26. data/lib/nokogiri/class_resolver.rb +67 -0
  27. data/lib/nokogiri/css/node.rb +9 -8
  28. data/lib/nokogiri/css/parser.rb +11 -3
  29. data/lib/nokogiri/css/parser.y +10 -2
  30. data/lib/nokogiri/css/parser_extras.rb +20 -20
  31. data/lib/nokogiri/css/syntax_error.rb +1 -0
  32. data/lib/nokogiri/css/tokenizer.rb +2 -1
  33. data/lib/nokogiri/css/tokenizer.rex +2 -1
  34. data/lib/nokogiri/css/xpath_visitor.rb +174 -75
  35. data/lib/nokogiri/css.rb +38 -6
  36. data/lib/nokogiri/decorators/slop.rb +8 -7
  37. data/lib/nokogiri/extension.rb +1 -1
  38. data/lib/nokogiri/gumbo.rb +1 -0
  39. data/lib/nokogiri/html.rb +16 -10
  40. data/lib/nokogiri/html4/builder.rb +1 -0
  41. data/lib/nokogiri/html4/document.rb +84 -75
  42. data/lib/nokogiri/html4/document_fragment.rb +11 -7
  43. data/lib/nokogiri/html4/element_description.rb +1 -0
  44. data/lib/nokogiri/html4/element_description_defaults.rb +426 -520
  45. data/lib/nokogiri/html4/entity_lookup.rb +2 -1
  46. data/lib/nokogiri/html4/sax/parser.rb +2 -1
  47. data/lib/nokogiri/html4/sax/parser_context.rb +1 -0
  48. data/lib/nokogiri/html4/sax/push_parser.rb +7 -7
  49. data/lib/nokogiri/html4.rb +11 -5
  50. data/lib/nokogiri/html5/document.rb +24 -10
  51. data/lib/nokogiri/html5/document_fragment.rb +5 -2
  52. data/lib/nokogiri/html5/node.rb +6 -3
  53. data/lib/nokogiri/html5.rb +68 -64
  54. data/lib/nokogiri/jruby/dependencies.rb +10 -9
  55. data/lib/nokogiri/syntax_error.rb +1 -0
  56. data/lib/nokogiri/version/constant.rb +2 -1
  57. data/lib/nokogiri/version/info.rb +19 -13
  58. data/lib/nokogiri/version.rb +1 -0
  59. data/lib/nokogiri/xml/attr.rb +5 -3
  60. data/lib/nokogiri/xml/attribute_decl.rb +2 -1
  61. data/lib/nokogiri/xml/builder.rb +69 -31
  62. data/lib/nokogiri/xml/cdata.rb +2 -1
  63. data/lib/nokogiri/xml/character_data.rb +1 -0
  64. data/lib/nokogiri/xml/document.rb +178 -96
  65. data/lib/nokogiri/xml/document_fragment.rb +41 -38
  66. data/lib/nokogiri/xml/dtd.rb +3 -2
  67. data/lib/nokogiri/xml/element_content.rb +1 -0
  68. data/lib/nokogiri/xml/element_decl.rb +2 -1
  69. data/lib/nokogiri/xml/entity_decl.rb +3 -2
  70. data/lib/nokogiri/xml/entity_reference.rb +1 -0
  71. data/lib/nokogiri/xml/namespace.rb +2 -0
  72. data/lib/nokogiri/xml/node/save_options.rb +7 -4
  73. data/lib/nokogiri/xml/node.rb +512 -348
  74. data/lib/nokogiri/xml/node_set.rb +46 -54
  75. data/lib/nokogiri/xml/notation.rb +12 -0
  76. data/lib/nokogiri/xml/parse_options.rb +11 -7
  77. data/lib/nokogiri/xml/pp/character_data.rb +8 -6
  78. data/lib/nokogiri/xml/pp/node.rb +24 -26
  79. data/lib/nokogiri/xml/pp.rb +1 -0
  80. data/lib/nokogiri/xml/processing_instruction.rb +2 -1
  81. data/lib/nokogiri/xml/reader.rb +17 -19
  82. data/lib/nokogiri/xml/relax_ng.rb +1 -0
  83. data/lib/nokogiri/xml/sax/document.rb +20 -19
  84. data/lib/nokogiri/xml/sax/parser.rb +36 -34
  85. data/lib/nokogiri/xml/sax/parser_context.rb +7 -3
  86. data/lib/nokogiri/xml/sax/push_parser.rb +5 -5
  87. data/lib/nokogiri/xml/sax.rb +1 -0
  88. data/lib/nokogiri/xml/schema.rb +7 -6
  89. data/lib/nokogiri/xml/searchable.rb +42 -22
  90. data/lib/nokogiri/xml/syntax_error.rb +4 -4
  91. data/lib/nokogiri/xml/text.rb +1 -0
  92. data/lib/nokogiri/xml/xpath/syntax_error.rb +2 -1
  93. data/lib/nokogiri/xml/xpath.rb +12 -0
  94. data/lib/nokogiri/xml/xpath_context.rb +2 -3
  95. data/lib/nokogiri/xml.rb +3 -3
  96. data/lib/nokogiri/xslt/stylesheet.rb +1 -0
  97. data/lib/nokogiri/xslt.rb +3 -2
  98. data/lib/nokogiri.rb +19 -16
  99. data/lib/xsd/xmlparser/nokogiri.rb +25 -24
  100. metadata +124 -52
@@ -1,4 +1,5 @@
1
1
  # frozen_string_literal: true
2
+
2
3
  module Nokogiri
3
4
  module XML
4
5
  class EntityDecl < Nokogiri::XML::Node
@@ -8,12 +9,12 @@ module Nokogiri
8
9
  undef_method :namespace_definitions
9
10
  undef_method :line if method_defined?(:line)
10
11
 
11
- def self.new name, doc, *args
12
+ def self.new(name, doc, *args)
12
13
  doc.create_entity(name, *args)
13
14
  end
14
15
 
15
16
  def inspect
16
- "#<#{self.class.name}:#{sprintf("0x%x", object_id)} #{to_s.inspect}>"
17
+ "#<#{self.class.name}:#{format("0x%x", object_id)} #{to_s.inspect}>"
17
18
  end
18
19
  end
19
20
  end
@@ -1,4 +1,5 @@
1
1
  # frozen_string_literal: true
2
+
2
3
  module Nokogiri
3
4
  module XML
4
5
  class EntityReference < Nokogiri::XML::Node
@@ -1,4 +1,5 @@
1
1
  # frozen_string_literal: true
2
+
2
3
  module Nokogiri
3
4
  module XML
4
5
  class Namespace
@@ -6,6 +7,7 @@ module Nokogiri
6
7
  attr_reader :document
7
8
 
8
9
  private
10
+
9
11
  def inspect_attributes
10
12
  [:prefix, :href]
11
13
  end
@@ -1,4 +1,5 @@
1
1
  # frozen_string_literal: true
2
+
2
3
  module Nokogiri
3
4
  module XML
4
5
  class Node
@@ -22,7 +23,7 @@ module Nokogiri
22
23
 
23
24
  if Nokogiri.jruby?
24
25
  # Save builder created document
25
- AS_BUILDER = 128
26
+ AS_BUILDER = 128
26
27
  # the default for XML documents
27
28
  DEFAULT_XML = AS_XML # https://github.com/sparklemotion/nokogiri/issues/#issue/415
28
29
  # the default for HTML document
@@ -34,13 +35,15 @@ module Nokogiri
34
35
  DEFAULT_HTML = FORMAT | NO_DECLARATION | NO_EMPTY_TAGS | AS_HTML
35
36
  end
36
37
  # the default for XHTML document
37
- DEFAULT_XHTML = FORMAT | NO_DECLARATION | NO_EMPTY_TAGS | AS_XHTML
38
+ DEFAULT_XHTML = FORMAT | NO_DECLARATION | AS_XHTML
38
39
 
39
40
  # Integer representation of the SaveOptions
40
41
  attr_reader :options
41
42
 
42
43
  # Create a new SaveOptions object with +options+
43
- def initialize options = 0; @options = options; end
44
+ def initialize(options = 0)
45
+ @options = options
46
+ end
44
47
 
45
48
  constants.each do |constant|
46
49
  class_eval %{
@@ -55,7 +58,7 @@ module Nokogiri
55
58
  }
56
59
  end
57
60
 
58
- alias :to_i :options
61
+ alias_method :to_i, :options
59
62
  end
60
63
  end
61
64
  end