Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. Qt for WebAssembly
  4. BindingError: emval::as has unknown type j
Qt 6.11 is out! See what's new in the release blog

BindingError: emval::as has unknown type j

Scheduled Pinned Locked Moved Unsolved Qt for WebAssembly
2 Posts 2 Posters 197 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • M Offline
    M Offline
    Matthew Daskilewicz
    wrote last edited by
    #1

    I get this error in my browser when the .wasm file is loading, causing it to fail to load.

    (Qt 6.9.3 + emsdk 3.1.70 + qmake)

    Through lots of trial and error, I figured out that it's happening when using emscripten::val, or maybe EM_JS, in a .cpp file that is located in a subfolder (relative to the .pro file). Moving the file up to the main directory yields a wasm file that works normally.

    Has anyone seen this and have any more details on what's causing it and what is a better fix than moving the file? My .pro file is pretty basic and I don't see any reason the location of the file should matter.

    1 Reply Last reply
    0
    • Nils SjobergN Offline
      Nils SjobergN Offline
      Nils Sjoberg
      wrote last edited by
      #2

      Try an unoptimized build first (without optimizations) to verify a code folding/LTO issue, and if so, update emsdk to a newer version; if you don't feel like messing with it, moving the file is the quick fix.

      "What's up, Doc?"

      1 Reply Last reply
      0

      • Login

      • Login or register to search.
      • First post
        Last post
      0
      • Categories
      • Recent
      • Tags
      • Popular
      • Users
      • Groups
      • Search
      • Get Qt
      • Unsolved