[PATCH vkd3d v3 2/3] vkd3d-compiler: Move some argument validation out of parse_command_line().
Henri Verbeet
hverbeet at gmail.com
Thu Jan 6 03:41:36 CST 2022
On Tue, 4 Jan 2022 at 14:25, Giovanni Mascellani
<gmascellani at codeweavers.com> wrote:
> On 26/12/21 05:43, Zebediah Figura wrote:
> > + if (!options.preprocess_only && !validate_target_type(options.source_type, options.target_type))
> > + {
> > + fprintf(stderr, "Target type '%s' is invalid for source type '%s'.\n",
> > + get_target_type_info(options.target_type)->name,
> > + get_source_type_info(options.source_type)->name);
> > + return 0;
> > + }
> > +
> > + if (!options.preprocess_only && options.source_type == VKD3D_SHADER_SOURCE_HLSL && !options.profile)
> > + {
> > + fprintf(stderr, "You need to specify a profile when compiling from HLSL source.\n");
> > + return 0;
> > + }
> > +
>
> Shouldn't these two return 1? So they did before, and that condition
> really looks like an error.
>
They probably should, yes.
More information about the wine-devel
mailing list