dart-sass/lib/src/ast/sass/argument_declaration.dart
Natalie Weizenbaum 50912350af Add support for functions.
Argument list objects are still not implemented.
2016-08-30 15:51:22 -07:00

24 lines
659 B
Dart

// Copyright 2016 Google Inc. Use of this source code is governed by an
// MIT-style license that can be found in the LICENSE file or at
// https://opensource.org/licenses/MIT.
import 'package:source_span/source_span.dart';
import 'argument.dart';
import 'node.dart';
class ArgumentDeclaration implements SassNode {
final List<Argument> arguments;
final String restArgument;
final FileSpan span;
ArgumentDeclaration(Iterable<Argument> arguments,
{this.restArgument, this.span})
: arguments = new List.unmodifiable(arguments);
String toString() => arguments.join(', ') +
(restArgument == null ? '' : ", $restArgument...");
}