Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • Users
  • Groups
  • Search
  • Get Qt Extensions
  • Unsolved
Collapse
Brand Logo
  1. Home
  2. Qt Development
  3. General and Desktop
  4. __fastcall' incompatible with the '/clr' option
Forum Updated to NodeBB v4.3 + New Features

__fastcall' incompatible with the '/clr' option

Scheduled Pinned Locked Moved Unsolved General and Desktop
5 Posts 3 Posters 1.4k 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.
  • A Offline
    A Offline
    Asperamanca
    wrote on last edited by
    #1

    I reuse some Qt sources in a /CLR (MS common language runtime) project. In this environment, I receive hundreds of warnings of this kind:

    src/corelib/tools/qchar.h(310): warning C4561: '__fastcall' incompatible with the '/clr' option: converting to '__stdcall'
    
    1. Is this "just for information", or will this break code?
    2. Is using Qt in a /CLR environment supported or not?

    There is a sample combining Qt and .NET in the docs, which (to me) implies that combining Qt and CLR should be possible: https://doc.qt.io/archives/qt-4.8/activeqt-dotnet.html

    I have found two old "rejected" issue reports (https://bugreports.qt.io/browse/QTBUG-13823 and https://bugreports.qt.io/browse/QTBUG-5399), but they don't really tell me anything about the behavior of Qt in this environment.

    JonBJ jsulmJ 2 Replies Last reply
    0
    • A Asperamanca

      I reuse some Qt sources in a /CLR (MS common language runtime) project. In this environment, I receive hundreds of warnings of this kind:

      src/corelib/tools/qchar.h(310): warning C4561: '__fastcall' incompatible with the '/clr' option: converting to '__stdcall'
      
      1. Is this "just for information", or will this break code?
      2. Is using Qt in a /CLR environment supported or not?

      There is a sample combining Qt and .NET in the docs, which (to me) implies that combining Qt and CLR should be possible: https://doc.qt.io/archives/qt-4.8/activeqt-dotnet.html

      I have found two old "rejected" issue reports (https://bugreports.qt.io/browse/QTBUG-13823 and https://bugreports.qt.io/browse/QTBUG-5399), but they don't really tell me anything about the behavior of Qt in this environment.

      JonBJ Offline
      JonBJ Offline
      JonB
      wrote on last edited by
      #2

      @Asperamanca

      1. Is this "just for information", or will this break code?

      It's a warning, and compiler is changing __fastcall to plain __stdcall, so that bit should be alright.

      1 Reply Last reply
      2
      • A Asperamanca

        I reuse some Qt sources in a /CLR (MS common language runtime) project. In this environment, I receive hundreds of warnings of this kind:

        src/corelib/tools/qchar.h(310): warning C4561: '__fastcall' incompatible with the '/clr' option: converting to '__stdcall'
        
        1. Is this "just for information", or will this break code?
        2. Is using Qt in a /CLR environment supported or not?

        There is a sample combining Qt and .NET in the docs, which (to me) implies that combining Qt and CLR should be possible: https://doc.qt.io/archives/qt-4.8/activeqt-dotnet.html

        I have found two old "rejected" issue reports (https://bugreports.qt.io/browse/QTBUG-13823 and https://bugreports.qt.io/browse/QTBUG-5399), but they don't really tell me anything about the behavior of Qt in this environment.

        jsulmJ Offline
        jsulmJ Offline
        jsulm
        Lifetime Qt Champion
        wrote on last edited by
        #3

        @Asperamanca

        1. Just a warning fastcall/stdcall are simply different ways to call a function and pass parameters to it
        2. Yes, it does. There are even official builds. But you're simply including Qt code in your project.

        https://forum.qt.io/topic/113070/qt-code-of-conduct

        1 Reply Last reply
        2
        • A Offline
          A Offline
          Asperamanca
          wrote on last edited by Asperamanca
          #4

          Would the official build be "Qt for Windows UWP"?

          Also, from the technical FAQ in the Qt Wiki:

          Is there any way to compile the Qt source code and Qt applications with /clr flag?

          We don't support building Qt or Qt applications with CLR directly. To integrate existing components you can use the Active Qt http://doc.qt.io/qt-5/activeqt.html framework, which allows integration of Active X and COM object in Qt applications.

          jsulmJ 1 Reply Last reply
          0
          • A Asperamanca

            Would the official build be "Qt for Windows UWP"?

            Also, from the technical FAQ in the Qt Wiki:

            Is there any way to compile the Qt source code and Qt applications with /clr flag?

            We don't support building Qt or Qt applications with CLR directly. To integrate existing components you can use the Active Qt http://doc.qt.io/qt-5/activeqt.html framework, which allows integration of Active X and COM object in Qt applications.

            jsulmJ Offline
            jsulmJ Offline
            jsulm
            Lifetime Qt Champion
            wrote on last edited by
            #5

            @Asperamanca I think I'm wrong with what I said (not a Windows developer anymore :-)). "Qt for Windows UWP" uses C++ and is not based on .Net, so no CLR.

            https://forum.qt.io/topic/113070/qt-code-of-conduct

            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 Extensions
            • Unsolved