diff options
author | Luke Wilde <lukew@serenityos.org> | 2021-09-11 23:28:55 +0100 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-09-12 01:41:44 +0200 |
commit | f8eb616fe32137c6b3338d6d14cfcac7cd8c0fb1 (patch) | |
tree | 55e81654e19bf4f5a53ca6d69b4f9f6217fdc544 /Meta/Lagom | |
parent | 3eca8cb24353604431a1d8bfbb968f5ef218cda3 (diff) | |
download | serenity-f8eb616fe32137c6b3338d6d14cfcac7cd8c0fb1.zip |
LibWeb: Add support for the IDL any type
The any type is essentially a raw JS::Value.
Diffstat (limited to 'Meta/Lagom')
-rw-r--r-- | Meta/Lagom/Tools/CodeGenerators/LibWeb/WrapperGenerator.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Meta/Lagom/Tools/CodeGenerators/LibWeb/WrapperGenerator.cpp b/Meta/Lagom/Tools/CodeGenerators/LibWeb/WrapperGenerator.cpp index 13c4f0da66..9039c68bbf 100644 --- a/Meta/Lagom/Tools/CodeGenerators/LibWeb/WrapperGenerator.cpp +++ b/Meta/Lagom/Tools/CodeGenerators/LibWeb/WrapperGenerator.cpp @@ -717,6 +717,10 @@ static void generate_to_cpp(SourceGenerator& generator, ParameterType& parameter @return_statement@ } )~~~"); + } else if (parameter.type.name == "any") { + scoped_generator.append(R"~~~( + auto @cpp_name@ = @js_name@@js_suffix@; +)~~~"); } else { dbgln("Unimplemented JS-to-C++ conversion: {}", parameter.type.name); VERIFY_NOT_REACHED(); |