W3C home > Mailing lists > Public > www-style@w3.org > April 2010

Re: Single-line comments

From: Brad Kemper <brad.kemper@gmail.com>
Date: Sat, 3 Apr 2010 13:41:06 -0700
Cc: "Glen" <glen.84@gmail.com>, <www-style@w3.org>
Message-Id: <F952795A-FB43-442F-BC5A-269689601006@gmail.com>
To: François REMY <fremycompany_pub@yahoo.fr>

On Apr 3, 2010, at 12:29 PM, François REMY wrote:

> The problem would then become very visible :
>  
> a {
>     // non-ok : value;
>     ok: value;
> }
>  
> <== UA Optimisation (discarding space chars after the first) ==>
> a { // non-ok : value; ok: value; }
> 

I was thinking more of editing software and less of, say, browsers. But maybe it would happen in some browsers too.

Also, similar situation is this:

DIV { property: value; }  // A div rule 
A { i-want-to-be-parsed: also } 
 
/* white space collapsed: */
DIV { property: value; }  // A div rule A { i-want-to-be-parsed: also }

> I don't expect developers to be able to use single-line comments immediately -- they will obviously only be usable when all browsers in use support them. 

This is different from not supporting a particular property. If using a comment in a style-sheet causes other rules or declarations to be unexpectedly (and somewhat unpredictably) dropped when parsed in earlier software, that is a pretty bad thing.


Received on Saturday, 3 April 2010 20:41:42 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:20:26 GMT