summaryrefslogtreecommitdiff
path: root/l10ntools
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2019-02-27 13:16:34 +0100
committerStephan Bergmann <sbergman@redhat.com>2019-02-27 21:49:09 +0100
commit86e0e147984f8ca48ab0a9c88c37e9e4c4274088 (patch)
treea6db3f3ad0877108a95d1246d3d979869f585b65 /l10ntools
parent69e9262eeb24fa40c3f3f5e7c90c643b252b6b57 (diff)
Untabify .l files (to silence loplugin:indentation warnings)
Change-Id: I8368c8a1d52f6c55a8cea952b2b02345e41c1e5c Reviewed-on: https://gerrit.libreoffice.org/68448 Tested-by: Jenkins Reviewed-by: Stephan Bergmann <sbergman@redhat.com>
Diffstat (limited to 'l10ntools')
-rw-r--r--l10ntools/source/cfglex.l116
-rw-r--r--l10ntools/source/xrmlex.l146
2 files changed, 131 insertions, 131 deletions
diff --git a/l10ntools/source/cfglex.l b/l10ntools/source/cfglex.l
index 8b19ad61466c..f8afa3f82607 100644
--- a/l10ntools/source/cfglex.l
+++ b/l10ntools/source/cfglex.l
@@ -30,9 +30,9 @@
#define YYLMAX 64000
/* to enable debug output define LEXDEBUG */
-#define LEXDEBUG 1
+#define LEXDEBUG 1
#ifdef LEXDEBUG
-#define OUTPUT fprintf
+#define OUTPUT fprintf
#else
#define OUTPUT(Par1,Par2);
#endif
@@ -63,105 +63,105 @@ int bText=0;
%%
-\<[^\>]*"xml:lang="\""x-no-translate"\"[^\<]*\/\> {
- bText = 0;
- workOnTokenSet( CFG_TOKEN_NO_TRANSLATE, yytext );
+\<[^\>]*"xml:lang="\""x-no-translate"\"[^\<]*\/\> {
+ bText = 0;
+ workOnTokenSet( CFG_TOKEN_NO_TRANSLATE, yytext );
}
\<.*\/\> {
- bText = 0;
- workOnTokenSet( ANYTOKEN, yytext );
+ bText = 0;
+ workOnTokenSet( ANYTOKEN, yytext );
}
-\<[^\>]*"xml:lang="\".*\"[^\<]*\> {
- bText = 1;
- workOnTokenSet( CFG_TEXT_START, yytext );
+\<[^\>]*"xml:lang="\".*\"[^\<]*\> {
+ bText = 1;
+ workOnTokenSet( CFG_TEXT_START, yytext );
}
-\<[^\/\!][^\>]*\> {
- bText = 0;
- workOnTokenSet( CFG_TAG, yytext );
+\<[^\/\!][^\>]*\> {
+ bText = 0;
+ workOnTokenSet( CFG_TAG, yytext );
}
-"<!"DOCTYPE[^\>]*\> {
- bText = 0;
- workOnTokenSet( CFG_TAG, yytext );
+"<!"DOCTYPE[^\>]*\> {
+ bText = 0;
+ workOnTokenSet( CFG_TAG, yytext );
}
-\<\!\-\- {
- char c1 = 0, c2 = 0;
- int c3 = yyinput();
- char pChar[2];
- pChar[1] = 0x00;
- pChar[0] = c3;
-
- workOnTokenSet( COMMENT, yytext );
- workOnTokenSet( COMMENT, pChar );
-
- for(;;) {
- if ( c3 == EOF )
- break;
- if ( c1 == '-' && c2 == '-' && c3 == '>' )
- break;
- c1 = c2;
- c2 = c3;
- c3 = yyinput();
-
- pChar[0] = c3;
- workOnTokenSet( COMMENT, pChar );
- }
+\<\!\-\- {
+ char c1 = 0, c2 = 0;
+ int c3 = yyinput();
+ char pChar[2];
+ pChar[1] = 0x00;
+ pChar[0] = c3;
+
+ workOnTokenSet( COMMENT, yytext );
+ workOnTokenSet( COMMENT, pChar );
+
+ for(;;) {
+ if ( c3 == EOF )
+ break;
+ if ( c1 == '-' && c2 == '-' && c3 == '>' )
+ break;
+ c1 = c2;
+ c2 = c3;
+ c3 = yyinput();
+
+ pChar[0] = c3;
+ workOnTokenSet( COMMENT, pChar );
+ }
}
\<\/[^\>]*\> {
- bText = 0;
- workOnTokenSet( CFG_CLOSETAG, yytext );
+ bText = 0;
+ workOnTokenSet( CFG_CLOSETAG, yytext );
}
\<[^\>\!]*\> {
- bText = 0;
- if ( yytext[ 1 ] == '!' && yytext[ 2 ] == '-' && yytext[ 3 ] == '-' )
- workOnTokenSet( COMMENT, yytext );
- else
- workOnTokenSet( CFG_UNKNOWNTAG, yytext );
+ bText = 0;
+ if ( yytext[ 1 ] == '!' && yytext[ 2 ] == '-' && yytext[ 3 ] == '-' )
+ workOnTokenSet( COMMENT, yytext );
+ else
+ workOnTokenSet( CFG_UNKNOWNTAG, yytext );
}
.|\n {
yycolumn = 1;
- if ( bText == 1 )
- workOnTokenSet( CFG_TEXTCHAR, yytext );
- else
- workOnTokenSet( UNKNOWNCHAR, yytext );
+ if ( bText == 1 )
+ workOnTokenSet( CFG_TEXTCHAR, yytext );
+ else
+ workOnTokenSet( UNKNOWNCHAR, yytext );
}
%%
/*****************************************************************************/
-int yywrap(void)
+int yywrap(void)
/*****************************************************************************/
{
- return 1;
+ return 1;
}
/*****************************************************************************/
void YYWarning( const char *s )
/*****************************************************************************/
{
- /* write warning to stderr */
- fprintf( stderr,
- "Warning: \"%s\" in line %d, column %d: \"%s\"\n", s, yylineno, yycolumn, yytext );
+ /* write warning to stderr */
+ fprintf( stderr,
+ "Warning: \"%s\" in line %d, column %d: \"%s\"\n", s, yylineno, yycolumn, yytext );
}
/*****************************************************************************/
void yyerror ( const char *s )
/*****************************************************************************/
{
- /* write error to stderr */
- fprintf( stderr,
- "Error: \"%s\" in line %d, column %d: \"%s\"\n", s, yylineno, yycolumn, yytext );
- exit(EXIT_FAILURE);
+ /* write error to stderr */
+ fprintf( stderr,
+ "Error: \"%s\" in line %d, column %d: \"%s\"\n", s, yylineno, yycolumn, yytext );
+ exit(EXIT_FAILURE);
}
SAL_IMPLEMENT_MAIN_WITH_ARGS(argc, argv) {
diff --git a/l10ntools/source/xrmlex.l b/l10ntools/source/xrmlex.l
index 34f37aa8f74b..c5ab75a14a5a 100644
--- a/l10ntools/source/xrmlex.l
+++ b/l10ntools/source/xrmlex.l
@@ -30,9 +30,9 @@
#define YYLMAX 64000
/* to enable debug output define LEXDEBUG */
-#define LEXDEBUG 1
+#define LEXDEBUG 1
#ifdef LEXDEBUG
-#define OUTPUT fprintf
+#define OUTPUT fprintf
#else
#define OUTPUT(Par1,Par2);
#endif
@@ -63,167 +63,167 @@ int bText=0;
%%
"<p "[^\>]*xml:lang[^\>]*\> {
- WorkOnTokenSet( XRM_TEXT_START , yytext );
+ WorkOnTokenSet( XRM_TEXT_START , yytext );
}
"</p>" {
- WorkOnTokenSet( XRM_TEXT_END, yytext );
+ WorkOnTokenSet( XRM_TEXT_END, yytext );
}
"<h1 "[^\>]*xml:lang[^\>]*\> {
- WorkOnTokenSet( XRM_TEXT_START , yytext );
+ WorkOnTokenSet( XRM_TEXT_START , yytext );
}
"</h1>" {
- WorkOnTokenSet( XRM_TEXT_END, yytext );
+ WorkOnTokenSet( XRM_TEXT_END, yytext );
}
"<h2 "[^\>]*xml:lang[^\>]*\> {
- WorkOnTokenSet( XRM_TEXT_START , yytext );
+ WorkOnTokenSet( XRM_TEXT_START , yytext );
}
"</h2>" {
- WorkOnTokenSet( XRM_TEXT_END, yytext );
+ WorkOnTokenSet( XRM_TEXT_END, yytext );
}
"<h3 "[^\>]*xml:lang[^\>]*\> {
- WorkOnTokenSet( XRM_TEXT_START , yytext );
+ WorkOnTokenSet( XRM_TEXT_START , yytext );
}
"</h3>" {
- WorkOnTokenSet( XRM_TEXT_END, yytext );
+ WorkOnTokenSet( XRM_TEXT_END, yytext );
}
"<h4 "[^\>]*xml:lang[^\>]*\> {
- WorkOnTokenSet( XRM_TEXT_START , yytext );
+ WorkOnTokenSet( XRM_TEXT_START , yytext );
}
"</h4>" {
- WorkOnTokenSet( XRM_TEXT_END, yytext );
+ WorkOnTokenSet( XRM_TEXT_END, yytext );
}
"<h5 "[^\>]*xml:lang[^\>]*\> {
- WorkOnTokenSet( XRM_TEXT_START , yytext );
+ WorkOnTokenSet( XRM_TEXT_START , yytext );
}
"</h5>" {
- WorkOnTokenSet( XRM_TEXT_END, yytext );
+ WorkOnTokenSet( XRM_TEXT_END, yytext );
}
"<display-name>" {
- WorkOnTokenSet( DESC_DISPLAY_NAME_START , yytext );
+ WorkOnTokenSet( DESC_DISPLAY_NAME_START , yytext );
}
"</display-name>" {
- WorkOnTokenSet( DESC_DISPLAY_NAME_END, yytext );
+ WorkOnTokenSet( DESC_DISPLAY_NAME_END, yytext );
}
"<name "[^\>]*lang[^\>]*\> {
- WorkOnTokenSet( DESC_TEXT_START , yytext );
+ WorkOnTokenSet( DESC_TEXT_START , yytext );
}
"</name>" {
- WorkOnTokenSet( DESC_TEXT_END, yytext );
+ WorkOnTokenSet( DESC_TEXT_END, yytext );
}
"<extension-description>" {
- WorkOnTokenSet( DESC_EXTENSION_DESCRIPTION_START , yytext );
+ WorkOnTokenSet( DESC_EXTENSION_DESCRIPTION_START , yytext );
}
"</extension-description>" {
- WorkOnTokenSet( DESC_EXTENSION_DESCRIPTION_END , yytext );
+ WorkOnTokenSet( DESC_EXTENSION_DESCRIPTION_END , yytext );
}
"<src "[^\>]*lang[^\>]*\> {
- WorkOnTokenSet( DESC_EXTENSION_DESCRIPTION_SRC , yytext );
+ WorkOnTokenSet( DESC_EXTENSION_DESCRIPTION_SRC , yytext );
}
-"<!--" {
- char c1 = 0, c2 = 0;
- int c3 = yyinput();
- char pChar[2];
- pChar[1] = 0x00;
- pChar[0] = c3;
+"<!--" {
+ char c1 = 0, c2 = 0;
+ int c3 = yyinput();
+ char pChar[2];
+ pChar[1] = 0x00;
+ pChar[0] = c3;
- WorkOnTokenSet( COMMENT, yytext );
- WorkOnTokenSet( COMMENT, pChar );
+ WorkOnTokenSet( COMMENT, yytext );
+ WorkOnTokenSet( COMMENT, pChar );
- for(;;) {
- if ( c3 == EOF )
- break;
- if ( c1 == '-' && c2 == '-' && c3 == '>' )
- break;
- c1 = c2;
- c2 = c3;
- c3 = yyinput();
- pChar[0] = c3;
- WorkOnTokenSet( COMMENT, pChar );
- }
+ for(;;) {
+ if ( c3 == EOF )
+ break;
+ if ( c1 == '-' && c2 == '-' && c3 == '>' )
+ break;
+ c1 = c2;
+ c2 = c3;
+ c3 = yyinput();
+ pChar[0] = c3;
+ WorkOnTokenSet( COMMENT, pChar );
+ }
}
.|\n {
- if ( bText == 1 )
- WorkOnTokenSet( XML_TEXTCHAR, yytext );
- else
- WorkOnTokenSet( UNKNOWNCHAR, yytext );
+ if ( bText == 1 )
+ WorkOnTokenSet( XML_TEXTCHAR, yytext );
+ else
+ WorkOnTokenSet( UNKNOWNCHAR, yytext );
}
%%
/*****************************************************************************/
-int yywrap(void)
+int yywrap(void)
/*****************************************************************************/
{
- return 1;
+ return 1;
}
/*****************************************************************************/
void YYWarning( const char *s )
/*****************************************************************************/
{
- /* write warning to stderr */
- fprintf( stderr,
- "Warning: \"%s\" in line %d: \"%s\"\n", s, yylineno, yytext );
+ /* write warning to stderr */
+ fprintf( stderr,
+ "Warning: \"%s\" in line %d: \"%s\"\n", s, yylineno, yytext );
}
/*****************************************************************************/
void yyerror ( const char *s )
/*****************************************************************************/
{
- /* write error to stderr */
- fprintf( stderr,
- "Error: \"%s\" in line %d: \"%s\"\n", s, yylineno, yytext );
- SetError();
+ /* write error to stderr */
+ fprintf( stderr,
+ "Error: \"%s\" in line %d: \"%s\"\n", s, yylineno, yytext );
+ SetError();
}
SAL_IMPLEMENT_MAIN_WITH_ARGS(argc, argv) {
- /* error level */
- int nRetValue = 0;
- FILE *pFile;
+ /* error level */
+ int nRetValue = 0;
+ FILE *pFile;
- if ( !GetOutputFile( argc, argv ) )
- {
- return 1;
- }
- pFile = GetXrmFile();
- InitXrmExport( getFilename() );
+ if ( !GetOutputFile( argc, argv ) )
+ {
+ return 1;
+ }
+ pFile = GetXrmFile();
+ InitXrmExport( getFilename() );
if ( !pFile )
- return 1;
+ return 1;
- yyin = pFile;
+ yyin = pFile;
- /* create global instance of class XmlExport */
- //InitXrmExport( pOutput );
+ /* create global instance of class XmlExport */
+ //InitXrmExport( pOutput );
- /* start parser */
- yylex();
+ /* start parser */
+ yylex();
- /* get error info. and end export */
- nRetValue = GetError();
- EndXrmExport();
+ /* get error info. and end export */
+ nRetValue = GetError();
+ EndXrmExport();
- /* return error level */
- return nRetValue;
+ /* return error level */
+ return nRetValue;
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab cinoptions=b1,g0,N-s cinkeys+=0=break: */