00:07:50 | * | yglukhov joined #nim |
00:13:16 | * | yglukhov quit (Ping timeout: 250 seconds) |
00:27:29 | * | Matthias247 quit (Read error: Connection reset by peer) |
00:30:36 | * | jaco60 quit (Ping timeout: 250 seconds) |
00:32:52 | * | Jesin joined #nim |
00:38:53 | * | bigfondue_ quit (Ping timeout: 246 seconds) |
00:47:15 | * | makoLine quit (Ping timeout: 240 seconds) |
01:08:07 | * | solidsnack quit (Quit: My Mac has gone to sleep. ZZZzzz…) |
01:10:18 | * | yglukhov joined #nim |
01:13:58 | * | Demon_Fox joined #nim |
01:14:35 | * | yglukhov quit (Ping timeout: 240 seconds) |
01:21:06 | * | vendethiel quit (Ping timeout: 240 seconds) |
01:27:10 | cryzed | So I got kind of bored with the markdown parser... |
01:27:22 | cryzed | trying my hand at a simple snake for now using the sdl2 bindings |
01:27:44 | cryzed | The problem wasn't lexing or parsing the tokens in the end -- it's writing the regular expressions |
01:31:44 | cryzed | https://gist.github.com/cryzed/7e3e3fe2286e48866228 if anyone wants to continue where I left off with my code (although I doubt it) |
01:40:53 | cryzed | Is there possibly something similar to Python's decorators in Nim? I would like to mark some procs with certain requirements, i.e. a certain init function must have been called before they can be used -- is there something like that, possibly using Nim's macro system? |
02:12:14 | * | [CBR]Unspoken quit (Read error: Connection reset by peer) |
02:26:24 | * | phao quit (Ping timeout: 256 seconds) |
02:32:09 | * | [CBR]Unspoken joined #nim |
02:34:46 | cryzed | dom96, some more symbol forwarding in certain modules seems like a good idea for example |
02:34:52 | cryzed | htmlparser comes to mind |
02:34:57 | cryzed | or option for nre |
02:39:18 | * | xiong joined #nim |
02:57:42 | * | ulyssesdwolfe joined #nim |
02:59:30 | * | ulyssesdwolfe quit (Client Quit) |
03:10:51 | * | xiong quit (Quit: Page closed) |
03:11:37 | * | yglukhov joined #nim |
03:16:16 | * | yglukhov quit (Ping timeout: 256 seconds) |
03:39:21 | * | Guest28428 is now known as Heartmender |
03:40:24 | onionhammer | cryzed ive asked for such a feature before.. constructors |
03:43:28 | * | exebook quit (Ping timeout: 256 seconds) |
03:48:35 | cryzed | onionhammer, how are constructors related to what I have said? I don't follow |
03:49:12 | cryzed | onionhammer, I am talking about decorators -- as in easily wrap other functions in different functions |
03:50:25 | cryzed | onionhammer, to have a "constructor" you can simply define a type, write a newMyType func that initializes that creates and initializes that type using the implicitly created type constructor and then define procs with the first argument of your type |
03:50:37 | cryzed | there you have your class/object with constructors -- but that's not what I meant |
03:59:36 | * | exebook joined #nim |
04:04:09 | * | bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…) |
04:08:06 | * | bjz joined #nim |
05:01:43 | onionhammer | cryzed, you said "certain init function must have been called before they can be used" |
05:01:59 | onionhammer | cryzed I interpreted this as "the proc expects the object to be initialized properly" |
05:02:19 | onionhammer | right now nim has no guarantees someone didnt just create an instance of a type without going through the so-called 'constructor' |
05:02:23 | onionhammer | it's not a true constructor |
05:02:32 | onionhammer | so the object can be in any state the caller wants |
05:03:39 | onionhammer | when I say "constructor" i mean that the only way to get one of those objects is to actually invoke one of the constructors for that type |
05:03:51 | onionhammer | excepting perhaps value types in an array |
05:13:06 | * | yglukhov joined #nim |
05:13:28 | * | sepisoad joined #nim |
05:17:26 | * | yglukhov quit (Ping timeout: 240 seconds) |
05:18:06 | * | exebook quit (Ping timeout: 256 seconds) |
05:21:58 | * | bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…) |
05:24:59 | * | bjz joined #nim |
05:36:43 | * | solidsnack joined #nim |
05:41:52 | * | solidsnack quit (Quit: My Mac has gone to sleep. ZZZzzz…) |
05:42:03 | * | exebook joined #nim |
05:43:08 | * | desophos_ joined #nim |
05:47:00 | * | desophos quit (Ping timeout: 256 seconds) |
05:48:35 | * | ephja quit (Ping timeout: 240 seconds) |
05:55:46 | * | darkf joined #nim |
05:59:09 | * | solidsnack joined #nim |
05:59:32 | * | solidsnack quit (Client Quit) |
06:00:23 | * | solidsnack joined #nim |
06:01:22 | * | xiongxin joined #nim |
06:04:10 | * | desophos_ quit (Read error: Connection reset by peer) |
06:08:52 | * | solidsnack quit (Ping timeout: 272 seconds) |
06:14:37 | * | Demon_Fox quit (Quit: Leaving) |
06:25:37 | * | solidsnack joined #nim |
06:40:14 | * | BitPuffin|osx quit (Ping timeout: 250 seconds) |
06:46:32 | * | M-Quora quit (Remote host closed the connection) |
06:46:33 | * | M-max quit (Remote host closed the connection) |
06:56:18 | * | M-Quora joined #nim |
07:08:12 | * | sepisoad quit (Quit: Leaving) |
07:14:22 | * | yglukhov joined #nim |
07:16:09 | * | M-max joined #nim |
07:17:54 | * | arnetheduck quit (Ping timeout: 272 seconds) |
07:18:26 | * | yglukhov quit (Ping timeout: 240 seconds) |
07:29:29 | * | gour joined #nim |
07:30:36 | * | arnetheduck joined #nim |
08:00:39 | * | allan0 joined #nim |
08:02:39 | * | allan0_ quit (Ping timeout: 250 seconds) |
08:06:35 | * | gokr quit (Ping timeout: 240 seconds) |
08:28:48 | * | HakanD___ joined #nim |
08:35:07 | * | barosl joined #nim |
08:44:18 | * | xiongxin quit (Ping timeout: 252 seconds) |
08:47:03 | * | barosl quit (Quit: Leaving) |
09:06:28 | * | solidsnack quit (Ping timeout: 256 seconds) |
09:08:51 | * | solidsnack joined #nim |
09:13:50 | * | solidsnack quit (Ping timeout: 256 seconds) |
09:15:46 | * | yglukhov joined #nim |
09:20:46 | * | yglukhov quit (Ping timeout: 272 seconds) |
09:54:47 | * | yglukhov joined #nim |
10:03:19 | * | solidsnack joined #nim |
10:07:40 | * | solidsnack quit (Ping timeout: 256 seconds) |
10:25:38 | * | vikaton quit (Read error: Connection reset by peer) |
10:25:39 | * | mikolalysenko quit (Ping timeout: 260 seconds) |
10:25:39 | * | NhanH quit (Ping timeout: 250 seconds) |
10:26:05 | * | CARAM__ quit (Ping timeout: 250 seconds) |
10:26:05 | * | n1ftyn8_ quit (Ping timeout: 250 seconds) |
10:26:11 | * | clone1018 quit (Ping timeout: 246 seconds) |
10:27:03 | * | biscarch quit (Ping timeout: 260 seconds) |
10:30:18 | * | Guest4360 quit (Ping timeout: 260 seconds) |
10:31:11 | * | Matthias247 joined #nim |
10:40:34 | * | HakanD___ quit (Ping timeout: 272 seconds) |
10:41:30 | * | HakanD___ joined #nim |
10:43:05 | * | NhanH joined #nim |
10:44:25 | * | vikaton joined #nim |
10:44:47 | * | CARAM__ joined #nim |
10:47:07 | * | Guest4360 joined #nim |
10:47:53 | * | n1ftyn8_ joined #nim |
10:48:00 | * | biscarch joined #nim |
10:48:13 | * | clone1018 joined #nim |
10:49:10 | * | mikolalysenko joined #nim |
10:49:11 | * | gour quit (Read error: Connection reset by peer) |
10:50:37 | * | gour joined #nim |
10:52:49 | * | yglukhov quit (Remote host closed the connection) |
10:54:37 | * | yglukhov joined #nim |
10:58:46 | * | yglukhov quit (Ping timeout: 240 seconds) |
11:02:31 | * | jaco60 joined #nim |
11:03:38 | * | xiongxin joined #nim |
11:16:16 | * | vendethiel joined #nim |
11:19:29 | * | HakanD___ quit (Quit: Be back later ...) |
11:49:50 | * | boopisaway is now known as boop |
11:51:41 | * | solidsnack joined #nim |
11:55:55 | * | solidsnack quit (Ping timeout: 240 seconds) |
12:06:44 | * | sepisoad joined #nim |
12:16:53 | * | gokr joined #nim |
12:47:18 | * | phao joined #nim |
12:53:07 | cryzed | onionhammer, why is such a constructor needed though? If you make it clear in the documentation "use this constructor or you are on your own" I don't see the problem |
12:53:10 | * | sepisoad quit (Read error: Connection reset by peer) |
12:56:10 | * | yglukhov joined #nim |
12:57:14 | * | gokr quit (Quit: Leaving.) |
12:57:24 | * | gokr joined #nim |
13:01:26 | * | yglukhov quit (Ping timeout: 240 seconds) |
13:02:58 | cryzed | Araq, why are the destroy procs in the SDL2 bindings overloaded for most stuff, but explicit for texture and renderer? |
13:03:20 | cryzed | Oh wait, nevermind. They are just at a different place |
13:03:29 | * | xiongxin quit (Quit: Page closed) |
13:10:36 | * | yglukhov joined #nim |
13:13:30 | * | sepisoad joined #nim |
13:14:46 | * | yglukhov quit (Ping timeout: 240 seconds) |
13:17:43 | dom96 | cryzed: In regards to your markdown parser, I personally wouldn't use regular expressions to do the parsing. |
13:17:56 | cryzed | dom96, just do it character by character? |
13:18:00 | dom96 | yeah |
13:18:13 | cryzed | I thought about that too, I might reconsider doing it that way -- you are right |
13:18:35 | cryzed | regex probably make more sense for more structured langauges with actual error states for the syntax |
13:18:40 | cryzed | everything is valid in markdown |
13:21:22 | cryzed | dom96, I did something like this: https://gist.github.com/cryzed/a0c9f99ffb58f4bc58da |
13:21:32 | cryzed | it's caller logger.nim and I import it in various modules |
13:21:58 | cryzed | does this do what I expect it to? I.e. create no-ops in my regular code when I use any of the overwritten templates, and only create code when I use enableLogging? |
13:22:12 | cryzed | I am planning to possibly use these in game code, so I need a way to disable them entirely with no overhead whatsoever |
13:22:18 | cryzed | *called |
13:24:34 | dom96 | cryzed: yeah, looks good. |
13:27:35 | * | gour quit (Quit: WeeChat 1.3) |
13:30:51 | * | sepisoad quit (Read error: Connection reset by peer) |
13:34:01 | cryzed | dom96, :) |
13:34:05 | * | Jesin quit (Quit: Leaving) |
13:39:49 | * | solidsnack joined #nim |
13:41:57 | * | ephja joined #nim |
13:44:02 | * | solidsnack quit (Ping timeout: 250 seconds) |
13:58:02 | * | yglukhov joined #nim |
14:02:16 | * | yglukhov quit (Ping timeout: 256 seconds) |
14:24:50 | * | matkuki joined #nim |
14:27:05 | * | yglukhov joined #nim |
14:31:15 | * | yglukhov quit (Ping timeout: 240 seconds) |
14:35:57 | * | matkuki quit (Quit: ChatZilla 0.9.92 [Firefox 42.0/20151029151421]) |
14:39:08 | * | HakanD___ joined #nim |
14:42:28 | * | matkuki joined #nim |
14:44:40 | * | Jesin joined #nim |
14:45:54 | * | matkuki quit (Client Quit) |
14:49:43 | * | yglukhov joined #nim |
14:51:09 | * | HakanD____ joined #nim |
14:52:42 | * | HakanD___ quit (Ping timeout: 256 seconds) |
14:53:44 | * | HakanD____ quit (Read error: No route to host) |
14:54:32 | * | yglukhov quit (Ping timeout: 272 seconds) |
14:54:43 | * | HakanD____ joined #nim |
15:00:57 | * | yglukhov joined #nim |
15:02:33 | * | sepisoad joined #nim |
15:05:06 | * | yglukhov quit (Ping timeout: 240 seconds) |
15:12:22 | * | yglukhov joined #nim |
15:14:52 | * | HakanD____ quit (Quit: Be back later ...) |
15:16:03 | * | HakanD_____ joined #nim |
15:16:26 | * | yglukhov quit (Ping timeout: 240 seconds) |
15:24:28 | * | yglukhov joined #nim |
15:27:56 | * | solidsnack joined #nim |
15:28:54 | * | yglukhov quit (Ping timeout: 250 seconds) |
15:32:22 | * | solidsnack quit (Ping timeout: 256 seconds) |
15:35:28 | * | yglukhov joined #nim |
15:36:04 | * | aziz joined #nim |
15:39:46 | * | yglukhov quit (Ping timeout: 240 seconds) |
15:46:28 | * | yglukhov joined #nim |
15:50:46 | * | yglukhov quit (Ping timeout: 240 seconds) |
15:53:51 | * | sepisoad quit (Quit: Yaaic - Yet another Android IRC client - http://www.yaaic.org) |
15:57:23 | * | yglukhov joined #nim |
16:03:09 | * | HakanD_____ quit (Quit: Be back later ...) |
16:03:46 | * | yglukhov quit (Ping timeout: 240 seconds) |
16:05:49 | * | Ven joined #nim |
16:10:11 | * | kevincoleman joined #nim |
16:10:40 | * | kevincoleman quit (Client Quit) |
16:18:12 | * | Jesin quit (Quit: Leaving) |
16:28:36 | * | smithy_ joined #nim |
16:29:59 | * | smithy_ left #nim ("Leaving") |
16:40:40 | * | Trustable joined #nim |
16:55:33 | * | Jesin joined #nim |
16:57:18 | * | gokr quit (Read error: Connection reset by peer) |
17:01:00 | * | BitPuffin|osx joined #nim |
17:13:31 | * | matkuki joined #nim |
17:16:15 | * | solidsnack joined #nim |
17:21:28 | * | solidsnack quit (Ping timeout: 272 seconds) |
17:44:46 | matkuki | Are there any tutorials on concepts? |
17:53:14 | reactormonk | matkuki, they're still somewhat buggy IIRC |
17:54:08 | matkuki | reactormonk: Oh, ok. |
17:55:06 | gmpreussner | not true. concepts work really well now. Araq put in a lot of fixes in the past weeks. |
17:55:14 | reactormonk | gmpreussner, cool |
17:55:25 | reactormonk | matkuki, think of typeclasses. That's a good start. |
17:55:31 | gmpreussner | the remaining problems are in the GitHub issues list, but there aren't many left. |
17:55:43 | reactormonk | concepts can do a more, but typeclasses are the basics. |
17:56:25 | ephja | really? |
17:56:45 | reactormonk | hm? |
17:56:58 | matkuki | reactormonk: I have never used concepts before, any links on good tutorial docs in other languages? |
17:57:30 | ephja | if concepts do work well then that means that many relevant issues haven't been closed yet |
17:57:41 | ephja | solved issues to be exact |
17:58:21 | reactormonk | matkuki, yeah, look up typeclasses and/or interfaces. The downside of interfaces as opposed to typeclasses is that interfaces need to be implemented when the object is open, e.g. in the class definition. typeclasses for a type can be defined anywhere. |
17:59:06 | matkuki | Thanks, will do. |
17:59:20 | gmpreussner | ephja: there are remaining issues, to be sure, but in my extensive use of concepts i haven't found many that were blockers. most use cases are covered, and much of the rest has acceptable workarounds |
17:59:32 | reactormonk | ,ahttp://learnyouahaskell.com/types-and-typeclasses |
17:59:34 | reactormonk | matkuki, http://learnyouahaskell.com/types-and-typeclasses |
18:00:01 | matkuki | reactormonk: Great! |
18:00:36 | ephja | gmpreussner: what about var parameters? they are very common |
18:00:59 | ephja | can they be worked around without having to rewrite everything once 'var' in concepts work correctly? |
18:02:30 | ephja | I don't recall seeing anything resembling concept fixes |
18:06:06 | * | NhanH quit (Ping timeout: 240 seconds) |
18:09:46 | * | NhanH joined #nim |
18:10:34 | * | CARAM___ joined #nim |
18:10:52 | * | clone1018_ joined #nim |
18:13:26 | * | LibreWulf quit (Ping timeout: 240 seconds) |
18:13:26 | * | Guest4360 quit (Ping timeout: 240 seconds) |
18:13:26 | * | strcmp1 quit (Ping timeout: 240 seconds) |
18:13:27 | * | clone1018 quit (Ping timeout: 240 seconds) |
18:13:28 | * | themagician quit (Ping timeout: 240 seconds) |
18:13:28 | * | CARAM__ quit (Ping timeout: 240 seconds) |
18:13:29 | * | Sornaensis quit (Ping timeout: 240 seconds) |
18:13:29 | * | dv-_ quit (Ping timeout: 240 seconds) |
18:15:24 | * | themagician joined #nim |
18:15:34 | * | clone1018_ is now known as clone1018 |
18:16:42 | * | BitPuffin|osx quit (Ping timeout: 256 seconds) |
18:17:38 | * | CARAM___ is now known as CARAM__ |
18:20:31 | * | Sornaensis joined #nim |
18:20:31 | * | strcmp1 joined #nim |
18:21:11 | * | LibreWulf joined #nim |
18:21:23 | * | Guest4360 joined #nim |
18:26:33 | * | Sornaensis quit (Ping timeout: 240 seconds) |
18:28:31 | * | Sornaensis joined #nim |
18:29:20 | * | krux_ joined #nim |
18:29:30 | * | dv- joined #nim |
18:29:31 | * | dv- quit (Signing in (dv-)) |
18:29:31 | * | dv- joined #nim |
18:29:31 | * | krux_ quit (Changing host) |
18:29:31 | * | krux_ joined #nim |
18:32:32 | krux_ | How do I cast an array[4, array[4, float64]] to a ptr float64 ? I need this to pass it into a c function |
18:33:11 | krux_ | value[0][0].addr doesn't compile, it says there is no address |
18:42:18 | * | Ven quit (Quit: My MacBook has gone to sleep. ZZZzzz…) |
18:43:46 | * | HakanD_____ joined #nim |
18:46:09 | krux_ | anybody here? |
18:51:58 | ephja | krux_: it must be a var |
18:52:47 | ephja | wasn't unsafeAddr supposed to work on immutable variables? but that doesn't seem to be the case |
18:55:32 | krux_ | despite the fact that I don't know why let varibles don't work, the problem is something else |
18:55:57 | krux_ | value[0].addr works, but it is the wrong type |
18:56:21 | krux_ | value[0][0].addr would be the right type, but the compiler says: expression has no address |
18:58:50 | ephja | works for me |
18:59:12 | krux_ | what works for you? |
19:00:01 | krux_ | ephja: does value[0][0].addr work for you? |
19:00:13 | ephja | x.addr, x[0].addr and x[0][0].addr, where x is "var x: array[4, array[4, float64]]" |
19:00:32 | krux_ | what is your nim version? |
19:00:55 | ephja | Nim Compiler Version 0.12.1 (2015-12-03) [Linux: amd64] |
19:01:16 | krux_ | ok I have 0.12.0 |
19:01:21 | krux_ | maybe that is the reason |
19:02:02 | ephja | and this doesn't work? https://gist.github.com/ephja/945811bf28f039c54504 |
19:04:02 | * | Jesin quit (Quit: Leaving) |
19:05:11 | * | yglukhov joined #nim |
19:24:04 | * | sepisoad joined #nim |
19:24:44 | * | kulelu88 joined #nim |
19:24:44 | * | kulelu88 quit (Changing host) |
19:24:44 | * | kulelu88 joined #nim |
19:26:23 | krux_ | ephja: actually it is funny, because it does work. The problem must be something else |
19:26:41 | krux_ | I am working with glm and would like to pass matrid to glLoadMatrixd |
19:26:57 | * | yglukhov quit (Remote host closed the connection) |
19:33:54 | * | heinrich5991 quit (*.net *.split) |
19:33:54 | * | BlaXpirit quit (*.net *.split) |
19:33:54 | * | SirCmpwn quit (*.net *.split) |
19:33:54 | * | CcxCZ quit (*.net *.split) |
19:33:55 | * | mtj_ quit (*.net *.split) |
19:33:55 | * | eldamar quit (*.net *.split) |
19:33:56 | * | fold3 quit (*.net *.split) |
19:33:56 | * | rinukkusu quit (*.net *.split) |
19:33:56 | * | low-profile quit (*.net *.split) |
19:33:57 | * | cncl quit (*.net *.split) |
19:33:57 | * | dv- quit (*.net *.split) |
19:33:58 | * | so quit (*.net *.split) |
19:33:58 | * | sarlalian quit (*.net *.split) |
19:33:59 | * | onionhammer quit (*.net *.split) |
19:33:59 | * | federico3 quit (*.net *.split) |
19:33:59 | * | SianaGearz quit (*.net *.split) |
19:33:59 | * | joebo quit (*.net *.split) |
19:33:59 | * | delian66 quit (*.net *.split) |
19:34:20 | * | dv- joined #nim |
19:34:21 | * | heinrich5991 joined #nim |
19:34:21 | * | BlaXpirit joined #nim |
19:34:21 | * | SirCmpwn joined #nim |
19:34:21 | * | so joined #nim |
19:34:21 | * | cncl joined #nim |
19:34:21 | * | low-profile joined #nim |
19:34:21 | * | rinukkusu joined #nim |
19:34:21 | * | fold3 joined #nim |
19:34:21 | * | eldamar joined #nim |
19:34:21 | * | mtj_ joined #nim |
19:34:21 | * | CcxCZ joined #nim |
19:34:21 | * | sarlalian joined #nim |
19:34:21 | * | onionhammer joined #nim |
19:34:21 | * | federico3 joined #nim |
19:34:21 | * | SianaGearz joined #nim |
19:34:21 | * | joebo joined #nim |
19:34:21 | * | delian66 joined #nim |
19:37:09 | * | heinrich5991 quit (Excess Flood) |
19:39:22 | * | heinrich5991 joined #nim |
19:39:44 | * | so quit (Ping timeout: 245 seconds) |
19:40:39 | * | desophos joined #nim |
19:43:24 | * | BitPuffin|osx joined #nim |
19:44:39 | * | yglukhov joined #nim |
20:06:53 | * | makoLine joined #nim |
20:09:42 | * | bjz quit (Quit: Textual IRC Client: www.textualapp.com) |
20:10:06 | * | bjz joined #nim |
20:16:17 | * | boop quit (Ping timeout: 250 seconds) |
20:32:02 | * | sepisoad quit (Quit: Leaving) |
20:35:14 | * | so joined #nim |
20:36:46 | * | darkf quit (Quit: Leaving) |
20:37:26 | * | bjz quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…) |
20:39:14 | * | matkuki quit (Quit: ChatZilla 0.9.92 [Firefox 42.0/20151029151421]) |
20:43:39 | * | boop joined #nim |
20:52:58 | * | mat4 joined #nim |
20:53:28 | onionhammer | cryzed why? because people dont read documentation, and its better to get an error at compile time than at runtime |
20:53:42 | mat4 | hi all |
20:53:42 | cryzed | I see |
20:53:45 | cryzed | mat4, hi |
20:54:27 | cryzed | onionhammer, couldn't you always set a hidden attribute for your type "instantiated" that only gets set by your newX method? |
20:54:40 | cryzed | that way you could check manually I suppose |
20:54:44 | onionhammer | that would be a runtime error |
20:54:47 | cryzed | but it's a workaround definitely, yes |
20:54:52 | cryzed | yeah |
20:55:39 | cryzed | I don't think you'll get your wish unfortunately -- the release is nearing and this seems like a big feature to simply patch in |
20:56:54 | * | HakanD_____ quit (Quit: Be back later ...) |
21:01:42 | * | gunn quit (Max SendQ exceeded) |
21:02:11 | onionhammer | heres the thread i was referring to if ur curious http://forum.nim-lang.org/t/703 |
21:06:51 | onionhammer | imo my proposal for module-only initialization is all we'd really need |
21:07:18 | * | k1io quit (Ping timeout: 260 seconds) |
21:07:40 | onionhammer | i.e. give lib authors the ability to restrict callers from invoking the constructor syntax for a type they defined in their module |
21:09:31 | * | yglukhov_ joined #nim |
21:09:31 | * | yglukhov quit (Read error: Connection reset by peer) |
21:09:44 | * | k1io joined #nim |
21:10:01 | * | gunn joined #nim |
21:14:24 | * | gunn quit (Max SendQ exceeded) |
21:18:31 | * | gunn joined #nim |
21:21:30 | * | yglukhov_ quit (Ping timeout: 272 seconds) |
21:22:16 | * | gunn quit (Max SendQ exceeded) |
21:28:15 | cryzed | onionhammer, thanks for linking it |
21:28:20 | cryzed | seems like a controversial topic for sure |
21:30:58 | * | gunn joined #nim |
21:37:38 | * | yglukhov joined #nim |
21:41:46 | * | yglukhov quit (Ping timeout: 240 seconds) |
21:41:50 | kulelu88 | what do you guys think of #crystal-lang? |
21:42:45 | mat4 | nice |
21:48:11 | cryzed | I don't get hwo you can advertise with "ruby-inspired snytax" |
21:48:20 | cryzed | but I suppose that's entirely subjective |
21:48:31 | * | matkuki joined #nim |
21:48:32 | cryzed | *how *syntax |
21:49:02 | kulelu88 | they use LLVM while nim uses its own compiler |
21:50:16 | cryzed | can't you freely choose the compiler backend? |
21:51:46 | kulelu88 | I find that language interesting because it is in some ways similar to the market Nim appeals to |
21:52:27 | * | jakesyl joined #nim |
21:52:34 | cryzed | It was uninteresting to me as soon as I read Ruby-like syntax |
21:52:50 | cryzed | That might be superficial, but I need to like the language I plan on working with |
21:53:22 | kulelu88 | cryzed: what issues do you have with Ruby? |
21:53:32 | cryzed | I don't like the syntax |
21:53:37 | cryzed | also it's slow |
21:53:40 | cryzed | er than Python |
21:53:44 | cryzed | I'm a Python guy |
21:54:09 | cryzed | IMHO the only reason it's still somewhat alive is because of Ruby on Rails |
21:54:11 | kulelu88 | but I've heard folks say ruby and python are similar |
21:54:23 | cryzed | they are, in so far that they are both interpreted languages -- that's about it |
21:54:57 | kulelu88 | I need to learn more about how they are different |
21:58:19 | cryzed | kulelu88, I suspect you'll quickly find that Python is much stronger in most aspects -- stdlib, speed, active community and really cool projects in regards to making it faster (PyPy, Nuitka etc.). Then again, I admit, I haven't checked out Ruby any more than on a superficial level, but I immediately disliked how it felt. When and if you read an article about ruby it's usually guranteed to mention webframework or RoR at least once, and that's |
21:58:19 | cryzed | the top reason it's still popular imho. |
21:58:48 | matkuki | What is the most elegant way to get around this? |
21:58:50 | matkuki | https://bpaste.net/show/ef04e8ed029f |
21:59:37 | cryzed | by initializing fillCount to 1? |
22:00:06 | cryzed | it is named fill - count, if you set count to 0 and expect it to print one of the filled indexes that wouldn't make much sense |
22:00:58 | matkuki | it shouldn't even loop, like in most other languages. |
22:03:00 | cryzed | your code runs for me |
22:03:33 | matkuki | really, let me check again... |
22:03:46 | cryzed | as in, it doesn't loop |
22:04:42 | matkuki | You're right! Wrong example. |
22:06:02 | matkuki | Damn, the correct line is 'fillCount: uint32 = 0' |
22:06:47 | matkuki | Araq was right, try not to use unsigned! Thanks cryzed! |
22:07:00 | ephja | you dislike ruby's syntax? |
22:07:05 | cryzed | matkuki, yep :) |
22:07:06 | cryzed | I do |
22:07:11 | ephja | and I dunno how one can be inspired by something in an objective manner |
22:08:02 | cryzed | ephja, I don't follow. Crystal advertises with that |
22:08:55 | ephja | yes, but why can't you advertise the fact that a particular language has been inspired by another? |
22:10:17 | cryzed | You can -- it just doesn't appeal to me. Not the fact that it says its syntax was inspired by Ruby, but the fact that it syntax was inspired by Ruby |
22:10:23 | ephja | matkuki: or 0u32 |
22:10:24 | cryzed | *its |
22:11:19 | ephja | is it verbose? inconsistent? |
22:11:28 | matkuki | ephja: will try |
22:12:19 | * | boop is now known as boopisaway |
22:12:51 | cryzed | I don't like it, that's all. I prefer Python's and Nim's |
22:15:00 | mat4 | I think ephja is just curious *why* you don't like Ruby's syntax |
22:20:08 | * | Trustable quit (Ping timeout: 250 seconds) |
22:25:04 | cryzed | I think it's ugly. I don't know enough about Ruby to tell whether it's inconsistent or not. It's hard to put a finger on, but the few times I had seen snippets of Ruby code I just thought it looked confusing instead of nice or elegant. It uses for example many unusual "special" characters at different places, IIRC ? are allowed in method/function names then the | | syntax doesn't appeal to me. There are many small things -- but as I said, I |
22:25:04 | cryzed | don't know enough about Ruby to point out anything else less superficial. When I decided which to learn Python or Ruby I checked out the ecosystem, the general sense/feeling I got when reading code and I strongly felt that I prefer Python for some reason |
22:26:20 | cryzed | It wasn't strongly based in logic, it was just me liking one syntax better than the other and Python seemed/seems more popular for general-purpose programming |
22:34:30 | ephja | ok |
22:37:10 | cryzed | ephja, I hope _this_ isn't the thing that makes me unpopular with you -- as I said, the decision wasn't based in logic and I just went with the first impression I got. In the end if I felt that Ruby was much more popular than Python, I would have probably chosen it, despite me not liking the syntax better |
22:38:02 | * | ^aurora^ joined #nim |
22:40:55 | ephja | cryzed: no I was just curious |
22:41:13 | cryzed | alright. Since this would be a waste, I have much more stupid things to say :D |
22:46:42 | * | kulelu88 quit (Quit: Leaving) |
22:48:32 | cryzed | So has anyone seen any Nim game dev libraries? I've seen plans to create some a few times, but no specific results yet |
22:48:47 | mat4 | generally: There exist some common style philosophies which reach back to the first high-level programming languages. Inconsistencies and related readability problems arised though some kind of language syncretism which affecting most modern programming languages |
22:48:53 | * | kulelu88 joined #nim |
22:48:53 | * | kulelu88 quit (Changing host) |
22:48:53 | * | kulelu88 joined #nim |
22:48:59 | cryzed | I'm currently using the SDL2 bindings and adding, I assume, common game-programming patterns to it |
22:49:01 | mat4 | in my opinion |
22:49:34 | cryzed | > the amalgamation or attempted amalgamation of different religions, cultures, or schools of thought. |
22:49:37 | cryzed | I had to look this up |
22:50:12 | cryzed | mat4, do you also feel that's the case for Nim? |
22:51:46 | mat4 | to the lesser yes. For example I stumbled frequently over '=' as operator for constants and ':' for variable definations |
22:52:51 | cryzed | : is used to (optionally) specify the type and = to assign the value -- that seems pretty clear to me. Unless I am misunderstanding? |
22:55:58 | mat4 | it's clear however the seperation is syntactical unneeded (but ease parsing) |
22:57:06 | cryzed | eases parsing by humans you mean? |
22:57:30 | cryzed | because I don't think it's much of an issue to adapt the parser for that case |
22:57:41 | mat4 | yes |
22:57:48 | cryzed | then I agree |
22:58:57 | mat4 | or the '=' as entry symbol for procedure definations |
22:59:37 | mat4 | the colon is also used as postfix for block statements |
22:59:42 | mat4 | ... |
23:01:21 | mat4 | finally the multiplication operator also marks external definations (like Oberon) |
23:03:09 | * | ^aurora^ quit (Quit: Textual IRC Client: www.textualapp.com) |
23:04:06 | * | matkuki quit (Quit: ChatZilla 0.9.92 [Firefox 42.0/20151029151421]) |
23:05:31 | * | kniteli joined #nim |
23:06:29 | mat4 | for programmers which are familiar with other styles this can be misleading |
23:09:08 | mat4 | so most style related discussions end up in judgement though habit (which is bad because such habit lead easily to mental inflexibility) |
23:16:26 | * | mat4 quit (Quit: Verlassend) |
23:17:46 | * | aziz quit (Remote host closed the connection) |
23:42:29 | * | Matthias247 quit (Read error: Connection reset by peer) |
23:43:37 | * | makoLine quit (Quit: Leaving) |