Recent

Author Topic: Latest trunk, opening my form in IDE gives read error / access violation  (Read 2274 times)

MISV

  • Sr. Member
  • ****
  • Posts: 493
With the latest trunk, opening my form in IDE gives read error / access violation. Never had this problem before.



using lldb I got this

Code: Pascal  [Select]
  1. ...
  2. Warning: TWinControl.DestroyHandle btnViewFiles_Nav_ViewerSwitch:TmsButtonControl Handle not Allocated
  3. 2018-08-11 00:19:46.253420+0200 lazarus[19517:86522] [lazarus] CGBitmapContextCreate: unsupported parameter combination: set CGBITMAP_CONTEXT_LOG_ERRORS environmental variable to see the details
  4. 2018-08-11 00:19:46.253476+0200 lazarus[19517:86522] [lazarus] CGContextScaleCTM: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable.
  5. 2018-08-11 00:19:46.253496+0200 lazarus[19517:86522] [lazarus] CGContextGetCTM: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable.
  6. 2018-08-11 00:19:46.253513+0200 lazarus[19517:86522] [lazarus] CGContextSetBaseCTM: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable.
  7. 2018-08-11 00:19:46.254360+0200 lazarus[19517:86522] [lazarus] CGBitmapContextCreate: unsupported parameter combination: set CGBITMAP_CONTEXT_LOG_ERRORS environmental variable to see the details
  8. 2018-08-11 00:19:46.254401+0200 lazarus[19517:86522] [lazarus] CGContextScaleCTM: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable.
  9. 2018-08-11 00:19:46.254437+0200 lazarus[19517:86522] [lazarus] CGContextGetCTM: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable.
  10. 2018-08-11 00:19:46.254467+0200 lazarus[19517:86522] [lazarus] CGContextSetBaseCTM: invalid context 0x0. If you want to see the backtrace, please set CG_CONTEXT_SHOW_BACKTRACE environmental variable.
  11. Process 19517 stopped
  12. * thread #1, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS (code=1, address=0x24)
  13.     frame #0: 0xa678f163 libobjc.A.dylib`objc_msgSend + 19
  14. libobjc.A.dylib`objc_msgSend:
  15. ->  0xa678f163 <+19>: movl   0x20(%edx), %edi
  16.     0xa678f166 <+22>: pushl  %esi
  17.     0xa678f167 <+23>: movl   (%edi), %esi
  18.     0xa678f169 <+25>: movl   %ecx, %edx
  19. Target 0: (lazarus) stopped.



using lldb backtrack I got this

Code: Pascal  [Select]
  1. error: sourcefilemanager.o {0x000125fb}: unhandled type tag 0x0020 (DW_TAG_set_type), please file a bug and attach the file at the start of this error message
  2. ...
  3. error: main.o {0x00024a9f}: unhandled type tag 0x0020 (DW_TAG_set_type), please file a bug and attach the file at the start of this error message
  4. ...
  5. error: comctrls.o {0x000482a4}: unhandled type tag 0x0020 (DW_TAG_set_type), please file a bug and attach the file at the start of this error message
  6. error: need to add support for DW_TAG_base_type 'FormalDef' encoded with DW_ATE = 0x7, bit_size = 0
  7. error: need to add support for DW_TAG_base_type 'FormalDef' encoded with DW_ATE = 0x7, bit_size = 0
  8. error: need to add support for DW_TAG_base_type 'FormalDef' encoded with DW_ATE = 0x7, bit_size = 0
  9. error: need to add support for DW_TAG_base_type 'FormalDef' encoded with DW_ATE = 0x7, bit_size = 0
  10. * thread #1, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS (code=1, address=0x24)
  11.   * frame #0: 0xa678f163 libobjc.A.dylib`objc_msgSend + 19
  12.     frame #1: 0xa678f0af libobjc.A.dylib`objc_retain + 29
  13.     frame #2: 0x91657924 AppKit`-[NSTableView removeTableColumn:] + 29
  14.     frame #3: 0x002d7a52 lazarus`COLUMNDELETE(self=0x0a06aef0, ALV=0x13292050, AINDEX=4) at cocoawscomctrls.pas:747
  15.     frame #4: 0x00236c95 lazarus`WSDESTROYCOLUMN(this=0x13426620) at listcolumn.inc:105
  16.     frame #5: 0x00236752 lazarus`WSCREATECOLUMNS(this=0x12a69430) at listcolumns.inc:91
  17.     frame #6: 0x0023c571 lazarus`INITIALIZEWND(this=0x13292050) at customlistview.inc:534
  18.     frame #7: 0x0021361c lazarus`CREATEWND(this=0x13292050) at wincontrol.inc:7579
  19.     frame #8: 0x00fc9a2e lazarus`UMSCONTROLS$_$TMSLISTVIEW_$__$$_CREATEWND + 14
  20.     frame #9: 0x00212d61 lazarus`CREATEHANDLE(this=0x13292050) at wincontrol.inc:7463
  21.     frame #10: 0x00214101 lazarus`HANDLENEEDED(this=0x13292050) at wincontrol.inc:7913
  22.     frame #11: 0x002136fd lazarus`CREATEWND(this=0x13291cb0) at wincontrol.inc:7598
  23.     frame #12: 0x00212d61 lazarus`CREATEHANDLE(this=0x13291cb0) at wincontrol.inc:7463
  24.     frame #13: 0x00214101 lazarus`HANDLENEEDED(this=0x13291cb0) at wincontrol.inc:7913
  25.     frame #14: 0x002d70de lazarus`ADDPAGE(self=0x09ae2ce0, ATABCONTROL=0x1327a1a0, ACHILD=0x13291cb0, AINDEX=1) at cocoawscomctrls.pas:542
  26.     frame #15: 0x00230ffc lazarus`ADDREMOVEPAGEHANDLE(this=0x1327a1a0, APAGE=0x13291cb0) at customnotebook.inc:746
  27.     frame #16: 0x002301ec lazarus`CREATEWND(this=0x1327a1a0) at customnotebook.inc:313
  28.     frame #17: 0x00212d61 lazarus`CREATEHANDLE(this=0x1327a1a0) at wincontrol.inc:7463
  29.     frame #18: 0x00214101 lazarus`HANDLENEEDED(this=0x1327a1a0) at wincontrol.inc:7913
  30.     frame #19: 0x002136fd lazarus`CREATEWND(this=0x13279610) at wincontrol.inc:7598
  31.     frame #20: 0x00212d61 lazarus`CREATEHANDLE(this=0x13279610) at wincontrol.inc:7463
  32.     frame #21: 0x00214101 lazarus`HANDLENEEDED(this=0x13279610) at wincontrol.inc:7913
  33.     frame #22: 0x002136fd lazarus`CREATEWND(this=0x13279270) at wincontrol.inc:7598
  34.     frame #23: 0x00212d61 lazarus`CREATEHANDLE(this=0x13279270) at wincontrol.inc:7463
  35.     frame #24: 0x00214101 lazarus`HANDLENEEDED(this=0x13279270) at wincontrol.inc:7913
  36.     frame #25: 0x002136fd lazarus`CREATEWND(this=0x131ff790) at wincontrol.inc:7598
  37.     frame #26: 0x00212d61 lazarus`CREATEHANDLE(this=0x131ff790) at wincontrol.inc:7463
  38.     frame #27: 0x00214101 lazarus`HANDLENEEDED(this=0x131ff790) at wincontrol.inc:7913
  39.     frame #28: 0x002136fd lazarus`CREATEWND(this=0x13278e90) at wincontrol.inc:7598
  40.     frame #29: 0x00230172 lazarus`CREATEWND(this=0x13278e90) at customnotebook.inc:303
  41.     frame #30: 0x00212d61 lazarus`CREATEHANDLE(this=0x13278e90) at wincontrol.inc:7463
  42.     frame #31: 0x00214101 lazarus`HANDLENEEDED(this=0x13278e90) at wincontrol.inc:7913
  43.     frame #32: 0x002136fd lazarus`CREATEWND(this=0x131ff3f0) at wincontrol.inc:7598
  44.     frame #33: 0x00212d61 lazarus`CREATEHANDLE(this=0x131ff3f0) at wincontrol.inc:7463
  45.     frame #34: 0x00214101 lazarus`HANDLENEEDED(this=0x131ff3f0) at wincontrol.inc:7913
  46.     frame #35: 0x002136fd lazarus`CREATEWND(this=0x131ff050) at wincontrol.inc:7598
  47.     frame #36: 0x00212d61 lazarus`CREATEHANDLE(this=0x131ff050) at wincontrol.inc:7463
  48.     frame #37: 0x00214101 lazarus`HANDLENEEDED(this=0x131ff050) at wincontrol.inc:7913
  49.     frame #38: 0x002d70de lazarus`ADDPAGE(self=0x09ae2ce0, ATABCONTROL=0x133af2c0, ACHILD=0x131ff050, AINDEX=2) at cocoawscomctrls.pas:542
  50.     frame #39: 0x00230ffc lazarus`ADDREMOVEPAGEHANDLE(this=0x133af2c0, APAGE=0x131ff050) at customnotebook.inc:746
  51.     frame #40: 0x002301ec lazarus`CREATEWND(this=0x133af2c0) at customnotebook.inc:313
  52.     frame #41: 0x00212d61 lazarus`CREATEHANDLE(this=0x133af2c0) at wincontrol.inc:7463
  53.     frame #42: 0x00214101 lazarus`HANDLENEEDED(this=0x133af2c0) at wincontrol.inc:7913
  54.     frame #43: 0x002136fd lazarus`CREATEWND(this=0x133aee20) at wincontrol.inc:7598
  55.     frame #44: 0x0006a6d3 lazarus`CREATEWND(this=0x133aee20) at scrollingwincontrol.inc:23
  56.     frame #45: 0x000722e6 lazarus`CREATEWND(this=0x133aee20) at customform.inc:2703
  57.     frame #46: 0x00073464 lazarus`CREATEWND(this=0x133aee20) at customform.inc:3171
  58.     frame #47: 0x00212d61 lazarus`CREATEHANDLE(this=0x133aee20) at wincontrol.inc:7463
  59.     frame #48: 0x00214101 lazarus`HANDLENEEDED(this=0x133aee20) at wincontrol.inc:7913
  60.     frame #49: 0x002140e7 lazarus`HANDLENEEDED(this=0x133af2c0) at wincontrol.inc:7907
  61.     frame #50: 0x002140e7 lazarus`HANDLENEEDED(this=0x132a7170) at wincontrol.inc:7907
  62.     frame #51: 0x002140e7 lazarus`HANDLENEEDED(this=0x132a7510) at wincontrol.inc:7907
  63.     frame #52: 0x002140e7 lazarus`HANDLENEEDED(this=0x132a78b0) at wincontrol.inc:7907
  64.     frame #53: 0x002140e7 lazarus`HANDLENEEDED(this=0x132a7c50) at wincontrol.inc:7907
  65.     frame #54: 0x002140e7 lazarus`HANDLENEEDED(this=0x0869d4b0) at wincontrol.inc:7907
  66.     frame #55: 0x002140e7 lazarus`HANDLENEEDED(this=0x0869dc20) at wincontrol.inc:7907
  67.     frame #56: 0x002140e7 lazarus`HANDLENEEDED(this=0x134edda0) at wincontrol.inc:7907
  68.     frame #57: 0x002140e7 lazarus`HANDLENEEDED(this=0x134d9030) at wincontrol.inc:7907
  69.     frame #58: 0x002115cf lazarus`GETHANDLE(this=0x134d9030) at wincontrol.inc:6524
  70.     frame #59: 0x00fbcf2f lazarus`CMSCOMBOBOX$_$TMSCOMBOBOX_$__$$_INITCALCHEIGHTDATA + 143
  71.     frame #60: 0x00fbc897 lazarus`CMSCOMBOBOX$_$TMSCOMBOBOX_$__$$_SETIMAGES$TIMAGELIST + 71
  72.     frame #61: 0x00121a57 lazarus`TYPINFO_$$_SETPOINTERPROP$TOBJECT$PPROPINFO$POINTER + 135
  73.     frame #62: 0x00121b79 lazarus`TYPINFO_$$_SETOBJECTPROP$TOBJECT$PPROPINFO$TOBJECT + 9
  74.     frame #63: 0x000ec508 lazarus`CLASSES$_$TREADER_$__$$_DOFIXUPREFERENCES + 664
  75.     frame #64: 0x000ed24c lazarus`CLASSES$_$TREADER_$__$$_READDATA$TCOMPONENT + 236
  76.     frame #65: 0x000e38cf lazarus`CLASSES$_$TCOMPONENT_$__$$_READSTATE$TREADER + 15
  77.     frame #66: 0x0021e0e0 lazarus`READSTATE(this=0x133aee20, READER=0x126f2650) at control.inc:3947
  78.     frame #67: 0x000ee77b lazarus`CLASSES$_$TREADER_$__$$_READROOTCOMPONENT$TCOMPONENT$$TCOMPONENT + 683
  79.     frame #68: 0x004a0208 lazarus`READSTREAM(parentfp=0xbfffe618, ASTREAM=0x12f16540, STREAMCLASS=0x133ae4e0) at jitforms.pp:875
  80.     frame #69: 0x0049fd51 lazarus`ADDJITCOMPONENTFROMSTREAM(this=0x039fece0, BINSTREAM=0x12f16540, UNITRESOURCEFILEFORMAT=0x0152f528, ANCESTORCLASS=0x133c0810, NEWUNITNAME=SHORTSTRING @ 0xbfffe7f4, INTERACTIVE=true, VISIBLE=true, DISABLEAUTOSIZE=true, CONTEXTOBJ=0x09bb4440) at jitforms.pp:944
  81.     frame #70: 0x004bf2bc lazarus`CREATERAWCOMPONENTFROMSTREAM(this=0x09975800, BINSTREAM=0x12f16540, UNITRESOURCEFILEFORMAT=0x0152f528, ANCESTORTYPE=0x133c0810, NEWUNITNAME=SHORTSTRING @ 0xbfffe7f4, INTERACTIVE=true, VISIBLE=true, DISABLEAUTOSIZE=true, CONTEXTOBJ=0x09bb4440) at customformeditor.pp:1583
  82.     frame #71: 0x006b6311 lazarus`LOADLFM(this=0x08b23a20, ANUNITINFO=0x09bb4440, LFMBUF=0x1276abe0, OPENFLAGS=<unavailable>, CLOSEFLAGS=<unavailable>) at sourcefilemanager.pas:6517
  83.     frame #72: 0x006b58f2 lazarus`LOADLFM(this=0x08b23a20, ANUNITINFO=0x09bb4440, OPENFLAGS=<unavailable>, CLOSEFLAGS=<unavailable>) at sourcefilemanager.pas:6313
  84.     frame #73: 0x006a287d lazarus`OPENRESOURCE(this=0x039c9d60) at sourcefilemanager.pas:899
  85.     frame #74: 0x006a43c1 lazarus`OPENEDITORFILE(this=0x039c9d60, APAGEINDEX=-1, AWINDOWINDEX=0, AEDITORINFO=0x09cbe720, AFLAGS=<unavailable>) at sourcefilemanager.pas:1420
  86.     frame #75: 0x006a140e lazarus`OPENEDITORFILE(AFILENAME="/Volumes/DiskW/projects-cool-name/company-tool/front_form.pas", PAGEINDEX=-1, WINDOWINDEX=0, AEDITORINFO=0x09cbe720, FLAGS=<unavailable>, USEWINDOWID=true) at sourcefilemanager.pas:416
  87.     frame #76: 0x006acbd3 lazarus`INITOPENEDPROJECTFILE(this=0x08b23a20, AFILENAME="/Volumes/DiskW/company-tool/front_form/ToolLazarusOSX.lpi", FLAGS=<unavailable>) at sourcefilemanager.pas:4063
  88.     frame #77: 0x0009dbdc lazarus`DOOPENPROJECTFILE(this=0x077c2020, AFILENAME="/Volumes/DiskW/projects-cool-thomas/Micro-Sys-SiteMap/SitemapLazarusOSX.lpi", FLAGS=<unavailable>) at main.pp:6407
  89.     frame #78: 0x006a3ff5 lazarus`OPENEDITORFILE(this=0x09cbdaa0, APAGEINDEX=-1, AWINDOWINDEX=-1, AEDITORINFO=0x00000000, AFLAGS=<unavailable>) at sourcefilemanager.pas:1327
  90.     frame #79: 0x006a140e lazarus`OPENEDITORFILE(AFILENAME="/Volumes/DiskW/company-tool/front_form/ToolLazarusOSX.lpi", PAGEINDEX=-1, WINDOWINDEX=-1, AEDITORINFO=0x00000000, FLAGS=<unavailable>, USEWINDOWID=false) at sourcefilemanager.pas:416
  91.     frame #80: 0x0009b7d4 lazarus`DOOPENEDITORFILE(this=0x077c2020, AFILENAME="/Volumes/DiskW/company-tool/front_form/ToolLazarusOSX.lpi", PAGEINDEX=-1, WINDOWINDEX=-1, AEDITORINFO=0x00000000, FLAGS=<unavailable>) at main.pp:5680
  92.     frame #81: 0x0009b757 lazarus`DOOPENEDITORFILE(this=0x077c2020, AFILENAME="/Volumes/DiskW/company-tool/front_form/ToolLazarusOSX.lpi", PAGEINDEX=-1, WINDOWINDEX=-1, FLAGS=<unavailable>) at main.pp:5674
  93.     frame #82: 0x000921a9 lazarus`MNUOPENCLICKED(this=0x077c2020, SENDER=0x09977510) at main.pp:3013
  94.     frame #83: 0x004105e9 lazarus`DOONCLICK(this=0x09977510, SENDER=0x09977510) at idecommands.pas:1620
  95.     frame #84: 0x0041060a lazarus`DOONCLICK(this=0x09977510) at idecommands.pas:1625
  96.     frame #85: 0x0043afb9 lazarus`CLICK(this=0x0a0c8770) at toolbarintf.pas:620
  97.     frame #86: 0x00242275 lazarus`MOUSEUP(this=0x0a0c8770, BUTTON=MBLEFT, SHIFT=<unavailable>, X=11, Y=11) at toolbutton.inc:175
  98.     frame #87: 0x0021ac8d lazarus`DOMOUSEUP(this=0x0a0c8770, MESSAGE=TLMMOUSE @ 0xbffff278, BUTTON=MBLEFT) at control.inc:2303
  99.     frame #88: 0x0021b87b lazarus`WMLBUTTONUP(this=0x0a0c8770, MESSAGE=TLMMOUSE @ 0xbffff278) at control.inc:2785
  100.     frame #89: 0x00024481 lazarus`SYSTEM$_$TOBJECT_$__$$_DISPATCH$formal + 145
  101.     frame #90: 0x0021aaca lazarus`WNDPROC(this=0x0a0c8770, THEMESSAGE=TLMESSAGE @ 0xbffff278) at control.inc:2243
  102.     frame #91: 0x00219544 lazarus`PERFORM(this=0x0a0c8770, MSG=514, WPARAM=0, LPARAM=720907) at control.inc:1581
  103.     frame #92: 0x0020e230 lazarus`ISCONTROLMOUSEMSG(this=0x09af0bf0, THEMESSAGE=<unavailable>) at wincontrol.inc:4763
  104.     frame #93: 0x0020f4ef lazarus`WNDPROC(this=0x09af0bf0, MESSAGE=TLMESSAGE @ 0xbffff438) at wincontrol.inc:5390
  105.     frame #94: 0x001fe4f1 lazarus`DELIVERMESSAGE(TARGET=0x09af0bf0, AMESSAGE=<unavailable>) at lclmessageglue.pas:112
  106.     frame #95: 0x002b6bbb lazarus`DELIVERMESSAGE(this=0x09c8be00, MSG=<unavailable>) at cocoawscommon.pas:1494
  107.     frame #96: 0x002b6206 lazarus`MOUSEUPDOWNEVENT(this=0x09c8be00, EVENT=0x03a48180, AFORCEASMOUSEUP=false, AOVERRIDEBLOCK=false) at cocoawscommon.pas:1197
  108.     frame #97: 0x002b5ea6 lazarus`MOUSEUPDOWNEVENT(this=0x09c8be00, EVENT=0x03a48180, AFORCEASMOUSEUP=false, AOVERRIDEBLOCK=false) at cocoawscommon.pas:1126
  109.     frame #98: 0x001e7295 lazarus`"-[TCocoaCustomControl mouseUp:]"(self=0x0aa8a490, _cmd="mouseUp:", EVENT=0x03a48180) at cocoaprivate.pp:621
  110.     frame #99: 0x91c8eb12 AppKit`-[NSWindow(NSEventRouting) _reallySendEvent:isDelayedEvent:] + 672
  111.     frame #100: 0x91c8e4c0 AppKit`-[NSWindow(NSEventRouting) sendEvent:] + 475
  112.     frame #101: 0x001fae11 lazarus`"-[TCocoaWindow sendEvent:]"(self=0x03b61580, _cmd="sendEvent:", EVENT=0x03a48180) at cocoawindows.pas:876
  113.     frame #102: 0x91aeb2d1 AppKit`-[NSApplication(NSEvent) sendEvent:] + 2657
  114.     frame #103: 0x001dc0dc lazarus`"-[TCocoaApplication sendEvent:]"(self=0x03a235e0, _cmd="sendEvent:", THEEVENT=0x03a48180) at cocoaint.pas:398
  115.     frame #104: 0x001dc72b lazarus`APPWAITMESSAGE(this=0x03c98020) at cocoaobject.inc:134
  116.     frame #105: 0x000778ca lazarus`IDLE(this=0x03c406a0, WAIT=true) at application.inc:414
  117.     frame #106: 0x0007969e lazarus`HANDLEMESSAGE(this=0x03c406a0) at application.inc:1283
  118.     frame #107: 0x00079b4c lazarus`RUNLOOP(this=0x03c406a0) at application.inc:1419
  119.     frame #108: 0x001dc02a lazarus`"-[TCocoaApplication run]"(self=0x03a235e0, _cmd="run") at cocoaint.pas:388
  120.     frame #109: 0x001dc442 lazarus`APPRUN(this=0x03c98020, ALOOP=(Proc = <Unable to determine byte size.>, Self = 0x03c406a0)) at cocoaobject.inc:84
  121.     frame #110: 0x00079afd lazarus`RUN(this=0x03c406a0) at application.inc:1407
  122.     frame #111: 0x00011430 lazarus`PASCALMAIN at lazarus.pp:153
  123.     frame #112: 0x000353c1 lazarus`FPC_SysEntry + 17
  124.     frame #113: 0x00011151 lazarus`FPC_SYSTEMMAIN + 81
  125.     frame #114: 0x000111a0 lazarus`main(ARGC=1, ARGV=0xbffffb3c, ARGP=0xbffffb44) + 32
  126.     frame #115: 0x000110df lazarus`_start + 198
  127.     frame #116: 0x00011018 lazarus`start + 40
  128. (lldb)
  129.  



I am currently reviewing my code inside my TmsButtonControl - no clear suspects so far but will be researching and reporting back
« Last Edit: August 11, 2018, 04:23:11 pm by MISV »

MISV

  • Sr. Member
  • ****
  • Posts: 493
It seems the warnings "Handle not Allocated" and "obsolete call to CreareWnd" have earlier caused issues for other (long while back though), so I do not think those warnings are related to the issue DFM read error / access violation / EXC_BAD_ACCESS

For reference with other who have had the same issue (2016ish):
https://forum.lazarus.freepascal.org/index.php?topic=35597.0
https://forum.lazarus.freepascal.org/index.php?topic=33530.45



Reported issue here
https://bugs.freepascal.org/view.php?id=34114
« Last Edit: August 11, 2018, 05:53:17 pm by MISV »

MISV

  • Sr. Member
  • ****
  • Posts: 493
Update: Problem also happens when using a standard TListView from LCL - I have submitted a demo in the bug report!

(For those interested, my TmsListView is a thin wrapper I use to help get me better Delphi/Lazarus DFM/LFM compability, with regards to CreateWND, only thing done in Lazarus is calling inherited)



Here is relevant debug log:

Quote
thread 0000001, queue = 'com.apple.main-thread', stop reason = EXC_BAD_ACCESS (code=1, address=0x24)
  * frame #0: 0xa678f163 libobjc.A.dylib`objc_msgSend + 19
    frame 0000001: 0xa678f0af libobjc.A.dylib`objc_retain + 29
    frame 0000002: 0x91657924 AppKit`-[NSTableView removeTableColumn:] + 29
    frame 0000003: 0x002d7a52 lazarus`COLUMNDELETE(self=0x0a06aef0, ALV=0x13292050, AINDEX=4) at cocoawscomctrls.pas:747
    frame 0000004: 0x00236c95 lazarus`WSDESTROYCOLUMN(this=0x13426620) at listcolumn.inc:105
    frame 0000005: 0x00236752 lazarus`WSCREATECOLUMNS(this=0x12a69430) at listcolumns.inc:91
    frame 0000006: 0x0023c571 lazarus`INITIALIZEWND(this=0x13292050) at customlistview.inc:534
    frame 0000007: 0x0021361c lazarus`CREATEWND(this=0x13292050) at wincontrol.inc:7579
    frame 0000008: 0x00fc9a2e lazarus`UMSCONTROLS$_$TMSLISTVIEW_$__$$_CREATEWND + 14
    frame 0000009: 0x00212d61 lazarus`CREATEHANDLE(this=0x13292050) at wincontrol.inc:7463
« Last Edit: August 11, 2018, 05:52:48 pm by MISV »

MISV

  • Sr. Member
  • ****
  • Posts: 493
More information + workaround:

If you have have zero columns at designtime in the tlistview = the form will load correctly in the IDE

However, my demo project with multiple columns triggers the problem when being loaded in the IDE


« Last Edit: August 13, 2018, 12:23:40 am by MISV »

MISV

  • Sr. Member
  • ****
  • Posts: 493
This workaround solution is not sufficient though - it will happen at runtime whenever InitializeWND is called in customlistview and the listview has any columns (since LCL code will try remove all existing columns which fails somehow in syncning with underlying cocoa)


skalogryz

  • Global Moderator
  • Hero Member
  • *****
  • Posts: 2030
    • havefunsoft.com
did you try the latest trunk?
Patron Cocoa Widgetset development https://www.patreon.com/skalogryz

MISV

  • Sr. Member
  • ****
  • Posts: 493
Trunk in use was 11th August.

However, using fpcupdeluxe now to get latest trunk I get the following error:

Quote
/Users/examplename/EN/lazaruscoc/lazarus/lcl/interfaces/./cocoa/cocoawinapi.inc(206,5) Error: (3026) Wrong number of parameters specified for call to "Move"
/Users/examplename/EN/lazaruscoc/fpc/units/i386-darwin/univint/MacOSAll.ppu:Quickdraw.pas(882,11) Error: (5088) Found declaration: Move(SmallInt;SmallInt);
cocoaint.pas(404) Fatal: (10026) There were 2 errors compiling module, stopping
Fatal: (1018) Compilation aborted
Error: /Users/examplename/EN/lazaruscoc/fpc/bin/i386-darwin/ppc386 returned an error exitcode
Error: (lazarus) Compile package LCL 1.9: stopped with exit code 256
Error: (lazarus) [TLazPackageGraph.CompileRequiredPackages] "Exit code 256"

fpcupdeluxe: ERROR: UniversalInstaller (ConfigModule: suggestedpackages): Failure trying to rebuild Lazarus.
Details:


ERROR: Fpcupdeluxe fatal error !

- reported: https://bugs.freepascal.org/view.php?id=34132

(however, above is i386/cocoa - I will try 64bit)
« Last Edit: August 15, 2018, 09:51:57 am by MISV »

MISV

  • Sr. Member
  • ****
  • Posts: 493
Seems to have been solved in latest trunks! :)