00:01:12 | Araq | Joe_knock: meh if we need something like this, we're doing it wrong |
00:06:14 | * | jagillion quit (Ping timeout: 258 seconds) |
00:10:37 | Joe_knock | Araq: Would it be cheating if I simply ported what is there over to Nimrod using Python code? :P |
00:12:22 | * | fowl quit (Ping timeout: 258 seconds) |
00:13:08 | Araq | port as much python code to nim as you want |
00:13:14 | Araq | I did the same years ago |
00:13:27 | Araq | I don't have any python code left |
00:14:14 | Joe_knock | No, I mean using python itself to do this? :P If I can successfully replicate what that software does in Python, I can then transition it to Nimrod *slowly* |
00:14:48 | Araq | hrm? |
00:15:07 | TingPing | on devel install fails anyway =( |
00:15:41 | Araq | you mean a virtual environment for Nim in python which has the 2-3 split problem? |
00:16:54 | Joe_knock | Araq: A nim language/environment manager written in Python to help solve the dependency issue/s (which will happen, especially after bigbreak) |
00:17:54 | Araq | Joe_knock: babel is renamed to nimble for bigbreak, that should mitigate problems |
00:18:24 | Joe_knock | That could actually work for each new version :P new package manager :'D |
00:20:18 | Araq | TingPing: what's the problem? |
00:20:40 | TingPing | clang: error: no such file or directory: 'tools/niminst/nimcache/libzip_all.o' |
00:23:28 | TingPing | also shouldn't the libdir be an include dir, it just installs .nim files? |
00:24:36 | Araq | hrm perhaps try -d:useLibzipSrc |
00:25:02 | Araq | or don't use useLibzipSrc |
00:25:23 | Araq | TingPing: dunno, I copied python iirc |
00:25:33 | Araq | python uses lib too |
00:25:36 | TingPing | true |
00:26:26 | TingPing | but include files are only used for building, python files are used at runtime, where a c lib is used at runtime |
00:26:45 | Araq | FPC uses lib as well |
00:27:06 | Araq | and that's a compiler |
00:29:18 | TingPing | -d:useLibzipSrc didnt change anything |
00:34:51 | NimBot | Araq/Nimrod bigbreak dcaba49 Araq [+0 ±1 -0]: deprecated '#[' comments for future multi-line comment feature |
00:34:51 | NimBot | Araq/Nimrod bigbreak e9dec2f Araq [+0 ±4 -0]: better lock level handling |
00:34:51 | NimBot | Araq/Nimrod bigbreak 2c1f3f7 Araq [+24 ±7 -0]: manual split up into multiple files; documented the new concurrency system |
00:34:51 | NimBot | Araq/Nimrod bigbreak 2011805 Araq [+0 ±2 -0]: Merge branch 'bigbreak' of https://github.com/Araq/Nimrod into bigbreak |
00:35:37 | Araq | TingPing: sorry I need to sleep now |
00:36:02 | Araq | good night |
00:36:09 | TingPing | gn |
00:58:20 | * | brson quit (Quit: leaving) |
00:58:35 | * | tillzy_ joined #nimrod |
00:58:35 | * | tillzy_ is now known as tillzy |
01:10:06 | * | q66 quit (Quit: Leaving) |
01:12:14 | TingPing | Araq, not quite tested, nor do i know the far reaching effects of changinge a few dirs, but id like your opinion: https://github.com/TingPing/Nimrod/commit/19eeb28bab3ce5698281ecb4041bc576333c0ae4 |
01:12:35 | * | francisl quit (Quit: francisl) |
01:13:07 | * | tillzy quit (Quit: tillzy) |
01:14:03 | * | francisl joined #nimrod |
01:15:14 | * | askatasuna joined #nimrod |
01:18:37 | * | bjz_ quit (Ping timeout: 260 seconds) |
01:28:47 | * | Joe_knock quit (Quit: Leaving) |
01:29:52 | * | johnsoft quit (Ping timeout: 250 seconds) |
01:30:08 | * | willwillson quit (Remote host closed the connection) |
01:30:54 | * | johnsoft joined #nimrod |
01:33:59 | * | BlueNinja joined #nimrod |
01:34:08 | * | BlueNinja left #nimrod ("Leaving") |
01:58:56 | flaviu1 | TingPing: Not Araq, but I don't think I've ever seen a patch with that quality of commit message |
02:06:54 | * | saml_ joined #nimrod |
02:15:30 | * | saml_ quit (Ping timeout: 246 seconds) |
02:18:10 | * | francisl quit (Quit: francisl) |
02:29:29 | * | saml_ joined #nimrod |
02:47:03 | * | francisl joined #nimrod |
02:48:00 | * | saml_ quit (Ping timeout: 258 seconds) |
02:54:30 | * | filwit quit (Quit: Leaving) |
03:01:53 | * | saml_ joined #nimrod |
03:05:04 | * | darkf_ joined #nimrod |
03:05:44 | * | darkf quit (Disconnected by services) |
03:05:46 | * | darkf_ is now known as darkf |
03:16:21 | * | flaviu1 quit (Ping timeout: 272 seconds) |
03:30:54 | * | Fran__ joined #nimrod |
03:33:37 | * | Francisco quit (Ping timeout: 245 seconds) |
03:35:21 | * | fowl joined #nimrod |
04:09:17 | * | francisl quit (Quit: francisl) |
04:14:38 | * | saml_ quit (Ping timeout: 258 seconds) |
04:25:23 | * | darkf quit (Ping timeout: 272 seconds) |
04:26:35 | * | xenagi quit (Read error: Connection reset by peer) |
04:36:01 | * | askatasuna quit (Ping timeout: 260 seconds) |
04:50:02 | * | nande quit (Remote host closed the connection) |
05:05:58 | * | johnsoft quit (Ping timeout: 272 seconds) |
05:06:44 | * | johnsoft joined #nimrod |
05:08:09 | * | darkf joined #nimrod |
05:11:47 | * | dirkk0 joined #nimrod |
05:40:51 | * | nande joined #nimrod |
05:52:12 | * | skyfex quit (Quit: Computer has gone to sleep.) |
05:52:46 | * | skyfex joined #nimrod |
06:09:46 | Araq | TingPing: er ... that breaks everything. |
06:10:27 | TingPing | who depends on those files? |
06:15:30 | Araq | who knows |
06:15:44 | Araq | why did you even patch the compiler? |
06:15:56 | * | fowl quit (Quit: Leaving) |
06:15:58 | Araq | what's wrong with it? |
06:16:04 | TingPing | so it looks in the new paths..? |
06:16:22 | TingPing | i would assume nobody other than the compiler reads the compiler config file |
06:16:51 | Araq | which news paths? |
06:17:05 | TingPing | and the other compiler change was the stupid /usr/ or /usr/local checks |
06:17:17 | TingPing | - $prefix/etc > $prefix/etc/nimrod |
06:17:47 | Araq | so it'll produce /opt/etc/nimrod ? |
06:18:00 | TingPing | if you install into /opt yes |
06:18:06 | Araq | that's not how opt works |
06:18:33 | TingPing | this is how every build system ive ever used works, the actual value of the prefix should not matter to it |
06:18:43 | Araq | heck that's the reason why *prefix* makes no sense as a concept |
06:19:21 | Araq | I don't think I've ever seen /opt/etc ... maybe I'm wrong? |
06:19:30 | TingPing | who the hell uses opt anyway? |
06:19:47 | * | johnsoft quit (Ping timeout: 245 seconds) |
06:20:17 | * | johnsoft joined #nimrod |
06:20:18 | Araq | I don't care, it's part of Unix |
06:20:35 | Araq | who the hell uses /usr/local for that matter |
06:20:39 | TingPing | if you insist we could add a single /opt work around |
06:20:46 | TingPing | its the default prefix for every build system... |
06:22:29 | Araq | well sorry. I won't accept a patch like this. It WILL cause problems and the endless bikeshedding of how to install Nim needs to stop. |
06:23:35 | Araq | I mean, what's the problem again? you didn't read the docs and got confused. Fair enough, it's not standard. But most people don't package Nim. |
06:23:53 | TingPing | no, its completely broken atm if you use any remotely non-standard prefix |
06:24:06 | TingPing | and it SHOULD follow standards even when it does 'work' by your definition |
06:24:29 | TingPing | most people not packaging nim is a problem, not an excuse to be bad at packaging |
06:24:29 | Araq | I think any non-standard prefix should be treated like /opt |
06:26:07 | TingPing | well im sorry to hear that |
06:26:25 | * | TingPing left #nimrod ("Leaving") |
06:30:14 | Araq | these standards are brain damagingly stupid to begin with ... |
06:30:40 | Araq | not following them is an act of wisdom. |
06:38:05 | * | BlaXpirit joined #nimrod |
06:55:36 | * | Matthias247 joined #nimrod |
07:22:42 | * | Matthias247 quit (Read error: Connection reset by peer) |
07:25:41 | * | Matthias247 joined #nimrod |
07:26:49 | * | Matthias247 quit (Read error: Connection reset by peer) |
07:33:07 | * | nande quit (Remote host closed the connection) |
07:35:06 | * | BlaXpirit quit (Quit: Quit Konversation) |
07:36:21 | * | BlaXpirit joined #nimrod |
07:41:09 | * | dirkk0 quit (Quit: Leaving) |
07:55:33 | * | bjz joined #nimrod |
08:00:48 | * | bjz quit (Ping timeout: 260 seconds) |
08:11:21 | * | dirkk0 joined #nimrod |
08:32:55 | Trixar_za | Araq: +1 |
08:59:13 | * | skyfex quit (Ping timeout: 260 seconds) |
09:02:29 | * | endou joined #nimrod |
09:04:12 | * | BlaXpirit quit (Quit: Quit Konversation) |
09:06:33 | * | BlaXpirit joined #nimrod |
09:34:18 | * | BlaXpirit quit (Quit: Quit Konversation) |
09:58:53 | * | vendethiel quit (Ping timeout: 240 seconds) |
10:11:28 | * | johnsoft quit (Ping timeout: 260 seconds) |
10:11:47 | * | johnsoft joined #nimrod |
10:19:41 | * | BitPuffin joined #nimrod |
10:50:27 | * | flaviu1 joined #nimrod |
10:54:25 | * | bjz joined #nimrod |
10:55:53 | * | flaviu1 quit (Ping timeout: 240 seconds) |
10:58:18 | * | dirkk0 quit (Quit: This computer has gone to sleep) |
11:12:52 | * | kuzy000_ joined #nimrod |
11:17:37 | * | dirkk0 joined #nimrod |
11:21:41 | * | dirkk0 quit (Client Quit) |
11:53:31 | * | EXetoC quit (Quit: WeeChat 1.0.1) |
12:04:54 | * | noam quit (Ping timeout: 246 seconds) |
12:29:27 | * | darkf quit (Quit: Leaving) |
12:38:57 | * | dirkk0 joined #nimrod |
12:39:29 | * | dirkk0 quit (Client Quit) |
12:49:47 | * | wan quit (Quit: WeeChat 1.0) |
12:55:09 | * | dirkk0 joined #nimrod |
13:23:26 | * | noam joined #nimrod |
13:26:36 | * | untitaker quit (Ping timeout: 250 seconds) |
13:33:35 | * | untitaker joined #nimrod |
13:38:18 | * | askatasuna joined #nimrod |
13:44:56 | bogen | packaging Nim is not hard. I don't see the problem. |
13:54:25 | * | askatasuna quit (Ping timeout: 244 seconds) |
13:58:55 | * | nim joined #nimrod |
13:58:55 | * | nim quit (Client Quit) |
14:04:55 | * | io2 joined #nimrod |
14:25:24 | * | francisl_ joined #nimrod |
14:30:05 | * | francisl_ quit (Client Quit) |
14:31:28 | * | askatasuna joined #nimrod |
14:38:11 | * | bogen quit (Quit: Leaving.) |
14:46:18 | * | BlaXpirit joined #nimrod |
14:51:45 | * | willwillson joined #nimrod |
14:55:45 | * | prosper_ joined #nimrod |
15:12:24 | * | xcombelle joined #nimrod |
15:36:42 | * | prosper_ quit (Remote host closed the connection) |
15:36:49 | * | dirkk0 left #nimrod ("Leaving") |
15:44:45 | * | perturbation joined #nimrod |
15:59:47 | * | enquora joined #nimrod |
16:01:14 | perturbation | Does anyone know of a way of recursively parsing (flattening) C header files? I was thinking of writing a wrapper for the C xchat plugin API in nimrod, and c2nim gets me 95% there, but the xchat-plugin.h includes <time.h> and that doesn't seem to get pulled in. |
16:02:04 | perturbation | If I just wanted to do a one-off, I could wrap all of the data types/methods with {.importc, header: "xchat-plugin.h".} pragmas, but I'd rather just write a native nimrod module |
16:06:08 | * | rpag joined #nimrod |
16:26:16 | * | shodan45 joined #nimrod |
16:29:09 | * | johnsoft quit (Ping timeout: 246 seconds) |
16:30:10 | * | johnsoft joined #nimrod |
16:51:38 | * | brson joined #nimrod |
16:55:42 | * | willwillson quit (Ping timeout: 245 seconds) |
17:01:24 | * | bogen joined #nimrod |
17:03:04 | * | prosper_ joined #nimrod |
17:04:23 | * | dirkk0 joined #nimrod |
17:05:52 | * | prosper_ quit (Remote host closed the connection) |
17:09:14 | * | vendethiel joined #nimrod |
17:12:01 | * | skyfex joined #nimrod |
17:12:59 | * | prosper_ joined #nimrod |
17:15:18 | * | dom96 quit (Excess Flood) |
17:16:46 | * | dom96 joined #nimrod |
17:25:37 | * | prosper_ quit (Ping timeout: 245 seconds) |
17:28:23 | * | prosper_ joined #nimrod |
17:47:36 | * | Sht0 joined #nimrod |
17:51:42 | * | Ven joined #nimrod |
17:54:07 | * | BlaXpirit quit (Read error: Connection reset by peer) |
17:54:49 | * | BlaXpirit joined #nimrod |
18:06:45 | * | prosper_ quit (Remote host closed the connection) |
18:09:39 | * | BlaXpirit quit (Quit: Quit Konversation) |
18:11:08 | * | BlaXpirit joined #nimrod |
18:15:11 | * | EXetoC joined #nimrod |
18:15:28 | * | nande joined #nimrod |
18:31:00 | * | Fran__ is now known as Francisco |
18:33:10 | * | Ven quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
18:37:14 | * | bogen left #nimrod (#nimrod) |
18:37:52 | * | quasinoxen joined #nimrod |
18:46:54 | * | rpag quit (Quit: Leaving) |
18:48:55 | * | BitPuffin quit (Ping timeout: 244 seconds) |
18:51:29 | * | wan joined #nimrod |
18:54:45 | * | willwillson joined #nimrod |
18:57:26 | * | Ven joined #nimrod |
19:14:06 | * | Trustable joined #nimrod |
19:16:53 | * | Matthias247 joined #nimrod |
19:29:26 | * | skyfex quit (Quit: Computer has gone to sleep.) |
19:30:00 | * | skyfex joined #nimrod |
19:30:08 | * | q66 joined #nimrod |
19:30:44 | * | hguux joined #nimrod |
19:32:28 | Araq | perturbation: you cannot reasonably c2nim time.h |
19:32:37 | Araq | it's already wrapped via times.nim |
19:33:14 | Araq | that said, there is tools/cmerge for merging C files |
19:36:05 | * | Jehan_ joined #nimrod |
19:37:35 | * | Joe_knock joined #nimrod |
19:38:41 | perturbation | hmm... thanks Araq. I'll take a look. I was hoping I could just do the moral equivalent of 'cpp xchat-plugin.h | c2nim > xchatplugin.nim' |
19:39:08 | perturbation | (but the GNU pre-processor at least warps the file a bit such that c2nim then complains...) |
19:43:22 | Araq | Jehan_: please read doc/manual/locking.txt |
19:43:32 | Jehan_ | Araq: Will do. |
19:43:49 | Jehan_ | By the way, after working through it on paper, your subtyping rule looks correct. |
19:44:10 | Araq | brb |
19:53:00 | Araq | back |
19:55:20 | Jehan_ | How do you actually assign lock levels to locks? The document is silent on that. |
19:55:59 | Araq | there will be system.UncheckedLock and system.Lock[TLockLevel] |
19:56:30 | Araq | type Lock[T: static[int]] = ... |
19:57:06 | * | flaviu1 joined #nimrod |
19:57:13 | Araq | the implementation is hacky, it's simply checked if the type has a 'static T' generic parameter |
19:57:15 | Jehan_ | Does the system support read-write locks? |
19:57:58 | Araq | I think so |
19:58:11 | Araq | since "Lock" is not builtin at all |
19:58:18 | Araq | you can create your own lock types |
20:00:34 | Jehan_ | Yeah, but "access" means something completely different in each case. |
20:00:55 | Araq | it's up to you how to encapsulate the accesss |
20:01:17 | Jehan_ | Hmm, I see. |
20:01:39 | Araq | however '.guard' is a problem for writing libraries |
20:02:43 | Jehan_ | I guess one could ensure read-only access by making something a non-var parameter. |
20:03:26 | Jehan_ | Also not sure how the system works with higher order functions that don't have a lock level. |
20:04:21 | * | dirkk0 quit (Quit: Leaving) |
20:07:00 | * | vezzy joined #nimrod |
20:08:15 | * | quasinoxen quit (Ping timeout: 246 seconds) |
20:09:46 | * | Mat3 joined #nimrod |
20:09:48 | Mat3 | hello |
20:11:53 | * | woodgiraffe quit (Ping timeout: 240 seconds) |
20:12:40 | Joe_knock | Hello folks. |
20:15:05 | * | Sht0 quit () |
20:15:21 | perturbation | cmerge works fine, but xchat's C API is kind of broken... _xchat_list (among other types) are listed but not defined in xchat-plugin.h, which means I'd have to chase them down and redefine... ugh |
20:16:23 | Joe_knock | is dom96 around? |
20:19:58 | Araq | Joe_knock: no, he has a real life now ;-) |
20:20:15 | Araq | hi Mat3 |
20:20:37 | Araq | Jehan_: the effect system in general has special treatment for higher order functions |
20:21:36 | Joe_knock | Araq: School or teenage years? :P |
20:23:09 | Jehan_ | College, as I understand it. |
20:23:21 | * | vezzy quit (Quit: No Ping reply in 180 seconds.) |
20:23:44 | * | quasinoxen joined #nimrod |
20:26:01 | Mat3 | hi Araq and all |
20:26:36 | Joe_knock | I'd like to know, based on this: http://www.techempower.com/benchmarks/ why Jester is so weak in performance? |
20:26:54 | Araq | again? that old benchmark? |
20:27:01 | Mat3 | sorry, what kind of framework is Jester ? |
20:27:14 | Araq | it's not properly multi-threaded, that's why, Joe_knock |
20:27:19 | * | prosper_ joined #nimrod |
20:27:38 | Araq | Mat3: super-duper awesome web framework |
20:27:52 | Mat3 | ah, these one |
20:28:10 | Joe_knock | Araq: Is that a flaw in the framework or the test-code? |
20:28:26 | * | Celestic joined #nimrod |
20:28:30 | Celestic | Hey all, anyone around? |
20:28:42 | Araq | hi Celestic |
20:28:44 | Celestic | Looking for some help with a PHP/javascript thing I'm doing. |
20:28:46 | Celestic | Hello Araq. |
20:28:54 | Mat3 | hello Celestric |
20:28:54 | Celestic | What's up? |
20:29:25 | Celestic | Anyone here into PHP/js? or have a background in it? |
20:29:31 | Celestic | I'm sure it's a fairly basic question, I'm just rather new to it. |
20:29:39 | Araq | Joe_knock: the benchmark doesn't really support multi-processing which is what jester used |
20:30:04 | Araq | Celestic: just ask |
20:30:21 | Joe_knock | Celestic: Throw them questions :P |
20:30:22 | * | xcombelle quit (Quit: Quitte) |
20:30:50 | Joe_knock | Araq: So what is the true performance then? Cause I see node.js ahead of a static language :'D |
20:31:07 | Celestic | I'm trying to implement something that'll work harmoniously with ajax/jquery (POST to a .php end-point) and then return back the HTML to another page. |
20:32:37 | Joe_knock | Celestic: A page link to another page? |
20:32:47 | Celestic | Here, let me show you.. |
20:32:48 | Celestic | 1sec |
20:33:02 | Celestic | titan.csit.rmit.edu.au/~e54061/wp/movie-service.php?filmID=RC&CRC=s300000 |
20:33:06 | Celestic | I want to be able to query that |
20:33:12 | Celestic | with RC/AC and other values |
20:33:16 | Celestic | and then have the HTML returned |
20:33:21 | Celestic | embedded/included on a page |
20:33:25 | Celestic | I can't think of a better way to describe it |
20:33:43 | Celestic | so let's say movie.php should query movie-service.php via POST using ajax/jquery and then present it back onto the page at movie.php |
20:34:21 | Celestic | I don't understand how that'll actually work, that's the issue I'm having. |
20:34:37 | Celestic | Am I storing the HTML in a var and then echoing that var? |
20:36:30 | * | prosper__ joined #nimrod |
20:36:57 | Araq | Joe_knock: I don't know. Nor do I care. the benchmark is stupid. |
20:37:10 | * | dom96_and joined #nimrod |
20:37:39 | * | prosper_ quit (Read error: Connection reset by peer) |
20:37:46 | Celestic | Anyone got any ideas? |
20:37:49 | Celestic | or is this not the right place to ask |
20:37:49 | Joe_knock | Celestic: Do you want to "scrape" that link and then embed it into your own web page? |
20:37:56 | Araq | Celestic: how come you're here and not in #php ? |
20:38:11 | Celestic | Joe_knock - yeah, using jquery/ajax. |
20:38:16 | Celestic | Araq - I haven't registered for a username |
20:38:21 | Celestic | mainly cause freenode gets rooted like once a month |
20:38:31 | Celestic | and I don't really have any interest in having my details on a DB dump |
20:39:00 | dom96_and | Joe_knock: it was slower because I didn't optimise it at all and the test implementation was done quickly too. |
20:39:05 | Mat3 | understandable |
20:39:27 | dom96_and | Please do benchmark the latest new_async (that's a branch) jester |
20:39:27 | * | prosper__ quit (Remote host closed the connection) |
20:39:44 | Mat3 | hi dom96 |
20:39:56 | Joe_knock | dom96_and: What is the true performance (IYO) ? |
20:40:37 | Joe_knock | Celestic, Are you trying to dynamically scrape links from another website? You need to actually use a web-scraper then. |
20:40:42 | dom96_and | The problem is that it doesn't yet scale to multiple cores |
20:41:04 | dom96_and | On a single core it's equal to Golang |
20:41:30 | dom96_and | Celestic: #php |
20:41:44 | Celestic | Joe_knock |
20:41:44 | Celestic | no |
20:41:59 | Celestic | titan.csit.rmit.edu.au/~e54061/wp/movie-service.php?filmID=RC&CRC=s30000 |
20:42:04 | Celestic | I want to request this one URL using jquery/ajax |
20:42:08 | Celestic | and then embed it in MY page |
20:42:12 | Celestic | it on MY page |
20:42:14 | Joe_knock | oh!!! |
20:42:16 | Celestic | you know what I mean? |
20:42:18 | Celestic | html/php |
20:42:35 | Celestic | and I'm not really sure how to do that.. I was just going to iframe it, but i was told that wouldn't be acceptable. |
20:42:40 | Joe_knock | How do you want to embed it? Celestic |
20:42:55 | Joe_knock | aah, iframes was what I was going to suggest. |
20:43:15 | Celestic | I was trying to do something like this |
20:43:16 | Celestic | <div id='MS-film'> <div id='MS-image'><img src='http://titan.csit.rmit.edu.au/~e54061/wp/movie-service/<?php echo $imgs[$_REQUEST['filmID']]; ?>' alt='<?php echo $titles[$_REQUEST['filmID']]; ?> Poster' /></div> <div id='MS-title'><?php echo $titles[$_REQUEST['filmID']]; ?></div> <div id='MS-description'><?php echo $descriptions[$_REQUEST['filmID']]; ?></div> <div id='MS-rating'><?php echo $ratings[$_REQUEST['filmID']]; ?></di |
20:43:53 | * | Joe_knock scrubs my eyes |
20:45:12 | * | quasinoxen quit (Ping timeout: 245 seconds) |
20:46:46 | Celestic | http://pastebin.com/ffkiKThG |
20:46:51 | Celestic | that's the js I've done for it Joe_knock |
20:50:08 | Joe_knock | Celestic: Is this homework? |
20:50:14 | Celestic | Yes. It is. |
20:50:20 | Joe_knock | "No CRC code found in the POST array. See tute-lab 6 activity 3 on page 2 for more information, but here is some code that almost works to help you get started:" |
20:50:23 | Celestic | I'm not wanting someone to do it for me |
20:50:26 | Celestic | I looked there |
20:50:27 | Celestic | it doesn't clear it up |
20:50:34 | Celestic | I'm simply wanting to work out how to print |
20:50:38 | Celestic | the values from the query |
20:50:40 | Celestic | and then I can work out the rest |
20:50:41 | Celestic | tbh |
20:51:18 | dom96_and | Celestic: why are you asking here? |
20:51:27 | Joe_knock | Try storing the the values into a variable first, then pushing that variable to something like a JSON object and then rendering it from JSON. |
20:51:31 | Celestic | It's 4 AM, and I figured someone might know. |
20:51:43 | Celestic | Joe_knock - Thanks. I'll try that. |
20:51:45 | Celestic | That's actually a good idea. |
20:52:25 | Joe_knock | Celestic: The real reason they're asking is because this is nimrod and we're so far away from PHP... |
20:52:39 | Celestic | Yeah, fair enough. |
20:52:47 | Celestic | I'll try what you said |
20:52:52 | Celestic | thanks for the help though, I appreciate it. |
20:54:27 | Joe_knock | anytime Celestic. |
20:57:30 | Mat3 | I can now compile with the SDL wrapper. The problem is now, that the SDL2 library is not found: "could not load: libSDL2.so" |
20:57:41 | * | Demos joined #nimrod |
20:57:54 | Mat3 | if I try to execute the program |
20:58:49 | Mat3 | whereby the SDL test programs supplied compile and execute fine |
20:59:29 | * | Ven quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
21:04:39 | Mat3 | the librarys are correctly installed |
21:06:13 | * | dom96_and quit (Ping timeout: 260 seconds) |
21:06:54 | willwillson | whereis libSDL2.so? |
21:07:05 | Mat3 | /usr/local/lib |
21:08:58 | Mat3 | it runs if I hardcode these path to sdl2.nim |
21:10:20 | Mat3 | so some flag settings need to be fixed |
21:11:18 | willwillson | does it work if you add /usr/local/lib to LD_LIBRARY_PATH? |
21:15:50 | Mat3 | yes ! thanks. I've found out that these shell variable was not updated by the make script after compilation (SDL library) |
21:20:17 | Mat3 | instead pkg_config was used for compilation of the test programs (which returns hardcoded paths to the C compiler) |
21:21:17 | willwillson | maybe running ldconfig will help? |
21:22:04 | Mat3 | I simply have forgotten to add the local library path to my shell entry script, it runs now fine |
21:24:54 | willwillson | cool, I think dlopen will also check /etc/ld.so.cache, so if you have /usr/local/lib in your /etc/ld.so.conf and run ldconfig, it might also find it that way |
21:28:37 | Demos | Hey Araq: I notice that our subranges and substrings are closed on both ends. I mentioned this to a python programmer friend of mine and he was somewhat appaled and figured it would result in ALL THE BUGS. I disagree but I wanted to ask what the motivation was for this? |
21:29:30 | Mat3 | no, because the path is already existent in /etc/ld.so.conf/libc.conf, which is included |
21:31:46 | Jehan_ | Demos: I'm not sure why (closed, open) intervals are inherently superior (I know Dijkstra's argument and I don't buy it). |
21:31:59 | Araq | Dijkstra is simply wrong |
21:32:07 | Jehan_ | I find these intervals actually sometimes difficult to reason about. |
21:32:29 | Araq | for the simple reason that there might not be a high(x)+1 element |
21:32:29 | * | Mat3 thinks the ideas featured by ldconfig are quite mad |
21:32:34 | Jehan_ | For most people, intervals that are closed on both sides are simply the natural way of doing things. |
21:32:46 | Demos | I do not know dijkstra's argument, but in general I find each choice of intervals for array indices and ranges has a different and pretty equal set of easy to make errors |
21:33:10 | Jehan_ | Demos: It's about the same debate as 0- vs. 1-based array indexing. |
21:33:12 | Demos | having high(x) in Nimrod makes me not notice the range issues though |
21:33:15 | Demos | yeah |
21:33:17 | Araq | for x in low(myenum)..high(myenum) |
21:33:21 | Araq | case closed. |
21:33:38 | Jehan_ | Whatever you're already used to looks better to you. Confirmation bias. |
21:33:53 | Mat3 | some more syntax related discussion ? Fine |
21:34:04 | Araq | Dijkstra's way implies weakly typed enums so that high(enum)+1 can be created |
21:34:08 | Demos | I have been learning Fortran recently and I am LOVING being able to choose any shape I like for arrays |
21:34:36 | Jehan_ | Demos: It's why I always liked Pascal's way of doing arrays. |
21:34:53 | Demos | Jehan_, is pascal's the same as nimrod where you can just choose |
21:34:57 | Jehan_ | Yup. |
21:35:06 | Jehan_ | array[first..last] of type. |
21:35:19 | Demos | I do think that you need some kind of special way to take any kind of array, like DIMENSION(:) or our openarrays |
21:35:43 | Jehan_ | Wirth got rid of it in his later language designs, which I thought was misguided. |
21:36:11 | Jehan_ | For example, if you write code that involves vectors and matrices, mathematicians are used to having indices start at 1. |
21:36:44 | Jehan_ | Obviously, you can renumber those, but then you have to adjust them everywhere, which eventually leads to transcription errors. |
21:37:25 | Jehan_ | As I said, people simply tend to find more natural what they are used to. |
21:37:42 | Jehan_ | And then they usually construct ex post justifications why it's "objectively" better. :) |
21:37:48 | Demos | yeah, exactly. I do like how in fortran I think you can do stuff like INTEGER, DIMENSION(1:) :: x for a param and someone can pass you an array that is like DIMENSION(-5:2) and you would get one of DIMENSION(1:7) |
21:38:22 | Jehan_ | Yes, that's because Fortran was pretty much designed for applied mathematics. |
21:38:38 | Demos | I am really liking fortran, it is just REALLY, REALLY hard to learn |
21:38:45 | Jehan_ | Modern Fortran dialects are actually pretty neat languages. |
21:39:03 | Jehan_ | Most people don't realize how different they are from Fortran 77. |
21:39:15 | Demos | and like the allocatable arrays have automatic deallocation |
21:39:17 | EXetoC | Mat3: what about ldconfig? all I've ever had to do is add a dir to the path, and that's simple |
21:39:26 | Jehan_ | Lack of automatic memory management sucks, but is better mitigated than in most other languages. |
21:39:27 | Demos | actually I think it is just really hard to leak memory in fortran |
21:39:40 | Jehan_ | Demos: As soon as you use heap-allocated memory, easily. |
21:39:51 | EXetoC | but then there's the quirkiness regarding searching in a relative path for example |
21:39:59 | Jehan_ | The thing is more that it's easier to avoid having heap-allocated memory in Fortran. |
21:40:01 | Mat3 | I like the Fortran syntax (specially the possibility to implicitly signal variable types and ranges) |
21:40:24 | Demos | I was under the impression that if I returned like INTEGER, ALLOCATABLE, DIMENSION(:) :: result from a function it would get de-allocated at the end of the calling scope |
21:40:58 | * | DiffuseStorm joined #nimrod |
21:41:01 | Mat3 | eh, I mean all versions newer than Fortran 77? |
21:41:10 | Demos | and is has generics (sorta), good objects, good modules, really awesome parallel programming stuff, user defined operators, and so on |
21:41:15 | Demos | and it interops with C really well |
21:41:16 | Jehan_ | Demos: Yes, Fortran essentially uses automatic memory semantics for a lot of stuff |
21:41:28 | Jehan_ | Without having to write constructor/destructor boilerplate. |
21:41:57 | Demos | I would kill for a learn you a fortran 2008 though |
21:42:02 | Jehan_ | But I was talking about actual heap allocations that don't follow these simple semantics. |
21:42:33 | perturbation | Speaking as someone whose only exposure to Fortran was some relatively bad Fortran-77 code written by an (at-the-time) grad student... *shudder* |
21:42:40 | perturbation | *no* desire to revisit Fortran |
21:42:54 | perturbation | one of the languages created before the light of our lord(s) K&R |
21:43:46 | Mat3 | you mean these two guys from Berkeley with a passion for Basic and LSD ? |
21:43:57 | Jehan_ | perturbation: Fortran 2008 has pretty much nothing in common with Fortran 77 anymore. |
21:44:08 | perturbation | Berkeley == Unix + drugs... maybe related, maybe not |
21:44:16 | Araq | he means the 2 guys who never groked type systems and so conflated pointers with arrays |
21:44:17 | Demos | Also, I am not sure anyone actually has a Fortran 2008 compiler |
21:44:28 | Demos | I think intel Fortran just got full 2003 support like a month ago |
21:45:08 | Jehan_ | Demos: I don't think so, either, but Gnu Fortran supports a decent subset of the new features last I checked. |
21:45:23 | Jehan_ | Of course, I haven't written or read any actual Fortran code in years. :) |
21:45:46 | Jehan_ | I still follow the language (same as with Ada). |
21:45:51 | Araq | anyway, it's nice that nobody listened to my point |
21:46:09 | Araq | [a, b) is downright broken for a strong type system |
21:46:11 | perturbation | Araq: but how do you get buffer overflow if arrays != pointers |
21:46:28 | Araq | it's not a matter of preferences |
21:46:35 | Demos | Ada looked neat as well, but just so verbose. |
21:46:46 | Araq | [a, b] works, [a, b) does not |
21:47:02 | Mat3 | Araq: The type system in C was only introduced as hint for the code generator, safety was not a goal |
21:47:47 | * | askatasuna quit (Ping timeout: 245 seconds) |
21:47:52 | Araq | Mat3: the real problem with Unix and C is not that they are stupid to begin with. |
21:48:01 | Araq | the real problem is that they never got fixed. |
21:48:23 | Jehan_ | I think C can best be thought of as a portable assembly language still. I'm pretty sure that was also largely the design intent. |
21:49:24 | Jehan_ | Araq: Hmm, I think the problem with Unix was more that it "got fixed", after a fashion, and got encumbered with several subsystems that don't cleanly fit together. |
21:49:36 | Mat3 | Araq: Agree, except Plan 9 was planed as Unix right done |
21:49:46 | Jehan_ | Let me only mention System V IPC … :) |
21:49:58 | Demos | I do like that C gives you few ways to do things, I like how you just write a bunch of functions, and don't worry about classes or methods. Nimrod is like this too |
21:49:58 | Mat3 | BSD valloc |
21:50:15 | Jehan_ | Overall, however, I don't see a fundamental problem with Unix's design. |
21:50:33 | Araq | I don't see anything that *works* |
21:50:33 | Jehan_ | And given the limitations at the time, it was borderline brilliant. |
21:50:44 | Jehan_ | Araq: Not sure I'm following you there. |
21:51:13 | Araq | Jehan_: I see nothing that's been properly designed |
21:51:27 | Jehan_ | Araq: Hmm, then we'll probably have to agree to disagree. |
21:51:30 | Araq | the weird "nobody knows the grammar" shell languages |
21:51:45 | Araq | the non-existent APIs |
21:51:45 | Mat3 | Ehm, Unix was once created as quick and dirty replacement for Multics, primary for porting a game |
21:52:03 | Araq | the root user is ridiculous |
21:52:05 | Jehan_ | Define "non-existent APIs"? |
21:52:23 | Araq | shell escape sequences come immediatly to mind |
21:52:32 | perturbation | as opposed to what? Plan 9? OpenVMS? (Windows?) |
21:52:41 | Joe_knock | Are these syntax-level discussions encouraged? |
21:52:50 | perturbation | Unix is kind of hairy but (to misquote Churchill) its the worst thing except for everything else |
21:52:58 | Demos | I agree with that |
21:53:38 | perturbation | I *do* agree that 'POSIX-compliant' being ~= meaningless to true portability is a WTF |
21:54:21 | Mat3 | its design choices are ironical similar to MSDOS which grows from QDOS (quick and dirty operating system as CP/M clone) |
21:54:41 | Araq | so what does Unix do in a particularly good way? don't give me that pipes bullshit |
21:54:59 | Jehan_ | Demos: oddly enough, I consider the lack of classes one of Nim's weaknesses (no worries, I'm not going to advocate for their inclusion). |
21:55:12 | Araq | I've written the original osproc.nim, I know better |
21:55:32 | perturbation | err... SIGINT, SIGTERM, SIGKILL as poor man's IPC? |
21:55:32 | Araq | it's all messy and broken |
21:55:56 | Jehan_ | Araq: It has a relatively simple conceptual model that primarily relies on processes and files with a relatively simple set of operations for each. |
21:56:26 | Demos | Jehan_, I mean not having interfaces beyound some "you can do it with macros" handwaving might be good, but I dont like the idea of a datastructure that "contains" functions |
21:56:26 | Araq | Jehan_: it's all wrong from the ground up, but even if you think the principles are good |
21:56:34 | Araq | the implementation is not. |
21:56:38 | Jehan_ | Arguably, Plan 9 did that better. That's where my point about it growing poor subsystems comes into play. |
21:56:39 | perturbation | everything-is-a-file? |
21:57:21 | Jehan_ | Demos: Then you don't like modules, either? A class is simply a module that can have multiple instances. |
21:57:49 | Joe_knock | perturbation: yeah, it literally is that. |
21:57:57 | Joe_knock | folders are files also. |
21:57:57 | Jehan_ | Araq: As I said, we'll probably have to agree to disagree. |
21:58:55 | Mat3 | anyhow; There exist no real choice beside Un*x and Windows for development at moment |
21:59:07 | Araq | hey, there is Haiku :P |
21:59:14 | Araq | an Nim runs on it ... I think |
21:59:18 | Araq | *and |
21:59:26 | Jehan_ | Mat3: Pretty much. I'm actually happy that the OS landscape is not more diverse. |
21:59:54 | Jehan_ | Any new OS may fix some warts that existing ones have, but only at the cost of introducing others. |
22:00:19 | Araq | with that logic we shouldn't design new PLs either :P |
22:00:22 | Araq | *by that |
22:00:27 | Araq | so I disagree |
22:00:36 | Demos | Jehan_, I think about modules differently myself, but I guess they are kinda that |
22:00:39 | Jehan_ | Araq: That's different. |
22:00:46 | Araq | I think it's not even hard to design something better than what's out there |
22:01:01 | Jehan_ | A new OS means a ton of porting work for thousands of developers. |
22:01:10 | Jehan_ | A new language affects only those that use it. |
22:01:12 | Mat3 | Araq: Haiku recreate a now ~20 Years old operating system and runs mainly on x86 CPU's (I know there exist an incomplete ARM and AMD64 port) |
22:01:35 | Araq | Mat3: yes, but it's not Unix, so I like it ;-) |
22:01:36 | Jehan_ | Araq: No, but you go and port a reasonably large software base over to it. |
22:02:38 | DiffuseStorm | Guys I've written 1 piece of software that boots without an OS. Let me just make an Os out of it real quick. |
22:02:43 | Jehan_ | Haiku has its own problems, such as being tied to C++. |
22:03:21 | DiffuseStorm | That actually was the original intent, a small OS to learn OS dev, just don't have the time |
22:03:34 | Mat3 | there exist AROS :D |
22:03:45 | Jehan_ | Not because C++ is bad, but because they're tied to what the C++ language committee cooks up. |
22:04:59 | Jehan_ | Or having to support their own C++ dialect perpetually. |
22:05:41 | * | Mat3 just decide to create my own Computer from the ground up (with an TI DSP as main CPU) |
22:06:53 | Demos | one nice thing about C is that the ABI is always defined just because you have to do that to compile the language (pretty much) |
22:07:10 | Demos | trying to tie down an ABI for something more complex seems hopeless |
22:07:19 | Mat3 | which API, ANSI C ? |
22:07:30 | Jehan_ | ABI, not API. |
22:07:38 | Araq | oh not again |
22:07:39 | Mat3 | sorry, makes sense |
22:08:14 | Araq | ever wrapped a macro heavy piece of C code with lots of bitfields? ABI always defined my ass |
22:08:26 | * | Trustable quit (Remote host closed the connection) |
22:08:34 | Araq | ABI only works for a subset of C |
22:08:37 | DiffuseStorm | Actually I do have the time I'm just disgusted with having to use either C or C++ pretty much for least friction. I want a replacement for C. |
22:08:49 | Araq | it's just like c++ except that the subset is much larger |
22:08:54 | perturbation | Araq: b/c of endianness? |
22:08:55 | Jehan_ | Araq: Yeah, C could be simplified. |
22:09:42 | * | flaviu1 quit (Remote host closed the connection) |
22:09:45 | Araq | ABI works when you're aware of how the compiler maps it down to the byte-level and the compiler doesn't change how it does it |
22:09:56 | * | flaviu1 joined #nimrod |
22:10:29 | Araq | maybe Ocaml has a stable ABI too, who knows |
22:12:04 | Jehan_ | ABI is more about memory layout and how function calls work. |
22:12:13 | Araq | yes |
22:12:18 | Jehan_ | It's independent of most language features. |
22:12:43 | Araq | exactly, it's quite orthogonal to everything else |
22:13:06 | Araq | hence Ocaml could easily be ABI stable |
22:13:37 | Araq | though I guess having a GC is a valid counter point |
22:13:46 | * | flaviu1 quit (Remote host closed the connection) |
22:13:49 | Jehan_ | Yeah, I was thinking the same. |
22:13:54 | * | flaviu1 joined #nimrod |
22:14:07 | * | io2 quit (Quit: ...take irc away, what are you? genius, billionaire, playboy, philanthropist) |
22:15:05 | * | BlaXpirit quit (Quit: Quit Konversation) |
22:15:49 | * | Varriount_ joined #nimrod |
22:18:16 | Demos | well the OS could provide the GC |
22:18:30 | DiffuseStorm | That's true. |
22:18:32 | * | Varriount quit (Ping timeout: 245 seconds) |
22:22:26 | Jehan_ | Two problems with that: |
22:22:27 | * | flaviu1 quit (Remote host closed the connection) |
22:22:40 | Jehan_ | (1) You usually need more than one GC implementation. |
22:23:04 | Jehan_ | (2) GCs need to interact with the compiler, often in nontrivial ways. |
22:23:27 | Jehan_ | You could do it, but I'm not sure it would be a good idea. |
22:24:56 | * | flaviu1 joined #nimrod |
22:29:19 | Araq | Jehan_: I'm implementing a "mixed mode" for the compiler |
22:29:30 | Jehan_ | Define "mixed mode"? |
22:29:33 | Araq | so that modules that use importcpp are compiled as c++ |
22:29:41 | Araq | but other modules are still compiled as C |
22:29:45 | Jehan_ | Hmm, interesting. |
22:29:50 | Araq | and then its all linked together |
22:30:03 | Araq | it almost works |
22:30:08 | Araq | but |
22:30:16 | Jehan_ | But you'll have to wrap everything in extern "C" { … } so that name-mangling doesn't mess things up? |
22:30:26 | Araq | you're quick |
22:30:32 | Araq | extern "C" is causing problems |
22:30:50 | Jehan_ | I've just run into a similar problem before. |
22:31:24 | Araq | well I'm tinkering with a complex solution |
22:31:37 | * | kuzy000_ quit (Ping timeout: 260 seconds) |
22:31:51 | Araq | where imported procs get the extern "C" if the module is compiled as C |
22:32:18 | Araq | but I wonder if we can always generate NIM_EXTERNC instead |
22:33:40 | Araq | which is a macro that expands to nothing unless __cplusplus is defined |
22:34:53 | Jehan_ | Araq: Hmm. Not 100% sure. |
22:34:58 | * | bogen joined #nimrod |
22:35:19 | Jehan_ | Speaking of importc and friends, is there a way to have an importc require more than one header? |
22:38:42 | Araq | no. You have to hack around it with a dummy symbol that you actually use somehow |
22:39:06 | * | Mat3 quit (Quit: Verlassend) |
22:39:43 | Araq | hrm unfined reference to `__gxx_personality_sj0' |
22:39:56 | Araq | so the linking needs to be done with g++ .... |
22:40:01 | * | Araq sighs |
22:41:02 | Jehan_ | Or probably link the C++ stdlib explicitly (not that that helps). |
22:41:26 | Araq | not sure if that can be done in a portable way |
22:41:37 | Jehan_ | Yeah, that's what I meant. |
22:41:56 | Jehan_ | Do C++ exceptions in mixed mode use setjmp? |
22:42:15 | Jehan_ | Because if you mix setjmp() and try, that may become interesting. |
22:42:32 | Araq | yeah ... that's what I'm trying |
22:42:58 | Araq | however for what I've in mind it should be fine |
22:43:03 | Jehan_ | Anyhow, I'm off. See you. :) |
22:43:10 | * | Jehan_ quit (Quit: Leaving) |
22:44:11 | * | flaviu1 quit (Read error: No route to host) |
22:44:24 | * | flaviu1 joined #nimrod |
22:46:10 | Araq | hrm for bigbreak we can get rid of all these old C compiler configurations, right? |
22:46:25 | DiffuseStorm | Araq: (I'm assuming you've written parsers) Where did you learn how to parse a programming language? It seems particularly tricky. I'm not sure how one would build a tree, given that errors can be anywhere. |
22:46:40 | bogen | who uses the old C compiler configurations? |
22:46:58 | Araq | bogen: I don't know. |
22:47:31 | DiffuseStorm | Lexing is super easy, than x500 in difficuly xD |
22:48:14 | Araq | DiffuseStorm: I wrote my first interpreter for some domain specific language when I was 16 iirc |
22:48:30 | DiffuseStorm | Hmm not bad. |
22:48:50 | Araq | so I don't remember how I learned it |
22:48:53 | DiffuseStorm | kk |
22:49:59 | * | Jesin quit (Quit: Leaving) |
22:50:23 | * | Jesin joined #nimrod |
22:51:07 | Triplefox | I think I made progress by playing with PEG.js in college |
22:51:16 | * | Shoop joined #nimrod |
22:51:22 | Araq | thinking about it |
22:51:43 | Araq | there was no clean separation between lexer and parser |
22:51:45 | DiffuseStorm | Araq: what's the hardest stage? |
22:51:49 | DiffuseStorm | I see |
22:51:54 | Triplefox | PEGs are fun and pretty simple conceptually, from there I just started doing hand-written parsers that were combinations of state machine and recursive descent |
22:52:06 | Araq | and I did it with substring and "delete" |
22:52:08 | Triplefox | it helped when i started adding more passes |
22:52:44 | Shoop | Hi, beginner here. Im getting strange behavior from this program but im probably doing something stupid. It only prints a single '\n' instead of cba - http://pastebin.com/PkRZwPQc |
22:52:52 | Araq | DiffuseStorm: hardest is to implement somewhat efficient precedence handling |
22:53:33 | Shoop | oops i mean abc, i am going to make it reverse but i was running into strange errors |
22:53:50 | Araq | Shoop: use newStringOfCap or don't use 'add' but result[i] = s[i] instead |
22:53:56 | DiffuseStorm | The only thing I have done so far related to parsing (when I was 17, now 20) was to parse Excel documents and generate a c# program from it. Then I created special commands within Excel I'd write to control how the program would be generated. It was a very specific solution to a data exploration quest. |
22:54:09 | Shoop | Araq: why doesnt add work? |
22:54:38 | Araq | it "works" but it adds after the len(s)s characters |
22:54:41 | DiffuseStorm | Basically Excel specified a single 'test' and the program was then generated to run that test through tons of data. |
22:54:53 | Shoop | Araq: are strings of static length? |
22:54:54 | Araq | and so you have binary zeros in the string that 'echo' doesn't handle |
22:55:10 | Araq | Shoop: no. |
22:55:29 | Shoop | Araq: then why doesnt add extend the length of the string? |
22:55:36 | Araq | it does. |
22:55:46 | Araq | but you need to listen |
22:56:06 | Shoop | Araq: just curious about behind the scenes, your changes are correct |
22:56:23 | Araq | well I already explained it to you |
22:56:31 | Araq | result = newString(3) |
22:56:35 | Araq | produces: |
22:56:41 | Araq | "\0\0\0" |
22:56:49 | Araq | then you add to *that* |
22:57:01 | Araq | but echo only prints up to the first \0 |
22:57:03 | Shoop | Araq: so once i use newString to set the length of the string, echo will only print that many characters? |
22:57:13 | Shoop | Araq: oh wait nvm |
22:57:22 | Shoop | Araq: the \0 signals the end of the string |
22:57:23 | * | enquora quit (Quit: enquora) |
22:57:31 | Demos | no, echo prints till it sees a \0, I recomend you just say result = "" |
22:57:35 | Demos | and then add to that |
22:57:56 | Araq | Shoop: not really but echo uses C's output functions |
22:58:06 | Araq | and so inherits that \0 behaviour |
22:58:23 | Araq | fixing it causes other problems |
22:58:26 | Shoop | Araq: ok i understand now, thanks for explaining :D. Really liking the language btw |
22:59:16 | Araq | btw for reverse you should iterate from 0 to s.len div 2 |
22:59:34 | Araq | otherwise you reverse twice and end up with nothing reversed |
23:00:26 | Shoop | Araq: ok, cool thanks |
23:02:37 | Shoop | And a random question, why not make 10..0 work so you can have decreasing range statements? |
23:03:26 | Araq | DiffuseStorm: parsing however, is the easy part of a compiler. everything after parsing is *much* harder |
23:04:19 | Araq | Shoop: that cannot work in any reasonable way |
23:05:05 | Shoop | Make a..b where b < a = the reverse of b..a? |
23:05:32 | DiffuseStorm | Yeah I imagined so |
23:06:29 | Araq | Shoop: so 0.. x.len-1 if x.len == 0 should iterate in reverse? that's madness |
23:07:04 | Shoop | 0..0 is just 0 regardless |
23:07:23 | Araq | but it's 0.. -1 |
23:07:25 | Shoop | oh i see |
23:07:42 | Shoop | good point |
23:07:52 | Shoop | *shuffles into corner |
23:07:54 | * | Shoop quit (Quit: Page closed) |
23:17:29 | * | perturbation quit (Quit: goodbye, all!) |
23:22:04 | NimBot | Araq/Nimrod bigbreak c99ec16 Araq [+0 ±4 -0]: deprecated string case statements without 'else' |
23:22:04 | NimBot | Araq/Nimrod bigbreak 4298553 Araq [+0 ±3 -0]: system.writeFile works at compile-time |
23:22:04 | NimBot | Araq/Nimrod bigbreak 2475794 Araq [+0 ±1 -0]: fixes a minor bug when 'type' is used in a wrong way |
23:22:04 | NimBot | Araq/Nimrod bigbreak 62ccf13 Araq [+0 ±2 -0]: 'try' works at compile-time |
23:22:04 | NimBot | 3 more commits. |
23:46:28 | * | Matthias247 quit (Read error: Connection reset by peer) |