Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-113614

Script lookup is always not efficient

    XMLWordPrintable

Details

    • Bug
    • Resolution: Unresolved
    • P2: Important
    • Some future release
    • 6.5.0, 6.6
    • QML: Compiler
    • None

    Description

      Using some Lib.js

      .pragma library
      
      function foo() {
          console.log("foo() called")
      }
      

      , exported by

      set_source_files_properties(Lib.js PROPERTIES QT_QML_SOURCE_TYPENAME Lib)
      

      and called via

              Lib.foo()
      

      always runs into

      Warning: main.qml:11:9: Could not compile binding for onCompleted: Cannot generate efficient code for script lookup [compiler]
              Lib.foo()
              ^^^
      

      .

      What can I do to make it "efficient" and get rid of that message?

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            qtqmlteam Qt Qml Team User
            cajus Cajus Pollmeier
            Votes:
            1 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:

              Gerrit Reviews

                There are no open Gerrit changes