parsing - Where can I find Webkit's CSS grammar files? -


unlike html, css context free grammar. syntax grammar described in bnf or ebnf notation.

according tali garsiel's articke how browsers work, webkit uses flex , bison parser generators create parsers automatically css grammar files.

as webkit open source project, expect these grammar files can found somewhere in its source code. haven't been able find it, though. can me out here?


note 1 :

i'm not asking how browsers parse/render css / how browsers read , interpret css!!

i know already. in fact, it's explained pretty in aforementioned article how browsers work. no, it's not duplicate of question.

what i'm looking for, specific css grammar files webkit uses parse/render css, haven't been able find anywhere.


note 2 :

i'm not asking recommend or find book, tool, software library, tutorial or other off-site... @ all.

i'm asking find files webkit uses (or used) parsing css, because i've been unable find them myself.


note 3 :

i'm asking because i'm looking convenient way parse css. want base approach on way browser parses css (more = analysing how parsed webkit browsers).

so yes, question programming question , totally on topic here @ stack overflow.

the bison file (or @ least, version of it) in css directory cssgrammar.y.in. file preprocessed , run through bison using a perl script.

apparently flex scanner rewritten in 2011/12; see webkit bug. handbuilt scanner part of cssparser.cpp.

by looking in git history, find older versions. example, in safari-4-branch, found following bison , flex files.


Comments

Popular posts from this blog

qt - Using float or double for own QML classes -

Create Outlook appointment via C# .Net -

ios - Swift Array Resetting Itself -