mirror of
https://github.com/danog/dart-sass.git
synced 2025-01-22 22:02:00 +01:00
Fix analysis errors (#1470)
This commit is contained in:
parent
78aacbcda2
commit
f06937e2df
@ -1,7 +1,6 @@
|
||||
name: sass_analysis
|
||||
version: 0.0.0
|
||||
description: Shared analysis options for Sass team packages.
|
||||
author: Sass Team
|
||||
homepage: https://github.com/sass/dart-sass/tree/master/analysis
|
||||
|
||||
publish_to: none
|
||||
|
@ -149,7 +149,9 @@ class ArgumentDeclaration implements SassNode {
|
||||
if (names.contains(argument.name)) return false;
|
||||
} else if (names.contains(argument.name)) {
|
||||
namedUsed++;
|
||||
} else if (argument.defaultValue == null) return false;
|
||||
} else if (argument.defaultValue == null) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if (restArgument != null) return true;
|
||||
|
@ -5,7 +5,7 @@
|
||||
import 'package:js/js.dart';
|
||||
|
||||
@JS("Function")
|
||||
class JSFunction implements Function {
|
||||
class JSFunction {
|
||||
external JSFunction(String arg1, [String? arg2, String? arg3]);
|
||||
|
||||
// Note that this just invokes the function with the given arguments, rather
|
||||
|
@ -73,7 +73,7 @@ class SassTypes {
|
||||
}
|
||||
|
||||
@JS()
|
||||
class NodeSassBooleanClass implements Function {
|
||||
class NodeSassBooleanClass {
|
||||
external NodeSassBoolean call();
|
||||
external NodeSassBoolean get TRUE;
|
||||
external NodeSassBoolean get FALSE;
|
||||
@ -124,13 +124,13 @@ class NodeSassMap {
|
||||
}
|
||||
|
||||
@JS()
|
||||
class NodeSassNullClass implements Function {
|
||||
class NodeSassNullClass {
|
||||
external Object call();
|
||||
external NodeSassNull get NULL;
|
||||
}
|
||||
|
||||
@JS()
|
||||
class NodeSassNull implements Function {
|
||||
class NodeSassNull {
|
||||
external Constructor get constructor;
|
||||
}
|
||||
|
||||
|
@ -108,8 +108,9 @@ void main() {
|
||||
test(
|
||||
"lists with undefined separators are reported as having space "
|
||||
"separators", () {
|
||||
expect(parseValue("()").getSeparator(), isFalse);
|
||||
expect(parseValue("join((), 1px)").getSeparator(), isFalse);
|
||||
expect(parseValue<NodeSassList>("()").getSeparator(), isFalse);
|
||||
expect(
|
||||
parseValue<NodeSassList>("join((), 1px)").getSeparator(), isFalse);
|
||||
});
|
||||
|
||||
test("has a useful .constructor.name", () {
|
||||
|
Loading…
x
Reference in New Issue
Block a user