Skip to content

Commit

Permalink
fix: fix compile.
Browse files Browse the repository at this point in the history
  • Loading branch information
andycall committed Oct 30, 2024
1 parent 682e3a5 commit 7200c77
Show file tree
Hide file tree
Showing 6 changed files with 10 additions and 10 deletions.
2 changes: 1 addition & 1 deletion bridge/core/api/document.cc
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,7 @@ WebFValue<Element, ElementPublicMethods> DocumentPublicMethods::ElementFromPoint
}

WebFValue<Element, HTMLElementPublicMethods> DocumentPublicMethods::DocumentElement(webf::Document* document) {
auto* document_element = document->documentElement();
auto* document_element = DynamicTo<HTMLElement>(document->documentElement());
WebFValueStatus* status_block = document_element->KeepAlive();
return WebFValue<Element, HTMLElementPublicMethods>{document_element, document_element->htmlElementPublicMethods(),
status_block};
Expand Down
3 changes: 2 additions & 1 deletion bridge/core/css/parser/find_length_of_declaration_list-inl.h
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
#include <arm_neon.h>
#endif

#include "core/base/compiler_specific.h"
#include "foundation/string_view.h"

namespace webf {
Expand Down Expand Up @@ -365,7 +366,7 @@ ALWAYS_INLINE static size_t FindLengthOfDeclarationList(const uint8_t* begin,

#endif

inline static size_t FindLengthOfDeclarationList(std::string_view str) {
inline ALWAYS_INLINE size_t FindLengthOfDeclarationList(std::string_view str) {
return FindLengthOfDeclarationList(reinterpret_cast<const uint8_t*>(str.data()),
reinterpret_cast<const uint8_t*>(str.data() + str.length()));
}
Expand Down
1 change: 0 additions & 1 deletion bridge/core/dom/node.cc
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@
#include "element.h"
#include "empty_node_list.h"
#include "node.h"
#include "node_data.h"
#include "node_traversal.h"
#include "qjs_node.h"
#include "text.h"
Expand Down
2 changes: 0 additions & 2 deletions bridge/core/html/html_element.h
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,6 @@ class HTMLElement : public Element {
return &html_element_public_methods;
}

private:

void ParseAttribute(const webf::Element::AttributeModificationParams &) override;
};

Expand Down
6 changes: 4 additions & 2 deletions bridge/foundation/shared_ui_command.cc
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
* Copyright (C) 2022-present The WebF authors. All rights reserved.
*/

#include <atomic>
#include <memory>
#include "shared_ui_command.h"
#include "core/executing_context.h"
#include "foundation/logging.h"
Expand Down Expand Up @@ -45,7 +47,7 @@ void* SharedUICommand::data() {

uint32_t SharedUICommand::kindFlag() {
// simply spin wait for the swapBuffers to finish.
while (is_blocking_writing_.load(std::memory_order::memory_order_acquire)) {
while (is_blocking_writing_.load(std::memory_order_acquire)) {
}

return active_buffer->kindFlag();
Expand All @@ -59,7 +61,7 @@ int64_t SharedUICommand::size() {
// third called by dart to clear commands.
void SharedUICommand::clear() {
// simply spin wait for the swapBuffers to finish.
while (is_blocking_writing_.load(std::memory_order::memory_order_acquire)) {
while (is_blocking_writing_.load(std::memory_order_acquire)) {
}
active_buffer->clear();
}
Expand Down
6 changes: 3 additions & 3 deletions bridge/scripts/code_generator/bin/code_generator.js
Original file line number Diff line number Diff line change
Expand Up @@ -319,10 +319,10 @@ function genPluginAPICodeFromTypeDefine() {
let headerFilePath = path.join(b.dist, '../include/plugin_api', b.filename.replace('plugin_api_', ''));
let genFilePath = path.join(b.dist, b.filename);

wirteFileIfChanged(headerFilePath + '.h', result.header);
writeFileIfChanged(headerFilePath + '.h', result.header);

if (result.source) {
wirteFileIfChanged(genFilePath + '.cc', result.source);
writeFileIfChanged(genFilePath + '.cc', result.source);
}
}

Expand Down Expand Up @@ -352,7 +352,7 @@ function genRustCodeFromTypeDefine() {

let genFilePath = path.join(b.dist, '../rusty_webf_sys/src', b.filename);

wirteFileIfChanged(genFilePath + '.rs', result);
writeFileIfChanged(genFilePath + '.rs', result);
}

}

0 comments on commit 7200c77

Please sign in to comment.