summary refs log tree commit diff stats
path: root/tests/threads
Commit message (Collapse)AuthorAgeFilesLines
* make tests green againAraq2018-11-161-1/+1
|
* Remove install.txt and readme.txt (#9521)Utwo2018-10-281-2/+2
| | | | | | | | * Remove install.txt and readme.txt * Refactor tests that use readme.txt * Tests open own source code
* Fixes 8535 (#8591)LemonBoy2018-08-171-0/+16
| | | | | | | | | | | | | | | | | | | * Goodbye postInitProc * Give preInitProc its own scope Avoid any conflict between the variables introduced by preInitProc and initProc since both are codegen'd in the same function body. * Fix codegen for global var init in emulated TLS Fixes #8535 * Add test for #8535 * Keep a bogus stack frame around * Remove more dead code
* fixes more nil handling regressionsAraq2018-08-131-2/+2
|
* fixes channels for --gc:regionsAndreas Rumpf2018-05-251-2/+2
|
* Support thread-local variables declared inside procs; fixes #7565Zahary Karadjov2018-05-071-0/+78
|
* the parser finally parses 'echo {1,2}' as it shouldAndreas Rumpf2017-09-302-2/+2
|
* Fixes #4719. (#5585)Eugene Kabanov2017-03-232-0/+58
|
* Update testament to include all tests from tests/threads category. (#5576)Eugene Kabanov2017-03-203-0/+3
|
* removed onThreadCreation; onThreadDestruction is now thread localAraq2017-02-261-7/+4
|
* added a testcase for getThreadIdAraq2017-01-311-0/+5
|
* added test case; threadex example crashes nowAraq2017-01-301-0/+25
|
* onThreadDestruction feature added to Nim's threading modelAndreas Rumpf2017-01-241-1/+6
|
* added system.onThreadCreation feature for safe thread local storage ↵Andreas Rumpf2017-01-181-0/+22
| | | | initializations
* moved random procs from math to its own module (breaking change)Andreas Rumpf2016-05-301-1/+1
|
* Consistently use Channel instead of TChanneldef2016-02-252-3/+3
|
* Fix a few deprecation warningsdef2016-01-255-5/+5
|
* tests: Trim .nim files trailing whitespaceAdam Strzelecki2015-09-046-8/+8
| | | | via OSX: find . -name '*.nim' -exec sed -i '' -E 's/[[:space:]]+$//' {} +
* fixes #1816Araq2015-01-021-0/+35
|
* further adaptationsAraq2014-08-293-3/+3
|
* renamed babelcmd to nimblecmd; config files are now nim.cfg; other renamingsAraq2014-08-291-0/+0
|
* asynchttpserver compiles again; made some tests greenAraq2014-08-132-4/+4
|
* removed flawed thread analysis passAraq2014-04-202-54/+3
|
* Tester now appreciates the test target. Modified 'cmd' in specs.Dominik Picheta2014-04-164-4/+4
|
* made some tests greenAraq2014-03-271-1/+3
|
* fix #931 and few more testsZahary Karadjov2014-02-181-0/+1
|
* Removes executable bit for text files.Grzegorz Adam Hankiewicz2013-03-164-0/+0
|
* added tactors2 testAraq2012-09-211-0/+25
|
* fixes #71; sorry about the polling implementationAraq2011-12-051-0/+19
|
* fixes 70Araq2011-12-041-4/+4
|
* deprecated endOfFile and readLineAraq2011-11-251-4/+4
|
* fixed bug that kept tls emulation from workingAraq2011-11-251-16/+15
|
* bugfix: 'when' sections in generic objects now work, so TThread[void] compilesAraq2011-11-201-1/+1
|
* tester: threading tests addedAraq2011-11-193-2/+59
|
* bugfix: fixed memory leaks in osproc moduleAraq2011-11-183-2/+18
|
* locks now in their own core moduleAraq2011-08-202-6/+0
|
* first steps to explicit channels for thread communication; added mainThreadIdAraq2011-07-161-5/+3
|
* preparations for 0.8.12Araq2011-07-104-0/+167
an> = DEFMODE; void detach(Client *c) { if(c->prev) c->prev->next = c->next; if(c->next) c->next->prev = c->prev; if(c == clients) clients = c->next; c->next = c->prev = NULL; } void dofloat(Arg *arg) { Client *c; maximized = False; for(c = clients; c; c = c->next) { if(isvisible(c)) { resize(c, True, TopLeft); } else ban(c); } if(!sel || !isvisible(sel)) { for(c = stack; c && !isvisible(c); c = c->snext); focus(c); } restack(); } void dotile(Arg *arg) { int h, i, n, w; Client *c; maximized = False; w = sw - mw; for(n = 0, c = clients; c; c = c->next) if(isvisible(c) && !c->isfloat) n++; if(n > 1) h = (sh - bh) / (n - 1); else h = sh - bh; for(i = 0, c = clients; c; c = c->next) { if(isvisible(c)) { if(c->isfloat) { resize(c, True, TopLeft); continue; } if(n == 1) { c->x = sx; c->y = sy + bh; c->w = sw - 2; c->h = sh - 2 - bh; } else if(i == 0) { c->x = sx; c->y = sy + bh; c->w = mw - 2; c->h = sh - 2 - bh; } else if(h > bh) { c->x = sx + mw; c->y = sy + (i - 1) * h + bh; c->w = w - 2; if(i + 1 == n) c->h = sh - c->y - 2; else c->h = h - 2; } else { /* fallback if h < bh */ c->x = sx + mw; c->y = sy + bh; c->w = w - 2; c->h = sh - 2 - bh; } resize(c, False, TopLeft); i++; } else ban(c); } if(!sel || !isvisible(sel)) { for(c = stack; c && !isvisible(c); c = c->snext); focus(c); } restack(); } void focusnext(Arg *arg) { Client *c; if(!sel) return; if(!(c = getnext(sel->next))) c = getnext(clients); if(c) { focus(c); restack(); } } void focusprev(Arg *arg) { Client *c; if(!sel) return; if(!(c = getprev(sel->prev))) { for(c = clients; c && c->next; c = c->next); c = getprev(c); } if(c) { focus(c); restack(); } } Bool isvisible(Client *c) { unsigned int i; for(i = 0; i < ntags; i++) if(c->tags[i] && seltag[i]) return True; return False; } void resizecol(Arg *arg) { unsigned int n; Client *c; for(n = 0, c = clients; c; c = c->next) if(isvisible(c) && !c->isfloat) n++; if(!sel || sel->isfloat || n < 2 || (arrange != dotile) || maximized) return; if(sel == getnext(clients)) { if(mw + arg->i > sw - 100 || mw + arg->i < 100) return; mw += arg->i; } else { if(mw - arg->i > sw - 100 || mw - arg->i < 100) return; mw -= arg->i; } arrange(NULL); } void restack() { Client *c; XEvent ev; if(!sel) { drawstatus(); return; } if(sel->isfloat || arrange == dofloat) { XRaiseWindow(dpy, sel->win); XRaiseWindow(dpy, sel->twin); } if(arrange != dofloat) for(c = nexttiled(clients); c; c = nexttiled(c->next)) { XLowerWindow(dpy, c->twin); XLowerWindow(dpy, c->win); } drawall(); XSync(dpy, False); while(XCheckMaskEvent(dpy, EnterWindowMask, &ev)); } void togglemode(Arg *arg) { arrange = (arrange == dofloat) ? dotile : dofloat; if(sel) arrange(NULL); else drawstatus(); } void toggleview(Arg *arg) { unsigned int i; seltag[arg->i] = !seltag[arg->i]; for(i = 0; i < ntags && !seltag[i]; i++); if(i == ntags) seltag[arg->i] = True; /* cannot toggle last view */ reorder(); arrange(NULL); } void view(Arg *arg) { unsigned int i; for(i = 0; i < ntags; i++) seltag[i] = False; seltag[arg->i] = True; reorder(); arrange(NULL); } void viewall(Arg *arg) { unsigned int i; for(i = 0; i < ntags; i++) seltag[i] = True; reorder(); arrange(NULL); } void zoom(Arg *arg) { unsigned int n; Client *c; for(n = 0, c = clients; c; c = c->next) if(isvisible(c) && !c->isfloat) n++; if(!sel || sel->isfloat || n < 2 || (arrange != dotile) || maximized) return; if((c = sel) == nexttiled(clients)) if(!(c = nexttiled(c->next))) return; detach(c); if(clients) clients->prev = c; c->next = clients; clients = c; focus(c); arrange(NULL); }