←2014-04-12 2014-04-13 2014-04-14→ ↑2014 ↑all
00:18:13 -!- nooodl has quit (Quit: Leaving).
00:18:30 -!- nooodl has joined.
00:21:30 -!- Tritonio1 has quit (Ping timeout: 240 seconds).
00:22:52 -!- Tritonio has joined.
00:23:12 -!- tromp has joined.
00:25:06 -!- Frooxius has quit (Ping timeout: 240 seconds).
00:25:07 <zzo38> Many text adventure games use a virtual machine, which is then run in the interpreter. I have a bit different idea, to instead make a intermediate code, which is then compiled by the OEM into the proper code for the machine and then put into a disk, tape, ROM cartridge, or internet. Probably it would run faster like that and possibly smaller file too.
00:25:33 <zzo38> So, it is compiled into a 6502 code, x86 code, or possibly even a C code.
00:25:53 <pikhq> I imagine it wouldn't matter too much though -- zcode tends to be pretty swift on most platforms. :)
00:30:29 <zzo38> Yes, it is; I have written interpreters for Z-code.
00:32:24 <zzo38> There is, though, also TADS, Glulx, Level 9 A-code, OASYS, and others. (I have worked with OASYS, too; it is designed to be interpreted but could be compiled too due to its Restricted-Harvard format.)
00:34:23 <zzo38> But most of them have some complexity involved, so a simpler format can be made, and make it fit on smaller ROM cartridges. Some older computers don't have lowercase, and omit some other ASCII characters too; using only uppercase and also improve text compression. (Z-machine version 3 can run on uppercase-only computers, but mixed-case text is still needed in the story file.)
00:36:05 <pikhq> Are you familiar with Linus Akesson's Zeugma?
00:36:11 <zzo38> Yes, I know of it.
00:36:30 <zzo38> I also, made part of a Z-machine interpreter for Famicom, myself.
00:36:45 <zzo38> (which isn't tested and probably contains many errors)
00:38:26 <zzo38> Here is the entire code so far of Famicom Z-machine: http://wiki.nesdev.com/w/index.php/User:Zzo38/Famicom_Z-machine
00:39:18 <zzo38> I believe Zeugma is for version 4, 5, 8. My program is for version 1, 2, 3.
00:41:26 <zzo38> Many Z-machine interpreters contain errors.
00:41:40 <zzo38> Hardly any implements permanent shifts correctly.
00:43:06 <pikhq> How many examples of version 1-3 Z-code are there?
00:43:26 <pikhq> Small handful of early Infocom games?
00:44:01 <zzo38> There are many, actually.
00:44:11 <zzo38> I think most Infocom games are version 3
00:45:18 -!- nooodl has quit (Quit: Leaving).
00:45:44 -!- nooodl has joined.
00:49:02 <zzo38> Tell me if you find my program to be OK and/or anything you think is wrong with it, please.
00:54:38 <zzo38> A compiled system would probably work better though, especially if it is far simpler than Z-machine.
00:55:51 -!- adu has joined.
01:00:42 -!- nisstyre has joined.
01:02:56 <zzo38> How many different SQL "CREATE FUNCTION" syntaxes are there?
01:03:59 -!- oerjan has quit (Quit: Night).
01:06:25 <zzo38> There seems to be a lot of different ones, and there are more differences when aggregate functions are involved too.
01:10:45 -!- Sorella has quit (Ping timeout: 276 seconds).
01:13:43 -!- tromp has quit (Remote host closed the connection).
01:21:43 <Sgeo> http://arstechnica.com/information-technology/2012/01/microsoft-pimps-it-old-school-with-a-pricey-text-adventure-game/
01:24:16 <Bike> this is disappointing.
01:31:57 -!- drlemon has quit (Read error: Connection reset by peer).
01:32:00 -!- drlemon_ has joined.
01:56:46 -!- Tritonio has quit (Ping timeout: 245 seconds).
01:57:29 <kmc> Sgeo: :D
01:59:30 -!- adu has quit (Quit: adu).
02:06:57 -!- adu has joined.
02:09:46 -!- conehead has quit (Quit: Computer has gone to sleep).
02:26:29 -!- SleepyPikachu has joined.
02:26:45 -!- SleepyPikachu has quit (Quit: leaving).
02:42:47 <Sgeo> I'm guess Erlang is a language that you don't want to use as just a general make-yourself-a-better-programmer language? At least, I have a feeling that let-it-crash may be a bad idea to bring into non-Erlang ecosystems
02:43:18 <kmc> i'm a pretty big fan of let-it-crash tbh
02:43:33 <Sgeo> But does that work outside of Erlang?
02:44:25 <kmc> you can design systems that way in any language(s)
02:44:29 <kmc> erlang may make it easier
02:44:39 <kmc> functional programming in C is also quite popular
02:45:52 <Sgeo> Maybe I should get more understanding of let it crash
02:46:16 <Sgeo> I guess a cryptographic primitive that fails quickly and blatantly if a precondition isn't met is an example?
02:46:23 <kmc> well i don't know the finer points of it eithe
02:46:24 <kmc> r
02:46:30 <kmc> Rust lost linked task failure :/
02:46:34 <zzo38> Functional programming in C? But, then you would need a user-parameter.
02:46:37 <kmc> it's a real pita
02:46:37 <zzo38> Isn't it?
02:46:45 <Bike> i just imagine myself standing over a flaming computer and laughing
02:46:47 <kmc> zzo38: yeah, and void* user parameters are quite popular
02:46:53 <Bike> YOU GOT WHAT YOU DESERVED
02:46:57 <kmc> although it's kind of a joke to call that functional programming
02:47:12 <kmc> people don't much write higher order combinators around their closure structs in C
02:47:19 <kmc> even people who went to MIT
02:47:24 <zzo38> kmc: Yes, a lot of SQLite API functions that will call back functions, will have void* user parameters.
02:47:55 <zzo38> I know it isn't real functional programming, but it would be one thing you would require, if you are to start trying to make functional programming in a C code.
02:52:15 <HackEgo> [wiki] [[Special:Log/newusers]] create * Extwo * New user account
02:58:53 <zzo38> And still it isn't quite real function programming; functional programming isn't a C code anyways!
03:04:07 <Bike> the functional programming that can be spoken of is not the true functional programming
03:04:54 <zzo38> Now I made this "text adventure intermediate language". It has 36 opcodes (actually, 90 if you count the operand size bits), although some don't need to be implemented. It is possible for SAVE, LPTON, LPTOFF, PICTURE to all be no-operations; it is OK for QUIT and RESET to have the same operation as each other, and if SAVE isn't implement, RESTORE? can act the same as JUMP.
03:06:33 <zzo38> Binary and decimal numbers are treated differently, for compatibility with computers where such a thing would help. The high bit of a variable number is set to use that variable as a decimal number (although it takes up the same memory as the binary variables).
03:33:01 -!- drlemon_ has quit (*.net *.split).
03:33:02 -!- jconn has quit (*.net *.split).
03:33:04 -!- nisstyre has quit (*.net *.split).
03:33:04 -!- tromp_ has quit (*.net *.split).
03:33:04 -!- heroux has quit (*.net *.split).
03:33:04 -!- Melvar has quit (*.net *.split).
03:33:05 -!- zzo38 has quit (*.net *.split).
03:33:05 -!- TodPunk has quit (*.net *.split).
03:33:05 -!- shachaf has quit (*.net *.split).
03:33:06 -!- applybot has quit (*.net *.split).
03:33:06 -!- jix has quit (*.net *.split).
03:33:06 -!- newsham has quit (*.net *.split).
03:33:06 -!- quintopia has quit (*.net *.split).
03:33:06 -!- maurer has quit (*.net *.split).
03:33:07 -!- realzies has quit (*.net *.split).
03:33:08 -!- idris-ircslave has quit (*.net *.split).
03:33:09 -!- CapitalSigma has quit (*.net *.split).
03:33:10 -!- myndzi has quit (*.net *.split).
03:33:11 -!- Taneb has quit (*.net *.split).
03:33:11 -!- ejls has quit (*.net *.split).
03:33:11 -!- clog has quit (*.net *.split).
03:33:11 -!- mroman has quit (*.net *.split).
03:33:12 -!- Gracenotes has quit (*.net *.split).
03:33:13 -!- douglass_ has quit (*.net *.split).
03:33:13 -!- vravn has quit (*.net *.split).
03:33:14 -!- ggherdov has quit (*.net *.split).
03:33:14 -!- JZTech101 has quit (*.net *.split).
03:33:14 -!- nortti has quit (*.net *.split).
03:33:15 -!- adu has quit (*.net *.split).
03:33:15 -!- nooodl has quit (*.net *.split).
03:33:16 -!- Sgeo has quit (*.net *.split).
03:33:17 -!- fizzie has quit (*.net *.split).
03:33:18 -!- Jafet has quit (*.net *.split).
03:33:18 -!- HackEgo has quit (*.net *.split).
03:33:19 -!- int-e has quit (*.net *.split).
03:33:19 -!- elliott has quit (*.net *.split).
03:33:19 -!- Speed` has quit (*.net *.split).
03:33:19 -!- Sprocklem has quit (*.net *.split).
03:33:20 -!- Patashu[Zzz] has quit (*.net *.split).
03:33:20 -!- copumpkin has quit (*.net *.split).
03:33:21 -!- Bike has quit (*.net *.split).
03:33:22 -!- Sellyme has quit (*.net *.split).
03:33:22 -!- lambdabot has quit (*.net *.split).
03:33:22 -!- olsner has quit (*.net *.split).
03:33:23 -!- augur has quit (*.net *.split).
03:33:23 -!- jhj1 has quit (*.net *.split).
03:33:23 -!- myname has quit (*.net *.split).
03:33:25 -!- FireFly has quit (*.net *.split).
03:33:25 -!- aloril has quit (*.net *.split).
03:33:25 -!- atehwa has quit (*.net *.split).
03:33:26 -!- b_jonas has quit (*.net *.split).
03:33:26 -!- lifthrasiir has quit (*.net *.split).
03:33:27 -!- rodgort has quit (*.net *.split).
03:33:27 -!- kmc has quit (*.net *.split).
03:33:27 -!- ion has quit (*.net *.split).
03:33:27 -!- monotone has quit (*.net *.split).
03:33:27 -!- EgoBot has quit (*.net *.split).
03:33:27 -!- ineiros has quit (*.net *.split).
03:33:28 -!- lexande has quit (*.net *.split).
03:33:28 -!- sebbu has quit (*.net *.split).
03:33:29 -!- xpte has quit (*.net *.split).
03:33:29 -!- erdic has quit (*.net *.split).
03:33:31 -!- pikhq has quit (*.net *.split).
03:33:32 -!- coppro has quit (*.net *.split).
03:33:34 -!- ^v has quit (*.net *.split).
03:33:34 -!- Vorpal has quit (*.net *.split).
03:33:36 -!- Gregor has quit (*.net *.split).
03:33:36 -!- fungot has quit (*.net *.split).
03:33:36 -!- hexagon has quit (*.net *.split).
03:33:37 -!- hogeyui has quit (*.net *.split).
03:33:37 -!- SirCmpwn has quit (*.net *.split).
03:33:38 -!- Deewiant has quit (*.net *.split).
05:16:46 -!- coppro has joined.
05:16:46 -!- douglass_ has joined.
05:16:46 -!- Gracenotes has joined.
05:16:46 -!- mroman has joined.
05:16:46 -!- clog has joined.
05:16:46 -!- ejls has joined.
05:16:46 -!- Taneb has joined.
05:16:46 -!- Bike has joined.
05:16:46 -!- copumpkin has joined.
05:16:46 -!- Patashu[Zzz] has joined.
05:16:46 -!- Sprocklem has joined.
05:16:46 -!- pikhq has joined.
05:16:46 -!- lambdabot has joined.
05:16:46 -!- olsner has joined.
05:16:46 -!- augur has joined.
05:16:46 -!- jhj1 has joined.
05:16:46 -!- myname has joined.
05:16:46 -!- FireFly has joined.
05:16:46 -!- glogbackup has joined.
05:16:46 -!- int-e has joined.
05:16:46 -!- drlemon_ has joined.
05:16:46 -!- jconn has joined.
05:16:46 -!- `^_^v has joined.
05:16:46 -!- ^v has joined.
05:16:46 -!- Vorpal has joined.
05:16:46 -!- Gregor has joined.
05:16:46 -!- fungot has joined.
05:16:46 -!- hexagon has joined.
05:16:46 -!- hogeyui has joined.
05:16:46 -!- SirCmpwn has joined.
05:16:46 -!- Deewiant has joined.
05:16:52 -!- adu has joined.
05:16:53 -!- nooodl has joined.
05:16:53 -!- Sgeo has joined.
05:16:53 -!- fizzie has joined.
05:16:54 -!- ineiros has joined.
05:16:54 -!- lexande has joined.
05:16:54 -!- sebbu has joined.
05:18:07 -!- elliott has joined.
05:18:07 -!- tromp has joined.
05:18:07 -!- idris-ircslave has joined.
05:18:27 -!- erdic has joined.
05:18:28 -!- CapitalSigma has joined.
05:18:28 -!- myndzi has joined.
05:18:40 -!- HackEgo has joined.
05:18:40 -!- nisstyre has joined.
05:18:40 -!- tromp_ has joined.
05:18:40 -!- heroux has joined.
05:18:40 -!- Melvar has joined.
05:18:40 -!- zzo38 has joined.
05:18:40 -!- TodPunk has joined.
05:18:40 -!- shachaf has joined.
05:18:40 -!- jix has joined.
05:18:40 -!- newsham has joined.
05:18:40 -!- quintopia has joined.
05:18:40 -!- maurer has joined.
05:18:40 -!- realzies has joined.
05:18:44 -!- vravn has joined.
05:18:44 -!- ggherdov has joined.
05:18:44 -!- JZTech101 has joined.
05:18:44 -!- nortti has joined.
05:21:35 -!- ^v has quit (Quit: http://i.imgur.com/DrFFzea.png).
05:31:21 -!- Sellyme has joined.
05:31:22 -!- Speed` has joined.
05:31:22 -!- aloril has joined.
05:31:22 -!- atehwa has joined.
05:31:22 -!- b_jonas has joined.
05:31:22 -!- lifthrasiir has joined.
05:31:22 -!- kmc has joined.
05:31:22 -!- ion has joined.
05:31:22 -!- EgoBot has joined.
05:37:56 <HackEgo> [wiki] [[Boxy]] M http://esolangs.org/w/index.php?diff=39305&oldid=39300 * Zerk * (-1) /* Standard Library */ syntax
05:38:17 <HackEgo> [wiki] [[Talk:Smartboxes]] http://esolangs.org/w/index.php?diff=39306&oldid=39303 * Doesthiswork * (+541)
05:54:09 -!- rodgort has joined.
06:02:37 -!- nooodl has quit (Remote host closed the connection).
06:08:50 -!- zzo38 has quit (Remote host closed the connection).
06:16:06 -!- Sprocklem has quit (Quit: leaving).
06:16:29 <Sgeo> I think I want to know the context of every line of the Picard Song
06:19:43 <shachaf> int-e: Hoorint-e!
06:37:42 -!- oklopol has joined.
07:02:13 -!- MoALTz has joined.
07:04:29 -!- Patashu has joined.
07:07:36 -!- Patashu[Zzz] has quit (Ping timeout: 258 seconds).
07:15:22 -!- Slereah_ has joined.
07:18:54 -!- elliott has changed nick to Guest46968.
07:30:45 -!- erdic has quit (Changing host).
07:30:45 -!- erdic has joined.
07:35:29 -!- nisstyre has quit (Quit: WeeChat 0.4.3).
07:36:59 -!- Slereah_ has quit (Ping timeout: 250 seconds).
07:48:34 -!- nooodl has joined.
07:48:49 -!- Slereah_ has joined.
07:55:07 -!- AnotherTest has joined.
08:07:36 -!- Frooxius has joined.
08:14:41 -!- Slereah_ has quit (Ping timeout: 250 seconds).
08:18:27 -!- Patashu has quit (Ping timeout: 276 seconds).
08:21:24 -!- Jafet has joined.
08:23:55 -!- applybot has joined.
08:25:32 -!- password2 has joined.
09:18:15 -!- Sellyme has quit (*.net *.split).
09:18:15 -!- Speed` has quit (*.net *.split).
09:18:16 -!- aloril has quit (*.net *.split).
09:18:16 -!- atehwa has quit (*.net *.split).
09:18:17 -!- b_jonas has quit (*.net *.split).
09:18:17 -!- lifthrasiir has quit (*.net *.split).
09:18:18 -!- kmc has quit (*.net *.split).
09:18:18 -!- ion has quit (*.net *.split).
09:18:18 -!- EgoBot has quit (*.net *.split).
09:19:45 -!- Sellyme has joined.
09:19:46 -!- Speed` has joined.
09:19:46 -!- aloril has joined.
09:19:46 -!- atehwa has joined.
09:19:46 -!- b_jonas has joined.
09:19:46 -!- lifthrasiir has joined.
09:19:46 -!- kmc has joined.
09:19:46 -!- ion has joined.
09:19:46 -!- EgoBot has joined.
09:22:30 -!- conehead has joined.
09:31:44 <fizzie> olsner: STATUS UPDATE: 6011486208-byte partition sde2 extracted successfully overnight; turned out to be the / partition; had the crontab I was looking for, but scripts were in /home/foo for a system user foo, in flagrant disregard of FHS; now reading the rest.
09:33:25 <fizzie> (Disclaimer: I don't know if FHS really says anything about that, but I imagine it might.)
09:35:41 -!- Slereah_ has joined.
09:50:10 -!- adu has quit (Quit: adu).
09:59:44 -!- MindlessDrone has joined.
10:06:14 -!- password2 has quit (Remote host closed the connection).
10:09:55 -!- password2 has joined.
10:20:00 -!- Patashu has joined.
10:25:31 -!- Patashu[Zzz] has joined.
10:25:31 -!- Patashu has quit (Disconnected by services).
10:28:52 -!- Patashu has joined.
10:31:58 -!- Patashu[Zzz] has quit (Ping timeout: 245 seconds).
10:34:03 -!- Slereah_ has quit (Ping timeout: 245 seconds).
10:34:24 -!- Patashu[Zzz] has joined.
10:34:24 -!- Patashu has quit (Disconnected by services).
10:39:37 -!- password2 has left ("Leaving").
10:39:51 -!- Patashu has joined.
10:43:13 -!- Patashu[Zzz] has quit (Ping timeout: 245 seconds).
10:46:33 -!- Patashu has quit (Ping timeout: 245 seconds).
10:48:24 -!- Patashu has joined.
10:51:40 -!- Patashu[Zzz] has joined.
10:51:40 -!- Patashu has quit (Disconnected by services).
10:56:05 -!- Patashu[Zzz] has quit (Client Quit).
11:05:31 -!- yorick has joined.
11:08:33 -!- oerjan has joined.
11:14:33 -!- Slereah_ has joined.
11:14:44 -!- boily has joined.
11:15:01 -!- Patashu has joined.
11:16:55 <oerjan> @tell zzo38 <zzo38> [...] SAVE, LPTON, LPTOFF, PICTURE <-- you need a HDRON too hth
11:16:56 <lambdabot> Consider it noted.
11:17:26 <oerjan> lambdabot: you seem slow.
11:17:26 <myname> LPTON ICE
11:18:07 <oerjan> i know it is evil to pun zzo but i couldn't resist
11:19:21 <oerjan> BRYON and MSON are optional.
11:20:01 -!- Patashu[Zzz] has joined.
11:20:02 -!- Patashu has quit (Disconnected by services).
11:20:37 <Jafet> Hadroff
11:21:17 <myname> sounds a bit like barking
11:21:50 <int-e> oerjan: it's hard to tell who is slow on IRC
11:22:21 <int-e> (from here, the @tell and lambdabot's reply both had timestamp 13:16:55)
11:22:27 <oerjan> hm there's a big split gap in the logs
11:22:52 <oerjan> int-e: ok
11:23:00 <Jafet> Someone spammed freenode.
11:23:15 <myname> Jafet: big news
11:25:10 <int-e> oh. impressive spew of k-lines.
11:26:53 <Jafet> Yes. In other big news, Afghanistan held presidential elections for the first time in modern history.
11:32:42 -!- conehead has quit (Quit: Textual IRC Client: www.textualapp.com).
11:35:18 -!- Patashu[Zzz] has quit (Ping timeout: 245 seconds).
11:36:21 -!- Patashu has joined.
11:36:39 -!- Patashu has quit (Client Quit).
11:37:49 <oerjan> hm clog and glogbot were in different fragments but neither registered any talking. almost everyone who split split from both.
11:38:33 <oerjan> 20:36:03 --- quit: drlemon_ (*.net *.split)
11:38:34 <oerjan> 20:36:04 --- quit: jconn (*.net *.split)
11:38:34 <oerjan> 20:36:07 --- quit: impomatic (*.net *.split)
11:38:34 <oerjan> 20:36:08 --- quit: trout (*.net *.split)
11:38:34 <oerjan> 20:36:08 --- quit: scoff (*.net *.split)
11:38:36 <oerjan> 20:36:09 --- quit: glogbot (*.net *.split)
11:38:38 <oerjan> 20:36:11 --- quit: nisstyre (*.net *.split)
11:38:41 <oerjan> 20:36:11 --- quit: tromp_ (*.net *.split)
11:38:43 <oerjan> 20:36:11 --- quit: heroux (*.net *.split)
11:38:44 <fizzie> ...
11:38:46 <oerjan> 20:36:11 --- quit: Melvar (*.net *.split)
11:38:48 <oerjan> 20:36:12 --- quit: zzo38 (*.net *.split)
11:38:51 <oerjan> 20:36:12 --- quit: TodPunk (*.net *.split)
11:38:53 <oerjan> 20:36:13 --- quit: shachaf (*.net *.split)
11:38:54 -!- ChanServ has set channel mode: +o fizzie.
11:38:56 <oerjan> 20:36:14 --- quit: applybot (*.net *.split)
11:38:58 <oerjan> 20:36:15 --- quit: jix (*.net *.split)
11:39:00 -!- fizzie has set channel mode: +q oerjan!*@*.
11:39:08 <fizzie> (I assume a mispaste.)
11:39:19 <fizzie> Let's see if the faucet is still on.
11:39:20 -!- fizzie has set channel mode: -q oerjan!*@*.
11:39:21 <oerjan> 20:36:23 --- quit: ggherdov (*.net *.split)
11:39:23 -!- oerjan has left.
11:39:47 -!- fizzie has set channel mode: -o fizzie.
11:39:56 <fizzie> That was spectacular.
11:40:24 -!- oerjan has joined.
11:40:28 <oerjan> i hope parting flushed that buffer
11:40:39 <fizzie> Seems to have.
11:40:39 <oerjan> i have no idea what command does it.
11:41:01 <oerjan> i thought irssi was supposed to have protection against this D:
11:41:37 <oerjan> also this touchpad is evil hth
11:41:37 <fizzie> It is supposed to ask, but sometimes (if there's SSH lag or something) it doesn't realize.
11:42:20 <fizzie> Since the protection is based on "N lines in K units of time" kind of rules.
11:42:20 <oerjan> *sigh*
11:42:30 <oerjan> hm i think i planned to increase that timeout once.
11:43:08 <fizzie> [14:43:16] paste_detect_time = 5msecs
11:43:08 <Jafet> freenode probably throttles input.
11:43:12 <fizzie> That's, like, 1499 km in speed-of-light terms.
11:43:54 <Jafet> Ah, good ol' zeroth order models.
11:43:54 <oerjan> it was 10 msecs i now increased it to 100
11:45:04 <oerjan> i doubt i manage to type a normal line in less than 0.1 s
11:46:20 <oerjan> fizzie: i had just copied and pasted that long list into vim to compare clog's view with glogbot's.
11:47:50 <oerjan> Jafet: i'm pretty sure there was an election for karzai's second term? but this may have been the first time they handled it themselves.
11:48:18 <Jafet> Actually, there were two elections, but people didn't seem to like those very much.
11:49:30 <Melvar> ( :t mkShow
11:49:30 <idris-ircslave> BotPrelude.mkShow : (a -> String) -> Show a
11:52:05 <oerjan> (incidentally the only ones not split from clog were Gracenotes Taneb clog douglass_ ejls mroman, and the only ones not split from glogbot were glogbot impomatic scoff trout.
11:52:08 <oerjan> )
11:55:33 <int-e> I was asleep, hth.
11:55:59 <oerjan> int-e: you were in both lists.
11:56:23 <Jafet> I believe int-e's alibi.
11:57:49 * impomatic waves to oerjan :-)
11:58:06 <oerjan> hi impomatic
12:00:51 <impomatic> IRC alerted me so I zoomed across here in case everyone's talking about Core War or something :-D
12:01:32 <oerjan> sorry it was just clog war
12:02:30 <impomatic> I'll just mention this before I have lunch :-P http://corewar.co.uk/spring2014.htm
12:03:27 <impomatic> Oh also if you're interested in the history of worms / viruses I've found a description of one which possibly predates Creeper.
12:04:41 <int-e> @localtime oerjan
12:04:41 <lambdabot> Local time for oerjan is Sun Apr 13 14:04:41 2014
12:05:58 <int-e> 05:38:35 --- [Users #esoteric]
12:05:58 <int-e> 05:38:35 --> drlemon_ int-e jconn
12:06:22 <oerjan> that "but the program must still behave essentially the same" sounds rather subjective for a computer tournament...
12:06:25 <int-e> 05:40:24 --- glogbackup has joined #esoteric
12:06:57 <int-e> and then people started coming back 07:12:11 (all CET). That's my view of the netsplit.
12:07:28 <oerjan> rather fine fragments, i take.
12:09:37 <oerjan> glogbot split a bit earlier and rejoined a little later. tunes still hasn't fixed its broken clock.
12:09:42 <olsner> boily: btw UPPHETTA means to heat up (something)
12:09:56 <oerjan> olsner: what, with two t's?
12:10:14 <olsner> what other number of t's could there be?
12:10:28 <int-e> one two three?
12:10:29 <oerjan> one like in norwegian? (and english for that matter)
12:10:36 <int-e> well, "other", so one or three ;)
12:10:37 <oerjan> (opphete)
12:11:14 <int-e> "aufheizen" has no t at all (though you can count the implied one in the 'z')
12:11:34 <oerjan> no:hette means hood.
12:11:45 <olsner> that'd be sv:hätta
12:12:40 <olsner> well, literally... hood would probably be sv:huva nowadays
12:13:26 <oerjan> not cap?
12:14:20 <oerjan> that's what hue means in my dialect, although standard norwegian is lue.
12:15:08 <oerjan> actually more like huæ.
12:18:06 <boily> fr:chauffer.
12:18:15 <oerjan> "The thin atmosphere prevents Mars from retaining any heat energy, so temperatures near the equator can get up to 70 degrees F during a summer day, and then drop down to minus 100 degrees F at night."
12:18:52 <oerjan> i didn't know summer day temperatures on mars were so reasonable.
12:19:15 <Jafet> "up to"
12:20:13 <boily> `frink 70 fahrenheit to celsius
12:20:16 <HackEgo> Warning: undefined symbol "fahrenheit". \ Bounds in range expression are of unsupported types: (70 fahrenheit (undefined symbol), celsius (undefined symbol)) \ at frink.expr.bh.byte(frink) \ at frink.expr.bh.evaluate(frink) \ at frink.parser.Frink.parseString(frink) \ at frink.parser.Frink.parseStrings(frink) \ at frink.parser.Frink.
12:20:26 <olsner> iirc, 70 is about room temperature
12:20:47 <boily> `` echo $(((70 - 32) * 5 / 9))
12:20:48 <HackEgo> 21
12:21:10 <boily> 21 is good. I like 21.
12:23:40 <oerjan> the time period when mars may have had water is known as the "Noachian". although the implications are somewhat dampened by it being named after the region of Noachis Terra.
12:24:39 <oerjan> istr `frink has a weird way of converting temperatures, also your syntax is wrong for ordinary units as well, it's not a bloody natural language parser.
12:25:27 <oerjan> `sanetemp 70
12:25:28 <HackEgo> ​/home/hackbot/hackbot.hg/multibot_cmds/lib/limits: line 5: exec: sanetemp: not found
12:25:32 <oerjan> !sanetemp 70
12:25:34 <EgoBot> 21.1
12:25:46 <olsner> !insanetemp 21.1
12:25:47 <EgoBot> 69.9
12:25:49 <oerjan> !show sanetemp
12:25:50 <EgoBot> sh dc -e "1k?32-5*9/p"
12:25:59 <int-e> dampened, hmm. (damp = moist)
12:26:37 <oerjan> not the intended pun.
12:27:14 <boily> oerjan: what is istr twh
12:28:53 <int-e> I seem to recall
12:30:20 <int-e> oh, twh is another acronym in the hth family.
12:31:49 <int-e> but does it mean "that will help" or "that won't help"? ;-)
12:31:58 <boily> that would help, iirc.
12:32:03 <boily> `? twh
12:32:03 <HackEgo> twh would help, but is an hth derivative. hth. twh. hand.
12:32:09 <oerjan> `run (echo '#!/bin/bash'; echo 'echo "$@" | dc -e "1k?32-5*9/p"') > bin/sanetemp; chmod +x bin/sanetemp
12:32:11 <HackEgo> No output.
12:32:18 <oerjan> `sanetemp 70
12:32:19 <HackEgo> 21.1
12:32:27 <oerjan> !show insanetemp
12:32:28 <EgoBot> sh dc -e "1k?9*5/32+p"
12:32:52 <oerjan> `run (echo '#!/bin/bash'; echo 'echo "$@" | dc -e "1k?9*5/32+p"') > bin/insanetemp; chmod +x bin/insanetemp
12:32:53 <HackEgo> No output.
12:33:03 <oerjan> `insanetemp 21.1
12:33:04 <HackEgo> 69.9
12:33:33 <int-e> `` cat <<<$SHELL
12:33:33 <HackEgo> ​/bin/sh
12:34:21 <oerjan> /bin/sh on HackEgo does some bad things
12:34:38 <int-e> `file /bin/sh
12:34:39 <HackEgo> ​/bin/sh: symbolic link to `dash'
12:34:42 <oerjan> in particular iirc you don't want to echo user input with it.
12:35:08 <boily> `` /bin/sh echo echo
12:35:08 <HackEgo> ​/bin/sh: 0: Can't open echo
12:35:12 <boily> beuh...
12:35:20 <boily> `` /bin/sh -c echo echo
12:35:21 <HackEgo> No output.
12:35:21 <int-e> missing -c
12:35:35 <oerjan> it doesn't break on _all_ input, mind you.
12:35:38 <int-e> `` /bin/sh -c "echo echo"
12:35:38 <HackEgo> echo
12:36:20 <oerjan> i don't quite recall what caused the problem, but i think tabs may have been involved.
12:36:36 <oerjan> oh wait
12:36:59 <boily> `` echo -e '#!/bin/sh\necho "$@"' >bin/poulet; chmod +x bin/poulet
12:37:00 <HackEgo> No output.
12:37:13 <oerjan> it was when your input contained escape sequences like \n.
12:37:14 <int-e> `cat bin/`
12:37:14 <HackEgo> exec bash -c "$1"
12:37:25 <int-e> so that's why <<< worked :)
12:37:39 <fizzie> It's kind of unclear whether "insanetemp" (resp. "sanetemp") converts from insane to sane, or the other way around.
12:37:41 <oerjan> `poulet test\nho
12:37:41 <HackEgo> test \ ho
12:37:54 <boily> `poulet somethingsomething
12:37:54 <HackEgo> somethingsomething
12:37:56 <oerjan> fizzie: it's to hth
12:38:03 <boily> darn. the tab didn't work.
12:38:05 <oerjan> boily: it wasn't tabs, but \n
12:38:11 <int-e> ^H isn't a tab
12:38:19 <boily> `poulet somethingsomething
12:38:19 <HackEgo> somethingsomething
12:38:30 <boily> int-e: I got slightly confused.
12:38:32 <oerjan> it's hard to get it passed through unchanged.
12:38:40 <boily> `poulet somethingsomething
12:38:41 <HackEgo> somethingsomething
12:38:47 <boily> `poulet something
12:38:47 <HackEgo> something
12:38:49 <boily> something
12:38:51 * int-e sees nothing bad.
12:39:09 * boily sucks at mental calculation and hexadecimal this morning. I deserve an automapole.
12:39:57 <oerjan> int-e: my test shows it.
12:40:02 <int-e> http://int-e.eu/~bf3/tmp/Ohlo9ru5.png - wysiwyg
12:40:03 <oerjan> `poulet test\nho
12:40:03 <HackEgo> test \ ho
12:40:30 <oerjan> boily: you know you could be saved all this work if you paid attention to my self-corrections hth
12:40:59 <boily> IEUAAAAAAAAARGH!
12:41:11 <int-e> (unless it adds color codes, in which case they get filtered on my end)
12:41:19 <oerjan> the problem is that the idiom of using echo "$@" to pass command args unchanged as input to a command breaks with /bin/sh
12:41:59 <oerjan> int-e: that is, it's not _supposed_ to turn that \n into a newline.
12:42:16 <int-e> `poulet -?
12:42:16 <HackEgo> ​-?
12:42:49 <int-e> oooh. I have a file called -u in my home directory, how did that happen :)
12:43:20 <int-e> some curl mishap judgring by its content (a 401 error)
12:43:43 <oerjan> hm i remember someone added a command to do this automatically...
12:43:48 <oerjan> `run ls bin/*or*
12:43:49 <HackEgo> bin/forget \ bin/fortune \ bin/joustreport \ bin/ord \ bin/ordu \ bin/pastefortunes \ bin/print_args_or_input \ bin/rainwords \ bin/word \ bin/words
12:44:01 <oerjan> print_args_or_input, it was
12:44:08 <boily> `word
12:44:09 <HackEgo> aver
12:44:13 <boily> ...
12:44:26 <oerjan> boily: truth in advertising
12:44:46 -!- MoALTz has quit (Quit: bbl).
12:45:09 <int-e> oerjan: sorry. http://pubs.opengroup.org/onlinepubs/009695399/utilities/echo.html begs to differ.
12:45:23 <int-e> "the results are implementation-defined"
12:46:39 <oerjan> int-e: i'm not saying dash breaks the standard, i'm saying the standard is inconvenient.
12:49:07 <oerjan> "New applications are encouraged to use printf instead of echo."
12:49:20 <oerjan> `cat bin/print_args_or_input
12:49:21 <HackEgo> if [ "$#" -gt 0 ]; then printf '%s\n' "$*"; else cat; fi
12:49:32 <oerjan> oh they actually did
12:49:44 <oerjan> hm...
12:50:02 <int-e> oerjan: I guess the proper solution is a here document. foo <<EOF; $@; EOF. Inconvenient indeed.
12:50:18 <int-e> (since the ; have to be actual newlines)
12:50:38 <oerjan> `run sed -i 's/echo/print_args_or_input/' bin/*sanetemp
12:50:40 <HackEgo> No output.
12:50:43 <int-e> oh printf
12:50:45 <int-e> thanks
12:50:47 <oerjan> `cat bin/sanetemp
12:50:47 <HackEgo> ​#!/bin/bash \ print_args_or_input "$@" | dc -e "1k?32-5*9/p"
12:51:03 <oerjan> `sanetemp 32
12:51:03 <HackEgo> 0
12:51:18 <int-e> ???
12:51:21 <oerjan> `run echo 32 | sanetemp
12:51:22 <HackEgo> 0
12:51:29 <oerjan> now it can be used both ways
12:51:41 <int-e> bin/print_args_or_input can't be executed directly
12:51:54 <int-e> am I missing somehting?
12:52:02 <int-e> `sanetemp 1
12:52:03 <HackEgo> ​-17.2
12:52:32 <int-e> how does print_args_or_input work without a shebang line?
12:52:37 <oerjan> int-e: it's a convenience command someone made so we can easily write commands that take either stdin or cmdargs
12:53:03 <oerjan> int-e: hm
12:53:16 <oerjan> int-e: i guess it's just run as shell commands, then.
12:53:32 <oerjan> that's it's intended use, anyway.
12:54:09 <int-e> man bash helps: "If this execution fails because the file is not in executable format, and the file is not a directory, it is assumed to be a shell script."
12:54:15 <int-e> I didn't know!
12:54:26 <boily> `sanetemp -40
12:54:26 <HackEgo> dc: stack empty \ 4.4
12:54:36 <boily> `sanetemp (-40)
12:54:37 <HackEgo> dc: '(' (050) unimplemented \ dc: stack empty \ dc: ')' (051) unimplemented \ 4.4
12:55:04 <int-e> `sanetemp 40 0-
12:55:05 <HackEgo> 4.4
12:55:09 <int-e> `sanetemp 0 40-
12:55:10 <HackEgo> ​-40.0
12:55:55 <oerjan> `run sed -i '1i#!/bin/bash' bin/print_args_or_input
12:55:57 <HackEgo> No output.
12:56:04 <oerjan> `cat bin/print_args_or_input
12:56:04 <HackEgo> ​#!/bin/bash \ if [ "$#" -gt 0 ]; then printf '%s\n' "$*"; else cat; fi
12:56:21 <oerjan> `sanetemp 100
12:56:21 <HackEgo> 37.7
12:57:50 <oerjan> i guess dc isn't quite sane, only the temps.
12:58:08 <oerjan> `run ls/*temp*
12:58:08 <HackEgo> bash: ls/*temp*: No such file or directory
12:58:14 <oerjan> `run ls bin/*temp*
12:58:15 <HackEgo> bin/insanetemp \ bin/sanetemp
12:58:25 <oerjan> brain service needed
12:58:56 <int-e> `` echo -10 | sed 's/^/1 /;s/-/2-/' | dc -e "1k?32-5*9/p"
12:58:57 <HackEgo> ​-12.2
12:59:12 <int-e> err.
12:59:16 <int-e> `` echo -10 | sed 's/^/1 /;s/-/2-/' | dc -e "1k?*32-5*9/p"
12:59:16 <HackEgo> ​-23.3
12:59:22 <int-e> `` echo -40 | sed 's/^/1 /;s/-/2-/' | dc -e "1k?*32-5*9/p"
12:59:23 <HackEgo> ​-40.0
13:00:09 <int-e> actually
13:01:01 <int-e> `` echo -40 | dc -e "1k0 1?*32-5*9/p"
13:01:02 <HackEgo> ​-40.0
13:01:44 * oerjan happily lets int-e handle this.
13:03:20 <int-e> `` sed -i 's/k./k0 1?*/' bin/sanetemp bin/insanetemp
13:03:21 <HackEgo> No output.
13:03:56 <oerjan> `sanetemp -17
13:03:57 <HackEgo> ​-27.2
13:03:59 <int-e> `sanetemp -40
13:03:59 <HackEgo> ​-40.0
13:04:02 <int-e> `insanetemp -40
13:04:03 <HackEgo> ​-40.0
13:04:11 <oerjan> `sanetemp 32
13:04:12 <HackEgo> 0
13:04:21 <oerjan> `sanetemp 32.5
13:04:21 <HackEgo> ​.2
13:04:26 <oerjan> `sanetemp -32.5
13:04:27 <HackEgo> ​-35.8
13:05:35 <int-e> bin/{in,}sanetemp would have been more clever.
13:12:15 -!- MoALTz has joined.
13:15:28 -!- Sorella has joined.
13:57:58 -!- monotone has joined.
14:04:01 -!- password2 has joined.
14:21:07 -!- password2 has quit (Ping timeout: 252 seconds).
14:31:29 -!- boily has quit (Quit: Poulet!).
14:37:46 -!- oerjan has quit (Quit: leaving).
14:55:01 <myname> what
14:58:38 <myname> so... sane is which one?
14:59:32 <Taneb> `sanetemp 0
14:59:33 <HackEgo> ​-17.7
14:59:38 <Taneb> `sanetemp 32
14:59:38 <HackEgo> 0
14:59:50 <Taneb> F -> C
15:00:26 <Taneb> I presume Celsius is the sane one
15:04:36 <int-e> indeed
15:05:08 <int-e> Rankine is the truly insane one
15:06:16 <int-e> "Kelvin had a great idea there, but clearly we should base the scale on the more familiar Fahrenheit unit instead."
15:06:25 <fizzie> How about the Rømer and Réaumur scales?
15:07:04 <fizzie> There was a giant temperature-o-meter with markings in one of those in a park somewhere in Switzerland or Italy, I took a photo of it.
15:08:25 <Slereah_> How about just an exponential scale with k = 1
15:08:27 <fizzie> Réaumur, apparently.
15:08:57 <fizzie> (It's just Celsius except with 80 in place of 100.)
15:09:36 <int-e> right, Réaumur looks quite sane. Rømer not so much, because it seems to depend on the salt content of brine.
15:10:16 <Slereah_> Why can't we just use natural units
15:10:24 <Slereah_> Everything in Planck units!
15:10:57 <int-e> And both are saner than Fahrenheit (coldest temperature ever encountered at home = 0 ... body temperature = 100; everybody gets their own scale that way!)
15:11:32 <int-e> like good old time, with elbow and foot lengths of the king.
15:11:48 <Slereah_> man that must have sucked
15:12:02 <Slereah_> People would be always like "Hey king, can you drop by, I have stuff to measure"
15:12:25 <Jafet> That's why they're called rulers, you know
15:12:36 <Slereah_> *rimshot*
15:12:45 <int-e> (it would explain the attraction of the chinese to small feet ;-) )
15:13:06 <fizzie> Random hardware question: are there any potential issues with USB-connected SATA HD enclosures around the 2 TB barrier? (I had that 1.5 TB drive that broke, and was thinking of sticking a 3 TB drive in to replace it.)
15:13:10 <int-e> Jafet: ouch.
15:13:44 <Slereah_> Jafet : Reminds me of https://images.encyclopediadramatica.es/3/39/Robotnikwood.jpg
15:14:06 <fizzie> (I would have thought we're past that kind of problems already, but in the past there's been some kind of a "barrier" at pretty much every other power of two.)
15:14:11 <Guest46968> fizzie: have to use GPT if it's partitioned, I guess?
15:15:42 <fizzie> That's probably true. Though I don't think that should be a problem, as long as there isn't anything about the USB-to-SATA bridge that would have problems.
15:15:50 <Jafet> The 2TiB barrier is not visible to SATA
15:16:07 <Guest46968> fizzie: well, I was just thinking of issues with using a drive like that in general.
15:16:27 <Jafet> The only reason people made a big deal out of it was because old BIOSes couldn't deal with 4KiB sectors
15:17:58 <fizzie> I think I had a "must upgrade disk firmware in order for it to be recognizable at all" incompatibility with these current 3TB drives in this desktop.
15:19:38 <fizzie> Oh, no, it was the 1TB Samsung HD105SI instead. And some other computer.
15:20:32 <fizzie> Well, anyway, things never work out right if there's any chance for them to go wrong, has been my general feeling about hard disks.
15:24:33 -!- Slereah_ has quit (Ping timeout: 250 seconds).
15:31:02 -!- ^v has joined.
15:39:17 -!- impomatic has quit (Ping timeout: 250 seconds).
15:44:28 -!- Slereah_ has joined.
15:55:29 -!- zzo38 has joined.
16:03:33 -!- ais523 has joined.
16:03:59 <Vorpal> fizzie, you should use a lot of smaller disks in RAID instead then?
16:05:13 <fizzie> I don't have places to put them in. Anyway, maybe it'll work.
16:05:40 <fizzie> By all means it should, anyway.
16:06:13 <ais523> huh, beautiful timing: Evolution froze up, I typed in a killall command
16:06:13 <ais523> and just before I ran the command, it crashed
16:06:16 <ais523> Vorpal: I thought the disks were meant to be inexpensive
16:06:16 <ais523> rather than, necessarily, small
16:06:29 <zzo38> @messages-loud
16:06:30 <lambdabot> oerjan said 4h 49m 34s ago: <zzo38> [...] SAVE, LPTON, LPTOFF, PICTURE <-- you need a HDRON too hth
16:06:33 <Vorpal> ais523, you missed the context
16:06:51 <zzo38> oerjan: O, it is a joke...
16:07:03 <zzo38> Actually "LPTON" is short for "line printer on"
16:08:46 <Vorpal> ais523, I know it is ironic that I should say that yes
16:09:11 -!- callforjudgement has joined.
16:09:27 -!- ais523 has quit (Disconnected by services).
16:09:28 -!- callforjudgement has changed nick to ais523.
16:09:37 <Vorpal> <Vorpal> ais523, you missed the context <Vorpal> ais523, I know it is ironic that I should say that yes
16:09:41 <Vorpal> (wrt the disk size)
16:16:12 <b_jonas> man, C++ is getting ever better language for obfuscations too
16:16:17 <b_jonas> I like this
16:16:20 -!- impomatic has joined.
16:17:20 <ais523> yeah, C++ is pretty great for obfuscations
16:17:38 <ais523> in general, any apparently innocent line of C++ code can do pretty much anything, depending on the context
16:18:28 <ais523> unless it explicitly names a primitive data type
16:19:08 <Jafet> C is the language with apparently innocent lines. C++ is like a mob boss.
16:19:08 <b_jonas> have you noticed how lambda syntax now lets you define new variables (possibly shadowing existing ones) without ever mentioning a type name or "auto"? makes it even more difficult for a human to follow bindings.
16:19:14 <int-e> #define int Utils
16:20:19 <Vorpal> ais523, yes, it is pretty terrible for anything except obfuscation at this point
16:20:34 <Vorpal> At least with C++03 it wasn't /that/ bad
16:21:11 <ais523> int-e: that's the preprocessor, it doesn't count
16:21:12 <Guest46968> C++11 was an obvious improvement on C++03.
16:21:38 <newsham> bjonas: haskell lambdas dont even make you type a type name.. how evil
16:21:46 <ais523> C++11 is better at being C++ than previous versions were
16:22:18 <newsham> > C++11
16:22:19 <idris-ircslave> (input):1:1:When elaborating an application of function Prelude.Vect.++:
16:22:19 <idris-ircslave> No such variable C
16:22:20 <lambdabot> Not in scope: data constructor ‘C’
16:22:20 <b_jonas> newsham: yeah, but in haskell you don't have assignments to previously declared variables either
16:22:36 <fizzie> Were user-defined literals part of C++11?
16:22:45 <b_jonas> newsham: so, like, in haskell, x = 3 always introduces a new variable x
16:22:52 <Vorpal> <Guest46968> C++11 was an obvious improvement on C++03. <-- in some respects, yes
16:22:57 <b_jonas> in C++ it's probably just an assignment to an existing x
16:23:23 <Vorpal> fizzie, yes
16:23:36 <Vorpal> If you mean suffixes to numbers at least
16:23:46 <Vorpal> That I think is terrible, makes it much harder to follow
16:24:29 <Jafet> Nearly all C++03 code is valid C++11, and C++11 can do many other things. So the committee considers it an improvement.
16:24:48 <b_jonas> I consider it an improvement too
16:24:55 <b_jonas> especially because of move-return
16:24:58 <int-e> finally, threads.
16:24:58 <Vorpal> So... I was reading some C++ (03) code making heavy use of boost MPL the other day. Scary
16:25:03 <newsham> superset is an awesome langauge design technique!
16:25:13 <Jafet> Oh, you say you wanted a language that takes less than five years to learn properly and less than one coffee break to compile? Too bad.
16:25:25 <newsham> this tomato is really cool, now it just needs wheels!
16:26:28 <Vorpal> Jafet, the code base at work takes about an hour to completely build, using MSVC 2005. Building for both windows and the embedded real time OS. Oh and that is using a distcc-like thing for windows called IncrediBuild. I have no idea how long it would take with a single computer
16:26:37 <int-e> newsham: it's amazing how many gaps in the syntax tree you can fill that way.
16:26:41 <Vorpal> That is C++ for you
16:26:53 <Jafet> I remember building gcc from svn, soon after they switched to C++
16:27:03 <Vorpal> took ages I bet?
16:27:04 <b_jonas> Vorpal: try disabling link-time optimization. that sometimes helps a lot with MSVC.
16:27:09 -!- stuntaneous has joined.
16:27:13 <Jafet> (The svn repo is about 1GB now.)
16:27:27 <Vorpal> b_jonas, the real killer is generating the pdb files for debug build really...
16:27:39 <b_jonas> Jafet: yeah, gcc is building slow again
16:27:45 <b_jonas> there was a time when it built quickly
16:27:47 <b_jonas> strange
16:28:00 <b_jonas> I quite like C++
16:28:05 <Slereah_> Back in my dayyyys
16:28:11 <Vorpal> b_jonas, I have seen 700+ MB pdb files for the final applications. We link everything statically (since anything else is a MASSIVE pain on the RTOS target), so that doesn't help.
16:28:26 <Jafet> (Also, the commands I used to build gcc were "./configure && make; make; make; make; make install".)
16:28:28 <b_jonas> Slereah_: no no, back in my days gcc built slow, because computers were too slow
16:28:37 <Vorpal> b_jonas, the linker takes a LONG time for that
16:28:46 <Vorpal> b_jonas, it is not so bad in release builds though
16:28:52 <Slereah_> Back in someone's dayyyys
16:28:54 <b_jonas> Vorpal: generating pdb files you say? hmm
16:29:01 <fizzie> It's daily C syntax corner case time! http://sprunge.us/ccKL
16:29:04 -!- Sprocklem has joined.
16:29:27 <b_jonas> fizzie: hehehe
16:29:38 <int-e> back in those days e-mailing somebody the X11R5 sources was considered a DoS attack.
16:29:38 <Vorpal> b_jonas, can take up to 5 minutes to link debug builds sometimes, and some investigation showed most of that was spent writing the 700+ MB pdb file
16:30:01 <Vorpal> b_jonas, the application is more like 30 MB in debug (and iirc like 12 or so in release)
16:30:02 <HackEgo> [wiki] [[Talk:Smartboxes]] http://esolangs.org/w/index.php?diff=39307&oldid=39306 * Zerk * (+476) /* Implicit evaluation */
16:30:10 <b_jonas> there's a funny C++ code that used to build in old gccs then not build in later ones, and I actually understood why it is invalid code according to C++, but then some later gcc decided to accept it again
16:30:43 <Vorpal> <fizzie> It's daily C syntax corner case time! http://sprunge.us/ccKL <-- what is ptype?
16:30:44 <newsham> c++ still hasnt incorporated awk or sed or sh
16:30:50 <newsham> there is still room for improvement
16:30:56 <b_jonas> newsham: no, but they're getting close to that
16:31:26 <Vorpal> fizzie, also why does it do what it did there?
16:31:40 <fizzie> Vorpal: The "-" sign is the unary - operator, not part of the integer literal.
16:32:01 <fizzie> (And 2147483648 is larger than INT_MAX, so is of type long.)
16:32:02 <Vorpal> b_jonas, also that is not due to the disk btw, we all use high end intel SSDs in our computers
16:32:25 <Vorpal> fizzie, ahhh
16:32:28 <b_jonas> Vorpal: are you also using enough RAM?
16:32:45 <Vorpal> b_jonas, 12 GB in some machines, 16 in others. 64-bit windows 7
16:32:50 <fizzie> (The "-" sign in floating point literals is part of the literal syntax, but it probably doesn't matter there.)
16:32:55 <Jafet> 700 MB of RAM
16:32:58 <newsham> for(<FD>) { next unless(m/stuff/; ... }
16:33:03 <b_jonas> Vorpal: I see
16:33:25 -!- MoALTz_ has joined.
16:33:30 <Vorpal> b_jonas, we are going to switch to linux in the future though for the next version of the embedded platform, porting is currently in the works. I guess we will have to support the old one for quite some time to come though
16:33:33 <Jafet> Ironically, float range is sign-symmetric but int range is not
16:33:34 <b_jonas> here's that C++ thingy that I think shouldn't compile, but gcc now accepts it again: http://dpaste.com/1778559/
16:33:38 -!- ais523 has quit (Ping timeout: 245 seconds).
16:33:38 <Vorpal> so eh I don't bother too much
16:33:41 <b_jonas> this channel might apprecate it
16:34:08 <b_jonas> Jafet: it does matter a bit for floats too, because of preprocessor shenenigans with ## stuff
16:34:17 <b_jonas> not much though
16:34:21 <Vorpal> b_jonas, what is wrong with that?
16:34:35 <b_jonas> Vorpal: oh wait, that's the version that should compile
16:34:48 <b_jonas> Vorpal: change the ::d to d to have the version that is questionable
16:34:49 <Vorpal> b_jonas, I probably couldn't tell them apart
16:35:10 <b_jonas> Jafet: also probably for user-defined literals
16:35:21 <Vorpal> b_jonas, okay, why is that questionable, I don't see multiple d symbols in there
16:35:29 <b_jonas> here's the questionable version: http://dpaste.com/1778560/
16:36:06 <Vorpal> b_jonas, as far as I can see, there is only one class d in there?
16:36:10 <b_jonas> Vorpal: the trick is that in that context d can refer to the concrete type d<T>, or the type template d
16:36:18 <Vorpal> Ah
16:36:22 <b_jonas> Vorpal: ::d unambiguously refers to the template
16:36:42 <Vorpal> fuck template-template arguments :P
16:36:51 <b_jonas> the language usually disambiguates between the two because if you use the template a less than sign follows
16:36:56 -!- nucular has joined.
16:36:56 -!- nucular has quit (Changing host).
16:36:56 -!- nucular has joined.
16:37:00 -!- MoALTz has quit (Ping timeout: 276 seconds).
16:37:03 <b_jonas> which is why you need this crazy code to confuse the grammar
16:37:05 <Vorpal> b_jonas, yes and template-template breaks that
16:37:24 <Vorpal> C++ grammar is terrible
16:38:06 <Vorpal> That is one thing I like about python. A mostly sensibly grammar that is sensibly parseable
16:38:14 <Vorpal> Btw, is it "parseable" or "parsable"?
16:38:40 <Vorpal> s/sensibly/sensible/
16:39:30 <b_jonas> Vorpal: is it now? do you know the scoping rules for python, like what creates a new variable in a scope as opposed to referring to an existing one?
16:39:42 <int-e> Vorpal: yes, according to https://en.wiktionary.org/wiki/parsable
16:40:09 <Vorpal> b_jonas, okay that bit is a meh, but at least there is no ambiguity at the actual parsing stage. Afaik the grammar is LL(1)
16:40:32 <Vorpal> int-e, oh nice, I can mix and match after my mood ;)
16:41:40 <b_jonas> I have another crazy example about gcc, but that's more dependent on which generation of the C++ standard you look at
16:41:45 <b_jonas> let me find it
16:42:58 <b_jonas> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=59704
16:43:00 <Vorpal> Completely unrelated, I just looked at my car expenses spreadsheet, specifically the fuel page. Man, it is expensive having a car. At least if you live in Europe.
16:43:30 <b_jonas> Vorpal: it sure is
16:43:35 <Vorpal> Spent around 1225 USD on fuel alone since buying the car last summer.
16:43:44 <Vorpal> (~8000 SEK)
16:44:50 <Vorpal> This is a new chromium bug I think... Sometimes when I scroll the page goes blank. If I scroll a bit further it goes back to working again
16:45:01 <Vorpal> First showed up a couple of days ago...
16:45:59 <Vorpal> b_jonas, ouch
16:46:04 <int-e> b_jonas: evil gcc.
16:46:16 <Vorpal> int-e, also evil language and evil code
16:46:30 <b_jonas> Vorpal: yes, all of those
16:46:31 <Vorpal> b_jonas, what does = delete mean? I haven't used C++11
16:46:35 <Vorpal> not much at least
16:47:13 <Guest46968> I want to tell 2008 Vorpal about 2014 Vorpal having a car.
16:47:35 <Vorpal> Guest46968, why is that? Did I say something about cars back then?
16:47:45 <b_jonas> Vorpal: that means the function doesn't exist and will never be defined. it's most often used for copy constructors of non-copiable classes.
16:47:47 <Guest46968> um. I think you hated them but maybe I'm mixing you up.
16:47:52 <b_jonas> here it comes useful to produce a clear example
16:48:10 <b_jonas> it's not necessary for exhibiting this bug, just makes it simpler to show
16:48:23 <Vorpal> Guest46968, err think you are mixing me up. They are terrible for the environment, and I avoid driving when I don't have to. But I probably didn't go further than that
16:49:16 <Vorpal> b_jonas, ah yes, the old C++03 way of declaring but not defining such a function would produce a linker error instead
16:49:30 <Vorpal> or making it private (if in a class, unlike here)
16:49:51 <b_jonas> Vorpal: you can demonstrate this bug without delete, but then you'd have to check what function gcc actually chooses to call, instead of getting a straight error message
16:50:31 <Vorpal> b_jonas, or just define one of them and try to link it, resulting in a linker error as I said
16:51:10 <Vorpal> I didn't know you could mix varargs with overloading btw
16:51:18 <Vorpal> It seems like it could be terribly confusing
16:52:40 <Vorpal> fizzie, recommendation(s) for domain name reseller?
16:52:43 <b_jonas> Vorpal: the context is this. gcc has a language extension called __builtin_constant_p to determine whether an expression is compile-time constant. this is useful in macros that try to do magical optimized stuff.
16:52:55 <Vorpal> b_jonas, ah
16:53:08 <b_jonas> Vorpal: now Jens Gustedt noticed that this is possible to write in standtard C11, without an extesions,
16:53:12 <b_jonas> see https://gustedt.wordpress.com/2013/08/22/testing-compile-time-constness-and-null-pointers-with-c11s-_generic/
16:53:29 <b_jonas> but he wrote "I am not aware of a C++ feature that provides the same possibilities"
16:53:46 <b_jonas> so I wanted to implement the same thing in C++, and I do have a solution which seems to work,
16:54:04 <b_jonas> but the problem is, it's completely fragile and seems to depend on what gcc can optmize to a constant,
16:54:17 <b_jonas> instead of just what the language specs considers compile-time constant,
16:54:22 <Vorpal> Ah
16:54:23 -!- doesthiswork has joined.
16:54:25 <Sgeo> Why do bullshitters always put their bs "information" in a video instead of something nice and readable?
16:54:26 <b_jonas> so it could easily break in a future gcc.
16:54:30 <b_jonas> this bug is about that.
16:54:33 <b_jonas> but in the meanwhile,
16:54:40 <Sgeo> The bill this person is talking about was in 2010 and doesn't even mention 2014
16:54:41 <Vorpal> b_jonas, so what does _Generic do?
16:54:50 <Sgeo> So I cant just google
16:55:09 <b_jonas> c++1y wants to change the rule about what can be casts to a null pointer, so it would break my solution completely.
16:55:23 <Vorpal> hm
16:55:46 <b_jonas> Vorpal: it's a C11 thingy for choosing different expressions depending on the type of an expression.
16:55:48 <Vorpal> I need to look into what C11 brought to the table at some point btw
16:55:49 <int-e> Sgeo: charisma? hard to express that in text (unless you use comic sans ;-) )
16:55:59 -!- ais523 has joined.
16:56:08 <b_jonas> C++ doesn't have it, because it has function overloading instead.
16:56:11 <Vorpal> int-e, doesn't comic sans express the lack thereof
16:56:27 <b_jonas> Vorpal: the most useful thing it's brought is well-defined semantics for multithread stuff,
16:56:27 <int-e> Vorpal: yes. but so could a video.
16:56:32 <Sgeo> "Write Down This Date:
16:56:32 <Sgeo> July 1st, 2014"
16:56:42 <Sgeo> Can we write it down so we can give people like this the middle finger?
16:56:42 <b_jonas> Vorpal: with basically the same model as C++11,
16:56:44 <Vorpal> b_jonas, so a C header using it couldn't be included in a C++ program? Okay
16:57:15 <int-e> July 1st 2014. A perfectly ordinary day somewhat past the middle of 2014.
16:57:16 <Sgeo> Or maybe this person is schizophrenic, rather than a scammer?
16:57:21 <b_jonas> Vorpal: not normally, but such a C header could do an #ifdef to work in both cases, and some headers in gcc or libc will do that
16:57:29 <Sgeo> int-e: supposedly the US is going to collapse due to some law
16:57:35 <int-e> again.
16:58:08 <Vorpal> b_jonas, hm
16:58:17 <Sgeo> But there's a template here, I feel. Of using a video. They don't sound like a crazy. My vote is scammer.
16:58:44 <Sgeo> http://www.endofamerica.com/
16:58:54 <Sgeo> The video is so lengthy, still hasn't gotten to the point yet
17:01:18 <Sgeo> Why doesn't this person just GET TO THE POINT already
17:01:26 <Sgeo> Does doing this increase fear or something?
17:01:31 <Vorpal> Sgeo, why are you watching it then?
17:01:55 <Sgeo> I want to see what this scam is about
17:03:27 <Sgeo> Apparently it's fear-mongering about debt spending? WIth no relation to "On this date, U.S. House of Representatives Bill "H.R. 2847" goes into effect. It will usher in the true collapse of the U.S. dollar, and will make millions of Americans poorer, overnight. You now have just several months to prepare..." on the website
17:07:13 <int-e> http://www.truthorfiction.com/rumors/h/HR-2847-Dollar-Collapse.htm
17:07:40 <int-e> I tried reading the bill itself but I have no idea what it says.
17:08:24 <Sgeo> It doesn't say 2014, but maybe I missed something that's equivalent
17:09:14 <int-e> Sgeo: there are relative effective dates in there, e.g. "The amendments made by this section shall apply to obligations issued after the date which is 2 years after the date of the enactment of this Act."
17:09:24 <fizzie> Vorpal: I have my only .org from register4less, but they're not cheap; I've just been staying there because of inertia.
17:10:02 <fizzie> Vorpal: (For .fi domains, I recommend the Finnish Communications Regulatory Authority.)
17:10:38 <ais523> fizzie: misleading name?
17:10:59 <fizzie> ais523: It's possible they were relatively cheap at that time.
17:11:17 <Sgeo> "Our countries's unique ability to print more money"
17:11:33 <Sgeo> Oh, it's saying that we're the only one able to print US money, which is popular
17:12:37 <fizzie> "10MB of web space. A part of the R4L difference that we have offered our clients from the first day is free web space with your domain. With every R4L registration, you can host a web site up to 10MB in size, banner-free!"
17:12:53 -!- nooodl has quit (Ping timeout: 258 seconds).
17:12:55 <fizzie> I have a feeling 10 megabytes might not be anything to write home about, these days.
17:13:30 <Bike> might not even be enough space to fit t he ltter home, in fact
17:14:17 <int-e> ltter
17:17:54 <ais523> fizzie: it's still quite a lot of space if you're just storing text, though
17:18:31 <fizzie> ais523: It is, yes, but it does sound sort of "outdated".
17:24:31 <doesthiswork> sfeer theory shows the connection between comonads and natural deduction http://sfeertheory.littlefoolery.com/index.html
17:25:55 -!- ais523 has quit.
17:26:05 -!- ais523 has joined.
17:27:51 -!- ais523 has quit (Read error: Connection reset by peer).
17:27:54 -!- callforjudgement has joined.
17:30:20 <Vorpal> fizzie, hm
17:30:56 * pikhq submits a CFJ: can "ais523" and "callforjudgement" refer to the same entities?
17:31:18 <Vorpal> fizzie, with tilaa how many IPv4 do you get?
17:31:51 <Vorpal> fizzie, I can't find that on their site
17:32:18 <fizzie> Vorpal: One.
17:32:29 -!- scarf has joined.
17:32:37 -!- callforjudgement has quit (Read error: Connection reset by peer).
17:32:50 <fizzie> Vorpal: It's (sort of) there in the knowledge base, just not very prominently: https://support.tilaa.com/entries/20917782-Can-I-get-additional-IPv4-addresses-
17:33:21 -!- tromp has quit (Remote host closed the connection).
17:33:57 -!- tromp has joined.
17:34:01 <Vorpal> fizzie, ah
17:34:28 <HackEgo> [wiki] [[Boxy]] http://esolangs.org/w/index.php?diff=39308&oldid=39305 * Zerk * (+281) Reverted to using _var assignments, moved $ to #sugar where it belongs.
17:34:31 <fizzie> Vorpal: (They also assign only a single IPv6 address, not a /64 block or something, and you need to request more via their dashboard thing. But I think those are free.)
17:34:46 <Vorpal> fizzie, how is support btw?
17:34:57 <Vorpal> And do they have an IRC channel?
17:35:46 -!- scarf has quit (Client Quit).
17:36:13 -!- scarf has joined.
17:38:39 <fizzie> Vorpal: I don't think I've had any reason to contact them. I tried to check my email archive, but "tilaa" is the Finnish word both for "space" (as in, "the space between the walls", not stars-and-galaxies space) and "order" (as in, "order now while supplies last"), so I get a whole lot of emails in Finnish.
17:38:45 -!- tromp has quit (Ping timeout: 276 seconds).
17:39:48 -!- ais523 has joined.
17:39:49 <fizzie> "tilaa.com" seems to have been a better search term, but there's just email notices of downtime or planned maintenance; I've never had an occasion to contact their support.
17:40:03 <fizzie> I don't think they have an IRC channel, though I could be wrong about that.
17:40:39 <fizzie> They have a Twitter account. :p
17:41:17 -!- scarf has quit (Ping timeout: 240 seconds).
17:43:50 -!- callforjudgement has joined.
17:45:49 -!- ais523 has quit (Ping timeout: 250 seconds).
17:46:31 -!- Bike_ has joined.
17:46:34 -!- Bike has quit (Read error: Connection reset by peer).
17:50:27 -!- callforjudgement has quit.
17:50:34 -!- scarf has joined.
17:55:52 -!- scarf has quit.
17:56:01 -!- scarf has joined.
18:00:01 <Bike_> http://blog.regehr.org/archives/767 lol
18:00:12 -!- Bike_ has changed nick to Bike.
18:00:54 -!- heroux has quit (Ping timeout: 240 seconds).
18:01:55 -!- heroux has joined.
18:05:46 <Vorpal> fizzie, hm
18:09:23 <fizzie> Bike: I like that winner #2 end result very much.
18:10:03 <Bike> yeah it's pretty @_@
18:12:25 <fizzie> Though I was under the impression that the fact realloc can return some completely different pointer and invalidate the old one was pretty common knowledge.
18:12:51 <Jafet> A C compiler should not assume these things left and right, though.
18:13:23 <pikhq> Unfortunately for you, a C compiler is permitted to assume UB never happens.
18:13:28 <Jafet> For example, what happens when you use -nostdlib. (Sometimes, the compiler blindly continues using its assumptions)
18:13:28 <zzo38> fizzie: I also, thought so
18:14:02 <pikhq> -ffreestanding is the one to make it do a freestanding C implementation.
18:14:05 <Jafet> There was a bug in gcc 4.8 where gcc would compile an implementation of memset into a call to memset
18:14:07 <Bike> fizzie: well, i didn't know, not that i'm a C programmer, and i don't see it in man
18:14:25 <zzo38> I don't really like that, standard library assumptions, so, I defined that Black-C has a different way to specify standard library assumptions.
18:14:31 <pikhq> -nostdlib says "don't implicitly add -lc to the link line" and that's all.
18:14:52 <Bike> it's not what i'd infer from "changes the size of the memory block pointed to by ptr", certainly
18:14:54 <Jafet> Yes, I meant -ffreestanding might not turn off those assumptions.
18:14:56 <fizzie> Bike: It is only implied very vaguely in my realloc man page. "If the area pointed to was moved, a free(ptr) is done."
18:15:11 <pikhq> And *that* is a compiler bug. :)
18:15:20 <pikhq> fizzie: The man page isn't normative though.
18:15:33 <Bike> not normative, but more people are going to read it than ANSI!
18:16:01 <pikhq> " The realloc function deallocates the old object pointed to by ptr and returns a pointer to a new object that has the size specified by size. The contents of the new object shall be the same as that of the old object prior to deallocation, up to the lesser of the new and old sizes."
18:16:05 <Bike> btw is there some way to see what version of a given man page i have
18:16:30 <Bike> pikhq: is that the standard?
18:16:36 <fizzie> That is the standard, yes.
18:16:55 <Bike> that sounds like a totally different function from the one in my manual
18:16:55 <fizzie> It also mentions, in the return value section, that it "returns a pointer to the new object (which may have the same value as a pointer to the old object)".
18:17:09 <pikhq> Yes, that is 7.20.3.4 from the WG14/N1256 draft.
18:17:19 <pikhq> (closest I, a cheapskate, have to the actual spec)
18:17:36 <fizzie> The C89 wording is essentially very close to Bike's (and mine) man pages.
18:17:38 <Bike> i mean obviously it makes sense that it's going to have to get a new block sometimes, but i didn't know that from the manual, is all
18:17:49 <fizzie> "The realloc function changes the size of the object pointed to by ptr to the size specified by size . The contents of the object shall be unchanged up to the lesser of the new and old sizes."
18:18:13 <zzo38> So I would have it, the realloc function can be declared with ["implements"("realloc",ptr,len)] ["invalidate"(ptr)] before the function header, to indicate to the optimizer, such features. (Actually the first implies the second, but this is in case the compiler doesn't implement "implements".)
18:18:34 <fizzie> And the only bit that hints at the possibility of a move is the "returns" section: "The realloc function returns either a null pointer or a pointer to the possibly moved allocated space."
18:18:41 <scarf> ooh, are we taking about realloc?
18:18:47 <Bike> fizzie: that's actually the same as my man page, except it uses "will" instead of "shall"
18:18:55 <Bike> scarf: yes, see my link above, there's an amusing UB
18:18:59 <Bike> amusing result of UB, rather
18:19:06 <scarf> I was reading C11's definition of realloc, and AFAICT, if you give it a zero size and an existing pointer
18:19:21 <scarf> it's allowed to return a non-NULL pointer that you aren't allowed to dereference
18:19:29 <Bike> zzo38: does "implements" tell the compiler to use optimizations hardcoded for "realloc"?
18:19:30 <scarf> and that can be deallocated
18:19:34 <pikhq> Yes, that matches malloc's behavior.
18:19:39 <zzo38> Bike: Yes.
18:19:50 <Bike> boring. i like "invalidate" though.
18:19:51 <pikhq> malloc(0) can return NULL or a unique pointer that it is UB to dereference.
18:20:01 <Bike> sounds like the sort of thing rust probably has
18:20:25 <pikhq> This is the same in C99 and C90.
18:20:26 <fizzie> pikhq: It can be safely passed to free, however.
18:20:37 <pikhq> Yes, but the same is true of NULL.
18:20:46 <zzo38> pikhq: Yes, what make sense to me is that realloc with an existing pointer and zero size, ought to free the pointer and then return whatever malloc(0) is, which can be safely freed whether or not the result is null.
18:20:46 <scarf> pikhq: yeah, but realloc-as-0 is documented to be the same as free in the man pages
18:20:52 <scarf> and it's quite useful for it to behave like that
18:21:04 <pikhq> scarf: Yes, it is quite useful.
18:21:09 <scarf> as such, I've been making realloc wrappers I write do a free instead if given zero size
18:21:42 <pikhq> zzo38: Conceptually that's what it *does*.
18:22:13 <pikhq> Except a hypothetical evil implementation could have realloc make the opposite choice from malloc. :(
18:22:45 <Guest46968> it's amusing that if (!(p = malloc(sz))) die(); is incorrect
18:22:46 <zzo38> pikhq: I don't care as long as whatever it returns can be safely freed once, and that whatever it returns can also be passed to realloc.
18:23:09 <Bike> Guest46968: for sz = 0 you mean?
18:23:12 <Guest46968> yeah
18:23:16 <pikhq> zzo38: Well, the C standard does require that to work no matter which implementation choice is made.
18:23:20 <scarf> pikhq: it's unspecified, isn't it, not impl-defined?
18:23:24 <scarf> so it could change randomly during a program
18:23:38 <zzo38> pikhq: Yes, which is how it should be, so it is OK.
18:24:03 <Jafet> What happened to the evil libc project, anyway
18:24:16 <pikhq> scarf: " If the size of the space requested is zero, the behavior is implementation- defined: either a null pointer is returned, or the behavior is as if the size were some nonzero value, except that the returned pointer shall not be used to access an object."
18:24:36 <scarf> oh good, it is impl-defined
18:24:56 <fizzie> You could argue that realloc is not allowed to return NULL, since it must "return a pointer to a new object that has the size specified by /size/" and can return NULL only if "the new object could not be allocated". And you can't say that it can return NULL under the "could not be allocated" rule, because "if memory for the new object cannot be allocated, the old object is not deallocated and ...
18:25:01 <scarf> hey, is it legal to pass a negative size to malloc?
18:25:02 <fizzie> ... its value is unchanged".
18:25:12 <fizzie> scarf: It's a size_t, it has no negative values.
18:25:15 <scarf> oh right, yeah
18:25:22 <scarf> I'd just notice that, but you got there first
18:25:34 <scarf> I was confused by valgrind telling me that I'd passed -8 to malloc recently
18:25:45 <scarf> (it was very helpful that it did that, that bug would have taken longer to find otherwise)
18:25:56 <scarf> presumably it assumes very large size_ts are actually negative
18:26:26 <Jafet> What if it told you that you'd passed 0xfffffffffffffff8
18:26:34 <scarf> yeah, that'd be useful too
18:26:50 <pikhq> Yes. It's essentially impossible to meet some of C's requirements while allowing objects with a size that don't fit in ssize_t.
18:26:56 <scarf> but the Valgrind docs imply to me that they care a lot about making the output understandable to end users, which implies to me that many end users tend to be confused by it
18:27:09 <zzo38> If you are passing a size with the high bit set then probably it is wrong anyways since it likely take up too much of the program's RAM.
18:27:22 <pikhq> Which means that sufficiently large objects (larger than SSIZE_T_MAX) are utterly illegal in practice. :)
18:27:29 <scarf> pikhq: you're reminding me of a thread on comp.lang.c about whether you could have a conforming implementation that could allocate objects larger than SIZE_MAX bytes using calloc
18:27:45 <fizzie> There was someone on another channel doing fd = open(...); if (fd < 0) die_noisily(); printf("fd = %d", fd); with an accidentally unsigned fd, and was very confused by "it prints fd = -1 but it doesn't die_noisily whaaat". (A case of not enough compiler warning flags, of course.)
18:28:00 <Jafet> That is metaphysics.
18:28:04 <scarf> I know that one outcome on the thread is that a lot of libc devs realised that their libcs were buggy when given such arguments, at least
18:28:05 <zzo38> scarf: I suppose that might be possible.
18:28:16 <pikhq> scarf: "Essentially" for the sake of skipping out on such a debate. :)
18:28:54 <scarf> fizzie: this reminds me, I've been planning to change all the integers in NetHack, apart from bitfields, to signed (making them wider if necessary)
18:29:01 <scarf> can you think of anything that might end up breaking as a result?
18:29:16 <Jafet> Prot ring hacks
18:29:40 <Jafet> I suppose you mean things that aren't exploits
18:29:43 <fizzie> scarf: Hah, realloc of size 0 is the very first defect report of C11: http://www.open-std.org/jtc1/sc22/wg14/www/docs/dr_400.htm
18:29:49 <Guest46968> scarf: weird decision
18:29:58 <scarf> note that it's OK if code could theoretically break from the change, so long as it's not used in NetHack
18:30:22 <scarf> Guest46968: I want to autogenerate structure descriptions, rather than relying on a bunch of code implemented by hand that has to be manually synchronized across up to six different files
18:30:28 <scarf> automatically generating unsigned ints is just asking for pain
18:30:35 <scarf> thus making them all signed is a saner option
18:32:39 <zzo38> What are these structure descriptions?
18:32:42 <scarf> hmm, so they're officially making size-0 realloc an error
18:32:45 <scarf> pity :-(
18:33:00 <zzo38> And, sometimes you might want unsigned numbers
18:33:07 <scarf> zzo38: I only started work on them a couple of days ago, it's not really finished
18:33:15 <zzo38> scarf: I sometimes use malloc(0) and realloc with size zero, too, though.
18:33:18 <scarf> but you define numerical types by giving a range
18:33:28 <scarf> e.g. you write [0, 100] and that probably becomes int8_t
18:33:55 <scarf> [0, 255] would become int16_t unless you explicitly say that unsigned types are allowed, in which case it might become uint8_t or a bitfield unsigned : 8
18:34:00 <zzo38> TeX actually does contain macros which are there in case the compiler won't generate unsigned types.
18:34:31 <scarf> in general, I assume that you shouldn't be having overflow happen at all
18:34:46 <Guest46968> just use a bignum type for everything.
18:35:35 <zzo38> (These macros are in section 112)
18:35:41 <fizzie> scarf: The mixed-sign integer comparison rules (or, rather, the usual arithmetic conversions in that context) are kind of unintuitive occasionally, at least. (Both get integer promotions first; then if the unsigned type has larger rank, the signed is converted to unsigned and unsigned comparison takes place; alternatively if the signed type can represent all values of the unsigned type, the ...
18:35:45 <scarf> 'twould be nice, but that's not easy to retrofit onto a 27-year-old C codebase
18:35:47 <fizzie> ... unsigned operand is converted to signed and the comparison is signed; alternatively both are converted to the unsigned type corresponding to the operand with the signed type.)
18:36:02 -!- ^v has quit (Ping timeout: 252 seconds).
18:36:13 <Guest46968> scarf: easier if you use C++ to define the bignum type
18:36:16 <scarf> fizzie: I don't remember that rule 100%, but do know how it works approximately
18:36:16 <Guest46968> then you get operator overloading
18:36:24 <scarf> scarf: NetHack doesn't compile as C++
18:36:42 <Guest46968> that's an easier problem to solve than replacing all arithmetic operators
18:36:44 <scarf> err, Guest46968:
18:36:58 <scarf> and really, neither problem is particularly easy to solve
18:37:03 <fizzie> So (-1L < 1ULL) for example is false, which you maybe might not expect.
18:37:04 <zzo38> Section 110 contains the description of this feature; "Some Pascal compilers ... insist on allocating space for an additional sign bit; on such systems you can get 256 values into a quarterword only if the subrange is `-128 .. 127'."
18:37:32 <scarf> fizzie: I expected that, fwiw
18:37:38 <fizzie> While (1-LL < 1U) is true.
18:37:46 <fizzie> Er, -1LL, not 1-LL.
18:37:55 <scarf> zzo38: what about 16-bit systems? wouldn't a quarterword be 4 bits?
18:38:08 <scarf> also, TeX is written in Pascal?
18:38:22 <Guest46968> yes
18:38:33 <Guest46968> it's written in pascal but translated to C with a program solely designed to translate TeX to C to compile it
18:38:39 <zzo38> TeX is written in WEB, which is a preprocessor for Pascal.
18:38:56 <zzo38> The "word" in TeX has to be 32-bits even in 16-bit systems though.
18:39:33 <myname> wait, tex is written in a preprocessor for pascal which is translated into c to be compiled?
18:39:47 <Guest46968> yes
18:40:03 <zzo38> It could be compiled using some Pascal compilers too, though.
18:40:04 <myname> like, seriously?
18:40:07 <Guest46968> yes
18:40:18 <myname> but... why?
18:40:38 <Guest46968> yes
18:40:42 <Jafet> Like thousands of other programs of the 70s, TeX was written in pascal.
18:41:02 <scarf> also, blog.regehr.org talks about UB quite a bit, and is frequently a good read
18:41:12 <scarf> it has an example where it doesn't check the return value of printf
18:41:20 <scarf> and then actually talks about the possible behaviour of the program
18:41:28 <scarf> (this is, btw, the #1 most common bug in hello world programs)
18:41:47 <scarf> `run /bin/true --help > /dev/full
18:41:48 <HackEgo> ​/bin/true: write error: No space left on device
18:41:55 <scarf> `run /bin/true --help > /dev/full; echo $?
18:41:56 <HackEgo> ​/bin/true: write error: No space left on device \ 1
18:42:18 <scarf> admittedly, /checking/ the return value can also lead to absurdities
18:42:18 <fizzie> And -1L < 1U is false on systems where long is the same size as int, but true on systems where long is longer.
18:42:42 <zzo38> The preprocessor does various things, such as convert hex and octal numbers into decimal, implement macros, convert all names into uppercase and remove all underscores, as well as rearrange and transclude "chunks", generate a string pool, and generate an index and various cross-references, pretty-print the code, etc.
18:42:43 <scarf> now I wonder if any program uses that to compare the size of int to the size of long
18:42:44 <myname> i have a long long in my pants!
18:42:46 <myname> sorry
18:43:12 <scarf> zzo38: now I wonder if Knuth uses a preprocessor to write INTERCAL
18:43:16 <fizzie> (On the first kind of systems, long can represent all values of unsigned int so 1U is converted to long; on the second it can't, so both are converted to unsigned long.)
18:43:18 <scarf> that converts variable names to numbers, for instance
18:43:29 <Jafet> `run echo 'long long long n;' > /tmp/a.c && gcc /tmp/a.c
18:43:29 <HackEgo> ​/tmp/a.c:1:11: error: ‘long long long’ is too long for GCC
18:43:47 <int-e> hehe
18:43:55 <scarf> he uses three-letter variable names that are converted into variable numbers using the five-bit Baudot encoding
18:44:19 <scarf> I'm upset that gcc doesn't still have a pragma to run NetHack
18:44:22 <scarf> (it was documented, thus legal)
18:44:39 <scarf> actually it used to interpret all pragmas like that, as a protest against bugs in the definition of #pragma
18:44:41 <myname> what
18:44:42 <Jafet> I thought it did, at one point
18:45:02 <scarf> but the bugs were fixed, and it now implements a few pragmas of itso wn
18:45:02 <Jafet> Oh
18:45:03 <scarf> *own
18:45:09 <scarf> so it can't implement /all/ of them like that
18:45:15 <scarf> and thus it doesn't implement any like that
18:45:36 <Bike> http://blog.regehr.org/archives/140 haha, beaut
18:46:11 <zzo38> Another thing WEB does is read a "change file" which makes changes to the program before it is compiled. This is implemented so that you can make the changes needed for whatever system you are compiling on.
18:46:57 <myname> like... patches?
18:47:16 <zzo38> Yes
18:47:43 <Bike> i don't think i understand how this termination analysis works...
18:47:45 <scarf> Bike: incidentally, gcc now has an option that, among other things, tells you about functions it wanted to perform optimizations on (normally moving calls to them elsewhere), but couldn't because it isn't sure that they terminate
18:47:46 <Jafet> I like "change file"
18:48:04 <scarf> (although it suspects that they probably do)
18:49:18 <Bike> is there an annotation or something to say that they terminate?
18:49:22 <scarf> incidentally, CLC-INTERCAL actually optimizes detected infinite loops into infinite sleeps
18:49:37 <scarf> Bike: there's __attribute__((pure)), which implies termination among other things
18:49:57 <scarf> if the function is total but impure, then gcc couldn't do the optimizations in question anyway, so there's no real gain
18:49:57 <Bike> surely always terminating mutagenic functions aren't uncommon
18:50:02 <Bike> oh.
18:51:22 <int-e> Bike: I remember having run into something like this. I wanted to produce a stack overflow, void f() { f(); } ... and the call got optimized away by icc.
18:51:31 <Bike> hm, does the analysis work by figuring that once it's run through all 1000³ tuples it can stop
18:51:36 <scarf> wow, according to http://blog.regehr.org/archives/161, in C++0x, infinite lops are UB
18:52:07 <Bike> guess i should just try it
18:52:18 <scarf> unless they access library functions that do I/O, do synchronization with other threads, or change volatile variables
18:52:33 <Bike> ok, yeah, there's a delay.
18:52:52 <Bike> a delay that is appreciably burning my CPU, even
18:53:21 <Bike> i suppose it doesn't say what gcc does, though.
18:53:29 <scarf> Bike: I think it works correctly in gcc
18:53:47 <scarf> given that a) it doesn't mention gcc, and b) gcc explicitly checks for termination when optimizing out code
18:53:50 <Bike> i don't think i'm willing to install icc for this
18:54:34 <fizzie> scarf: Anyhow, if you're dealing mostly with narrower-than-int unsigned types (like I'd assume, given NetHack), those probably have been converted to int by integer promotions in most of their uses in arithmetics/comparisons before now, already.
18:55:00 <scarf> fizzie: NetHack uses types more or less at random, AFAICT
18:55:09 <scarf> I guess there have been guiding principles in the past, but they've changed over time
18:55:19 <scarf> plain unsigned is entirely visible on occasion
18:55:34 <scarf> actually, the main problem is when they've tried to do overflow checks, and those checks don't work
18:55:43 <Bike> "nethack" and "random" in the same sentence brings odd memories to mind
18:55:52 -!- MindlessDrone has quit (Quit: MindlessDrone).
18:56:04 <scarf> Bike: well NetHack is a very random gmae
18:56:06 <scarf> *game
18:56:10 <scarf> its implementation's also pretty random
18:56:13 <myname> nethack <3
18:57:14 <Bike> scarf: was thinking of rnz
18:57:35 <scarf> Bike: "These C compilers known to not preserve termination properties of code: Sun CC 5.10, Intel CC 11.1, LLVM 2.7, Open64 4.2.3, and Microsoft Visual C 2008 and 2010. The LLVM developers consider this behavior a bug and have since fixed it. As far as I know, the other compiler vendors have no plans to change the behavior.
18:57:36 <scarf> These C compilers, as far as I know, do not change the termination behavior of their inputs: GCC 3.x, GCC 4.x, and the WindRiver Diab compiler."
18:58:00 <Bike> that seems like a pretty strong claim, i wonder how you'd prove it
18:58:06 <scarf> myname: in case you didn't know, I'm the lead maintainer of the fan project to restart NetHack development
18:58:16 <myname> scarf: :O
18:58:17 <scarf> and the main aim of 4.3 is cleaning up the code
18:58:21 <Bike> "This observation is not untrue, but it’s a little like explaining that World War II happened because people couldn’t all just get along." not bad
18:58:28 <Bike> scarf: oh, you're ais, aren't you
18:58:34 <myname> i used to play nethack with like 2 dozens of patches applied
18:58:39 <Bike> names are hard
18:58:45 <myname> and a bit UI modifying by myself
18:58:46 <Jafet> "Fan project"
18:58:47 <scarf> Bike: yes
18:58:49 -!- scarf has changed nick to ais523.
18:59:28 <Bike> rnz is so amusing, it seems like a in-the-wild semiexample of the kind of prng knuth talks about
18:59:36 <ais523> sorry, I set my client to cycle nicks on connection failure, because I use unreliable connections often enough that it helps keep them refreshed
18:59:57 <ais523> Bike: well it doesn't suffer from patterns in the output, just from an utterly nonsensical distribution
19:00:05 <Bike> that's why it's semi-, yeah
19:00:44 <Bike> if i was running a stats class i'd compare rnz to cauchy to explain different kinds of "nonsensical"
19:01:04 <myname> ais523: i assume that this will take years
19:01:08 <Bike> (rnz, if i'm not mistaken, has defined moments)
19:01:44 <ais523> myname: yeah, but we've been working on it for years
19:01:57 <myname> ais523: well, you just proved me right
19:02:13 <ais523> fewer than 50% of the lines in NetHack 4 come from NetHack 3.4.3 or earlier, even when you ignore whitespace changes
19:02:29 <ais523> (if you don't ignore whitespace changes, it's close to 0% because we reindented the entire source tree)
19:02:34 <Bike> now i wish i was good enough with cass to give symbolic definitions of all of rnz's moments.
19:02:46 <Jafet> Has anyone actually calculated the higher moments of rnz
19:03:04 <myname> ais523: what is the reason behind that?
19:03:28 <ais523> myname: for reindenting it? because it was entirely inconsistent before
19:03:41 <myname> ais523: for the project itself
19:03:44 <ais523> I standardised it on what seemed to be the most common indentation scheme within the existing code
19:03:46 <Bike> Jafet: seems unlikely, given that the wikis mostly analyze a continuous distribution slightly different from rnz
19:03:54 <ais523> oh, for the project, it's because there have been no public updates in over 10 years
19:04:07 <ais523> which is far too long to leave NetHack stagnant
19:04:13 <ais523> so if the devteam won't update it, we will
19:04:47 <Bike> i actually don't recall how to do moments of a discrete distribution, hopefully you just replace the integral with a sum
19:05:00 <Jafet> Sometime in the past 10 years, crawl happened to nethack
19:05:37 <zzo38> I want to write roguelike game using SQL.
19:05:47 <Bike> wow wikipedia's article on moments is not very formal
19:05:56 <myname> zzo38: go for it
19:06:02 <myname> i want to write a roguelike in rust
19:06:20 <Bike> maybe i should see if i know enough real analysis to figure this out, after i do my nine hours of homework
19:06:21 <zzo38> myname: OK do you know how to do?
19:06:35 <ais523> Jafet: well, there are enough people who think that NetHack is better (including me) that there's still a healthy NetHack community
19:06:44 <myname> zzo38: you are there for that creative stuff
19:07:41 <ais523> so it's not really fatal at all; competition can be helpful
19:07:44 <ais523> myname: fwiw, structdesc has three types of borrowed pointers, two types of owned pointers, and two which can be owned /or/ borrowed depending on context; I'm considering adding reference counting too
19:07:58 <ais523> this is because it's meant to describe the behaviour of existing C programs
19:08:06 <zzo38> (Not entirely written in SQL; part of it written in C, such as the display and input manager, and some of the functions and virtual table modules, and some other performance related things, and a few other things)
19:08:12 <Jafet> I prefer crawl, though that may be due to the fact that I have not finished it yet.
19:08:12 <ais523> and only disallow the behaviour if it's completely nonsensical
19:09:01 <Sgeo> I wonder how much money I'm spending on ignoring things like sales and atm fees and coupons on receipts
19:09:03 <Bike> "The 1st through 3rd elements indicate cases where the I/O subsystem truncated the string. " shit, printf can do this?
19:09:40 <zzo38> Bike: I would think there are cases where no other way is possible, but to truncate the string.
19:10:01 <myname> ais523: i would prefer a sane port of nethack for android
19:10:01 <Bike> could you have a libc where printf never prints anything and always returns zero if there's no error
19:10:14 <ais523> myname: I've had thoughts along those lines too
19:10:22 <ais523> not owning a tablet myself, it'd be hard to get the ergonomics right
19:10:29 <zzo38> And then, you can add more items and stuff into the game, by adding more records into the table and adding triggers, and possibly more tables if needed; even such things can be changed during the game if these tables are copied into the save file!!
19:10:37 <ais523> the main difficulty is a control scheme
19:10:53 <ais523> I've been wondering about what a mouse-based scheme would look like, that'd be closer to tablet controls than keyboard
19:10:55 <ais523> but still not idential
19:10:55 <Bike> hopefully term on android works better than snes on android
19:10:56 <myname> ais523: well, there are (fairly limited) RL which work pretty well
19:11:09 <zzo38> ais523: You can still implement keyboard scheme; however, then you need also a scheme that work if you have a non-keyboard device.
19:11:28 <myname> but stuff like clicking on a location and a menu would be a big improvement
19:11:46 <zzo38> I think touch screen interfaces are just terrible in general, though.
19:11:46 <ais523> I'm assuming that most smartphones and tablets on which people want to play NetHack don't have physical keyboards, and that I could use a soft keyboard if I wanted to but that it would take up a large amount of screen space
19:12:01 <ais523> and thus other alternativels are likely to be better
19:12:17 <myname> screen space is not THAT big of a problem
19:12:35 <myname> it's more that keys are pretty small and you could move a lot out of that
19:12:48 <myname> like moving, picking up, opening/kicking doors, ...
19:12:51 <Jafet> To do it well, you may need to change some parts of the game to be more like powder.
19:13:04 <myname> what's powder?
19:13:08 <Bike> wowwwww that C++ behavior
19:13:22 <Jafet> Powder is a dungeon crawler written for consoles.
19:13:45 <zzo38> I really believe keyboard interface are much better than touchscreens and so on.
19:14:00 <myname> i may have seen it on nds
19:14:00 <Bike> "Haskell fails to distinguish between the error and non-terminating cases: this can be seen as trading diagnostic power for speed" :')
19:14:01 <ais523> myname: POWDER started out as a project by Jeff Lait (famous both for POWDER and for many 7DRLs) to port NetHack to the DS by rewriting it from scratch, but after starting he decided to make a different game instead that was merely similar to NetHack, rather than identical
19:14:10 <myname> ah :D
19:14:20 <ais523> and it's diverged more from that to become a roguelike of its own
19:14:23 <ais523> err, GBA, not DS
19:14:25 <ais523> I think
19:14:29 <ais523> then it got ported to a bunch of other systems
19:14:33 <ais523> it was some Nintendo portable, anyway
19:14:46 <myname> but even more than that i'd LOVE to have something dwarf fortress like for android
19:14:48 <zzo38> (So, the Famicom version of Attribute Zone, is supporting input from the keyboard in all cases! You can use the standard controller but only for playing ROM levels and the other features are not supported unless you use a keyboard)
19:15:27 <Jafet> dwarf fortress is already unplayable on a PC, and uses too much power
19:15:32 <myname> also, do you guys know cataclysm?
19:15:38 <Jafet> Though I suspect some of that is due to bad programming
19:15:38 <myname> Jafet: yeah, i play it via ssh :D
19:15:50 <myname> quite unsure
19:16:10 <myname> i do think the maths behind it are pretty well
19:16:23 <fizzie> That http://blog.regehr.org/archives/161 is wrong when it says "int main(void) { unsigned short a = 65535; return a + 1; } -- may return 65536 or 0 -- depending on whether the particular C implementation being used has defined the size of an unsigned short to be 16 bits or to be larger than 16 bits", incidentally. It can return 0 (if both unsigned short and unsigned int are 16 bits), 65536 (if ...
19:16:29 <fizzie> ... the size of int is 18 bits or larger) or "the result is implementation-defined or an implementation-defined signal is raised" (if short is 16 bits and int is 17 bits), or the behaviour is undefined (if both short and int are 17 bits).
19:16:37 <Jafet> I continue to hold the position that df2 is not actually a game, based on my attempt to "play" it
19:16:59 <Bike> fizzie: some promotion thing?
19:17:03 <ais523> df2 as in a sequel to dwarf fortress, or a sequel to slaves to armok?
19:17:08 <zzo38> fizzie: OK, although I don't expect most computers to have 17-bits numbers
19:17:19 <myname> Jafet: df2?
19:17:20 <Bike> also, you should point that out, just to give more power to the "can't reason bout my C" thing
19:17:25 <Jafet> Wait, it's sta2, not df2.
19:17:29 <ais523> right
19:17:31 <zzo38> I suppose it is possible but many programs wouldn't work so well on such things anyways, regardless of that.
19:17:34 <fizzie> Bike: Yes, integer promotions. They are mentioned in comment #6 but without considering the case of small ints.
19:18:04 <myname> i watched a tutorial about df once
19:18:06 <fizzie> Oh, it's also mentioned in comment #16 in an almost complete form.
19:18:31 <myname> after half an hour it said "finally, we are in the game. this is, where most of the players quit, too"
19:18:52 -!- ais523 has quit (Read error: Connection reset by peer).
19:18:59 <fizzie> It's missing the implementation-defined case, but that's just additional finessing.
19:19:07 -!- ais523 has joined.
19:19:14 <Bike> hmmmmm now i wish i had more time/effort, i want to prove kinetics is impossible again
19:19:43 -!- adu has joined.
19:20:38 -!- callforjudgement has joined.
19:21:20 <callforjudgement> fizzie: I was trying to figure out if 16-bit short, 17-int is legal; if int and unsigned int have to be the same size, it isn't
19:21:21 <Bike> myname: the one time i tried to play df we were going to do a tradeoff game but worldgen took so long that we ran out of time
19:21:32 <callforjudgement> because it has to be a multiple of CHAR_BIT
19:21:36 <myname> :D
19:21:49 <Bike> can't CHAR_BIT be 1
19:21:50 <myname> Bike: let me guess "nah, maximum time, what could go wrong"
19:21:51 <callforjudgement> however, could int be 24 bits, 7 of which are padding bits (with unsigned int being 24 bits)
19:21:57 <callforjudgement> Bike: no, has to be at least 8
19:21:59 <Bike> myname: basically
19:22:01 <Bike> callforjudgement: sucks
19:22:12 <kmc> `coins
19:22:14 <HackEgo> bercoin thcoin norfualcoin reviejcoin datecoin cluecoin irkcoin sinrcoin anycoin hypecoin cluhiccoin undercoin l0jdcoin spacecoin develatlinecoin birthcoin dzecoin beakgefcoin leszccoin khalcoin
19:22:50 <kmc> good coins
19:22:54 <callforjudgement> we've had "cluecoin" before
19:22:55 <kmc> also, good morning everyone
19:23:08 <callforjudgement> evening kmc
19:23:15 <Bike> hello hello, we have been discussing weird C for far too long
19:23:20 <kmc> @localtime callforjudgement
19:23:21 <lambdabot> Local time for callforjudgement is Sun Apr 13 20:23:20 2014
19:23:23 <olsner> anycoin sounds like it could be actually useful
19:23:23 <kmc> sorry that I missed it :(
19:23:26 <Bike> weird C is like weird fiction except incredibly dull
19:23:31 <callforjudgement> oh, the conversation's still going on
19:23:32 <zzo38> Now you need a silver coin, gold coin, copper coin, platinum coin, lead coin, iron coin, and radioactive coin.
19:23:43 <olsner> (i.e. cryptocoin compatible with every other cryptocoin)
19:24:01 <fizzie> callforjudgement: Unsigned int can have padding too.
19:24:02 -!- ais523 has quit (Ping timeout: 276 seconds).
19:24:03 <olsner> unicoin would be another nice name for that
19:24:11 <callforjudgement> fizzie: oh right, it's only unsigned char that can't
19:24:23 <fizzie> Unsigned char, and the exact-width integer types from <stdint.h>.
19:24:24 <callforjudgement> because unsigned char has to be able to type-pun correctly
19:24:35 <callforjudgement> fizzie: yeah but they don't have to exist
19:24:40 <Bike> zzo38: 180Tantalumcoin
19:24:41 <fizzie> Right.
19:24:52 <callforjudgement> one nice thing I noted is that C11 reserves uint9_t, uint10_t, etc., as well as the least and fast variants
19:25:01 <zzo38> Now I wrote document of "text adventure intermediate language"
19:25:01 <Bike> 180mTantalumcoin, rather
19:25:04 <myname> olsner: like, i will farm a dogecoin in an hour and sell it for hundreds of dollars as a bitcoin?
19:25:05 <kmc> callforjudgement: heh
19:25:11 <kmc> also POSIX reserves every name ending in _t?
19:25:15 <callforjudgement> kmc: yes
19:25:21 <zzo38> http://sprunge.us/PfHL
19:25:29 <callforjudgement> there are some really broad reservations, though
19:25:34 <olsner> myname: something like that, but the exchange rate could be reasonable (whatever that means)
19:25:36 <callforjudgement> like C reserves everything starting with a capital E
19:25:41 <zzo38> Now I can write a compiler library for its use.
19:25:42 <callforjudgement> if errno.h is included
19:25:49 <myname> olsner: i call that "usd"
19:26:03 <zzo38> Is this good like it is now?
19:26:08 <olsner> myname: that's not a -coin
19:26:08 <callforjudgement> (splint will give warnings about that on high warning levels; that's one of its less buggy warnings)
19:26:14 <myname> usdcoin
19:27:32 <myname> or better, mynamecoin
19:27:49 <myname> im gonna be famous
19:28:25 <fizzie> POSIX also reserves every identifier beginning with "str", "mem" or "wcs" if <string.h> is included, and every identifier beginning with "str" if <stdlib.h> is included.
19:28:48 <fizzie> And everything beginning with "to" or "is" if <ctype.h> is included.
19:28:53 <zzo38> Please tell me if this document is better now, or if you think anything I did wrong.
19:28:57 <olsner> why not just reserve the whole thing
19:29:05 <callforjudgement> then you couldn't write programs
19:29:11 <Jafet> Why not
19:29:22 <myname> i smell a new esolang
19:29:22 <fizzie> Also all identifiers ending in _MIN or _MAX if <limits.h> is included.
19:29:23 <callforjudgement> hmm, actually
19:29:33 -!- ^v has joined.
19:29:36 <callforjudgement> C with no non-reserved identifiers, and all reserved identifiers are used for a legal purpose
19:29:39 <callforjudgement> could be interesting
19:29:39 <kmc> greedy old posix
19:29:55 <callforjudgement> I was wondering about storing data in argv, but sadly it doesn't have a standard name
19:31:44 <fizzie> You can use errno as an arbitrary int, I believe.
19:32:07 <fizzie> "The macros are -- errno which expands to a modifiable lvalue that has type int and thread local storage duration, --"
19:32:11 <callforjudgement> yes, I think that would work
19:32:21 <fizzie> (Though it's just one int.)
19:32:24 <Jafet> It may be legal to overwrite stderr
19:32:25 <callforjudgement> could you create a bunch of extra threads in order to gain more storage?
19:32:31 <Jafet> In which case, you get a pointer
19:33:09 <callforjudgement> admittedly, communicating between them could be a pain
19:33:11 <fizzie> "stderr" and such are not required to be lvalues.
19:33:25 <fizzie> They're just "expressions of type "pointer to FILE" that point to FILE objects".
19:33:44 <fizzie> (They're also macros.)
19:34:28 <fizzie> There's the "file loophole", of course, if you allow for a reasonably consistent file system as seen by fopen/etc.
19:35:23 <fizzie> Though I'm not sure where the FILE * would go for doing more than one operation on an opened file.
19:36:30 <Jafet> Close and open it again
19:36:46 <Jafet> Wait, you can't chain functions.
19:36:46 <fizzie> But you can't close it if you read from it.
19:37:02 <callforjudgement> is fcloseall() standard?
19:37:13 <fizzie> I don't think it is.
19:37:19 -!- callforjudgement has changed nick to ais523.
19:37:32 <fizzie> And anyway it'd be really convenient if you could, say, seek *and* read.
19:37:42 <ais523> "GNU extension"
19:37:56 <Jafet> If we're in posix, there is optarg.
19:39:06 <fizzie> If we're in POSIX, you can use open() and such, and stick the fd in... errno... except it's perhaps not the safest place when calling library functions.
19:39:25 <Jafet> optind and opterr can store fds.
19:39:54 <Jafet> Or you can dup2 it around to a known index.
19:40:16 <fizzie> Hm, there's that.
19:40:34 <ais523> doing this in C11 is more interesting; POSIX sounds like it'd be too easy
19:42:12 <fizzie> I guess you can always freopen("data.file", "w+", stderr); and then just use the stderr handle for storage.
19:43:29 <ais523> stderr's readable, right?
19:43:40 <fizzie> You can freopen it to any mode.
19:43:43 <ais523> I know that reading from stderr's one way to get at the terminal when you have a redirected stdin
19:43:55 <ais523> although a fragile one, there are better methods if on POSIX
19:44:49 <Jafet> Hm, you can store a function pointer and retrieve it using signal.
19:45:12 <Jafet> (Obviously, you can in fact store one per signal.)
19:45:51 <fizzie> That might be handy, though you can of course store one in a file too.
19:46:29 <fizzie> (Just take the address of a compound literal of a pointer-to-function type, and pass to fwrite.)
19:47:06 -!- augur has quit (Ping timeout: 240 seconds).
19:47:15 <fizzie> Though reading it back in any very useful way sounds slightly more tricky.
19:48:15 <fizzie> At least the hello, world program is easy.
19:48:35 -!- augur has joined.
19:48:44 -!- ais523 has quit (Read error: Connection reset by peer).
19:48:54 -!- ais523 has joined.
19:49:47 -!- ^v has quit (Quit: http://i.imgur.com/DrFFzea.png).
19:51:03 -!- heroux has quit (Ping timeout: 250 seconds).
19:51:48 <Jafet> Hmm, you can use asctime for up to 26 bytes of storage.
19:52:19 <kmc> myname: regarding usdcoin, see Xia, P. (2014) Dollarcoin: A cryptocurrency with proof-of-dollar. Presented at ACH SIGBOVIK 2014, Carnegie Mellon University, 1 April (pp. 75-77). http://sigbovik.org/2014/proceedings.pdf
19:52:46 -!- heroux has joined.
19:52:55 <myname> kmc: there is nothing crazy enough for not being done :D
19:52:59 <kmc> correct
19:53:06 <fizzie> Jafet: You can get a pointer, yes, but any call to asctime will overwrite the contents, right?
19:53:16 <Bike> i'm going to imagine this is the xia of "prove newtonian mechanics impossible" fame
19:53:29 <kmc> myname: the proof of work entails writing a hash on a dollar bill, burning it, and posting the video to the block chain
19:53:49 <Bike> #blazeit
19:54:49 <Bike> random question: does anyone know of a paper title better than "Can One Hear The Shape Of A Drum"
19:54:58 <Sgeo> kmc: I'm loving this
19:55:17 <Sgeo> Is all sigbovik humorous? I take it from that chart in the paper that that's the poin
19:55:19 <Sgeo> point
19:56:06 <kmc> Sgeo: yes, although it does publish humorous things that are real and impressive, as well as fake things
19:56:15 <kmc> notably http://www.cs.cmu.edu/~tom7/mario/
19:56:24 <Bike> playfun rox my sox
20:03:26 <zzo38> When looking at Nock on esolang wiki it also links to the Urbit they mention, they use kelvin version numbering, where higher numbers indicate more likely to change and zero means it won't ever change at all.
20:04:12 <Taneb> zzo38, that's clever
20:04:21 <Bike> bitches don't know bout my electron degeneracy pressure
20:05:12 <kmc> nobody's in #oteric.es
20:05:56 <Taneb> I am kind of curious how many people joined and parted that as you said it, kmc
20:06:19 <kmc> lol
20:06:25 <Taneb> (at least 1)
20:06:47 -!- password2 has joined.
20:14:06 -!- adu has quit (Quit: adu).
20:16:06 -!- adu has joined.
20:17:13 -!- ^v has joined.
20:23:52 <zzo38> Now I am writing the C library for dealing with Text Adventure Intermediate Language, and then, maybe also the Haskell library can be written.
20:27:02 -!- nooodl has joined.
20:30:55 -!- stuntaneous has quit (Remote host closed the connection).
20:31:35 <myname> TAIL
20:34:48 <Taneb> zzo38, that sounds interesting
20:35:20 <Taneb> Does Inform (the only text adventure creation thing I know about) use Text Adventure Intermediate Language or does it use something else?
20:36:42 -!- tromp has joined.
20:38:11 -!- ^v has quit (Read error: Connection reset by peer).
20:38:38 -!- ^v has joined.
20:40:53 -!- tromp has quit (Ping timeout: 250 seconds).
20:52:27 -!- AnotherTest has quit (Ping timeout: 276 seconds).
20:52:32 <zzo38> Taneb: It compile into a Z-machine code, with some differences.
20:52:52 <zzo38> Z-machine is OK too, but much more complicated than the one I design.
20:56:41 <zzo38> Inform also compiles into Glulx.
20:56:47 <zzo38> (which is even more complicated)
21:07:45 -!- Slereah_ has quit (Ping timeout: 250 seconds).
21:10:08 -!- nooodl has quit (Quit: Leaving).
21:10:24 -!- nooodl has joined.
21:14:12 -!- adu has quit (Quit: adu).
21:14:22 <zzo38> (Both of them lack some features the other one has.)
21:14:22 -!- ^v has quit (Read error: Connection reset by peer).
21:14:51 -!- ^v has joined.
21:16:14 <HackEgo> [wiki] [[Language list]] http://esolangs.org/w/index.php?diff=39309&oldid=39287 * Zerk * (+11) /* B */ ++Boxy
21:16:45 -!- adu has joined.
21:20:40 -!- nooodl has quit (Quit: Leaving).
21:20:46 <zzo38> I may write some text adventure games using TAIL format and some using Z-machine format.
21:21:06 -!- nooodl has joined.
21:22:10 -!- nooodl has quit (Client Quit).
21:22:42 -!- nooodl has joined.
21:25:46 -!- conehead has joined.
21:28:01 -!- nooodl has quit (Quit: Leaving).
21:28:19 <fizzie> ais523: Jafet: Here's a rudimentary brainfuck interpreter in mostly-correct interpreter-free C, as long as you preprocess it out: http://sprunge.us/QJXJ
21:28:26 -!- nooodl has joined.
21:28:29 -!- nooodl has quit (Remote host closed the connection).
21:28:33 <fizzie> That's the only program it's been tested with, so expect bugs.
21:29:05 <fizzie> Oh, brainfuck without input, that is.
21:29:19 <ais523> fizzie: *identifier-free?
21:29:23 -!- nooodl has joined.
21:29:24 <fizzie> Yes.
21:29:26 <fizzie> Thinko.
21:29:50 -!- copumpkin has quit (Quit: My MacBook Pro has gone to sleep. ZZZzzz…).
21:29:57 <ais523> fizzie: you're storing data in stdin's file pointer? clever
21:30:01 <Guest46968> fizzie: heh, is that meant to be TC?
21:30:14 <fizzie> Yes, the file position is used as a variable safer than errno.
21:30:15 <ais523> err, stderr's
21:30:16 <ais523> Guest46968: it's a BF interp
21:30:19 <ais523> so yes
21:30:28 <Guest46968> ais523: typical C BF interps are not TC...
21:30:53 <fizzie> Well, under the limits imposed by sizeof (int) for the tape.
21:30:54 <kmc> fizzie: nice :D
21:30:57 <Guest46968> oh, identifier-free
21:31:00 <Guest46968> I was wondering what interpreter-free is.
21:31:05 <Guest46968> fizzie: right, you can use fseek to get around that though
21:31:07 <Guest46968> (arguably)
21:31:10 <Guest46968> ftell is allowed to fail
21:31:19 <kmc> that's identifier-free post-pre-processing I suppose
21:31:28 <fizzie> kmc: Yes. Or at least should be.
21:32:01 <fizzie> Guest46968: Right, though I'd need to mungle it even more for that, since I rely on seeking the same file to other places than the tape.
21:32:14 <ais523> fizzie: why is there a sizeof(int) limit? I thought the general argument in favour of C being TC is that file pointers are allowed to be bignums
21:32:27 <ais523> ah right, ftell calls
21:32:52 <fizzie> ais523: It keeps the tape pointer in one of those errno-read "variables", so that it can seek the stderr file between the program source and current tape cell.
21:33:58 <fizzie> Also I'm not entirely sure the initial reading of the brainfuck program is valid, but that could be worked around pretty easily by just embedding the program.
21:34:30 <fizzie> It's at least relying on rewind() to not set errno.
21:35:28 <fizzie> I guess I could just open the stdin file (which is never written to, only its position is used) a bit earlier so I can use V to store the program length over the rewind, actually.
21:35:38 <Guest46968> ais523: ftell can fail
21:36:11 <ais523> Guest46968: I mean that fizzie's program uses ftell
21:36:13 <Guest46968> at least in POSIX (EOVERFLOW)
21:36:20 <ais523> and thus is bounded by off_t limits and so not TC
21:36:35 <Guest46968> but I'm telling you you're wrong
21:36:40 <Guest46968> or, oh
21:36:41 <Guest46968> okay
21:36:44 <Guest46968> I missed the context
21:36:48 <ais523> but a program that didn't ftell could still be TC
21:37:42 <fizzie> http://sprunge.us/iMEW?c I think that's better w.r.t. the initial program loading. I'm probably not going to work around that TC limitation.
21:38:13 <fizzie> Though it could be done very trivially by looking at brainfuck without output, in which case stdout can be dedicated for the tape, and can grow to arbitrary size without ftell issues.
21:38:24 <fizzie> (Brainfuck without output is kind of boring, though.)
21:40:10 <Sgeo> http://paradoxspace.com/
21:40:41 <Sgeo> http://www.paradoxspace.com/fourohfour
21:40:48 <fizzie> I'm still not entirely sure something like fwrite(&errno, 1, 1, stderr); is completely valid, since I guess if library functions are free to set errno whenever they want, fwrite could e.g. zero errno before reading in the bytes.
21:42:59 <olsner> I think most functions only modify errno if there's an error
21:43:05 -!- oerjan has joined.
21:43:28 <^v> :O
21:43:57 <olsner> not sure if they don't have to change it or if they must not change it though
21:44:12 <ais523> I think they have to leave it the same, but maybe can change it during the call
21:44:25 <ais523> that's supposed to be unobservable because errno's thread-local
21:44:34 <ais523> I hadn't thought of passing &errno as a buffer to write before today
21:48:04 <olsner> I suspect you can't take the address of errno, e.g. because it could be a macro that expands to a function call
21:48:47 <oerjan> `addquote <int-e> like good old time, with elbow and foot lengths of the king. <Slereah_> man that must have sucked <Slereah_> People would be always like "Hey king, can you drop by, I have stuff to measure" <Jafet> That's why they're called rulers, you know
21:48:48 <HackEgo> 1184) <int-e> like good old time, with elbow and foot lengths of the king. <Slereah_> man that must have sucked <Slereah_> People would be always like "Hey king, can you drop by, I have stuff to measure" <Jafet> That's why they're called rulers, you know
21:49:00 <ais523> olsner: it's defined as an lvalue, IIRC
21:49:12 <ais523> although I think it can be a macro that expands to a pointer dereference
21:49:46 <Jafet> It is normally a macro that expands to a pointer dereference of a function call.
21:49:59 <olsner> hmm, it would be a bit difficult to set errno if it's an rvalue
21:50:08 <ais523> is &*functioncall() legal?
21:50:08 <Jafet> `run echo $'#include <errno.h>\nerrno' | cpp | tail
21:50:09 <HackEgo> ​# 1 "/usr/include/x86_64-linux-gnu/asm/errno.h" 2 3 4 \ # 5 "/usr/include/linux/errno.h" 2 3 4 \ # 26 "/usr/include/x86_64-linux-gnu/bits/errno.h" 2 3 4 \ # 47 "/usr/include/x86_64-linux-gnu/bits/errno.h" 3 4 \ extern int *__errno_location (void) __attribute__ ((__nothrow__)) __attribute__ ((__const__)); \ # 37 "/usr/include/errno.h" 2 3 4 \ # 5
21:50:35 <ais523> that looks more like head than tail
21:50:40 <Jafet> Every lvalue should have an address.
21:51:22 <Jafet> `run echo $'#include <errno.h>\nint main() { return errno; }\n' | cpp | tail
21:51:22 <HackEgo> ​# 1 "/usr/include/x86_64-linux-gnu/asm/errno.h" 2 3 4 \ # 5 "/usr/include/linux/errno.h" 2 3 4 \ # 26 "/usr/include/x86_64-linux-gnu/bits/errno.h" 2 3 4 \ # 47 "/usr/include/x86_64-linux-gnu/bits/errno.h" 3 4 \ extern int *__errno_location (void) __attribute__ ((__nothrow__)) __attribute__ ((__const__)); \ # 37 "/usr/include/errno.h" 2 3 4 \ # 5
21:51:31 <Jafet> Oh, wait
21:51:35 <Jafet> `run echo $'#include <errno.h>\nint main() { return errno; }\n' | cpp | rev
21:51:35 <HackEgo> ​">nidts<" 1 # \ ">enil-dnammoc<" 1 # \ ">nidts<" 1 # \ 4 3 1 "h.onrre/edulcni/rsu/" 1 # \ 4 3 "h.onrre/edulcni/rsu/" 92 # \ 4 3 1 "h.serutaef/edulcni/rsu/" 1 # \ 4 3 "h.serutaef/edulcni/rsu/" 323 # \ 4 3 1 "h.sfederp/stib/ung-xunil-46_68x/edulcni/rsu/" 1 # \ 4 3 2 "h.serutaef/edulcni/rsu/" 423 # \ 4 3 "h.serutaef/edulcni/rsu/" 653 # \ 4 3 1 "h.s
21:51:42 <Jafet> Nope
21:51:45 <Jafet> `run echo $'#include <errno.h>\nint main() { return errno; }\n' | cpp | tac
21:51:46 <HackEgo> int main() { return (*__errno_location ()); } \ # 2 "<stdin>" 2 \ \ # 59 "/usr/include/errno.h" 3 4 \ # 37 "/usr/include/errno.h" 2 3 4 \ extern int *__errno_location (void) __attribute__ ((__nothrow__)) __attribute__ ((__const__)); \ # 47 "/usr/include/x86_64-linux-gnu/bits/errno.h" 3 4 \ # 26 "/usr/include/x86_64-linux-gnu/bits/errno.h" 2 3 4 \
21:52:25 <olsner> `run echo $'#include <errno.h>\nint main() { return errno; }\n' | cpp | grep main
21:52:26 <HackEgo> int main() { return (*__errno_location ()); }
21:55:52 <myname> side note: i am kinda disappointed that there is a cat replacement called dog but no tac replacement called god
21:56:48 -!- Sprocklem has quit (Quit: leaving).
21:56:59 -!- adu has quit (Quit: adu).
21:58:56 -!- adu has joined.
22:00:22 <zzo38> Can you notify Google of the bug in their server that isn't correctly implementing headerless HTTP?
22:00:39 <zzo38> (There are other bugs in their server too; sometimes a HEAD request returns 404 even though GET works properly.)
22:00:45 <fizzie> It's defined as a "modifiable lvalue" and the possibility of it being *somefunction() is explicitly mentioned.
22:02:57 <zzo38> myname: You are allowed to write such software if you like to make
22:03:36 <myname> zzo38: that doesn't sound like any fun at all
22:03:59 <zzo38> OK then don't write such program, if you don't want to write such program.
22:04:49 <myname> only advantage would be being the founder of god
22:12:09 -!- ais523 has quit.
22:16:41 -!- adu has quit (Quit: adu).
22:17:31 -!- password2 has quit (Ping timeout: 250 seconds).
22:29:34 -!- adu has joined.
22:31:11 -!- not^v has joined.
22:31:51 -!- ^v has quit (Read error: Connection reset by peer).
23:04:37 -!- nucular has quit (Quit: Excess Food).
23:09:40 -!- doesthiswork has quit (Quit: Page closed).
23:21:39 -!- yorick has quit (Remote host closed the connection).
23:41:27 <HackEgo> [wiki] [[Boxy]] http://esolangs.org/w/index.php?diff=39310&oldid=39308 * Zerk * (+248) mostly/* Nock Interpreter */ apparently things are reversible, partially. Which I supposed was implied by "unification".
23:41:53 -!- contrapumpkin has joined.
23:43:34 <zzo38> I started writing this library in C (for Text Adventure Intermediate Language), and then I should probably also write one for Haskell, and one for SQL, as well. If you want any other programming language then write it by yourself please
23:43:46 -!- nooodl has quit (Quit: Leaving).
23:44:04 <zzo38> Maybe you have some idea how it could be represent by Haskell?
23:44:43 <zzo38> Do you have a better idea than I do?
23:45:30 -!- nisstyre has joined.
23:49:24 <Sgeo> I don't know what Text Adventure Intermediate Language is
23:53:31 <zzo38> Sgeo: http://sprunge.us/ULeC
23:54:52 -!- boily has joined.
23:59:13 -!- zzo38 has quit (Remote host closed the connection).
←2014-04-12 2014-04-13 2014-04-14→ ↑2014 ↑all