Re: [code] [textadept] Textadept 10.0 alpha

From: Mitchell <m.att.foicica.com>
Date: Tue, 2 Jan 2018 13:22:41 -0500 (EST)

Hi Robert,

On Tue, 2 Jan 2018, Robert Gieseke wrote:

> Happy New Year!
>
> This looks very nice, and I had no big problems migrating. However, with
> some old code that includes `brace_match` with only one argument I get
> crashes when closing the message buffer:
>
> Thread 0 Crashed:: Dispatch queue: com.apple.main-thread
> 0 textadept 0x0004ccde std::_Rb_tree<std::string,
> std::pair<std::string const, std::string>,
> std::_Select1st<std::pair<std::string const, std::string> >,
> std::less<std::string>, std::allocator<std::pair<std::string const,
> std::string> > >::find(std::string const&) + 12
> 1 textadept 0x0004c5fb PropSetSimple::Get(char
> const*) const + 51
> 2 textadept 0x0006873d
> LexerLPeg::llexer_property(lua_State*) + 629
> 3 textadept 0x000778ac luaD_precall + 198
> 4 textadept 0x00077c42 luaD_call + 91
> 5 textadept 0x0008103c luaT_callTM + 149
> 6 textadept 0x00082029 luaV_finishget + 198
> 7 textadept 0x0008346f luaV_execute + 1217
> 8 textadept 0x00077c4e luaD_call + 103
> 9 textadept 0x00077c7c luaD_callnoyield + 36
> 10 textadept 0x00081051 luaT_callTM + 170
> 11 textadept 0x00082029 luaV_finishget + 198
> 12 textadept 0x00073521 lua_gettable + 208
> 13 textadept 0x00066a98
> LexerLPeg::lL_getexpanded(lua_State*, int) + 122
> 14 textadept 0x00068e58
> LexerLPeg::PropertySet(char const*, char const*) + 440
> 15 textadept 0x00041e3a LexState::PropSet(char
> const*, char const*) + 82
> 16 textadept 0x0004418d
> ScintillaBase::WndProc(unsigned int, unsigned long, long) + 2073
> 17 textadept 0x00059c1c
> ScintillaGTK::WndProc(unsigned int, unsigned long, long) + 430
> 18 textadept 0x0006ba72 l_callscintilla + 552
> 19 textadept 0x0006be82 lbuf_property + 969
> 20 textadept 0x000778ac luaD_precall + 198
> 21 textadept 0x00077c42 luaD_call + 91
> 22 textadept 0x0008103c luaT_callTM + 149
> 23 textadept 0x00082b21 luaV_finishset + 337
> 24 textadept 0x0008322a luaV_execute + 636
> 25 textadept 0x00077c4e luaD_call + 103
> 26 textadept 0x00077c7c luaD_callnoyield + 36
> 27 textadept 0x00071db8 f_call + 33
> 28 textadept 0x000771ab luaD_rawrunprotected + 70
> 29 textadept 0x00077cfe luaD_pcall + 73
> 30 textadept 0x00072786 lua_pcallk + 193
> 31 textadept 0x000870f4 luaB_pcall + 121
> 32 textadept 0x000778ac luaD_precall + 198
> 33 textadept 0x000843b2 luaV_execute + 5124
> 34 textadept 0x00077c4e luaD_call + 103
> 35 textadept 0x00077c7c luaD_callnoyield + 36
> 36 textadept 0x00071db8 f_call + 33
> 37 textadept 0x000771ab luaD_rawrunprotected + 70
> 38 textadept 0x00077cfe luaD_pcall + 73
> 39 textadept 0x00072786 lua_pcallk + 193
> 40 textadept 0x0006e785 lL_event + 364
> 41 textadept 0x0006f7fb new_view + 1030
> 42 textadept 0x00070e6a lview_split + 317
> 43 textadept 0x000778ac luaD_precall + 198
> 44 textadept 0x000843b2 luaV_execute + 5124
> 45 textadept 0x00077c4e luaD_call + 103
> 46 textadept 0x00077c7c luaD_callnoyield + 36
> 47 textadept 0x00071db8 f_call + 33
> 48 textadept 0x000771ab luaD_rawrunprotected + 70
> 49 textadept 0x00077cfe luaD_pcall + 73
> 50 textadept 0x00072786 lua_pcallk + 193
> 51 textadept 0x000870f4 luaB_pcall + 121
> 52 textadept 0x000778ac luaD_precall + 198
> 53 textadept 0x000843b2 luaV_execute + 5124
> 54 textadept 0x00077c4e luaD_call + 103
> 55 textadept 0x00077c7c luaD_callnoyield + 36
> 56 textadept 0x00071db8 f_call + 33
> 57 textadept 0x000771ab luaD_rawrunprotected + 70
> 58 textadept 0x00077cfe luaD_pcall + 73
> 59 textadept 0x00072786 lua_pcallk + 193
> 60 textadept 0x000870f4 luaB_pcall + 121
> 61 textadept 0x000778ac luaD_precall + 198
> 62 textadept 0x000843b2 luaV_execute + 5124
> 63 textadept 0x00077c4e luaD_call + 103
> 64 textadept 0x00077c7c luaD_callnoyield + 36
> 65 textadept 0x00071db8 f_call + 33
> 66 textadept 0x000771ab luaD_rawrunprotected + 70
> 67 textadept 0x00077cfe luaD_pcall + 73
> 68 textadept 0x00072786 lua_pcallk + 193
> 69 textadept 0x000870f4 luaB_pcall + 121
> 70 textadept 0x000778ac luaD_precall + 198
> 71 textadept 0x000843b2 luaV_execute + 5124
> 72 textadept 0x00077c4e luaD_call + 103
> 73 textadept 0x00077c7c luaD_callnoyield + 36
> 74 textadept 0x00071db8 f_call + 33
> 75 textadept 0x000771ab luaD_rawrunprotected + 70
> 76 textadept 0x00077cfe luaD_pcall + 73
> 77 textadept 0x00072786 lua_pcallk + 193
> 78 textadept 0x0006e785 lL_event + 364
> 79 textadept 0x00071141 lbuffer_delete + 200
> 80 textadept 0x000778ac luaD_precall + 198
> 81 textadept 0x000843b2 luaV_execute + 5124
> 82 textadept 0x00077c4e luaD_call + 103
> 83 textadept 0x00077c7c luaD_callnoyield + 36
> 84 textadept 0x00071db8 f_call + 33
> 85 textadept 0x000771ab luaD_rawrunprotected + 70
> 86 textadept 0x00077cfe luaD_pcall + 73
> 87 textadept 0x00072786 lua_pcallk + 193
> 88 textadept 0x00086ffd luaB_xpcall + 148
> 89 textadept 0x000778ac luaD_precall + 198
> 90 textadept 0x000843b2 luaV_execute + 5124
> 91 textadept 0x00077c4e luaD_call + 103
> 92 textadept 0x00077c7c luaD_callnoyield + 36
> 93 textadept 0x00071db8 f_call + 33
> 94 textadept 0x000771ab luaD_rawrunprotected + 70
> 95 textadept 0x00077cfe luaD_pcall + 73
> 96 textadept 0x00072786 lua_pcallk + 193
> 97 textadept 0x000870f4 luaB_pcall + 121
> 98 textadept 0x000778ac luaD_precall + 198
> 99 textadept 0x000843b2 luaV_execute + 5124
> 100 textadept 0x00077c4e luaD_call + 103
> 101 textadept 0x00077c7c luaD_callnoyield + 36
> 102 textadept 0x00071db8 f_call + 33
> 103 textadept 0x000771ab luaD_rawrunprotected + 70
> 104 textadept 0x00077cfe luaD_pcall + 73
> 105 textadept 0x00072786 lua_pcallk + 193
> 106 textadept 0x0006e785 lL_event + 364
> 107 textadept 0x0006eb08 s_keypress + 226
> 108 libgtk-quartz-2.0.0.dylib 0x002377b9
> _gtk_marshal_BOOLEAN__BOXED + 225
> 109 libgobject-2.0.0.dylib 0x00a69606 g_closure_invoke + 366
> 110 libgobject-2.0.0.dylib 0x00a832ba signal_emit_unlocked_R + 1320
> 111 libgobject-2.0.0.dylib 0x00a8283d g_signal_emit_valist + 3670
> 112 libgobject-2.0.0.dylib 0x00a82c53 g_signal_emit + 44
> 113 libgtk-quartz-2.0.0.dylib 0x003a7c5d gtk_widget_event_internal
> + 844
> 114 libgtk-quartz-2.0.0.dylib 0x003a76de gtk_widget_event + 283
> 115 libgtk-quartz-2.0.0.dylib 0x003bddbb
> gtk_window_propagate_key_event + 220
> 116 libgtk-quartz-2.0.0.dylib 0x003bde7a gtk_window_key_press_event
> + 77
> 117 libgtk-quartz-2.0.0.dylib 0x002377b9
> _gtk_marshal_BOOLEAN__BOXED + 225
> 118 libgobject-2.0.0.dylib 0x00a69c61 g_type_class_meta_marshal + 97
> 119 libgobject-2.0.0.dylib 0x00a69606 g_closure_invoke + 366
> 120 libgobject-2.0.0.dylib 0x00a83419 signal_emit_unlocked_R + 1671
> 121 libgobject-2.0.0.dylib 0x00a8283d g_signal_emit_valist + 3670
> 122 libgobject-2.0.0.dylib 0x00a82c53 g_signal_emit + 44
> 123 libgtk-quartz-2.0.0.dylib 0x003a7c5d gtk_widget_event_internal
> + 844
> 124 libgtk-quartz-2.0.0.dylib 0x003a76de gtk_widget_event + 283
> 125 libgtk-quartz-2.0.0.dylib 0x00235cc7 gtk_propagate_event + 519
> 126 libgtk-quartz-2.0.0.dylib 0x002347f7 gtk_main_do_event + 1211
> 127 libgdk-quartz-2.0.0.dylib 0x00652ed2 gdk_event_dispatch + 255
> 128 libglib-2.0.0.dylib 0x00aecaf8 g_main_dispatch + 399
> 129 libglib-2.0.0.dylib 0x00aed771 g_main_context_dispatch + 41
> 130 libglib-2.0.0.dylib 0x00aed950 g_main_context_iterate + 466
> 131 libglib-2.0.0.dylib 0x00aedd82 g_main_loop_run + 476
> 132 libgtk-quartz-2.0.0.dylib 0x00233ca5 gtk_main + 239
> 133 textadept 0x00070cf4 main + 860
> 134 textadept 0x00001c5a start + 54
>
> It's no problem because I can remove the matching code but maybe this
> points to another issue.

Scintilla's API can be picky. If you try to pass parameters of any type other than the expected one, unexpected things may happen. I will take a look into this and consider any necessary adjustments though.

Cheers,
Mitchell

-- 
You are subscribed to code.att.foicica.com.
To change subscription settings, send an e-mail to code+help.att.foicica.com.
To unsubscribe, send an e-mail to code+unsubscribe.att.foicica.com.
Received on Tue 02 Jan 2018 - 13:22:41 EST

This archive was generated by hypermail 2.2.0 : Wed 03 Jan 2018 - 06:45:43 EST