fix: Make functions in LambdaSupport.h purely virtual to avoid linking errors in debug builds

Some virtual functions in `LambdaSupport.h` are meant to be purely
virtual, but lack a `= 0` in their signature. In debug builds, this
causes the linker to look for a default implementation, resulting in a
linker error.

This patch marks the virtual functions as purely virtual, resolving
the linker issues in debug builds.
This commit is contained in:
Andi Drebes
2022-05-04 15:52:45 +02:00
committed by Andi Drebes
parent bd49cc9a48
commit f232935592

View File

@@ -249,7 +249,7 @@ public:
/// Compile the mlir program and produces a compilation result if succeed.
llvm::Expected<std::unique_ptr<CompilationResult>> virtual compile(
llvm::SourceMgr &program,
CompilationOptions options = CompilationOptions("main"));
CompilationOptions options = CompilationOptions("main")) = 0;
llvm::Expected<std::unique_ptr<CompilationResult>>
compile(llvm::StringRef program,
@@ -266,15 +266,16 @@ public:
}
/// Load the server lambda from the compilation result.
llvm::Expected<Lambda> virtual loadServerLambda(CompilationResult &result);
llvm::Expected<Lambda> virtual loadServerLambda(
CompilationResult &result) = 0;
/// Load the client parameters from the compilation result.
llvm::Expected<clientlib::ClientParameters> virtual loadClientParameters(
CompilationResult &result);
CompilationResult &result) = 0;
/// Call the lambda with the public arguments.
llvm::Expected<std::unique_ptr<clientlib::PublicResult>> virtual serverCall(
Lambda lambda, clientlib::PublicArguments &args);
Lambda lambda, clientlib::PublicArguments &args) = 0;
/// Build the client KeySet from the client parameters.
static llvm::Expected<std::unique_ptr<clientlib::KeySet>>