Register a SA Forums Account here!
JOINING THE SA FORUMS WILL REMOVE THIS BIG AD, THE ANNOYING UNDERLINED ADS, AND STUPID INTERSTITIAL ADS!!!

You can: log in, read the tech support FAQ, or request your lost password. This dumb message (and those ads) will appear on every screen until you register! Get rid of this crap by registering your own SA Forums Account and joining roughly 150,000 Goons, for the one-time price of $9.95! We charge money because it costs us money per month for bills, and since we don't believe in showing ads to our users, we try to make the money back through forum registrations.
 
  • Locked thread
redleader
Aug 18, 2005

Engage according to operational parameters

Plorkyeran posted:

you can't meaningfully implement a b+ tree in a language that doesn't give you any control over memory layout. you can write all of the algorithms and such, but if the end result doesn't have your leaves in contiguous blocks of memory it's all sort of pointless

i'm sure some fucker can and has done something like this with typed arrays

Adbot
ADBOT LOVES YOU

hackbunny
Jul 22, 2007

I haven't been on SA for years but the person who gave me my previous av as a joke felt guilty for doing so and decided to get me a non-shitty av

eschaton posted:

you totally have control over memory layout

you just write a little stack machine in JS that uses a bunch of giant arrays for its memory, and the target your compiler at the stack machine, not directly at JS

it's disgusting but it works well enough to run dosbox and mame in the browser (!!!)

brap
Aug 23, 2004

Grimey Drawer
typescript is meant to be a superset of JavaScript to enable gradual migration and conversion of existing projects. it's a good language that has a lot of use in the Real World

The MUMPSorceress
Jan 6, 2012


^SHTPSTS

Gary’s Answer

hackbunny posted:

it's disgusting but it works well enough to run dosbox and mame in the browser (!!!)

ive written a compiler that compiles a subset of c to a mips stack machine, so it can't be any more perilous than that. i guess that's another project to go on my pile of poo poo to do when im not completely miserable.

ComradeCosmobot
Dec 4, 2004

USPOL July

eschaton posted:

you totally have control over memory layout

you just write a little stack machine in JS that uses a bunch of giant arrays for its memory, and the target your compiler at the stack machine, not directly at JS

just target asm.js, op

DONT THREAD ON ME
Oct 1, 2002

by Nyc_Tattoo
Floss Finder
every time i read "asm.js" i think "rear end to mouth dot js" to myself for some reason

The MUMPSorceress
Jan 6, 2012


^SHTPSTS

Gary’s Answer
lol, now ive been thinking about this, and i realize that i think the various books and guides on mumps out there are wrong-ish. everything describes the structure of globals and arrays as a b+ tree, but i think it's important to call out that it's really a b+ tree where any leaf can be a pointer to another b+ tree.

afterall, a b+ tree is only an efficient means to represent a data structure like:
code:
var willBeABTree = ["hi"=5,"ho"=6,"there"="neighbor"]
which in mumps syntax is like:
code:
new arrayVar
s arrayVar("hi")=5,arrayVar("ho")=6,arrayVar("there")="neighbor"
but in mumps any of those keys (subscripts in mumps parlance) could itself have an array underneath it (which itself could contain more arrays):

code:
var willBeABTree = ["hi"=5,"ho"=6,"there"=["neighbor"="tim","grunt"="ayooooot"]]
which in mumps syntax is like:
code:
new arrayVar
s arrayVar("hi")=5,arrayVar("ho")=6,arrayVar("there","neigbhor)="tim",arrayVar("there","grunt")="ayooooot"
so mumps arrays/globals are essentially a terse syntax for indexing and nesting b+-trees plus intrinsic functions for traversing arbitrarily nested b+-trees efficiently

i suppose the other way it could be implemented underneath would be to treat the entire comma-delimited series of keys as a single composite key (and this might explain cache's limitation of 511 characters for a global reference; e.g. the global name+total length of keys and commas must be less than 511 characters), but that seems like a loving stupid way to do it since you're generally looping over children of a single key at any given time so you'd want to be able to have each key be a leaf that then points to a b+ tree that is the index of its children.

the cache documentation claims that it never has to rebuild an index no matter how many inserts and deletes you make to the global and there is no performance hit from that, but i assume that they are relying on some semantic playing of index not referring to the internal nodes of the tree, which are, inherently, merely indices of their children. that or they're just copying and chucking a node any time they insert into it or something and they just never propagate splits up the tree or something, but again that seems like it would degrade over time.

i guess this is why im not a systems engineer yet :(

eschaton
Mar 7, 2007

Don't you just hate when you wind up in a store with people who are in a socioeconomic class that is pretty obviously about two levels lower than your own?

LeftistMuslimObama posted:

i guess this is why im not a systems engineer yet :(

which seems more likely, that a terrible implementation of an archaic-when-designed language like MUMPS might not always make the best choices, or that you might actually be reasonably qualified to do something

I know which I'd bet on (hint she's LMO)

leper khan
Dec 28, 2010
Honest to god thinks Half Life 2 is a bad game. But at least he likes Monster Hunter.

eschaton posted:

which seems more likely, that a terrible implementation of an archaic-when-designed language like MUMPS might not always make the best choices, or that you might actually be reasonably qualified to do something

I know which I'd bet on (hint she's LMO)

how are these mutually exclusive?

The MUMPSorceress
Jan 6, 2012


^SHTPSTS

Gary’s Answer

leper khan posted:

how are these mutually exclusive?

eschaton is negging me in the vain hope that im not gay

The MUMPSorceress
Jan 6, 2012


^SHTPSTS

Gary’s Answer
antlr looks so much better than jcup. gonna be messy figuring out how to deal with the weird syntax of for loops in mumps though. the $o for loop is actually 3 separate statements executing together. i guess treating it as a do-while loop with the $o call hoisted into the beginning of the loop and the quit conditions treated as conditional breaks? the scoping would be 100% the same, but i can't think of a case where it would actually change a program's behavior.

hmmmmmmmm

Bloody
Mar 3, 2013

roll yer own parser

Luigi Thirty
Apr 30, 2006

Emergency confection port.

I'm currently wrapping a bunch of Amiga UI crap in a homemade C++ library for some reason, probably :spergin:

The MUMPSorceress
Jan 6, 2012


^SHTPSTS

Gary’s Answer

Bloody posted:

roll yer own parser

gently caress that dude. there's like 0 reason to write a worse parser than the 15 existing open-source parsers written by smart autists with singleminded focus

Shaman Linavi
Apr 3, 2012

LeftistMuslimObama posted:

gently caress that dude. there's like 0 reason to write a worse parser software than the 15 existing open-source parsers softwares written by smart autists with singleminded focus

eschaton
Mar 7, 2007

Don't you just hate when you wind up in a store with people who are in a socioeconomic class that is pretty obviously about two levels lower than your own?

Luigi Thirty posted:

I'm currently wrapping a bunch of Amiga UI crap in a homemade C++ library for some reason, probably :spergin:

why not use E? er, Amiga E?

its author has this to say about it:

wouter posted:

I wrote the entire thing in assembly language, which will always persist in my mind as the craziest software engineering exercise I have ever gone through (400kb of mostly uncommented assembly in a single source file, for a complex compiler).

eschaton fucked around with this message at 06:31 on Nov 15, 2016

jony neuemonic
Nov 13, 2009

LeftistMuslimObama posted:

learning typescript now. its better, but i have to say that it seems odd to me that theyd write a language specifically to take away the weirdness of js but then still hold onto stuff like the weird usage of colons in function signatures and poo poo like that. if youre going to make a good language that transpiles to js, why only take me half way in the name of preserving aesthetic similarity to js?

imo typescript syntax has some advantages over c#, especially the type declarations. "foo: string" beats "string foo" any day and the latter only exists to not scare the java programmers.

leper khan
Dec 28, 2010
Honest to god thinks Half Life 2 is a bad game. But at least he likes Monster Hunter.

jony neuemonic posted:

imo typescript syntax has some advantages over c#, especially the type declarations. "foo: string" beats "string foo" any day and the latter only exists to not scare the java programmers.

var foo

redleader
Aug 18, 2005

Engage according to operational parameters

jony neuemonic posted:

imo typescript syntax has some advantages over c#, especially the type declarations. "foo: string" beats "string foo" any day and the latter only exists to not scare the java programmers.

but what about tabs/spaces?!?

Luigi Thirty
Apr 30, 2006

Emergency confection port.

eschaton posted:

why not use E? er, Amiga E?

its author has this to say about it:

uhhhhhhhh well at least I'm not that insane

I'm using SAS/C which is a descendant of Lattice C and the most popular compiler for classic Amiga. it's apparently still sold for IBM mainframes and nothing else. I'm sure if I poke around aminet I can find someone who did this 20 years ago

other options include vbcc or GCC 2.x

Sweevo
Nov 8, 2007

i sometimes throw cables away

i mean straight into the bin without spending 10+ years in the box of might-come-in-handy-someday first

im a fucking monster

eschaton posted:

why not use E? er, Amiga E?

its author has this to say about it:

i wrote a few small things in E about 20 years ago. from what i remember its basically just pascal, but with more C-like syntax and a thin wrapper over some of the basic OS functions

HappyHippo
Nov 19, 2003
Do you have an Air Miles Card?

LeftistMuslimObama posted:

learning typescript now. its better, but i have to say that it seems odd to me that theyd write a language specifically to take away the weirdness of js but then still hold onto stuff like the weird usage of colons in function signatures and poo poo like that. if youre going to make a good language that transpiles to js, why only take me half way in the name of preserving aesthetic similarity to js?

the syntax was never the problem with js.

HappyHippo
Nov 19, 2003
Do you have an Air Miles Card?
except automatic semicolons

Flat Daddy
Dec 3, 2014

by Nyc_Tattoo
typescript is legit. i love that you can make non-nullable default and vs code will give me red squigglies if i do something bad.

the only bad thing about TS is it's compile-time only and provides no runtime features at all. like you can't have an interface with const strings like you can in java, and they refuse to implement an elvis operator because JS doesn't have one.


so i and a coworker are basically in limbo due to mgmt changes - we will take over an outsourced app in a couple weeks and currently have like 0-1 hr of work a day until then, so we're just rewriting the outsourced app piecemeal so we can just throw it the gently caress out (theres still worse stuff ive found in addition to what i posted about already)

we're rewriting in react, redux, and typescript and its amazing. theres a loss of type information between a couple of the pieces but besides that it's a really great environment

Flat Daddy
Dec 3, 2014

by Nyc_Tattoo
between typescript+vscode, tslint, react storybook, and redux time travel debugging and state transition logs, theres so many safety nets and so muchconstant feedback that i almost forget im writing jabascript

go play outside Skyler
Nov 7, 2005


fleshweasel posted:

typescript is meant to be a superset of JavaScript to enable gradual migration and conversion of existing projects. it's a good language that has a lot of use in the Real World

what happens when microsoft looses interest in the project?

go play outside Skyler
Nov 7, 2005


is it going to die a slow painful death like haxe?

Flat Daddy
Dec 3, 2014

by Nyc_Tattoo
then you delete the type annotations from your ts and rename to js

HoboMan
Nov 4, 2010

SQL code:
SELECT
/*a bunch of garbage*/
FROM v
	RIGHT JOIN jsu
	LEFT JOIN vr ON jsu.VID = vr.VID
	RIGHT JOIN ph
	INNER JOIN jsp
	INNER JOIN j ON jsp.JID = j.JID ON ph.PID = jsp.PID INNER JOIN js ON jsp.JSID = js.JSID ON jsu.JID = jsp.JID
		AND jsu.VGroup = jsp.VGroup
		AND jsu.PPID = jsp.PID ON v.VID = jsu.VID
WHERE js.JID = @JID
this is hurting my brain

hackbunny
Jul 22, 2007

I haven't been on SA for years but the person who gave me my previous av as a joke felt guilty for doing so and decided to get me a non-shitty av

go play outside Skyler posted:

is it going to die a slow painful death like haxe?

haxe is dead? good. their just deserts for choosing to write the compiler in ocaml to make it as little accessible as possible

Shaggar
Apr 26, 2006
AllScripts dudes in the office 2day training on their API. its soap but theres a single method where u specify the name of an action and then a list of optional parameters based on the action. amazing.

HoboMan
Nov 4, 2010

when you want to make a rest api but your boss insists you use soap


e: wait, doesn't that setup come out to be literally the worst of both worlds?

HoboMan fucked around with this message at 17:32 on Nov 15, 2016

Luigi Thirty
Apr 30, 2006

Emergency confection port.

http://aminet.net/package/dev/gcc/ADE

I have no idea how old GCC 2.95 is but there it is

Chalks
Sep 30, 2009

HoboMan posted:

when you want to make a rest api but your boss insists you use soap


e: wait, doesn't that setup come out to be literally the worst of both worlds?

Indeed. Unless you love soap envelopes, I guess.

Finster Dexter
Oct 20, 2014

Beyond is Finster's mad vision of Earth transformed.

HoboMan posted:

SQL code:
SELECT
/*a bunch of garbage*/
FROM v
	RIGHT JOIN jsu
	LEFT JOIN vr ON jsu.VID = vr.VID
	RIGHT JOIN ph
	INNER JOIN jsp
	INNER JOIN j ON jsp.JID = j.JID ON ph.PID = jsp.PID INNER JOIN js ON jsp.JSID = js.JSID ON jsu.JID = jsp.JID
		AND jsu.VGroup = jsp.VGroup
		AND jsu.PPID = jsp.PID ON v.VID = jsu.VID
WHERE js.JID = @JID
this is hurting my brain

wtf now my brain hurts

Luigi Thirty
Apr 30, 2006

Emergency confection port.

I think this is what I was looking for

quote:

This is the NEW version 1.10 by Aug, 30, 1994 of A++ Library.

A++ is not only a wrapper library but recollects system functions to powerful
objects that support programming the Amiga (i.e. automatically re-sizable gadgets, object attribute constraints, ...).

This archive contains the FULL SOURCE and support for compiling it with
SAS/C++ AND GNU/C++.

Looks like an object-oriented version of the Amiga libraries, woohoo

eschaton
Mar 7, 2007

Don't you just hate when you wind up in a store with people who are in a socioeconomic class that is pretty obviously about two levels lower than your own?

Luigi Thirty posted:

I think this is what I was looking for


Looks like an object-oriented version of the Amiga libraries, woohoo

what about boopsi or whatever it is?

Luigi Thirty
Apr 30, 2006

Emergency confection port.

that's for intuition, this is wrappers for the other libraries

JawnV6
Jul 4, 2004

So hot ...
wrappers is shims with libs inside

Adbot
ADBOT LOVES YOU

eschaton
Mar 7, 2007

Don't you just hate when you wind up in a store with people who are in a socioeconomic class that is pretty obviously about two levels lower than your own?

JawnV6 posted:

wrappers is shims with libs inside

  • Locked thread