Skip to content

Commit

Permalink
Fix a compilation error
Browse files Browse the repository at this point in the history
error: designated initializers are a C++20 extension [-Werror,-Wc++20-designator]
  • Loading branch information
thilinarmtb committed Nov 22, 2024
1 parent e4cb83e commit 4d4ea2b
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions src/occa/internal/utils/transpiler_utils.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -123,15 +123,15 @@ bool Transpiler::run(const std::string &filename,
auto includes = transpiler::buildIncludes(kernelProps);
auto hash = transpiler::getKernelHash(kernelProps);

oklt::UserInput input {
.backend = backend->second,
.source = std::move(sourceCode.value()),
.headers = {},
.sourcePath = expandedFile,
.includeDirectories = std::move(includes),
.defines = std::move(defines),
.hash = std::move(hash)
};
oklt::UserInput input;
input.backend = backend->second;
input.source = std::move(sourceCode.value());
input.headers = {};
input.sourcePath = expandedFile;
input.includeDirectories = std::move(includes);
input.defines = std::move(defines);
input.hash = std::move(hash);

auto result = normalizeAndTranspile(std::move(input));
if(!result) {
_fail(result.error());
Expand Down

0 comments on commit 4d4ea2b

Please sign in to comment.