Skip to content

Commit

Permalink
Fix ignored -fsycl-unnamed-lambda (triSYCL#145)
Browse files Browse the repository at this point in the history
  • Loading branch information
Luc Forget committed Oct 22, 2021
1 parent d281d2b commit ed6ed02
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 2 deletions.
1 change: 0 additions & 1 deletion clang/lib/Frontend/CompilerInvocation.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3976,7 +3976,6 @@ bool CompilerInvocation::ParseLangArgs(LangOptions &Opts, ArgList &Args,
options::OPT_fno_sycl_allow_variadic_func)
: Args.hasFlag(options::OPT_fsycl_allow_variadic_func,
options::OPT_fno_sycl_allow_variadic_func, false);
Opts.SYCLUnnamedLambda = Args.hasArg(options::OPT_fsycl_unnamed_lambda);

// Get OpenMP host file path if any and report if a non existent file is
// found
Expand Down
2 changes: 1 addition & 1 deletion clang/lib/Sema/SemaSYCL.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1093,7 +1093,7 @@ constructKernelName(Sema &S, const FunctionDecl *KernelCallerFunc,
std::string Str =
SYCLUniqueStableNameExpr::ComputeName(S.getASTContext(), KernelNameType);
Res = computeUniqueSYCLVXXName(Res, KernelNameType.getAsString());
return {Res, Str};
return {Res, computeUniqueSYCLVXXName(Str, Str)};
}

static bool isDefaultSPIRArch(ASTContext &Context) {
Expand Down

0 comments on commit ed6ed02

Please sign in to comment.