473,406 Members | 2,281 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,406 software developers and data experts.

Css Lex (CSS2.1 Appendix G)

http://www.w3.org/TR/CSS21/grammar.html

From appendix G we find these two lines:
\/\*[^*]*\*+([^/*][^*]*\*+)*\/ /* ignore comments */
{s}+\/\*[^*]*\*+([^/*][^*]*\*+)*\/ {unput(' '); /*replace by space*/}

What is the purpose of the second regular expression?

Brett
Jul 21 '05 #1
1 1941
in comp.infosystems.www.authoring.stylesheets, Brett Foster wrote:
http://www.w3.org/TR/CSS21/grammar.html

From appendix G we find these two lines:
\/\*[^*]*\*+([^/*][^*]*\*+)*\/ /* ignore comments */
{s}+\/\*[^*]*\*+([^/*][^*]*\*+)*\/ {unput(' '); /*replace by space*/} What is the purpose of the second regular expression?


First one finds comments in code when there is no spaces:
foo {/*comment*/color:red}
-> foo {color:red}
Second one collapses spaces as well:
foo /* comment */ {color:red}
-> foo {color:red}

{s} seems to be notation for whitespace in notation.

--
Lauri Raittila <http://www.iki.fi/lr> <http://www.iki.fi/zwak/fonts>
Utrecht, NL.
Support me, buy Opera:
https://secure.bmtmicro.com/opera/bu...tml?AID=882173
Jul 21 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

4
by: Neil Zanella | last post by:
Hello, I would like to know what the major enhancements of CSS2 over CSS1 are and whether CSS2 support is any better these days than it was a few years ago. In particular, do most browsers fully...
12
by: Michael Winter | last post by:
Is it possible to test for CSS level 2 support, preferably using just CSS2? For example, the following could alert the user that their browser doesn't support CSS1 or 2. Is there an equivalent for...
6
by: Patrick | last post by:
Hi I am a newbie struggling a little with css.It is hard to get it right in all browsers, so i decided to read the CSS2 specification on the w3 site. What is the following from the CSS2...
20
by: Karl Smith | last post by:
I heard a rumour that Opera succeeded where none have before, and implemented the tables described in HTML4 and CSS2. So I thought I'd try it out with the well known Periodic Table. ...
14
by: Michael Bulatovich | last post by:
Has anyone got a good link to a concise discussion of where things now stand regarding these two? e.g. What browsers are compliant with one or the other? What the adoption rate is of these...
7
by: David Garamond | last post by:
May I suggest that Appendix E also includes release date for each release, and also lists tentative/planned features for future releases (say: in 7.5, win32 port and 2-phase commit; in 8.0, ...;...
2
by: Xah Lee | last post by:
what's new in CSS2? http://xahlee.org/js/css2.html Xah xah@xahlee.org ∑ http://xahlee.org/
2
by: Dan | last post by:
Hi, Appendix F of the CSS 2.1 Spec (http://www.w3.org/TR/CSS21/propidx.html) displays some values with extra characters (e.g. "" in first row, second column for azimuth; "? ]" in second column,...
2
by: David E. Ross | last post by:
A new working draft of the CSS2.1 specification was published on-line on 11 April. Does anyone know what changed since the previous (13 June 2005) working draft? -- David E. Ross...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.