Commit d70da86e authored by Hitoshi Yoshida's avatar Hitoshi Yoshida Committed by Commit Bot

CodeGen: Fix include files in generated dictionaries

Bug: 839389
Change-Id: I4b86d896e527caa15a2150e2a1544cc080e227df
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/2026835Reviewed-by: default avatarYuki Shiino <yukishiino@chromium.org>
Cr-Commit-Position: refs/heads/master@{#736260}
parent d2478a08
...@@ -105,9 +105,8 @@ def collect_include_headers_of_idl_types(idl_types): ...@@ -105,9 +105,8 @@ def collect_include_headers_of_idl_types(idl_types):
header_paths.add("third_party/blink/renderer/" header_paths.add("third_party/blink/renderer/"
"platform/wtf/text/wtf_string.h") "platform/wtf/text/wtf_string.h")
elif idl_type.is_buffer_source_type: elif idl_type.is_buffer_source_type:
basename = name_style.file("DOM", idl_type.type_name)
header_paths.add("third_party/blink/renderer/core/typed_arrays/" header_paths.add("third_party/blink/renderer/core/typed_arrays/"
"{}.h".format(basename)) "dom_typed_array.h")
header_paths.add( header_paths.add(
"third_party/blink/renderer/platform/heap/handle.h") "third_party/blink/renderer/platform/heap/handle.h")
elif idl_type.is_object or idl_type.is_any: elif idl_type.is_object or idl_type.is_any:
......
...@@ -30,6 +30,7 @@ from .codegen_expr import expr_from_exposure ...@@ -30,6 +30,7 @@ from .codegen_expr import expr_from_exposure
from .codegen_format import format_template as _format from .codegen_format import format_template as _format
from .codegen_utils import collect_include_headers_of_idl_types from .codegen_utils import collect_include_headers_of_idl_types
from .codegen_utils import component_export from .codegen_utils import component_export
from .codegen_utils import component_export_header
from .codegen_utils import enclose_with_header_guard from .codegen_utils import enclose_with_header_guard
from .codegen_utils import make_copyright_header from .codegen_utils import make_copyright_header
from .codegen_utils import make_forward_declarations from .codegen_utils import make_forward_declarations
...@@ -662,6 +663,7 @@ def generate_dictionary(dictionary): ...@@ -662,6 +663,7 @@ def generate_dictionary(dictionary):
[member.idl_type for member in dictionary.own_members])) [member.idl_type for member in dictionary.own_members]))
header_node.accumulator.add_include_headers([ header_node.accumulator.add_include_headers([
base_class_header, base_class_header,
component_export_header(dictionary.components[0]),
"v8/include/v8.h", "v8/include/v8.h",
]) ])
header_node.accumulator.add_class_decls([ header_node.accumulator.add_class_decls([
...@@ -669,10 +671,12 @@ def generate_dictionary(dictionary): ...@@ -669,10 +671,12 @@ def generate_dictionary(dictionary):
"Visitor", "Visitor",
]) ])
source_node.accumulator.add_include_headers([ source_node.accumulator.add_include_headers([
"third_party/blink/renderer/bindings/core/v8/"
"native_value_traits_impl.h",
"third_party/blink/renderer/platform/bindings/exception_messages.h", "third_party/blink/renderer/platform/bindings/exception_messages.h",
"third_party/blink/renderer/platform/bindings/exception_state.h", "third_party/blink/renderer/platform/bindings/exception_state.h",
"third_party/blink/renderer/platform/bindings/v8_per_isolate_data.h",
"third_party/blink/renderer/platform/heap/visitor.h", "third_party/blink/renderer/platform/heap/visitor.h",
"v8/include/v8.h",
]) ])
header_node.extend([ header_node.extend([
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment