mirror of
https://gitlab.winehq.org/wine/vkd3d.git
synced 2024-11-21 16:46:41 -08:00
61 lines
1.4 KiB
Plaintext
61 lines
1.4 KiB
Plaintext
|
/*
|
||
|
* HLSL preprocessor
|
||
|
*
|
||
|
* Copyright 2020 Zebediah Figura for CodeWeavers
|
||
|
*
|
||
|
* This library is free software; you can redistribute it and/or
|
||
|
* modify it under the terms of the GNU Lesser General Public
|
||
|
* License as published by the Free Software Foundation; either
|
||
|
* version 2.1 of the License, or (at your option) any later version.
|
||
|
*
|
||
|
* This library is distributed in the hope that it will be useful,
|
||
|
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||
|
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
||
|
* Lesser General Public License for more details.
|
||
|
*
|
||
|
* You should have received a copy of the GNU Lesser General Public
|
||
|
* License along with this library; if not, write to the Free Software
|
||
|
* Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA
|
||
|
*/
|
||
|
|
||
|
%code requires
|
||
|
{
|
||
|
|
||
|
#include "vkd3d_shader_private.h"
|
||
|
#include "preproc.h"
|
||
|
|
||
|
}
|
||
|
|
||
|
%code provides
|
||
|
{
|
||
|
|
||
|
int preproc_yylex(PREPROC_YYSTYPE *yylval_param, PREPROC_YYLTYPE *yylloc_param, void *scanner);
|
||
|
|
||
|
}
|
||
|
|
||
|
%code
|
||
|
{
|
||
|
|
||
|
static void yyerror(const YYLTYPE *loc, void *scanner, struct preproc_ctx *ctx, const char *string)
|
||
|
{
|
||
|
FIXME("Error reporting is not implemented.\n");
|
||
|
}
|
||
|
|
||
|
}
|
||
|
|
||
|
%define api.prefix {preproc_yy}
|
||
|
%define api.pure full
|
||
|
%define parse.error verbose
|
||
|
%expect 0
|
||
|
%locations
|
||
|
%lex-param {yyscan_t scanner}
|
||
|
%parse-param {void *scanner}
|
||
|
%parse-param {struct preproc_ctx *ctx}
|
||
|
|
||
|
%token T_TEXT
|
||
|
|
||
|
%%
|
||
|
|
||
|
shader_text
|
||
|
: %empty
|