<< 26-03-2016 >>

00:11:28*desophos quit (Remote host closed the connection)
00:15:08*mahasamoot joined #nim
00:19:30*mahasamoot quit (Ping timeout: 250 seconds)
00:23:15*francisl quit (Quit: francisl)
00:23:21onionhammer1C# is very popular in the corporate world as well
00:28:19*irrequietus quit ()
00:50:12*desophos joined #nim
00:54:11*couven92 joined #nim
00:56:03*fredrik92 quit (Ping timeout: 240 seconds)
00:57:05*freddy92 joined #nim
00:58:33*couven92 quit (Ping timeout: 240 seconds)
01:01:59*couven92 joined #nim
01:02:30*couven92 quit (Client Quit)
01:05:28*freddy92 quit (Ping timeout: 244 seconds)
01:05:51VarriountAraq: The ParamTypesMatch procedure in sigmatch... why doesn't it return a bool or something?
01:14:26*pregressive joined #nim
01:32:48dom96https://twitter.com/velartrill/status/713501595430817792
01:35:52cnclclearly he hasn't used haskell with ghc extensions enabled
01:36:09cncl(she?)
01:38:35VarriountI'm finding her twitter tagline... interesting, as well as her website.
01:40:27VarriountI haven't actually had strong spaces bite me yet... then again, I'm paranoid and use braces anyway.
01:40:46dom96Varriount: The thing is: strong spaces aren't enabled by default.
01:41:07Varriountdom96: They aren't? I could have sworn they were enabled in the latest release.
01:41:42dom96These people aren't very friendly :(
01:44:32cnclyeah, don't expect a lot of friendliness from programmers, haha
01:47:09dom96oh well
01:48:15cncllanguages tend to gain more acceptance once there are a couple of high-profile projects made with them
01:48:55cncladvocacy alone will only do so much
01:48:59cncl(in my experience)
01:51:42dom96yeah, makes sense.
02:13:52dom96good night guys
02:18:52*filwit joined #nim
02:31:23*pregressive quit (Remote host closed the connection)
02:31:32*brson quit (Quit: leaving)
02:38:48*Demos_ joined #nim
02:39:06cnclseeya
02:42:09*Demos quit (Ping timeout: 260 seconds)
02:48:36*filwit quit (Quit: Leaving)
03:13:05*arnetheduck joined #nim
03:15:38*mahasamoot joined #nim
03:27:41*chrisheller joined #nim
03:30:33*Vivek quit (Ping timeout: 240 seconds)
03:30:48*Vivek joined #nim
03:31:02*nicktick joined #nim
03:31:12*Vivek is now known as Guest15833
03:38:10nicktickHint: [Link]
03:38:10nicktickd:\nim\sources\nimcache\system.o:system.c:(.text+0xdb3f): relocation truncated to fit: R_X86_64_PC32 against undefined symbol `_wfopen'
03:38:18nicktickwhat's it ?
03:39:06nickticknim c test_str.nim
03:39:31nicktickfs = newFileStream("dat",fmReadWrite)
03:40:20nicktickis there any library need be linked?
03:45:18cnclyou're using gcc?
04:01:31nicktickcncl , yes
04:02:40nicktickwith MSYS2
04:03:33cnclwhat's the output of gcc --version and nim --version
04:04:36nicktickgcc (GCC) 4.9.2 ,
04:04:36nicktickNim Compiler Version 0.12.0 (2015-10-27) [Windows: amd64]
04:04:37*apotheon joined #nim
04:06:39cnclthe output of the gcc version should have many more lines
04:07:00nicktickgcc (GCC) 4.9.2
04:07:00nicktickCopyright (c) 2014 Free Software Foundation, Inc.
04:07:14cnclhmm
04:07:19cnclyou don't see the build information?
04:07:33cnclmost gcc builds look like
04:07:36cnclgcc.exe (x86_64-win32-seh-rev0, Built by MinGW-W64 project) 5.3.0
04:07:40cnclor something like that
04:07:44nicktickno
04:07:52cnclwell
04:08:02cnclmy first suggestion is to update to newer gcc/mingw
04:08:08cncland newer nim (0.13.0)
04:08:20nicktickok
04:09:28cnclah
04:09:31cncli think i see
04:09:33cnclyou're using cygwin
04:09:44cnclnim for windows is not built for cygwin
04:09:50nicktickno, mingw
04:10:32cnclmsys2 uses cygwin
04:11:44cnclat least i think so
04:11:48cnclmaybe i'm wrong
04:11:52nicktick$ ./build.sh
04:11:52nicktickError: unknown operating system: mingw64_nt-10.0
04:12:23nicktickbut I did compile nim with this gcc ago.
04:12:47nickticknim(0.13.0) can't be installed on windows now?
04:12:53cnclit can, i'm using it right now
04:13:06cnclgcc.exe (x86_64-win32-seh-rev0, Built by MinGW-W64 project) 5.3.0
04:13:32cncli don't use msys2 or cygwin though
04:13:36cncli don't really know much about them
04:13:57cnclbut i do believe that the nim distribution for windows will not work with cygwin
04:16:03nicktickbuild64.bat work
04:16:19nicktickcompiling ...
04:26:55*vendethiel joined #nim
04:28:03cnclAraq: do i need to worry about the cost of reallocations for seq? in c++ (and elsewhere), for variable-sized arrays, i'm used to doing things like reserving a larger amount of space when creating the array to avoid multiple reallocations/resizes when filling it
04:28:46cncloften i will know roughly or exactly the maximum the number of entries that will be added to it
04:29:12cncli see that it's possible to use setLen or to call newSeq with a number, but that changes the actual number of entries in the seq and not just how much memory is allocated for it
04:29:24cnclbut i know nim has a managed runtime so maybe it's not something that has to be worried about?
04:44:01*brson joined #nim
04:55:07*NimBot joined #nim
04:58:25*Demon_Fox quit (Quit: Leaving)
05:00:03*exebook quit (Read error: Connection reset by peer)
05:21:49*exebook joined #nim
05:23:39*desophos_ joined #nim
05:28:48*desophos_ quit (Ping timeout: 276 seconds)
05:31:15*vendethiel quit (Ping timeout: 248 seconds)
05:33:26*chrisheller quit (Remote host closed the connection)
05:50:38*enthus1ast quit (Ping timeout: 244 seconds)
05:50:45*enthus1ast1 joined #nim
06:02:51*Demos_ quit (Ping timeout: 264 seconds)
06:07:22*bjz joined #nim
06:08:46*bjz_ quit (Ping timeout: 250 seconds)
06:35:19*enthus1ast1 quit (Quit: Leaving.)
06:49:53*desophos quit (Read error: Connection reset by peer)
06:54:23*darius93 joined #nim
06:56:54darius93I have a question: nim has gc correct? if so how often does it run because i ran a small sample code i found and after stress testing it, it doesnt seems to free up memory. the code is http://hastebin.com/ponuzapufu.coffee
07:05:00*yglukhov joined #nim
07:09:37*rok joined #nim
07:27:24*brson quit (Quit: leaving)
07:53:28*yglukhov quit (Remote host closed the connection)
07:59:19*yglukhov joined #nim
08:15:01*yglukhov quit (Remote host closed the connection)
08:16:12Araqdarius93: try --gc:v2 with async.
08:16:28Araqhopefully I can get it to become the default soon...
08:16:45Araqcncl: it's much like C++ in this respect
08:21:12*Demos joined #nim
08:24:15cnclAraq: ah, ok. so, for example, let's say i know that i will have about 1500 entries for something that i need to put into a seq, but i won't know exactly until i'm finished iterating some source data
08:25:12cnclis there some way to tell a seq to allocate enough space for 1500 entries, but not actually initialize the memory or have its len report as 1500?
08:25:37cncljust as a hint to avoid re-allocating/copying
08:25:45Araqadd newSeqOfCap to system.nim
08:25:52Araqthat's on my todo for a while now
08:26:01Araqbut you can do it. it's "easy".
08:26:23cnclah ok, thanks. i'll take a look
08:26:42cnclalso will add the uint `mod` :) i will change to a source build soon, and try that stuff
08:26:55cncli'm on the binary distribution but i'll change to building from source soon
08:35:24*yglukhov joined #nim
08:36:53*nicktick1 joined #nim
08:39:09*nicktick quit (Ping timeout: 246 seconds)
09:00:07VarriountAraq: Any chance for 'setCap', analagous to setLen?
09:02:53*vendethiel joined #nim
09:28:09*vendethiel quit (Ping timeout: 246 seconds)
09:34:12AraqVarriount: that would be less convienent to use wouldn't it?
09:35:28*Arrrr joined #nim
09:35:28*Arrrr quit (Changing host)
09:35:28*Arrrr joined #nim
10:03:56*endragor joined #nim
10:04:34*rok quit (Quit: rok)
10:05:31*macbeth joined #nim
10:24:09*bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
10:27:22*bjz joined #nim
10:43:24*heinrich5991 quit (Ping timeout: 276 seconds)
10:49:53*heinrich5991 joined #nim
10:55:55*irrequietus joined #nim
10:58:10*enthus1ast joined #nim
11:00:26cheatfateAraq, is it possible to access stack in runtime?
11:00:49cheatfatei mean get traceback
11:06:20*irrequietus quit ()
11:06:24*irrequietus_ joined #nim
11:06:43*irrequietus_ quit (Client Quit)
11:07:01flyxcheatfate: in debug builds, you can use writeStackTrace and getStackTrace from system.nim
11:07:28cheatfateflyx, thanks
11:15:15*Arrrr quit (Ping timeout: 248 seconds)
11:22:26*Arrrr joined #nim
11:33:35*toaoMgeorge joined #nim
11:50:42*exebook quit (Ping timeout: 260 seconds)
11:57:26*darkf quit (Quit: Leaving)
12:13:17toaoMgeorgeJust out of curiosity, what are the worst showstoppers for Nim right now?
12:15:20toaoMgeorgeProbably in a month or two I will have some time to get my hands dirty with the compiler...
12:19:44dom96toaoMgeorge: Glad to hear that :)
12:20:25dom96toaoMgeorge: We've got a showstopper label on github: https://github.com/nim-lang/Nim/issues?q=is%3Aissue+is%3Aopen+label%3AShowstopper
12:20:43*exebook joined #nim
12:24:04*Riviera- quit (Remote host closed the connection)
12:25:13*Trustable joined #nim
12:25:25AraqVarriount: why would it return 'bool'? type relations are way more complex than that ...
12:28:27toaoMgeorgedom96: thanks
12:28:48*fredrik92 joined #nim
12:32:24*gokr joined #nim
12:42:36fredrik92Hmm, for NimStudio you need sth. called a development build of Nim, how do I produce one? Build from source?
12:53:02dom96fredrik92: What's NimStudio?
12:54:35fredrik92dom96, Nim extension for Visual Studio (not the Nim plugin for VS Code) but the one for the big bloated IDE
12:55:04dom96fredrik92: ahh. I would guess that you do have to build Nim from source then.
12:56:54fredrik92Araq, I tried to compile Nim from source using VCC, that mainly failed because the nim source code uses ranged switch cases which is not supported by the MS Compiler
12:56:55*exebook quit (Read error: Connection reset by peer)
12:59:22Araqso build it properly
12:59:41Araquse a GGC based Nim first to compile a VCC based Nim.
13:03:44*fredrik92 quit (Read error: Connection reset by peer)
13:03:49*couven92 joined #nim
13:05:03*fredrik92 joined #nim
13:08:30*couven92 quit (Ping timeout: 268 seconds)
13:17:57*exebook joined #nim
13:36:29*ehmry joined #nim
13:36:30*rok joined #nim
14:04:15fredrik92Araq, but isn't the nim source code generated? If yes, any chance to expand ranged switch cases in the future? Or can run Regex over the entire thing a do a VCC compileable PR?
14:06:35fredrik92I actually started with that, so I could probably get it running after Easter... As a proof of concept?
14:12:11*baff1e quit (Remote host closed the connection)
14:16:56Varriountfredrik92: It's generated, but there are options for tailoring it to various compilers, IIRC
14:17:56Varriount--cc:vcc for example
14:23:54VarriountAraq: I don't suppose endb works wih the compiler?
14:27:50*macbeth quit (Quit: Page closed)
14:32:47darius93Araq, it seems to segfault when i add '--gc:v2'.
14:37:27*francisl joined #nim
14:38:29*francisl quit (Client Quit)
15:18:20cheatfatedo we have something like ordered stack, i need to push values of any order but i want to pop always maximum value of stack?
15:23:21endragorin stdlib - no, as far as I know. there is https://github.com/bluenote10/nim-heap
15:28:44*fredrik92 quit (Quit: Shutting down . . .)
15:32:23*fredrik92 joined #nim
15:35:15*Arrrr quit (Ping timeout: 276 seconds)
15:35:33*endragor_ joined #nim
15:38:02*rok quit (Quit: rok)
15:39:28*endragor quit (Ping timeout: 250 seconds)
15:40:27*endragor_ quit (Ping timeout: 276 seconds)
15:49:47fredrik92Hmm... I get a weird error when using nim and the target file are not in the same directory as my current working directory:
15:49:48fredrik92...\Source\GitHub\nim-lang>nim compile niminst
15:49:48fredrik92Hint: system [Processing]
15:49:48fredrik92Hint: niminst [Processing]
15:49:48fredrik92Error: cannot open '...\source\github\nim-lang\niminst.nim'
15:50:12fredrik92(On Windows in cmd)
15:50:52fredrik92But when I cd'ed into the niminst directory, nim compiled just fine!...
15:51:14fredrik92Backslash problems?
15:54:27*endragor joined #nim
15:56:14cheatfateendragor, thanks
16:06:19VarriountDemos: You around?
16:11:45fredrik92how do I generate csources for nim itself? instead of clong the nim-lang/csources repo? I have Nim installed and in my path
16:12:11*Arrrr joined #nim
16:12:11*Arrrr quit (Changing host)
16:12:11*Arrrr joined #nim
16:13:22dom96fredrik92: ./koch csources -d:release
16:17:02fredrik92thx
16:18:56*arnetheduck quit (Ping timeout: 244 seconds)
16:34:22*chrisheller joined #nim
16:35:47ArrrrWhy does sizeOf static variable display a different value than the one from a non static variable?
16:35:50Arrrrhttp://ideone.com/JyZyBf
16:35:51*s455wang left #nim ("WeeChat 1.3")
16:36:29fredrik92koch csources -d:release --cc:vcc fails:nim compile -f --symbolfiles:off --compileonly --gen_mapping --cc:gcc --skipUserCfg --os:linux --cpu:i386 -d:release --cc:vcc compiler/nim.nimc:\nim\lib\pure\math.nim(135, 8) Error: implementation of 'math.randomize()' expected
16:37:15fredrik92Oh, sry..
16:37:17fredrik92$ koch csources -d:release --cc:vcc
16:37:26fredrik92$ nim compile -f --symbolfiles:off --compileonly --gen_mapping --cc:gcc --skipUserCfg --os:linux --cpu:i386 -d:release --cc:vcc compiler/nim.nim
16:37:37fredrik92> c:\nim\lib\pure\math.nim(135, 8) Error: implementation of 'math.randomize()' expected
16:38:12fredrik92and that's both in the devel branch and the v0.13.0 branch of the Nim repo
16:41:02*filwit joined #nim
16:42:01*filwit quit (Client Quit)
16:43:40*filwit joined #nim
16:52:42dom96fredrik92: hrm, is koch passing both 'cc:gcc' and 'cc:vcc', is that the issue?
16:53:32fredrik92seems so... because when I just take that one line and execute it without --os:linux and --cc:gcc then everything is fine
16:54:02fredrik92But I cannot really figure out where koch generates that command and inserts gcc and linux...
16:54:43fredrik92tried to change the GitHub/nim-lang/Nim/config/nim.cfg, but that did not work either
16:55:03fredrik92and I have cc = vcc in my C:\Nim\config\nim.cfg
16:55:24dom96I think it's just generated here: https://github.com/nim-lang/Nim/blob/devel/koch.nim#L101
16:55:51dom96Guessing whatever creates `args` is doing it incorrectly, think you could investigate? :)
16:58:08fredrik92Yeah... will do... do we have a clue where args is coming from?
16:59:08dom96fredrik92: not sure, look up where `csources` is being called
16:59:19fredrik92ah, https://github.com/nim-lang/Nim/blob/devel/koch.nim#L377
17:06:50DemosVarriount, I am now
17:07:42*pregressive joined #nim
17:17:10*desophos joined #nim
17:29:48fredrik92dom96, the error actually happens in niminst which koch calls
17:42:25Varriountfredrik92: Do 'nim c --cc:vcc compiler/nim.nim'
17:42:53VarriountE.g, compile manually instead of using koch.
17:43:15*brson joined #nim
17:43:22fredrik92yes, that works.. But i actually wanted koch to csource nim using vcc settings... But that may not be possible?
17:45:54dom96fredrik92: why do you need the csources for vcc?
17:46:54fredrik92wanted to compile nim with vcc instead of gcc... right now, more as a proof of concept...
17:59:52fredrik92Araq, the nimcache option in nim is interpreted relative to the location of the nim.file to compile, not relative to the current directory! the -o option however is relative to the current working directory. That is actually a big problem when the nim file is not in current dir, because the linking step fails
18:00:25fredrik92the only way is to use absolute paths whenever possible, that always works
18:03:05dom96fredrik92: can't you simply do: nim c --cc:vcc compiler/nim to do so?
18:04:02dom96regarding the problem with -o, likely already reported https://github.com/nim-lang/Nim/labels/Path%20Handling
18:04:03fredrik92dom96 can I? I don't know... You guys here told me to do ./koch csource -d:release to generate Nim's C source code
18:04:37dom96fredrik92: Try it :)
18:09:09*pregressive quit (Remote host closed the connection)
18:09:43*pregressive joined #nim
18:13:55fredrik92is there a way to get nim only to generate code, no compile, no linking, no anything?
18:14:15*pregressive quit (Ping timeout: 264 seconds)
18:21:34*vendethiel joined #nim
18:23:23Demosnim does compile wiht VCC
18:23:30DemosI do it regularly
18:23:43Demoskoch boot --cc:vcc I think will work
18:23:53Demosyou do need vcc actually on the path
18:27:09*ehmry left #nim ("Leaving")
18:27:09mogKeyError: Identifier('ehmry') (file "/usr/lib/python3/dist-packages/sopel/tools/target.py", line 65, in clear_user)
18:29:51dom96fredrik92: nim c --compileonly --cc:vcc file.nim
18:32:57fredrik92Demos, you're right, that worked like a charm... csource appearently does not work nice with vcc
18:33:24Demosoh yeah, that's super annoying
18:33:32DemosI tend to bootstrap with an official release\
18:33:41Demosor the buildbots when those were working
18:34:20fredrik92hmm... well enough playing around for today... I will have a look tomorrow... :-)
18:34:22*fredrik92 quit (Quit: Shutting down . . .)
18:55:54*fredrik92 joined #nim
18:58:39*nicktick joined #nim
19:00:19*apotheon quit (Ping timeout: 248 seconds)
19:02:27*nicktick1 quit (Ping timeout: 248 seconds)
19:02:31*nicktick2 joined #nim
19:02:36*vendethiel quit (Ping timeout: 276 seconds)
19:06:10*nicktick quit (Ping timeout: 268 seconds)
19:11:45*apotheon joined #nim
19:17:50*Demon_Fox joined #nim
19:19:19*endragor quit (Remote host closed the connection)
19:40:18cheatfatei'm looking for fast concurrent hash map/table
19:49:18Varriountcheatfate: I think there's a lock free hash table in the stdlib.
19:52:49cheatfateVarriount, it looks a little bit strange
19:53:06cheatfateVarriount, maybe {.experimental.} staff
19:53:06VarriountHowso?
19:53:42cheatfateno header, no docs
19:55:26Varriountcheatfate: You can also use sharedtables.nim
19:56:07cheatfateVarriount, already tried to use sharedtables.nim it locking whole table...
19:56:14cheatfateand missed many functions
19:56:53Varriountcheatfate: What are you doing that you're running into such a large amount of lock contention?
19:58:11cheatfateVarriount, new variant of selectors.nim, with more feautures and multithreading
19:59:30Varriountcheatfate: https://github.com/nim-lang/Nim/tree/crazy_concurrency
19:59:55cheatfateVarriount, not working and forgotten i think
20:00:16Varriountcheatfate: Well, that branch is using shared tables.
20:00:37VarriountSo your choices are to use sharedtables, lockfree tables, or roll your own.
20:03:52cheatfatei think lockfree tables ready and tested only on 32bit
20:12:16*rok joined #nim
20:14:12Varriountcheatfate: I'd use the sharedtables module, and not pre-optimize
20:14:28VarriountA truly lock-free backend can always be added.
20:16:07VarriountAraq: Why is it 'paramTypesMatch' and not just 'typesMatch'?
20:23:59*nicktick joined #nim
20:27:34*nicktick2 quit (Ping timeout: 268 seconds)
20:28:51VarriountAraq: Also, what is considered to be "metaConvertible"?
20:38:26*vendethiel joined #nim
20:50:21VarriountAraq: I think I've found the bug with generic types - there's something wrong in typeRel
20:51:37*toaoMgeorge quit (Ping timeout: 268 seconds)
20:56:30*filwit quit (Quit: Leaving)
21:00:53*nicktick1 joined #nim
21:02:04*nicktick quit (Ping timeout: 244 seconds)
21:09:14*darkf joined #nim
21:14:09*Arrrr quit (Quit: WeeChat 1.4)
21:20:34*vendethiel quit (Ping timeout: 252 seconds)
21:23:08*tinAndi joined #nim
21:25:43*pregressive joined #nim
21:30:05AraqVarriount: well? what's the bug?
21:30:29VarriountAraq: I don't know quite yet. I'm still trying to decipher the huge function.
21:30:46VarriounttypeRel is saying that the generics are convertible though, which isn't true.
21:32:26Araqexactly!
21:35:11VarriountAraq: Well, I feel dumb.
21:35:24*fredrik92 quit (Ping timeout: 268 seconds)
21:35:28VarriountIt took me manually tracing the assignment code to get to this point.
21:36:07VarriountOf course, now there's the 500+ line monster that is typeRel to debug.
21:37:26Araqhmm, didn't I tell you it's in sigmatch.nim ?
21:40:27VarriountYes, but not which procedure.
21:42:05*Gonzih quit (Quit: WeeChat 1.4)
21:42:23*Gonzih joined #nim
21:50:39*nicktick joined #nim
21:52:28AraqVarriount: tyGenericInst
21:52:46Araqline 928
21:52:50Araqit's completely wrong.
21:53:43*nicktick1 quit (Ping timeout: 244 seconds)
21:59:11*vendethiel joined #nim
22:00:45VarriountI don't think I would have spotted that without quite a bit of effor.
22:01:19*rok quit (Quit: rok)
22:03:05cheatfateAraq, can i use seqs with threads? are seqs using shared memory?
22:04:09*tinAndi quit (Ping timeout: 260 seconds)
22:04:57Araqno.
22:05:38Varriountcheatfate: Think about it: what happens if one thread adds to a sequence and the internal arrays needs to be re-sized/moved?
22:06:06*nicktick1 joined #nim
22:07:45*nicktick2 joined #nim
22:08:23cheatfateVarriount, :) i understand this and bring my locks to it, problem is that all most of collection staff using "ref object" and not using allocShared... so other threads could not access this memory
22:08:45Varriountcheatfate: Use arrays?
22:09:23cheatfateinstack arrays?
22:09:40Varriountcheatfate: Arrays allocated from shared memory.
22:09:52cheatfatehmm
22:10:04*nicktick quit (Ping timeout: 252 seconds)
22:10:16cheatfatebut arrays could not be extended...
22:10:28Varriountcheatfate: So copy and reallocated the arrays.
22:10:31*fredrik92 joined #nim
22:11:15*nicktick1 quit (Ping timeout: 248 seconds)
22:11:16*fredrik92 quit (Read error: Connection reset by peer)
22:11:26cheatfateVarriount, could you please point me on some examples
22:11:39*fredrik92 joined #nim
22:14:16*fredrik92 quit (Read error: Connection reset by peer)
22:14:55cheatfateVarriount, i even dont know how to declare such array...
22:15:34VarriountOne moment.
22:21:03*vendethiel quit (Ping timeout: 240 seconds)
22:28:52*yglukhov quit (Read error: Connection reset by peer)
22:29:24*yglukhov joined #nim
22:31:10VarriountAraq: Has something changed with the {.unchecked.} pragma? I can't seem to use it on generic arrays.
22:33:42Araqno
22:33:57Varriountcheatfate: Use createShared, resizeShared, and freeShared to allocate blocks of memory.
22:34:54*nicktick joined #nim
22:34:59VarriountAraq: "type UncheckedArray[T] {.unchecked.} = array[0..30, T]" gives "Error: implementation of 'UncheckedArray' expected"
22:36:02cheatfateVarriount, i know about functions :)
22:36:36*nicktick2 quit (Ping timeout: 244 seconds)
22:36:37AraqVarriount: put the pragma before the [T]
22:40:18AraqVarriount: to make you feel better: I've no idea what that code section is supposed to do
22:41:22VarriountAraq: Well, I can see that the loop is meant to check the type relation of all the generic's subtypes. I don't quite understand why the first child node is skipped though.
22:42:25VarriountAraq: What's so special about the last child node of a parent node? I mean, why is skipTypes used so much in the compiler?
22:47:39Araqthe data structures are arranged so that the last child is most important
22:49:18VarriountAraq: So, in a PType that represents a generic type, the last node is..?
22:49:30Araqthe implementation/instantiation
22:49:48VarriountHuh.
22:50:01VarriountI would have thought the first node would be most important.
22:56:42Varriountcheatfate: https://gist.github.com/Varriount/a300ef3b3213eb1c79c7
22:59:39cheatfateVarriount, thanks
22:59:45cheatfatei will try to use it
23:00:43Varriountcheatfate: Note that ptr ptr is used - This means that when you want to resize the sequence, you won't get broken pointers.
23:01:18VarriountIt also means that the semantics for this particular data structure are the same as references - the data isn't copied on assignment.
23:01:32*vendethiel joined #nim
23:01:46VarriountThis is different from how Nim's sequences and strings behave. Nim strings and sequences are copy-on-assignment.
23:23:59*bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…)
23:24:26*bjz joined #nim
23:28:15*vendethiel quit (Ping timeout: 268 seconds)
23:28:27*vendethiel joined #nim
23:41:04cheatfateVarriount, could you please test this? https://gist.github.com/cheatfate/e7de8594e22df63ae455
23:41:37cheatfatei dont understand why capacity has been changed
23:42:51Varriountcheatfate: Are you sure you want that structure layout?
23:43:27cheatfateyeah i want copy-on-assignment for it
23:44:34cheatfatethere will be push/pop and iterate nothing more
23:46:14Varriountcheatfate: That will only copy the capacity and length, not the data.
23:46:48cheatfatei think we are talking about different things
23:47:22cheatfatei dont understand why first repr gives 64 and second one 72
23:47:48cheatfateafter first repr result.capacity = 64 after second repr result.capacity = 72
23:48:30Varriountcheatfate: It might have something to do with the wierd casting stuff on line 39
23:48:38VarriountWhat are you even trying to do there?
23:49:28*vendethiel quit (Ping timeout: 244 seconds)
23:49:41cheatfatei will try to set data = address of memory after structure
23:50:14cheatfate[structure][memory] i will try to point data to [memory]
23:50:26*Jesin quit (Quit: Leaving)
23:51:00Varriountcheatfate: You know that will break as soon as the object is assigned somewhere else, right?
23:51:59cheatfatewhat object?
23:52:56*Jesin joined #nim
23:53:12onionhammer1Araq how do you enable the new GC?
23:53:19onionhammer1or is it default yet in devel?
23:53:21Varriountonionhammer1: --gc:v2
23:54:14Varriountcheatfate: Ok, objects are value types. They usually lie on the stack, and their entire structure data is copied from one chunk of memory to another when assigned.
23:54:59*gokr quit (Quit: Leaving.)
23:55:14cheatfateand?
23:55:18VarriountIf you set the data member to point to the end of the object, the data member will have a wierd pointer to another object when it is copied.
23:56:11cheatfatebut data member will be not accessible...
23:56:16onionhammer1Araq Varriount looks like my websocket memtest thing is working better (?)
23:56:26onionhammer1with default GC still, not testing v2 yet
23:56:47Varriountcheatfate: Not directly, but I'm assuming that the push and pop procedures will need to access the data
23:57:00Araqyour websocket memtest is a decade old and I fixed it years ago.
23:57:09onionhammer1:P
23:57:21Varriountcheatfate: Also, assignment will only copy the *pointer* to the data, not the data itself. I'm not quite sure you want that.
23:57:23onionhammer1it wont build with gc v2 though ARaq
23:57:37onionhammer1stdlib_posix.c:106:1: error: unknown type name 'FILE'
23:57:39onionhammer1FILE* dumpheapfile;
23:58:11onionhammer1has anyone made a websocket nimble package yet?
23:58:57Araqshouldn't your system have a FILE type?
23:59:08cheatfateVarriount, ok i will do it in 2 allocs
23:59:10*nicktick2 joined #nim
23:59:26dom96hello guys