sassc 2.0.0 → 2.4.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/.gitignore +2 -0
- data/.gitmodules +1 -1
- data/.travis.yml +9 -3
- data/CHANGELOG.md +36 -0
- data/CODE_OF_CONDUCT.md +1 -1
- data/README.md +1 -1
- data/Rakefile +43 -7
- data/ext/depend +4 -0
- data/ext/extconf.rb +92 -0
- data/ext/libsass/VERSION +1 -0
- data/ext/libsass/include/sass/base.h +9 -1
- data/ext/libsass/include/sass/context.h +5 -1
- data/ext/libsass/src/MurmurHash2.hpp +91 -0
- data/ext/libsass/src/ast.cpp +755 -2028
- data/ext/libsass/src/ast.hpp +492 -2477
- data/ext/libsass/src/{to_c.cpp → ast2c.cpp} +22 -16
- data/ext/libsass/src/ast2c.hpp +39 -0
- data/ext/libsass/src/ast_def_macros.hpp +70 -10
- data/ext/libsass/src/ast_fwd_decl.cpp +5 -3
- data/ext/libsass/src/ast_fwd_decl.hpp +107 -296
- data/ext/libsass/src/ast_helpers.hpp +292 -0
- data/ext/libsass/src/ast_sel_cmp.cpp +396 -0
- data/ext/libsass/src/ast_sel_super.cpp +539 -0
- data/ext/libsass/src/ast_sel_unify.cpp +275 -0
- data/ext/libsass/src/ast_sel_weave.cpp +616 -0
- data/ext/libsass/src/ast_selectors.cpp +1043 -0
- data/ext/libsass/src/ast_selectors.hpp +522 -0
- data/ext/libsass/src/ast_supports.cpp +114 -0
- data/ext/libsass/src/ast_supports.hpp +121 -0
- data/ext/libsass/src/ast_values.cpp +1154 -0
- data/ext/libsass/src/ast_values.hpp +498 -0
- data/ext/libsass/src/backtrace.cpp +11 -7
- data/ext/libsass/src/backtrace.hpp +5 -5
- data/ext/libsass/src/base64vlq.cpp +5 -2
- data/ext/libsass/src/base64vlq.hpp +1 -1
- data/ext/libsass/src/bind.cpp +35 -34
- data/ext/libsass/src/bind.hpp +3 -1
- data/ext/libsass/src/c2ast.cpp +64 -0
- data/ext/libsass/src/c2ast.hpp +14 -0
- data/ext/libsass/src/cencode.c +4 -6
- data/ext/libsass/src/check_nesting.cpp +83 -88
- data/ext/libsass/src/check_nesting.hpp +39 -34
- data/ext/libsass/src/color_maps.cpp +168 -164
- data/ext/libsass/src/color_maps.hpp +152 -160
- data/ext/libsass/src/constants.cpp +20 -0
- data/ext/libsass/src/constants.hpp +19 -0
- data/ext/libsass/src/context.cpp +104 -121
- data/ext/libsass/src/context.hpp +43 -55
- data/ext/libsass/src/cssize.cpp +103 -188
- data/ext/libsass/src/cssize.hpp +45 -51
- data/ext/libsass/src/dart_helpers.hpp +199 -0
- data/ext/libsass/src/debugger.hpp +524 -361
- data/ext/libsass/src/emitter.cpp +26 -26
- data/ext/libsass/src/emitter.hpp +20 -18
- data/ext/libsass/src/environment.cpp +41 -27
- data/ext/libsass/src/environment.hpp +33 -22
- data/ext/libsass/src/error_handling.cpp +92 -94
- data/ext/libsass/src/error_handling.hpp +73 -50
- data/ext/libsass/src/eval.cpp +380 -515
- data/ext/libsass/src/eval.hpp +64 -57
- data/ext/libsass/src/eval_selectors.cpp +75 -0
- data/ext/libsass/src/expand.cpp +322 -263
- data/ext/libsass/src/expand.hpp +55 -39
- data/ext/libsass/src/extender.cpp +1188 -0
- data/ext/libsass/src/extender.hpp +399 -0
- data/ext/libsass/src/extension.cpp +43 -0
- data/ext/libsass/src/extension.hpp +89 -0
- data/ext/libsass/src/file.cpp +134 -88
- data/ext/libsass/src/file.hpp +28 -37
- data/ext/libsass/src/fn_colors.cpp +596 -0
- data/ext/libsass/src/fn_colors.hpp +85 -0
- data/ext/libsass/src/fn_lists.cpp +285 -0
- data/ext/libsass/src/fn_lists.hpp +34 -0
- data/ext/libsass/src/fn_maps.cpp +94 -0
- data/ext/libsass/src/fn_maps.hpp +30 -0
- data/ext/libsass/src/fn_miscs.cpp +244 -0
- data/ext/libsass/src/fn_miscs.hpp +40 -0
- data/ext/libsass/src/fn_numbers.cpp +227 -0
- data/ext/libsass/src/fn_numbers.hpp +45 -0
- data/ext/libsass/src/fn_selectors.cpp +205 -0
- data/ext/libsass/src/fn_selectors.hpp +35 -0
- data/ext/libsass/src/fn_strings.cpp +268 -0
- data/ext/libsass/src/fn_strings.hpp +34 -0
- data/ext/libsass/src/fn_utils.cpp +158 -0
- data/ext/libsass/src/fn_utils.hpp +62 -0
- data/ext/libsass/src/inspect.cpp +253 -266
- data/ext/libsass/src/inspect.hpp +72 -74
- data/ext/libsass/src/json.cpp +2 -2
- data/ext/libsass/src/lexer.cpp +25 -84
- data/ext/libsass/src/lexer.hpp +5 -16
- data/ext/libsass/src/listize.cpp +27 -43
- data/ext/libsass/src/listize.hpp +14 -11
- data/ext/libsass/src/mapping.hpp +1 -0
- data/ext/libsass/src/memory.hpp +12 -0
- data/ext/libsass/src/memory/allocator.cpp +48 -0
- data/ext/libsass/src/memory/allocator.hpp +138 -0
- data/ext/libsass/src/memory/config.hpp +20 -0
- data/ext/libsass/src/memory/memory_pool.hpp +186 -0
- data/ext/libsass/src/memory/shared_ptr.cpp +33 -0
- data/ext/libsass/src/memory/shared_ptr.hpp +332 -0
- data/ext/libsass/src/operation.hpp +193 -143
- data/ext/libsass/src/operators.cpp +56 -29
- data/ext/libsass/src/operators.hpp +11 -11
- data/ext/libsass/src/ordered_map.hpp +112 -0
- data/ext/libsass/src/output.cpp +59 -75
- data/ext/libsass/src/output.hpp +15 -22
- data/ext/libsass/src/parser.cpp +662 -818
- data/ext/libsass/src/parser.hpp +96 -100
- data/ext/libsass/src/parser_selectors.cpp +189 -0
- data/ext/libsass/src/permutate.hpp +164 -0
- data/ext/libsass/src/plugins.cpp +12 -8
- data/ext/libsass/src/plugins.hpp +8 -8
- data/ext/libsass/src/position.cpp +10 -26
- data/ext/libsass/src/position.hpp +44 -21
- data/ext/libsass/src/prelexer.cpp +14 -8
- data/ext/libsass/src/prelexer.hpp +9 -9
- data/ext/libsass/src/remove_placeholders.cpp +59 -57
- data/ext/libsass/src/remove_placeholders.hpp +20 -18
- data/ext/libsass/src/sass.cpp +25 -18
- data/ext/libsass/src/sass.hpp +22 -14
- data/ext/libsass/src/sass2scss.cpp +49 -18
- data/ext/libsass/src/sass_context.cpp +104 -132
- data/ext/libsass/src/sass_context.hpp +2 -2
- data/ext/libsass/src/sass_functions.cpp +7 -4
- data/ext/libsass/src/sass_functions.hpp +1 -1
- data/ext/libsass/src/sass_values.cpp +26 -21
- data/ext/libsass/src/settings.hpp +19 -0
- data/ext/libsass/src/source.cpp +69 -0
- data/ext/libsass/src/source.hpp +95 -0
- data/ext/libsass/src/source_data.hpp +32 -0
- data/ext/libsass/src/source_map.cpp +27 -20
- data/ext/libsass/src/source_map.hpp +14 -11
- data/ext/libsass/src/stylesheet.cpp +22 -0
- data/ext/libsass/src/stylesheet.hpp +57 -0
- data/ext/libsass/src/to_value.cpp +24 -22
- data/ext/libsass/src/to_value.hpp +18 -22
- data/ext/libsass/src/units.cpp +28 -22
- data/ext/libsass/src/units.hpp +9 -8
- data/ext/libsass/src/utf8/checked.h +12 -10
- data/ext/libsass/src/utf8/core.h +3 -0
- data/ext/libsass/src/utf8_string.cpp +12 -10
- data/ext/libsass/src/utf8_string.hpp +7 -6
- data/ext/libsass/src/util.cpp +97 -107
- data/ext/libsass/src/util.hpp +74 -30
- data/ext/libsass/src/util_string.cpp +125 -0
- data/ext/libsass/src/util_string.hpp +73 -0
- data/ext/libsass/src/values.cpp +33 -24
- data/ext/libsass/src/values.hpp +2 -2
- data/lib/sassc.rb +24 -0
- data/lib/sassc/engine.rb +7 -5
- data/lib/sassc/functions_handler.rb +11 -13
- data/lib/sassc/native.rb +10 -9
- data/lib/sassc/native/native_functions_api.rb +0 -5
- data/lib/sassc/script.rb +4 -6
- data/lib/sassc/version.rb +1 -1
- data/sassc.gemspec +32 -12
- data/test/engine_test.rb +32 -2
- data/test/functions_test.rb +38 -1
- data/test/native_test.rb +4 -4
- metadata +95 -109
- data/ext/Rakefile +0 -3
- data/ext/libsass/.editorconfig +0 -15
- data/ext/libsass/.gitattributes +0 -2
- data/ext/libsass/.github/CONTRIBUTING.md +0 -65
- data/ext/libsass/.github/ISSUE_TEMPLATE.md +0 -54
- data/ext/libsass/.gitignore +0 -85
- data/ext/libsass/.travis.yml +0 -64
- data/ext/libsass/COPYING +0 -25
- data/ext/libsass/GNUmakefile.am +0 -88
- data/ext/libsass/INSTALL +0 -1
- data/ext/libsass/LICENSE +0 -25
- data/ext/libsass/Makefile +0 -351
- data/ext/libsass/Makefile.conf +0 -55
- data/ext/libsass/Readme.md +0 -104
- data/ext/libsass/SECURITY.md +0 -10
- data/ext/libsass/appveyor.yml +0 -91
- data/ext/libsass/configure.ac +0 -138
- data/ext/libsass/contrib/libsass.spec +0 -66
- data/ext/libsass/docs/README.md +0 -20
- data/ext/libsass/docs/api-context-example.md +0 -45
- data/ext/libsass/docs/api-context-internal.md +0 -163
- data/ext/libsass/docs/api-context.md +0 -295
- data/ext/libsass/docs/api-doc.md +0 -215
- data/ext/libsass/docs/api-function-example.md +0 -67
- data/ext/libsass/docs/api-function-internal.md +0 -8
- data/ext/libsass/docs/api-function.md +0 -74
- data/ext/libsass/docs/api-importer-example.md +0 -112
- data/ext/libsass/docs/api-importer-internal.md +0 -20
- data/ext/libsass/docs/api-importer.md +0 -86
- data/ext/libsass/docs/api-value-example.md +0 -55
- data/ext/libsass/docs/api-value-internal.md +0 -76
- data/ext/libsass/docs/api-value.md +0 -154
- data/ext/libsass/docs/build-on-darwin.md +0 -27
- data/ext/libsass/docs/build-on-gentoo.md +0 -55
- data/ext/libsass/docs/build-on-windows.md +0 -139
- data/ext/libsass/docs/build-shared-library.md +0 -35
- data/ext/libsass/docs/build-with-autotools.md +0 -78
- data/ext/libsass/docs/build-with-makefiles.md +0 -68
- data/ext/libsass/docs/build-with-mingw.md +0 -107
- data/ext/libsass/docs/build-with-visual-studio.md +0 -90
- data/ext/libsass/docs/build.md +0 -97
- data/ext/libsass/docs/compatibility-plan.md +0 -48
- data/ext/libsass/docs/contributing.md +0 -17
- data/ext/libsass/docs/custom-functions-internal.md +0 -122
- data/ext/libsass/docs/dev-ast-memory.md +0 -223
- data/ext/libsass/docs/implementations.md +0 -56
- data/ext/libsass/docs/plugins.md +0 -47
- data/ext/libsass/docs/setup-environment.md +0 -68
- data/ext/libsass/docs/source-map-internals.md +0 -51
- data/ext/libsass/docs/trace.md +0 -26
- data/ext/libsass/docs/triage.md +0 -17
- data/ext/libsass/docs/unicode.md +0 -39
- data/ext/libsass/extconf.rb +0 -6
- data/ext/libsass/include/sass/version.h.in +0 -12
- data/ext/libsass/m4/.gitkeep +0 -0
- data/ext/libsass/m4/m4-ax_cxx_compile_stdcxx_11.m4 +0 -167
- data/ext/libsass/res/resource.rc +0 -35
- data/ext/libsass/script/bootstrap +0 -13
- data/ext/libsass/script/branding +0 -10
- data/ext/libsass/script/ci-build-libsass +0 -134
- data/ext/libsass/script/ci-build-plugin +0 -62
- data/ext/libsass/script/ci-install-compiler +0 -6
- data/ext/libsass/script/ci-install-deps +0 -20
- data/ext/libsass/script/ci-report-coverage +0 -42
- data/ext/libsass/script/spec +0 -5
- data/ext/libsass/script/tap-driver +0 -652
- data/ext/libsass/script/tap-runner +0 -1
- data/ext/libsass/script/test-leaks.pl +0 -103
- data/ext/libsass/src/GNUmakefile.am +0 -54
- data/ext/libsass/src/extend.cpp +0 -2130
- data/ext/libsass/src/extend.hpp +0 -86
- data/ext/libsass/src/functions.cpp +0 -2234
- data/ext/libsass/src/functions.hpp +0 -198
- data/ext/libsass/src/memory/SharedPtr.cpp +0 -114
- data/ext/libsass/src/memory/SharedPtr.hpp +0 -206
- data/ext/libsass/src/node.cpp +0 -319
- data/ext/libsass/src/node.hpp +0 -118
- data/ext/libsass/src/paths.hpp +0 -71
- data/ext/libsass/src/sass_util.cpp +0 -149
- data/ext/libsass/src/sass_util.hpp +0 -256
- data/ext/libsass/src/subset_map.cpp +0 -55
- data/ext/libsass/src/subset_map.hpp +0 -76
- data/ext/libsass/src/support/libsass.pc.in +0 -11
- data/ext/libsass/src/to_c.hpp +0 -39
- data/ext/libsass/test/test_node.cpp +0 -94
- data/ext/libsass/test/test_paths.cpp +0 -28
- data/ext/libsass/test/test_selector_difference.cpp +0 -25
- data/ext/libsass/test/test_specificity.cpp +0 -25
- data/ext/libsass/test/test_subset_map.cpp +0 -472
- data/ext/libsass/test/test_superselector.cpp +0 -69
- data/ext/libsass/test/test_unification.cpp +0 -31
- data/ext/libsass/version.sh +0 -10
- data/ext/libsass/win/libsass.sln +0 -39
- data/ext/libsass/win/libsass.sln.DotSettings +0 -9
- data/ext/libsass/win/libsass.targets +0 -118
- data/ext/libsass/win/libsass.vcxproj +0 -188
- data/ext/libsass/win/libsass.vcxproj.filters +0 -357
- data/lib/sassc/native/lib_c.rb +0 -21
- data/lib/tasks/libsass.rb +0 -33
data/ext/libsass/src/values.hpp
CHANGED
|
@@ -5,8 +5,8 @@
|
|
|
5
5
|
|
|
6
6
|
namespace Sass {
|
|
7
7
|
|
|
8
|
-
union Sass_Value* ast_node_to_sass_value (const
|
|
9
|
-
|
|
8
|
+
union Sass_Value* ast_node_to_sass_value (const Expression* val);
|
|
9
|
+
Value* sass_value_to_ast_node (const union Sass_Value* val);
|
|
10
10
|
|
|
11
11
|
}
|
|
12
12
|
#endif
|
data/lib/sassc.rb
CHANGED
|
@@ -1,6 +1,30 @@
|
|
|
1
1
|
# frozen_string_literal: true
|
|
2
2
|
|
|
3
3
|
module SassC
|
|
4
|
+
# The global load paths for Sass files. This is meant for plugins and
|
|
5
|
+
# libraries to register the paths to their Sass stylesheets to that they may
|
|
6
|
+
# be `@imported`. This load path is used by every instance of {Sass::Engine}.
|
|
7
|
+
# They are lower-precedence than any load paths passed in via the
|
|
8
|
+
# {file:SASS_REFERENCE.md#load_paths-option `:load_paths` option}.
|
|
9
|
+
#
|
|
10
|
+
# If the `SASS_PATH` environment variable is set,
|
|
11
|
+
# the initial value of `load_paths` will be initialized based on that.
|
|
12
|
+
# The variable should be a colon-separated list of path names
|
|
13
|
+
# (semicolon-separated on Windows).
|
|
14
|
+
#
|
|
15
|
+
# Note that files on the global load path are never compiled to CSS
|
|
16
|
+
# themselves, even if they aren't partials. They exist only to be imported.
|
|
17
|
+
#
|
|
18
|
+
# @example
|
|
19
|
+
# SassC.load_paths << File.dirname(__FILE__ + '/sass')
|
|
20
|
+
# @return [Array<String, Pathname, Sass::Importers::Base>]
|
|
21
|
+
def self.load_paths
|
|
22
|
+
@load_paths ||= if ENV['SASS_PATH']
|
|
23
|
+
ENV['SASS_PATH'].split(SassC::Util.windows? ? ';' : ':')
|
|
24
|
+
else
|
|
25
|
+
[]
|
|
26
|
+
end
|
|
27
|
+
end
|
|
4
28
|
end
|
|
5
29
|
|
|
6
30
|
require_relative "sassc/version"
|
data/lib/sassc/engine.rb
CHANGED
|
@@ -16,6 +16,7 @@ module SassC
|
|
|
16
16
|
def initialize(template, options = {})
|
|
17
17
|
@template = template
|
|
18
18
|
@options = options
|
|
19
|
+
@functions = options.fetch(:functions, Script::Functions)
|
|
19
20
|
end
|
|
20
21
|
|
|
21
22
|
def render
|
|
@@ -37,7 +38,7 @@ module SassC
|
|
|
37
38
|
Native.option_set_omit_source_map_url(native_options, true) if omit_source_map_url?
|
|
38
39
|
|
|
39
40
|
import_handler.setup(native_options)
|
|
40
|
-
functions_handler.setup(native_options)
|
|
41
|
+
functions_handler.setup(native_options, functions: @functions)
|
|
41
42
|
|
|
42
43
|
status = Native.compile_data_context(data_context)
|
|
43
44
|
|
|
@@ -54,11 +55,12 @@ module SassC
|
|
|
54
55
|
@dependencies = Native.context_get_included_files(context)
|
|
55
56
|
@source_map = Native.context_get_source_map_string(context)
|
|
56
57
|
|
|
57
|
-
Native.delete_data_context(data_context)
|
|
58
|
-
|
|
59
58
|
css.force_encoding(@template.encoding)
|
|
59
|
+
@source_map.force_encoding(@template.encoding) if @source_map.is_a?(String)
|
|
60
60
|
|
|
61
61
|
return css unless quiet?
|
|
62
|
+
ensure
|
|
63
|
+
Native.delete_data_context(data_context) if data_context
|
|
62
64
|
end
|
|
63
65
|
|
|
64
66
|
def dependencies
|
|
@@ -132,8 +134,8 @@ module SassC
|
|
|
132
134
|
end
|
|
133
135
|
|
|
134
136
|
def load_paths
|
|
135
|
-
paths = @options[:load_paths]
|
|
136
|
-
paths.join(
|
|
137
|
+
paths = (@options[:load_paths] || []) + SassC.load_paths
|
|
138
|
+
paths.join(File::PATH_SEPARATOR) unless paths.empty?
|
|
137
139
|
end
|
|
138
140
|
end
|
|
139
141
|
end
|
|
@@ -6,20 +6,24 @@ module SassC
|
|
|
6
6
|
@options = options
|
|
7
7
|
end
|
|
8
8
|
|
|
9
|
-
def setup(native_options)
|
|
9
|
+
def setup(native_options, functions: Script::Functions)
|
|
10
10
|
@callbacks = {}
|
|
11
11
|
@function_names = {}
|
|
12
12
|
|
|
13
|
-
list = Native.make_function_list(Script.custom_functions.count)
|
|
13
|
+
list = Native.make_function_list(Script.custom_functions(functions: functions).count)
|
|
14
14
|
|
|
15
|
-
|
|
16
|
-
|
|
15
|
+
# use an anonymous class wrapper to avoid mutations in a threaded environment
|
|
16
|
+
functions_wrapper = Class.new do
|
|
17
|
+
attr_accessor :options
|
|
18
|
+
include functions
|
|
19
|
+
end.new
|
|
20
|
+
functions_wrapper.options = @options
|
|
17
21
|
|
|
18
|
-
Script.custom_functions.each_with_index do |custom_function, i|
|
|
22
|
+
Script.custom_functions(functions: functions).each_with_index do |custom_function, i|
|
|
19
23
|
@callbacks[custom_function] = FFI::Function.new(:pointer, [:pointer, :pointer]) do |native_argument_list, cookie|
|
|
20
24
|
begin
|
|
21
25
|
function_arguments = arguments_from_native_list(native_argument_list)
|
|
22
|
-
result =
|
|
26
|
+
result = functions_wrapper.send(custom_function, *function_arguments)
|
|
23
27
|
to_native_value(result)
|
|
24
28
|
rescue StandardError => exception
|
|
25
29
|
# This rescues any exceptions that occur either in value conversion
|
|
@@ -28,7 +32,7 @@ module SassC
|
|
|
28
32
|
end
|
|
29
33
|
end
|
|
30
34
|
|
|
31
|
-
@function_names[custom_function] = Script.formatted_function_name(custom_function)
|
|
35
|
+
@function_names[custom_function] = Script.formatted_function_name(custom_function, functions: functions)
|
|
32
36
|
|
|
33
37
|
callback = Native.make_function(
|
|
34
38
|
@function_names[custom_function],
|
|
@@ -65,11 +69,5 @@ module SassC
|
|
|
65
69
|
$stderr.puts "[SassC::FunctionsHandler] #{message}"
|
|
66
70
|
Native.make_error(message)
|
|
67
71
|
end
|
|
68
|
-
|
|
69
|
-
class FunctionWrapper
|
|
70
|
-
class << self
|
|
71
|
-
attr_accessor :options
|
|
72
|
-
end
|
|
73
|
-
end
|
|
74
72
|
end
|
|
75
73
|
end
|
data/lib/sassc/native.rb
CHANGED
|
@@ -6,9 +6,12 @@ module SassC
|
|
|
6
6
|
module Native
|
|
7
7
|
extend FFI::Library
|
|
8
8
|
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
9
|
+
dl_ext = RbConfig::MAKEFILE_CONFIG['DLEXT']
|
|
10
|
+
begin
|
|
11
|
+
ffi_lib File.expand_path("libsass.#{dl_ext}", __dir__)
|
|
12
|
+
rescue LoadError # Some non-rvm environments don't copy a shared object over to lib/sassc
|
|
13
|
+
ffi_lib File.expand_path("libsass.#{dl_ext}", "#{__dir__}/../../ext")
|
|
14
|
+
end
|
|
12
15
|
|
|
13
16
|
require_relative "native/sass_value"
|
|
14
17
|
|
|
@@ -31,11 +34,10 @@ module SassC
|
|
|
31
34
|
require_relative "native/sass_input_style"
|
|
32
35
|
require_relative "native/sass_output_style"
|
|
33
36
|
require_relative "native/string_list"
|
|
34
|
-
require_relative "native/lib_c"
|
|
35
37
|
|
|
36
38
|
# Remove the redundant "sass_" from the beginning of every method name
|
|
37
39
|
def self.attach_function(*args)
|
|
38
|
-
super if args.size != 3
|
|
40
|
+
return super if args.size != 3
|
|
39
41
|
|
|
40
42
|
if args[0] =~ /^sass_/
|
|
41
43
|
args.unshift args[0].to_s.sub(/^sass_/, "")
|
|
@@ -50,10 +52,9 @@ module SassC
|
|
|
50
52
|
end
|
|
51
53
|
|
|
52
54
|
def self.native_string(string)
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
data
|
|
55
|
+
m = FFI::MemoryPointer.from_string(string)
|
|
56
|
+
m.autorelease = false
|
|
57
|
+
m
|
|
57
58
|
end
|
|
58
59
|
|
|
59
60
|
require_relative "native/native_context_api"
|
|
@@ -98,11 +98,6 @@ module SassC
|
|
|
98
98
|
attach_function "sass_color_set_#{color_channel}".to_sym, [:sass_value_ptr, :double], :void
|
|
99
99
|
end
|
|
100
100
|
|
|
101
|
-
# ADDAPI size_t ADDCALL sass_list_get_length(const union Sass_Value* v)
|
|
102
|
-
# ADDAPI union Sass_Value* ADDCALL sass_list_get_value (const union Sass_Value* v, size_t i);
|
|
103
|
-
attach_function :sass_list_get_length, [:sass_value_ptr], :size_t
|
|
104
|
-
attach_function :sass_list_get_value, [:sass_value_ptr, :size_t], :sass_value_ptr
|
|
105
|
-
|
|
106
101
|
# ADDAPI char* ADDCALL sass_error_get_message (const union Sass_Value* v);
|
|
107
102
|
# ADDAPI void ADDCALL sass_error_set_message (union Sass_Value* v, char* msg);
|
|
108
103
|
attach_function :sass_error_get_message, [:sass_value_ptr], :string
|
data/lib/sassc/script.rb
CHANGED
|
@@ -3,14 +3,12 @@
|
|
|
3
3
|
module SassC
|
|
4
4
|
module Script
|
|
5
5
|
|
|
6
|
-
def self.custom_functions
|
|
7
|
-
|
|
8
|
-
Functions.public_method_defined?(function)
|
|
9
|
-
end
|
|
6
|
+
def self.custom_functions(functions: Functions)
|
|
7
|
+
functions.public_instance_methods
|
|
10
8
|
end
|
|
11
9
|
|
|
12
|
-
def self.formatted_function_name(function_name)
|
|
13
|
-
params =
|
|
10
|
+
def self.formatted_function_name(function_name, functions: Functions)
|
|
11
|
+
params = functions.instance_method(function_name).parameters
|
|
14
12
|
params = params.map { |param_type, name| "$#{name}#{': null' if param_type == :opt}" }.join(", ")
|
|
15
13
|
return "#{function_name}(#{params})"
|
|
16
14
|
end
|
data/lib/sassc/version.rb
CHANGED
data/sassc.gemspec
CHANGED
|
@@ -19,31 +19,51 @@ Gem::Specification.new do |spec|
|
|
|
19
19
|
spec.executables = spec.files.grep(%r{^bin/}) { |f| File.basename(f) }
|
|
20
20
|
spec.test_files = spec.files.grep(%r{^(test|spec|features)/})
|
|
21
21
|
|
|
22
|
-
spec.required_ruby_version = ">= 2.
|
|
22
|
+
spec.required_ruby_version = ">= 2.0.0"
|
|
23
23
|
|
|
24
24
|
spec.require_paths = ["lib"]
|
|
25
25
|
|
|
26
|
-
spec.
|
|
26
|
+
spec.platform = Gem::Platform::RUBY
|
|
27
|
+
spec.extensions = ["ext/extconf.rb"]
|
|
27
28
|
|
|
28
29
|
spec.add_development_dependency "minitest", "~> 5.5.1"
|
|
29
30
|
spec.add_development_dependency "minitest-around"
|
|
30
31
|
spec.add_development_dependency "test_construct"
|
|
31
32
|
spec.add_development_dependency "pry"
|
|
32
33
|
spec.add_development_dependency "bundler"
|
|
34
|
+
spec.add_development_dependency "rake"
|
|
35
|
+
spec.add_development_dependency "rake-compiler"
|
|
36
|
+
spec.add_development_dependency "rake-compiler-dock"
|
|
33
37
|
|
|
34
|
-
spec.add_dependency "
|
|
35
|
-
spec.add_dependency "ffi", "~> 1.9.6"
|
|
38
|
+
spec.add_dependency "ffi", "~> 1.9"
|
|
36
39
|
|
|
37
40
|
gem_dir = File.expand_path(File.dirname(__FILE__)) + "/"
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
#
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
41
|
+
|
|
42
|
+
libsass_dir = File.join(gem_dir, 'ext', 'libsass')
|
|
43
|
+
if !File.directory?(libsass_dir) ||
|
|
44
|
+
# '.', '..', and possibly '.git' from a failed checkout:
|
|
45
|
+
Dir.entries(libsass_dir).size <= 3
|
|
46
|
+
Dir.chdir(__dir__) { system('git submodule update --init') } or
|
|
47
|
+
fail 'Could not fetch libsass'
|
|
48
|
+
end
|
|
49
|
+
|
|
50
|
+
# Write a VERSION file for non-binary gems (for `SassC::Native.version`).
|
|
51
|
+
if File.exist?(File.join(libsass_dir, '.git'))
|
|
52
|
+
libsass_version = Dir.chdir(libsass_dir) do
|
|
53
|
+
%x[git describe --abbrev=4 --dirty --always --tags].chomp
|
|
54
|
+
end
|
|
55
|
+
File.write(File.join(libsass_dir, 'VERSION'), libsass_version)
|
|
56
|
+
end
|
|
57
|
+
|
|
58
|
+
Dir.chdir(libsass_dir) do
|
|
59
|
+
submodule_relative_path = File.join('ext', 'libsass')
|
|
60
|
+
skip_re = %r{(^("?test|docs|script)/)|\.md$|\.yml$}
|
|
61
|
+
only_re = %r{\.[ch](pp)?$}
|
|
62
|
+
`git ls-files`.split($\).each do |filename|
|
|
63
|
+
next if filename =~ skip_re || filename !~ only_re
|
|
64
|
+
spec.files << File.join(submodule_relative_path, filename)
|
|
46
65
|
end
|
|
66
|
+
spec.files << File.join(submodule_relative_path, 'VERSION')
|
|
47
67
|
end
|
|
48
68
|
|
|
49
69
|
end
|
data/test/engine_test.rb
CHANGED
|
@@ -88,7 +88,7 @@ $var: 1;
|
|
|
88
88
|
SCSS
|
|
89
89
|
expected_output = <<-CSS
|
|
90
90
|
.foo {
|
|
91
|
-
baz: 0.
|
|
91
|
+
baz: 0.3333333333; }
|
|
92
92
|
CSS
|
|
93
93
|
output = Engine.new(template).render
|
|
94
94
|
assert_equal expected_output, output
|
|
@@ -198,6 +198,31 @@ SCSS
|
|
|
198
198
|
).render
|
|
199
199
|
end
|
|
200
200
|
|
|
201
|
+
def test_global_load_paths
|
|
202
|
+
temp_dir("included_1")
|
|
203
|
+
temp_dir("included_2")
|
|
204
|
+
|
|
205
|
+
temp_file("included_1/import_parent.scss", "$s: 30px;")
|
|
206
|
+
temp_file("included_2/import.scss", "@import 'import_parent'; $size: $s;")
|
|
207
|
+
temp_file("styles.scss", "@import 'import.scss'; .hi { width: $size; }")
|
|
208
|
+
|
|
209
|
+
::SassC.load_paths << "included_1"
|
|
210
|
+
::SassC.load_paths << "included_2"
|
|
211
|
+
|
|
212
|
+
assert_equal ".hi {\n width: 30px; }\n", Engine.new(
|
|
213
|
+
File.read("styles.scss"),
|
|
214
|
+
).render
|
|
215
|
+
::SassC.load_paths.clear
|
|
216
|
+
end
|
|
217
|
+
|
|
218
|
+
def test_env_load_paths
|
|
219
|
+
expected_load_paths = [ "included_1", "included_2" ]
|
|
220
|
+
::SassC.instance_eval { @load_paths = nil }
|
|
221
|
+
ENV['SASS_PATH'] = expected_load_paths.join(File::PATH_SEPARATOR)
|
|
222
|
+
assert_equal expected_load_paths, ::SassC.load_paths
|
|
223
|
+
::SassC.load_paths.clear
|
|
224
|
+
end
|
|
225
|
+
|
|
201
226
|
def test_load_paths_not_configured
|
|
202
227
|
temp_file("included_1/import_parent.scss", "$s: 30px;")
|
|
203
228
|
temp_file("included_2/import.scss", "@import 'import_parent'; $size: $s;")
|
|
@@ -261,7 +286,7 @@ CSS
|
|
|
261
286
|
def test_empty_template_returns_a_new_object
|
|
262
287
|
input = String.new
|
|
263
288
|
output = Engine.new(input).render
|
|
264
|
-
assert input.
|
|
289
|
+
assert !input.equal?(output), 'empty template must return a new object'
|
|
265
290
|
end
|
|
266
291
|
|
|
267
292
|
def test_empty_template_encoding_matches_input
|
|
@@ -270,6 +295,11 @@ CSS
|
|
|
270
295
|
assert_equal input.encoding, output.encoding
|
|
271
296
|
end
|
|
272
297
|
|
|
298
|
+
def test_handling_of_frozen_strings
|
|
299
|
+
output = Engine.new("body { background-color: red; }".freeze).render
|
|
300
|
+
assert_equal output, "body {\n background-color: red; }\n"
|
|
301
|
+
end
|
|
302
|
+
|
|
273
303
|
def test_import_plain_css
|
|
274
304
|
temp_file("test.css", ".something{color: red}")
|
|
275
305
|
expected_output = <<-CSS
|
data/test/functions_test.rb
CHANGED
|
@@ -140,7 +140,7 @@ module SassC
|
|
|
140
140
|
|
|
141
141
|
assert_match /Error: error in C function function_that_raises_errors/, exception.message
|
|
142
142
|
assert_match /Intentional wrong thing happened somewhere inside the custom function/, exception.message
|
|
143
|
-
|
|
143
|
+
assert_match /\[SassC::FunctionsHandler\] Intentional wrong thing happened somewhere inside the custom function/, stderr_output
|
|
144
144
|
end
|
|
145
145
|
|
|
146
146
|
def test_function_that_returns_a_sass_value
|
|
@@ -185,6 +185,33 @@ module SassC
|
|
|
185
185
|
CSS
|
|
186
186
|
end
|
|
187
187
|
|
|
188
|
+
def test_concurrency
|
|
189
|
+
10.times do
|
|
190
|
+
threads = []
|
|
191
|
+
10.times do |i|
|
|
192
|
+
threads << Thread.new(i) do |id|
|
|
193
|
+
out = Engine.new("div { url: inspect_options(); }", {test_key1: 'test_value', test_key2: id}).render
|
|
194
|
+
assert_match /test_key1/, out
|
|
195
|
+
assert_match /test_key2/, out
|
|
196
|
+
assert_match /test_value/, out
|
|
197
|
+
assert_match /#{id}/, out
|
|
198
|
+
end
|
|
199
|
+
end
|
|
200
|
+
threads.each(&:join)
|
|
201
|
+
end
|
|
202
|
+
end
|
|
203
|
+
|
|
204
|
+
def test_pass_custom_functions_as_a_parameter
|
|
205
|
+
out = Engine.new("div { url: test-function(); }", {functions: ExternalFunctions}).render
|
|
206
|
+
assert_match /custom_function/, out
|
|
207
|
+
end
|
|
208
|
+
|
|
209
|
+
def test_pass_incompatible_type_to_custom_functions
|
|
210
|
+
assert_raises(TypeError) do
|
|
211
|
+
Engine.new("div { url: test-function(); }", {functions: Class.new}).render
|
|
212
|
+
end
|
|
213
|
+
end
|
|
214
|
+
|
|
188
215
|
private
|
|
189
216
|
|
|
190
217
|
def assert_sass(sass, expected_css)
|
|
@@ -279,6 +306,10 @@ module SassC
|
|
|
279
306
|
return argument
|
|
280
307
|
end
|
|
281
308
|
|
|
309
|
+
def inspect_options
|
|
310
|
+
SassC::Script::Value::String.new(self.options.inspect, :string)
|
|
311
|
+
end
|
|
312
|
+
|
|
282
313
|
def returns_sass_value
|
|
283
314
|
return SassC::Script::Value::Color.new(red: 0, green: 0, blue: 0)
|
|
284
315
|
end
|
|
@@ -299,5 +330,11 @@ module SassC
|
|
|
299
330
|
|
|
300
331
|
end
|
|
301
332
|
|
|
333
|
+
module ExternalFunctions
|
|
334
|
+
def test_function
|
|
335
|
+
SassC::Script::Value::String.new("custom_function", :string)
|
|
336
|
+
end
|
|
337
|
+
end
|
|
338
|
+
|
|
302
339
|
end
|
|
303
340
|
end
|
data/test/native_test.rb
CHANGED
|
@@ -11,7 +11,7 @@ module SassC
|
|
|
11
11
|
|
|
12
12
|
class General < MiniTest::Test
|
|
13
13
|
def test_it_reports_the_libsass_version
|
|
14
|
-
assert_equal "3.
|
|
14
|
+
assert_equal "3.6.4", Native.version
|
|
15
15
|
end
|
|
16
16
|
end
|
|
17
17
|
|
|
@@ -185,9 +185,9 @@ module SassC
|
|
|
185
185
|
funct = FFI::Function.new(:pointer, [:pointer, :pointer, :pointer]) do |url, prev, cookie|
|
|
186
186
|
list = Native.make_import_list(2)
|
|
187
187
|
|
|
188
|
-
str = "$var: 5px
|
|
189
|
-
data =
|
|
190
|
-
data.
|
|
188
|
+
str = "$var: 5px;"
|
|
189
|
+
data = FFI::MemoryPointer.from_string(str)
|
|
190
|
+
data.autorelease = false
|
|
191
191
|
|
|
192
192
|
entry0 = Native.make_import_entry("fake_includ.scss", data, nil)
|
|
193
193
|
entry1 = Native.make_import_entry("not_included.scss", nil, nil)
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: sassc
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 2.
|
|
4
|
+
version: 2.4.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ryan Boland
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date:
|
|
11
|
+
date: 2020-06-02 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: minitest
|
|
@@ -87,7 +87,35 @@ dependencies:
|
|
|
87
87
|
- - ">="
|
|
88
88
|
- !ruby/object:Gem::Version
|
|
89
89
|
version: '0'
|
|
90
|
-
type: :
|
|
90
|
+
type: :development
|
|
91
|
+
prerelease: false
|
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
93
|
+
requirements:
|
|
94
|
+
- - ">="
|
|
95
|
+
- !ruby/object:Gem::Version
|
|
96
|
+
version: '0'
|
|
97
|
+
- !ruby/object:Gem::Dependency
|
|
98
|
+
name: rake-compiler
|
|
99
|
+
requirement: !ruby/object:Gem::Requirement
|
|
100
|
+
requirements:
|
|
101
|
+
- - ">="
|
|
102
|
+
- !ruby/object:Gem::Version
|
|
103
|
+
version: '0'
|
|
104
|
+
type: :development
|
|
105
|
+
prerelease: false
|
|
106
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
107
|
+
requirements:
|
|
108
|
+
- - ">="
|
|
109
|
+
- !ruby/object:Gem::Version
|
|
110
|
+
version: '0'
|
|
111
|
+
- !ruby/object:Gem::Dependency
|
|
112
|
+
name: rake-compiler-dock
|
|
113
|
+
requirement: !ruby/object:Gem::Requirement
|
|
114
|
+
requirements:
|
|
115
|
+
- - ">="
|
|
116
|
+
- !ruby/object:Gem::Version
|
|
117
|
+
version: '0'
|
|
118
|
+
type: :development
|
|
91
119
|
prerelease: false
|
|
92
120
|
version_requirements: !ruby/object:Gem::Requirement
|
|
93
121
|
requirements:
|
|
@@ -100,20 +128,20 @@ dependencies:
|
|
|
100
128
|
requirements:
|
|
101
129
|
- - "~>"
|
|
102
130
|
- !ruby/object:Gem::Version
|
|
103
|
-
version: 1.9
|
|
131
|
+
version: '1.9'
|
|
104
132
|
type: :runtime
|
|
105
133
|
prerelease: false
|
|
106
134
|
version_requirements: !ruby/object:Gem::Requirement
|
|
107
135
|
requirements:
|
|
108
136
|
- - "~>"
|
|
109
137
|
- !ruby/object:Gem::Version
|
|
110
|
-
version: 1.9
|
|
138
|
+
version: '1.9'
|
|
111
139
|
description: Use libsass with Ruby!
|
|
112
140
|
email:
|
|
113
141
|
- ryan@tanookilabs.com
|
|
114
142
|
executables: []
|
|
115
143
|
extensions:
|
|
116
|
-
- ext/
|
|
144
|
+
- ext/extconf.rb
|
|
117
145
|
extra_rdoc_files: []
|
|
118
146
|
files:
|
|
119
147
|
- ".gitignore"
|
|
@@ -125,88 +153,36 @@ files:
|
|
|
125
153
|
- LICENSE.txt
|
|
126
154
|
- README.md
|
|
127
155
|
- Rakefile
|
|
128
|
-
- ext/
|
|
129
|
-
- ext/
|
|
130
|
-
- ext/libsass
|
|
131
|
-
- ext/libsass/.github/CONTRIBUTING.md
|
|
132
|
-
- ext/libsass/.github/ISSUE_TEMPLATE.md
|
|
133
|
-
- ext/libsass/.gitignore
|
|
134
|
-
- ext/libsass/.travis.yml
|
|
135
|
-
- ext/libsass/COPYING
|
|
136
|
-
- ext/libsass/GNUmakefile.am
|
|
137
|
-
- ext/libsass/INSTALL
|
|
138
|
-
- ext/libsass/LICENSE
|
|
139
|
-
- ext/libsass/Makefile
|
|
140
|
-
- ext/libsass/Makefile.conf
|
|
141
|
-
- ext/libsass/Readme.md
|
|
142
|
-
- ext/libsass/SECURITY.md
|
|
143
|
-
- ext/libsass/appveyor.yml
|
|
144
|
-
- ext/libsass/configure.ac
|
|
145
|
-
- ext/libsass/contrib/libsass.spec
|
|
156
|
+
- ext/depend
|
|
157
|
+
- ext/extconf.rb
|
|
158
|
+
- ext/libsass/VERSION
|
|
146
159
|
- ext/libsass/contrib/plugin.cpp
|
|
147
|
-
- ext/libsass/docs/README.md
|
|
148
|
-
- ext/libsass/docs/api-context-example.md
|
|
149
|
-
- ext/libsass/docs/api-context-internal.md
|
|
150
|
-
- ext/libsass/docs/api-context.md
|
|
151
|
-
- ext/libsass/docs/api-doc.md
|
|
152
|
-
- ext/libsass/docs/api-function-example.md
|
|
153
|
-
- ext/libsass/docs/api-function-internal.md
|
|
154
|
-
- ext/libsass/docs/api-function.md
|
|
155
|
-
- ext/libsass/docs/api-importer-example.md
|
|
156
|
-
- ext/libsass/docs/api-importer-internal.md
|
|
157
|
-
- ext/libsass/docs/api-importer.md
|
|
158
|
-
- ext/libsass/docs/api-value-example.md
|
|
159
|
-
- ext/libsass/docs/api-value-internal.md
|
|
160
|
-
- ext/libsass/docs/api-value.md
|
|
161
|
-
- ext/libsass/docs/build-on-darwin.md
|
|
162
|
-
- ext/libsass/docs/build-on-gentoo.md
|
|
163
|
-
- ext/libsass/docs/build-on-windows.md
|
|
164
|
-
- ext/libsass/docs/build-shared-library.md
|
|
165
|
-
- ext/libsass/docs/build-with-autotools.md
|
|
166
|
-
- ext/libsass/docs/build-with-makefiles.md
|
|
167
|
-
- ext/libsass/docs/build-with-mingw.md
|
|
168
|
-
- ext/libsass/docs/build-with-visual-studio.md
|
|
169
|
-
- ext/libsass/docs/build.md
|
|
170
|
-
- ext/libsass/docs/compatibility-plan.md
|
|
171
|
-
- ext/libsass/docs/contributing.md
|
|
172
|
-
- ext/libsass/docs/custom-functions-internal.md
|
|
173
|
-
- ext/libsass/docs/dev-ast-memory.md
|
|
174
|
-
- ext/libsass/docs/implementations.md
|
|
175
|
-
- ext/libsass/docs/plugins.md
|
|
176
|
-
- ext/libsass/docs/setup-environment.md
|
|
177
|
-
- ext/libsass/docs/source-map-internals.md
|
|
178
|
-
- ext/libsass/docs/trace.md
|
|
179
|
-
- ext/libsass/docs/triage.md
|
|
180
|
-
- ext/libsass/docs/unicode.md
|
|
181
|
-
- ext/libsass/extconf.rb
|
|
182
160
|
- ext/libsass/include/sass.h
|
|
183
161
|
- ext/libsass/include/sass/base.h
|
|
184
162
|
- ext/libsass/include/sass/context.h
|
|
185
163
|
- ext/libsass/include/sass/functions.h
|
|
186
164
|
- ext/libsass/include/sass/values.h
|
|
187
165
|
- ext/libsass/include/sass/version.h
|
|
188
|
-
- ext/libsass/include/sass/version.h.in
|
|
189
166
|
- ext/libsass/include/sass2scss.h
|
|
190
|
-
- ext/libsass/
|
|
191
|
-
- ext/libsass/m4/m4-ax_cxx_compile_stdcxx_11.m4
|
|
192
|
-
- ext/libsass/res/resource.rc
|
|
193
|
-
- ext/libsass/script/bootstrap
|
|
194
|
-
- ext/libsass/script/branding
|
|
195
|
-
- ext/libsass/script/ci-build-libsass
|
|
196
|
-
- ext/libsass/script/ci-build-plugin
|
|
197
|
-
- ext/libsass/script/ci-install-compiler
|
|
198
|
-
- ext/libsass/script/ci-install-deps
|
|
199
|
-
- ext/libsass/script/ci-report-coverage
|
|
200
|
-
- ext/libsass/script/spec
|
|
201
|
-
- ext/libsass/script/tap-driver
|
|
202
|
-
- ext/libsass/script/tap-runner
|
|
203
|
-
- ext/libsass/script/test-leaks.pl
|
|
204
|
-
- ext/libsass/src/GNUmakefile.am
|
|
167
|
+
- ext/libsass/src/MurmurHash2.hpp
|
|
205
168
|
- ext/libsass/src/ast.cpp
|
|
206
169
|
- ext/libsass/src/ast.hpp
|
|
170
|
+
- ext/libsass/src/ast2c.cpp
|
|
171
|
+
- ext/libsass/src/ast2c.hpp
|
|
207
172
|
- ext/libsass/src/ast_def_macros.hpp
|
|
208
173
|
- ext/libsass/src/ast_fwd_decl.cpp
|
|
209
174
|
- ext/libsass/src/ast_fwd_decl.hpp
|
|
175
|
+
- ext/libsass/src/ast_helpers.hpp
|
|
176
|
+
- ext/libsass/src/ast_sel_cmp.cpp
|
|
177
|
+
- ext/libsass/src/ast_sel_super.cpp
|
|
178
|
+
- ext/libsass/src/ast_sel_unify.cpp
|
|
179
|
+
- ext/libsass/src/ast_sel_weave.cpp
|
|
180
|
+
- ext/libsass/src/ast_selectors.cpp
|
|
181
|
+
- ext/libsass/src/ast_selectors.hpp
|
|
182
|
+
- ext/libsass/src/ast_supports.cpp
|
|
183
|
+
- ext/libsass/src/ast_supports.hpp
|
|
184
|
+
- ext/libsass/src/ast_values.cpp
|
|
185
|
+
- ext/libsass/src/ast_values.hpp
|
|
210
186
|
- ext/libsass/src/b64/cencode.h
|
|
211
187
|
- ext/libsass/src/b64/encode.h
|
|
212
188
|
- ext/libsass/src/backtrace.cpp
|
|
@@ -215,6 +191,8 @@ files:
|
|
|
215
191
|
- ext/libsass/src/base64vlq.hpp
|
|
216
192
|
- ext/libsass/src/bind.cpp
|
|
217
193
|
- ext/libsass/src/bind.hpp
|
|
194
|
+
- ext/libsass/src/c2ast.cpp
|
|
195
|
+
- ext/libsass/src/c2ast.hpp
|
|
218
196
|
- ext/libsass/src/c99func.c
|
|
219
197
|
- ext/libsass/src/cencode.c
|
|
220
198
|
- ext/libsass/src/check_nesting.cpp
|
|
@@ -227,6 +205,7 @@ files:
|
|
|
227
205
|
- ext/libsass/src/context.hpp
|
|
228
206
|
- ext/libsass/src/cssize.cpp
|
|
229
207
|
- ext/libsass/src/cssize.hpp
|
|
208
|
+
- ext/libsass/src/dart_helpers.hpp
|
|
230
209
|
- ext/libsass/src/debug.hpp
|
|
231
210
|
- ext/libsass/src/debugger.hpp
|
|
232
211
|
- ext/libsass/src/emitter.cpp
|
|
@@ -237,14 +216,31 @@ files:
|
|
|
237
216
|
- ext/libsass/src/error_handling.hpp
|
|
238
217
|
- ext/libsass/src/eval.cpp
|
|
239
218
|
- ext/libsass/src/eval.hpp
|
|
219
|
+
- ext/libsass/src/eval_selectors.cpp
|
|
240
220
|
- ext/libsass/src/expand.cpp
|
|
241
221
|
- ext/libsass/src/expand.hpp
|
|
242
|
-
- ext/libsass/src/
|
|
243
|
-
- ext/libsass/src/
|
|
222
|
+
- ext/libsass/src/extender.cpp
|
|
223
|
+
- ext/libsass/src/extender.hpp
|
|
224
|
+
- ext/libsass/src/extension.cpp
|
|
225
|
+
- ext/libsass/src/extension.hpp
|
|
244
226
|
- ext/libsass/src/file.cpp
|
|
245
227
|
- ext/libsass/src/file.hpp
|
|
246
|
-
- ext/libsass/src/
|
|
247
|
-
- ext/libsass/src/
|
|
228
|
+
- ext/libsass/src/fn_colors.cpp
|
|
229
|
+
- ext/libsass/src/fn_colors.hpp
|
|
230
|
+
- ext/libsass/src/fn_lists.cpp
|
|
231
|
+
- ext/libsass/src/fn_lists.hpp
|
|
232
|
+
- ext/libsass/src/fn_maps.cpp
|
|
233
|
+
- ext/libsass/src/fn_maps.hpp
|
|
234
|
+
- ext/libsass/src/fn_miscs.cpp
|
|
235
|
+
- ext/libsass/src/fn_miscs.hpp
|
|
236
|
+
- ext/libsass/src/fn_numbers.cpp
|
|
237
|
+
- ext/libsass/src/fn_numbers.hpp
|
|
238
|
+
- ext/libsass/src/fn_selectors.cpp
|
|
239
|
+
- ext/libsass/src/fn_selectors.hpp
|
|
240
|
+
- ext/libsass/src/fn_strings.cpp
|
|
241
|
+
- ext/libsass/src/fn_strings.hpp
|
|
242
|
+
- ext/libsass/src/fn_utils.cpp
|
|
243
|
+
- ext/libsass/src/fn_utils.hpp
|
|
248
244
|
- ext/libsass/src/inspect.cpp
|
|
249
245
|
- ext/libsass/src/inspect.hpp
|
|
250
246
|
- ext/libsass/src/json.cpp
|
|
@@ -255,18 +251,23 @@ files:
|
|
|
255
251
|
- ext/libsass/src/listize.cpp
|
|
256
252
|
- ext/libsass/src/listize.hpp
|
|
257
253
|
- ext/libsass/src/mapping.hpp
|
|
258
|
-
- ext/libsass/src/memory
|
|
259
|
-
- ext/libsass/src/memory/
|
|
260
|
-
- ext/libsass/src/
|
|
261
|
-
- ext/libsass/src/
|
|
254
|
+
- ext/libsass/src/memory.hpp
|
|
255
|
+
- ext/libsass/src/memory/allocator.cpp
|
|
256
|
+
- ext/libsass/src/memory/allocator.hpp
|
|
257
|
+
- ext/libsass/src/memory/config.hpp
|
|
258
|
+
- ext/libsass/src/memory/memory_pool.hpp
|
|
259
|
+
- ext/libsass/src/memory/shared_ptr.cpp
|
|
260
|
+
- ext/libsass/src/memory/shared_ptr.hpp
|
|
262
261
|
- ext/libsass/src/operation.hpp
|
|
263
262
|
- ext/libsass/src/operators.cpp
|
|
264
263
|
- ext/libsass/src/operators.hpp
|
|
264
|
+
- ext/libsass/src/ordered_map.hpp
|
|
265
265
|
- ext/libsass/src/output.cpp
|
|
266
266
|
- ext/libsass/src/output.hpp
|
|
267
267
|
- ext/libsass/src/parser.cpp
|
|
268
268
|
- ext/libsass/src/parser.hpp
|
|
269
|
-
- ext/libsass/src/
|
|
269
|
+
- ext/libsass/src/parser_selectors.cpp
|
|
270
|
+
- ext/libsass/src/permutate.hpp
|
|
270
271
|
- ext/libsass/src/plugins.cpp
|
|
271
272
|
- ext/libsass/src/plugins.hpp
|
|
272
273
|
- ext/libsass/src/position.cpp
|
|
@@ -282,17 +283,16 @@ files:
|
|
|
282
283
|
- ext/libsass/src/sass_context.hpp
|
|
283
284
|
- ext/libsass/src/sass_functions.cpp
|
|
284
285
|
- ext/libsass/src/sass_functions.hpp
|
|
285
|
-
- ext/libsass/src/sass_util.cpp
|
|
286
|
-
- ext/libsass/src/sass_util.hpp
|
|
287
286
|
- ext/libsass/src/sass_values.cpp
|
|
288
287
|
- ext/libsass/src/sass_values.hpp
|
|
288
|
+
- ext/libsass/src/settings.hpp
|
|
289
|
+
- ext/libsass/src/source.cpp
|
|
290
|
+
- ext/libsass/src/source.hpp
|
|
291
|
+
- ext/libsass/src/source_data.hpp
|
|
289
292
|
- ext/libsass/src/source_map.cpp
|
|
290
293
|
- ext/libsass/src/source_map.hpp
|
|
291
|
-
- ext/libsass/src/
|
|
292
|
-
- ext/libsass/src/
|
|
293
|
-
- ext/libsass/src/support/libsass.pc.in
|
|
294
|
-
- ext/libsass/src/to_c.cpp
|
|
295
|
-
- ext/libsass/src/to_c.hpp
|
|
294
|
+
- ext/libsass/src/stylesheet.cpp
|
|
295
|
+
- ext/libsass/src/stylesheet.hpp
|
|
296
296
|
- ext/libsass/src/to_value.cpp
|
|
297
297
|
- ext/libsass/src/to_value.hpp
|
|
298
298
|
- ext/libsass/src/units.cpp
|
|
@@ -305,21 +305,10 @@ files:
|
|
|
305
305
|
- ext/libsass/src/utf8_string.hpp
|
|
306
306
|
- ext/libsass/src/util.cpp
|
|
307
307
|
- ext/libsass/src/util.hpp
|
|
308
|
+
- ext/libsass/src/util_string.cpp
|
|
309
|
+
- ext/libsass/src/util_string.hpp
|
|
308
310
|
- ext/libsass/src/values.cpp
|
|
309
311
|
- ext/libsass/src/values.hpp
|
|
310
|
-
- ext/libsass/test/test_node.cpp
|
|
311
|
-
- ext/libsass/test/test_paths.cpp
|
|
312
|
-
- ext/libsass/test/test_selector_difference.cpp
|
|
313
|
-
- ext/libsass/test/test_specificity.cpp
|
|
314
|
-
- ext/libsass/test/test_subset_map.cpp
|
|
315
|
-
- ext/libsass/test/test_superselector.cpp
|
|
316
|
-
- ext/libsass/test/test_unification.cpp
|
|
317
|
-
- ext/libsass/version.sh
|
|
318
|
-
- ext/libsass/win/libsass.sln
|
|
319
|
-
- ext/libsass/win/libsass.sln.DotSettings
|
|
320
|
-
- ext/libsass/win/libsass.targets
|
|
321
|
-
- ext/libsass/win/libsass.vcxproj
|
|
322
|
-
- ext/libsass/win/libsass.vcxproj.filters
|
|
323
312
|
- lib/sassc.rb
|
|
324
313
|
- lib/sassc/dependency.rb
|
|
325
314
|
- lib/sassc/engine.rb
|
|
@@ -328,7 +317,6 @@ files:
|
|
|
328
317
|
- lib/sassc/import_handler.rb
|
|
329
318
|
- lib/sassc/importer.rb
|
|
330
319
|
- lib/sassc/native.rb
|
|
331
|
-
- lib/sassc/native/lib_c.rb
|
|
332
320
|
- lib/sassc/native/native_context_api.rb
|
|
333
321
|
- lib/sassc/native/native_functions_api.rb
|
|
334
322
|
- lib/sassc/native/sass2scss_api.rb
|
|
@@ -357,7 +345,6 @@ files:
|
|
|
357
345
|
- lib/sassc/util.rb
|
|
358
346
|
- lib/sassc/util/normalized_map.rb
|
|
359
347
|
- lib/sassc/version.rb
|
|
360
|
-
- lib/tasks/libsass.rb
|
|
361
348
|
- sassc.gemspec
|
|
362
349
|
- test/custom_importer_test.rb
|
|
363
350
|
- test/engine_test.rb
|
|
@@ -380,15 +367,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
380
367
|
requirements:
|
|
381
368
|
- - ">="
|
|
382
369
|
- !ruby/object:Gem::Version
|
|
383
|
-
version: 2.
|
|
370
|
+
version: 2.0.0
|
|
384
371
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
385
372
|
requirements:
|
|
386
373
|
- - ">="
|
|
387
374
|
- !ruby/object:Gem::Version
|
|
388
375
|
version: '0'
|
|
389
376
|
requirements: []
|
|
390
|
-
|
|
391
|
-
rubygems_version: 2.7.6
|
|
377
|
+
rubygems_version: 3.1.2
|
|
392
378
|
signing_key:
|
|
393
379
|
specification_version: 4
|
|
394
380
|
summary: Use libsass with Ruby!
|