Converted to single-line parser specifications where appropriate.
authorthurston <thurston@052ea7fc-9027-0410-9066-f65837a77df0>
Thu, 25 Jan 2007 07:00:05 +0000 (07:00 +0000)
committerthurston <thurston@052ea7fc-9027-0410-9066-f65837a77df0>
Thu, 25 Jan 2007 07:00:05 +0000 (07:00 +0000)
git-svn-id: http://svn.complang.org/ragel/trunk@13 052ea7fc-9027-0410-9066-f65837a77df0

ragel/rlparse.kh
ragel/rlparse.kl
ragel/rlscan.rl
rlcodegen/xmlparse.kh
rlcodegen/xmlparse.kl

index f1649d6..287b560 100644 (file)
@@ -95,7 +95,7 @@ struct Parser
        token TK_Semi;
        }%%
 
-       %%{ write instance_data; }%%
+       %% write instance_data;
 
        void init();
        int parseLangEl( int type, const Token *token );
@@ -122,6 +122,6 @@ struct Parser
        NameRefList nameRefList;
 };
 
-%%{ write token_defs; }%%
+%% write token_defs;
 
 #endif
index ab43218..dd29446 100644 (file)
@@ -1350,12 +1350,12 @@ state_ref_names:
 
 void Parser::init()
 {
-       %%{ write init; }%%
+       %% write init;
 }
 
 int Parser::parseLangEl( int type, const Token *token )
 {
-       %%{ write exec; }%%
+       %% write exec;
        return errCount == 0 ? 0 : -1;
 }
 
index 73dc0f5..e8154a1 100644 (file)
@@ -766,9 +766,6 @@ void Scanner::endSection( )
                "|*" => { token( TK_BarStar ); };
 
                '}%%' => { 
-                       /* In order to generate anything we must be in the top level file
-                        * and the current spec must be active and there must not have been
-                        * any parse errors. */
                        updateCol();
                        endSection();
                        fgoto main;
@@ -780,9 +777,6 @@ void Scanner::endSection( )
                NL => {
                        updateCol();
                        if ( singleLineSpec ) {
-                               /* In order to generate anything we must be in the top level file
-                                * and the current spec must be active and there must not have been
-                                * any parse errors. */
                                endSection();
                                fgoto main;
                        }
index 3dadb12..2c4ace0 100644 (file)
@@ -72,7 +72,7 @@ struct Parser
                        TAG_option;
        }%%
 
-       %%{ write instance_data; }%%
+       %% write instance_data;
 
        void init();
        int parseLangEl( int type, const Token *token );
@@ -107,6 +107,6 @@ struct Parser
        CodeGenMap codeGenMap;
 };
 
-%%{ write token_defs; }%%
+%% write token_defs;
 
 #endif /* _XMLPARSE_H */
index c395061..c110588 100644 (file)
@@ -789,12 +789,12 @@ tag_cond_space: TAG_cond_space '/' TAG_cond_space
 
 void Parser::init()
 {
-       %%{ write init; }%%
+       %% write init;
 }
 
 int Parser::parseLangEl( int type, const Token *token )
 {
-       %%{ write exec; }%%
+       %% write exec;
        return errCount == 0 ? 0 : -1;
 }