←2019-06-20 2019-06-21 2019-06-22→ ↑2019 ↑all
00:04:10 <esowiki> [[User:Salpynx/Sator Resatus]] https://esolangs.org/w/index.php?diff=63589&oldid=63588 * Salpynx * (+1008) The Waterfall Model compilation sketch
00:07:22 <esowiki> [[User:Salpynx/Sator Resatus]] https://esolangs.org/w/index.php?diff=63590&oldid=63589 * Salpynx * (+2) /* The Waterfall Model */ bug fix (there may be more)
00:12:09 -!- sombrero has quit (Ping timeout: 256 seconds).
01:14:05 <esowiki> [[User:Salpynx/Sator Resatus]] https://esolangs.org/w/index.php?diff=63591&oldid=63590 * Salpynx * (+1095) /* Examples */ cellular automata, aspirational for now
01:18:38 -!- Phantom_Hoover has quit (Read error: Connection reset by peer).
01:39:55 -!- salpynx has joined.
03:10:10 -!- xkapastel has quit (Quit: Connection closed for inactivity).
03:10:51 -!- adu has joined.
03:22:12 -!- Sgeo has quit (Read error: Connection reset by peer).
03:22:36 -!- Sgeo has joined.
03:29:23 -!- Frater_EST has joined.
05:18:47 -!- Lord_of_Life has quit (Ping timeout: 245 seconds).
05:20:26 -!- Lord_of_Life has joined.
05:25:12 -!- FreeFull has quit.
05:25:14 -!- adu has quit (Quit: adu).
06:35:52 -!- imode has quit (Ping timeout: 245 seconds).
06:39:51 -!- clog has joined.
06:47:38 -!- uplime has changed nick to major_uplime.
07:19:39 -!- AnotherTest has joined.
07:30:49 -!- atslash has quit (Quit: Leaving).
07:33:35 -!- atslash has joined.
07:39:50 <ski> The answer become "Isosets", a foundational mathematical theory, where not only "sets" can contain several "elements", but "elements" can belong to several "sets".
07:40:00 * ski scratches head
07:47:31 <shachaf> What a bizarre set theory.
07:51:26 <myname> i always thought elements can belong to several sets all along
08:01:49 <shachaf> ski: hi ski
08:02:05 <shachaf> So I was thinking about function arguments.
08:03:11 <shachaf> Instead of currying multi-argument functions, which requires a bunch of complicated features like closures, it seems reasonable to me for a C-level language to have only one-argument functions that take tuples (like in maths).
08:03:15 -!- Bowserinator has quit (Quit: Blame iczero something happened).
08:03:17 -!- moony has quit (Quit: Bye!).
08:04:23 <shachaf> You could also have each function implicitly define a struct for its arguments.
08:04:56 <shachaf> Say [x,y,z] is tuple/struct literal syntax. The equivalent of "int f(char x, bool y)" would be a function taking a struct { char x; bool y; } argument.
08:05:07 <ski> yes
08:05:29 <shachaf> You can have keyword arguments by allowing a struct literal syntax, so you can write [x='a', y=true] or something and it extends to both structs and functions automatically.
08:05:44 <shachaf> You can also support default arguments with default struct value members and so on.
08:06:57 -!- Bowserinator has joined.
08:07:01 <shachaf> Hmm, the language feature I had in mind for making this work isn't quite well-specified, but it's something like flexible/dynamic compile-time values and statically runtime values.
08:07:15 -!- moony has joined.
08:07:54 <shachaf> E.g. some languages support integer literals that are arbitrary-size, but when you use a literal at a particular type, it turns into a value of that type and at that point can't be coerced further.
08:09:10 <shachaf> Similarly I was thinking that [x,y,z] or [x,b=y,c=z] are "compile-time literals" that can be coerced into tuples and structs and so on, but you can't coerce a tuple value into a struct.
08:10:11 <shachaf> This kind of system seems like it'd be pretty nice for making multi-argument and keyword/default argument functions work.
08:10:17 <shachaf> Do you know of anything like it?
08:10:42 <ski> hm, "flexible/dynamic compile-time values and statically runtime values" sounds backwards to how things are usually described, elaborate ?
08:11:04 <ski> can you coerce a record into a tuple ?
08:11:37 <ski> would the default values be part of the type ?
08:11:40 <shachaf> I should have better names for these things.
08:11:59 <shachaf> Yes, I'm imagining default values being part of a type (like struct T { int a = 5; }; in C++11).
08:13:23 <ski> hm, so you can have records with the same fields (of the same types), but different defaults
08:13:36 <shachaf> You could have struct A { int x; }; struct B { int x; };, which are distinct types, and the compiletime value [x=5] could be used as either one.
08:13:44 <shachaf> Sure, they're distinct types.
08:13:49 <ski> does this entail nominal rather than structural matching of record types ?
08:14:01 <shachaf> Just like you can write void f(int x, char y = 'a'); void g(int x, char y = 'b'); in C++.
08:14:05 <ski> (aka heavy-weight vs. light-weight)
08:14:34 <shachaf> I'm not sure what you mean.
08:15:32 <ski> what if you want to pass on a record that one function returns, to another. would both have to refer to the same, named, type, or is it enough that the types structurally match ?
08:16:02 <shachaf> I'm not sure what you mean by "record".
08:16:18 <ski> the same as "struct"
08:16:25 <shachaf> OK, so a specific type.
08:16:54 <shachaf> If you want to write f(g(x)), where g returns a record and f takes a record, they'd have to be the same type.
08:17:15 <shachaf> I guess that's not ideal.
08:18:02 <shachaf> But it might make sense, as long as f can explicitly specify that it takes a tuple or a specific type or something, to allow them to match.
08:18:45 -!- b_jonas has quit (Quit: leaving).
08:18:59 <shachaf> Writing f(g(x)) for multiargument f isn't supported in most languages at all -- I'm not sure how important it is for cases where f and g don't know about each other.
08:19:17 <shachaf> Oh, and you could presumably define an operator that explicitly takes a record into a "compiletime literal".
08:19:51 <shachaf> So it'd turn a value x of type struct A { int a; char b; }; into the record [a=x.a, b=x.b] or [x.a, x.b] or something.
08:20:00 <shachaf> Then you could write f(!g(x)) or something like that.
08:21:17 <shachaf> (I have some other ideas that might use this compiletime-only value in a pretty foundational way. But I'm still not sure how well it would work.)
08:22:31 <ski> hm, so `[x = 5]' is like an initializer, or a compound literal, that can be used to construct a value of some type (in an appropriate context), rather than itself specifying the value itself ?
08:23:29 <shachaf> I think so? I'm not quite sure what you mean.
08:23:45 <ski> (i think you have something like that in Pascal and Ada, where you declare named types which act roughly as `newtype's, and you can initialize variables holding them with ones coming from the representation type. i don't recall the details well enough)
08:23:55 <shachaf> I'm imagining it as a standalone value that can exist at compiletime but can't be assigned to a runtime variable (there's no memory layout for it etc.).
08:24:33 <shachaf> A macro/compiletime function can presumably operate on these things, but not a runtime function.
08:24:38 <ski> i mean that `[x = 5]' itself wouldn't have a well-defined type, but given a context of some tuple or record type, it can be used to construct a value of that type ?
08:24:57 <shachaf> And coercions from these literals to records can be statically checked at the time they're used.
08:25:01 <shachaf> Right.
08:32:04 <ski> (in C, you can't write `{4,"foo"}' as a value, but you can write `struct {int n; char *s} str = {4,"foo"};', and you can write a compound literal `(struct {int n; char *s}){4,"foo"}', even replacing `{4,"foo"}' with `{.n = 4,.s = "foo"}')
08:32:40 <shachaf> Yes.
08:32:45 <ski> (hm, the former being called a "designated initializer", apparenty)
08:33:03 <shachaf> C99's compound literals/designated initializers are quite nice.
08:35:21 <ski> <ski> can you coerce a record into a tuple ?
08:36:14 <shachaf> I think the answer is no, if tuple types exist.
08:36:40 <shachaf> (Tuple is just a special struct with no field names, or field names .0 .1 etc.?)
08:36:47 * ski nods
08:37:18 <ski> so how would this `!' work ?
08:37:57 <shachaf> I'm not sure, I just thought of it.
08:38:44 -!- arseniiv_ has joined.
08:39:46 <ski> fair enough
08:39:57 <shachaf> You can say that it mechanically turns a value of a record type into a literal.
08:40:30 <shachaf> struct { int x; char y; } v; "!v" -> [x=v.x, y=v.y]
08:40:56 <ski> so `[a=x.a, b=x.b]' rather than `[x.a, x.b]' then, i suppose
08:41:00 <ski> aye
08:41:10 <shachaf> If you give an explicit name to the literal->record coercion, say @, then @!v is equal to v. Or something.
08:47:06 * ski nods
09:27:17 <shachaf> ski: But if [a=x, b=y] is a compiletime value, it's a pretty odd one.
09:27:29 <shachaf> Because x and y are runtime values.
09:27:52 <shachaf> Maybe that's not that odd. But it's not what people usually mean by "compile-time values", I think.
09:38:28 <ski> partially static value
09:39:03 <ski> (cf. staged programming, binding time analysis, partial evaluation)
10:40:32 -!- xkapastel has joined.
11:36:57 -!- FreeFull has joined.
12:15:03 -!- arseniiv_ has changed nick to arseniiv.
12:25:13 -!- Frater_EST has quit (Ping timeout: 258 seconds).
13:07:41 <esowiki> [[User:Salpynx/Sator Resatus]] https://esolangs.org/w/index.php?diff=63592&oldid=63591 * Salpynx * (+911) /* Higher dimensions */ tesseract skeleton construction attempt
13:30:05 -!- xkapastel has quit (Quit: Connection closed for inactivity).
13:32:25 <Sgeo> Now that I recognize this conversion math as a rotation, it looks a lot easier to reverse
13:32:59 <Taneb> Which conversion math?
13:33:14 <Sgeo> https://gist.github.com/Sgeo/4c58d69fa4375e4f2f3592e1f9c6eb0e
13:33:56 <Taneb> Ah, neat
13:35:03 <Sgeo> Blah // Perform a rotation about z: Roll. We only need x, so y isn't transformed.
14:11:48 -!- wob_jonas has joined.
14:11:50 <wob_jonas> `olist 1168
14:11:51 <HackEso> olist 1168: shachaf oerjan Sgeo FireFly boily nortti b_jonas
14:11:52 <wob_jonas> that was quick
14:30:11 -!- xkapastel has joined.
14:39:09 -!- salpynx has quit (Ping timeout: 256 seconds).
14:42:58 -!- imode has joined.
14:59:01 -!- wob_jonas has quit (Remote host closed the connection).
15:10:08 <esowiki> [[Talk:Rook]] N https://esolangs.org/w/index.php?oldid=63593 * A * (+366) Please Psecify
15:10:47 <esowiki> [[Rook]] M https://esolangs.org/w/index.php?diff=63594&oldid=63585 * A * (+2) Bad link.
15:11:03 <esowiki> [[Talk:Rook]] M https://esolangs.org/w/index.php?diff=63595&oldid=63593 * A * (+0) Bad link.
15:13:23 <esowiki> [[Iota]] M https://esolangs.org/w/index.php?diff=63596&oldid=53227 * A * (+293)
15:16:40 <esowiki> [[Talk:Rook]] M https://esolangs.org/w/index.php?diff=63597&oldid=63595 * A * (+415) /* Please specify */
15:17:50 <esowiki> [[Talk:Rook]] M https://esolangs.org/w/index.php?diff=63598&oldid=63597 * A * (+20) Bad link again.
16:39:31 -!- b_jonas has joined.
16:49:42 -!- Phantom_Hoover has joined.
17:17:22 -!- Lord_of_Life_ has joined.
17:20:47 -!- Lord_of_Life has quit (Ping timeout: 268 seconds).
17:20:48 -!- Lord_of_Life_ has changed nick to Lord_of_Life.
17:29:46 -!- moei has joined.
18:49:19 -!- Vorpal_ has quit (Ping timeout: 246 seconds).
18:55:27 -!- Vorpal has joined.
19:45:47 -!- adu has joined.
20:08:48 <esowiki> [[Iota]] https://esolangs.org/w/index.php?diff=63599&oldid=63596 * Ais523 * (-293) Undo revision 63596 by [[Special:Contributions/A|A]] ([[User talk:A|talk]]): copyright violation (this content is copied from a CC-by-sa source)
20:10:50 <esowiki> [[Special:Log/delete]] revision * Ais523 * Ais523 changed visibility of a revision on page [[Iota]]: content hidden: Copyright violation
20:44:20 -!- major_uplime has changed nick to uplime.
20:50:05 -!- xkapastel has quit (Quit: Connection closed for inactivity).
20:56:04 <zzo38> Is there the possibility to guess at the proper values of rounded values in a JPEG file in order to try to improve the quality of a JPEG picture without altering the file?
21:33:58 -!- AnotherTest has quit (Ping timeout: 272 seconds).
21:42:47 <b_jonas> zzo38: probably only when the JPGE is of a very bad quality
21:45:10 <zzo38> Maybe you are correct, but still, how might be done?
21:46:44 <fizzie> You could build a model of what uncompressed pictures are like, and then twiddle with the rounding to make the result fit the model better.
21:47:25 <b_jonas> zzo38: look at neighboring blocks, see what doesn't cause an ugly edge between blocks
21:48:19 <b_jonas> zzo38: and when there's a clear boundary of some object, try to make it mostly straight and sharp and at the same location on all three plains
21:49:20 <zzo38> OK, those are ideas to do
21:50:10 <b_jonas> it might be an AI-complete task in general, because after some basic improvements, you have to recognize what the image is trying to depict
21:50:37 -!- xkapastel has joined.
21:51:31 <zzo38> Yes, that is what it might be.
22:56:27 -!- arseniiv_ has joined.
22:59:44 -!- arseniiv has quit (Ping timeout: 248 seconds).
22:59:56 <zzo38> Finally now they are adding into SQLite a SQLITE_DBCONFIG_NO_DQS option, but maybe there should be some way to set the that option at compile time too rather than only at run time.
23:12:03 <shachaf> zzo38: Did you see the idea about function arguments that I wrote here yesterday?
23:12:06 <shachaf> Do you like this?
23:13:39 <zzo38> I did not see it
23:17:32 <shachaf> Ah. Well, tell me if you see it.
23:17:49 <shachaf> I have some other ideas and questions that I didn't mention.
23:32:48 -!- arseniiv_ has quit (Ping timeout: 248 seconds).
23:34:33 <zzo38> OK, I looked at it now.
23:38:22 <zzo38> You can pass structs in C and LLVM (and in LLVM, structs is just tuples anyways), but if interfacing with C codes, they will work differently. (You can deal with this in the declaration perhaps, though, and generate code to convert if needed)
23:42:22 <shachaf> This is kind of a syntax/language semantics thing. The calling convention is ideally about the same.
23:43:59 <zzo38> Still if you use multiple outputs also as a multiple input then conversion must be performed (although it can be done automatically).
←2019-06-20 2019-06-21 2019-06-22→ ↑2019 ↑all