hamlit 2.9.4 → 2.9.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/lib/hamlit/filters/plain.rb +4 -3
- data/lib/hamlit/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 818a7688a58be17941aea6ddd21986d58186048882d0672b9f8a586d19a00972
|
4
|
+
data.tar.gz: 22c7eaef6d2fb67fe939c8d861780d4d56affa6df0d478ede2b0beb7da6bf79f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 56fa71f1352812b9f98e2042f4f59fb54cb35183ee3ee9c29fd9302293446522bbd5c03e0cd9859fb0d757ec854692e544a4a51e169bb9478da68b251f1059a2
|
7
|
+
data.tar.gz: 564b8282a5a1db7b476d664792d157112fbe5f4d28be48b0d31f89542c084fda0c17f86a2930306c3ed9b599b04e43073e81929488d49b0101a78ed2c336bceb
|
data/CHANGELOG.md
CHANGED
@@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file. This
|
|
4
4
|
project adheres to [Semantic Versioning](http://semver.org/). This change log is based upon
|
5
5
|
[keep-a-changelog](https://github.com/olivierlacan/keep-a-changelog).
|
6
6
|
|
7
|
+
## [2.9.5](https://github.com/k0kubun/hamlit/compare/v2.9.4...v2.9.5) - 2019-09-08
|
8
|
+
|
9
|
+
### Added
|
10
|
+
|
11
|
+
- Supported `:plain` filter in truffleruby
|
12
|
+
|
7
13
|
## [2.9.4](https://github.com/k0kubun/hamlit/compare/v2.9.3...v2.9.4) - 2019-09-08
|
8
14
|
|
9
15
|
### Added
|
data/lib/hamlit/filters/plain.rb
CHANGED
@@ -5,9 +5,6 @@ module Hamlit
|
|
5
5
|
class Filters
|
6
6
|
class Plain < Base
|
7
7
|
def compile(node)
|
8
|
-
unless Ripper.respond_to?(:lex)
|
9
|
-
raise NotImplementedError.new('This platform does not have Ripper.lex required for :plain filter')
|
10
|
-
end
|
11
8
|
text = node.value[:text]
|
12
9
|
text = text.rstrip unless ::Hamlit::HamlUtil.contains_interpolation?(text) # for compatibility
|
13
10
|
[:multi, *compile_plain(text)]
|
@@ -17,6 +14,10 @@ module Hamlit
|
|
17
14
|
|
18
15
|
def compile_plain(text)
|
19
16
|
string_literal = ::Hamlit::HamlUtil.unescape_interpolation(text)
|
17
|
+
unless Ripper.respond_to?(:lex) # truffleruby doesn't have Ripper.lex
|
18
|
+
return [[:escape, false, [:dynamic, string_literal]]]
|
19
|
+
end
|
20
|
+
|
20
21
|
StringSplitter.compile(string_literal).map do |temple|
|
21
22
|
type, str = temple
|
22
23
|
case type
|
data/lib/hamlit/version.rb
CHANGED