fix(include): fix broken include on empty files

This commit is contained in:
zawz 2022-01-24 14:46:48 +01:00
parent 29f0fd91ad
commit 2024152dc6

View file

@ -102,12 +102,10 @@ parse_context make_context(std::string const& in, std::string const& filename, b
} }
parse_context make_context(parse_context ctx, std::string const& in, std::string const& filename, bool bash) parse_context make_context(parse_context ctx, std::string const& in, std::string const& filename, bool bash)
{
if(in != "")
{ {
ctx.data = in.c_str(); ctx.data = in.c_str();
ctx.size = in.size(); ctx.size = in.size();
}
if(filename != "") if(filename != "")
ctx.filename = filename.c_str(); ctx.filename = filename.c_str();
if(bash) if(bash)