1
0
Fork 0
mirror of https://github.com/haml/haml.git synced 2022-11-09 12:33:31 -05:00

[Sass] I guess we don't need a special check for semicolons in properties anymore.

This commit is contained in:
Nathan Weizenbaum 2010-03-27 14:57:47 -07:00
parent 25346b7693
commit a55f643926
2 changed files with 2 additions and 4 deletions

View file

@ -159,8 +159,6 @@ module Sass::Tree
raise Sass::SyntaxError.new("Illegal property syntax: can't use new syntax when :property_syntax => :old is set.") raise Sass::SyntaxError.new("Illegal property syntax: can't use new syntax when :property_syntax => :old is set.")
elsif @options[:property_syntax] == :new && @prop_syntax == :old elsif @options[:property_syntax] == :new && @prop_syntax == :old
raise Sass::SyntaxError.new("Illegal property syntax: can't use old syntax when :property_syntax => :new is set.") raise Sass::SyntaxError.new("Illegal property syntax: can't use old syntax when :property_syntax => :new is set.")
elsif resolved_value[-1] == ?;
raise Sass::SyntaxError.new("Invalid property: #{declaration.dump} (no \";\" required at end-of-line).")
elsif resolved_value.empty? elsif resolved_value.empty?
raise Sass::SyntaxError.new("Invalid property: #{declaration.dump} (no value)." + raise Sass::SyntaxError.new("Invalid property: #{declaration.dump} (no value)." +
pseudo_class_selector_message) pseudo_class_selector_message)

View file

@ -32,8 +32,8 @@ MSG
"a\n :b: c" => 'Invalid property: ":b: c".', "a\n :b: c" => 'Invalid property: ":b: c".',
"a\n :b:c d" => 'Invalid property: ":b:c d".', "a\n :b:c d" => 'Invalid property: ":b:c d".',
"a\n :b=c d" => 'Invalid property: ":b=c d".', "a\n :b=c d" => 'Invalid property: ":b=c d".',
"a\n :b c;" => 'Invalid property: ":b c;" (no ";" required at end-of-line).', "a\n :b c;" => 'Invalid CSS after "c": expected expression (e.g. 1px, bold), was ";"',
"a\n b: c;" => 'Invalid property: "b: c;" (no ";" required at end-of-line).', "a\n b: c;" => 'Invalid CSS after "c": expected expression (e.g. 1px, bold), was ";"',
"a\n b : c" => 'Invalid property: "b : c".', "a\n b : c" => 'Invalid property: "b : c".',
"a\n b=c: d" => 'Invalid property: "b=c: d".', "a\n b=c: d" => 'Invalid property: "b=c: d".',
"a: b" => 'Properties aren\'t allowed at the root of a document.', "a: b" => 'Properties aren\'t allowed at the root of a document.',