From 3348ef25758496dbef518924a3c1e65b84d3456c Mon Sep 17 00:00:00 2001 From: Jamieson Pryor Date: Sun, 29 Dec 2024 09:53:43 -0800 Subject: [PATCH] Ignore .vscode configurations for git. This is a commonly generated directory for Visual Studio. PiperOrigin-RevId: 710506423 --- .gitignore | 1 + implementation/class.h | 13 ++++++++++++- implementation/return.h | 4 ++-- metaprogramming/string_literal.h | 4 ++-- 4 files changed, 17 insertions(+), 5 deletions(-) diff --git a/.gitignore b/.gitignore index bd12961c..80835edd 100644 --- a/.gitignore +++ b/.gitignore @@ -1 +1,2 @@ bazel* +.vscode diff --git a/implementation/class.h b/implementation/class.h index 81dee205..18a52196 100644 --- a/implementation/class.h +++ b/implementation/class.h @@ -36,7 +36,10 @@ namespace jni { template -struct Class {}; +struct Class { + constexpr Class() = default; + constexpr Class(const char* name) {} +}; template , // provided where they are and aren't present. //////////////////////////////////////////////////////////////////////////////// + // To stifle a test failure. + constexpr Class() + : Object("__JNI_BIND__NO_CLASS__"), + constructors_(Constructor<>{}), + static_(), + methods_(), + fields_() {} + // Methods + Fields. explicit constexpr Class(const char* class_name, Methods_... methods, Fields_... fields) diff --git a/implementation/return.h b/implementation/return.h index 8f352be3..7b6e8f57 100644 --- a/implementation/return.h +++ b/implementation/return.h @@ -31,7 +31,7 @@ struct Return : ReturnBase { using Raw = Raw_; - constexpr Return() = default; + constexpr Return() {} template constexpr explicit Return(Raw raw) : raw_(raw) {} @@ -42,7 +42,7 @@ struct Return : ReturnBase { using Raw = void; const Void raw_{}; - constexpr Return() = default; + constexpr Return() {} }; Return() -> Return; diff --git a/metaprogramming/string_literal.h b/metaprogramming/string_literal.h index e93a4b85..b6b88ab1 100644 --- a/metaprogramming/string_literal.h +++ b/metaprogramming/string_literal.h @@ -58,9 +58,9 @@ struct StringLiteral { template StringLiteral(const char (&str)[N]) -> StringLiteral; +} // namespace jni::metaprogramming + #endif // __cplusplus >= 202002L #endif // __cplusplus -} // namespace jni::metaprogramming - #endif // JNI_BIND_METAPROGRAMMING_STRING_LITERAL_H_