[Vm-dev] [OpenSmalltalk/opensmalltalk-vm] efcf1f: printCallStack and printAllStacks are now void, fi...

GitHub noreply at github.com
Thu Jul 21 15:03:42 UTC 2016

  Branch: refs/heads/Cog
  Home:   https://github.com/OpenSmalltalk/opensmalltalk-vm
  Commit: efcf1ff88261700754106eebbfe8cb7fc6a0ab66
  Author: Nicolas Cellier <nicolas.cellier at sirehna.com>
  Date:   2016-07-21 (Thu, 21 Jul 2016)

  Changed paths:
    M platforms/Mac OS/vm/sqMacMain.c
    M platforms/iOS/vm/Common/Classes/sqSqueakMainApp.m
    M platforms/win32/vm/sqWin32Main.c

  Log Message:
  printCallStack and printAllStacks are now void, fix prototype

Note: it's not sustainable to have prototypes replicated all around the source files...
I've seen some declaration differ about int or sqInt return type which is not 64 bits image friendly.

  Commit: 78296cf3b53af5e25bf40281d5bf1d2b5e44e0ac
  Author: Nicolas Cellier <nicolas.cellier at sirehna.com>
  Date:   2016-07-21 (Thu, 21 Jul 2016)

  Changed paths:
    M platforms/win32/plugins/HostWindowPlugin/sqWin32HostWindowPlugin.c

  Log Message:
  Fix incorrect use of recordMouseEvent  in sqHostWindowPlugin

This function was used with implcit declaration...
Unfortunately, the implementation (in sqWin32Window.c) does not fit the usage...
it takes a second parameter, number of clicks.
I suspect the plugin does not work for a long time...

The corection is a rough work around, not taking into account multiple clicks, and/or motions during click.

  Commit: 42336e487a877ab0031cddaf0ff0af6f190598cd
  Author: Nicolas Cellier <nicolas.cellier at sirehna.com>
  Date:   2016-07-21 (Thu, 21 Jul 2016)

  Changed paths:
    M platforms/win32/plugins/DropPlugin/sqWin32Drop.c
    M platforms/win32/vm/sqPlatformSpecific.h
    M platforms/win32/vm/sqWin32Backtrace.c
    M platforms/win32/vm/sqWin32Main.c
    M platforms/win32/vm/sqWin32PluginSupport.c
    M platforms/win32/vm/sqWin32Prefs.c
    M platforms/win32/vm/sqWin32Prefs.h
    M platforms/win32/vm/sqWin32Threads.c
    M platforms/win32/vm/sqWin32Window.c

  Log Message:
  Declare prototypes of functions used in platforms/win32

Not doing so is dangerous because we might pass an int (32 bits) instead of an sqInt (64 bits)
It is thus sane to eliminate the warnings of the kind:
../../platforms/win32/vm/xxx.c:58:4: warning: implicit declaration of function 'yyy' is invalid in C99 [-Wimplicit-function-declaration]

Current workaround leads to more duplication of prototypes which is not satisfactory.
We should better use header files in the future.

Compare: https://github.com/OpenSmalltalk/opensmalltalk-vm/compare/fba242c232fa...42336e487a87

More information about the Vm-dev mailing list