|
new version of elm is live, with better compiler error messages http://elm-lang.org/blog/compilers-as-assistants:
|
# ? Nov 19, 2015 16:13 |
|
|
# ? May 22, 2024 09:55 |
|
Suspicious Dish posted:Wrote another article about computer. Good stuff. Especially love the interactive animations, which makes me nostalgic for my flash roots.
|
# ? Nov 19, 2015 22:29 |
|
wrong thread
|
# ? Nov 20, 2015 00:16 |
|
want to use libraries like sdl or opengl in go? just use this simple workaround! https://github.com/golang/go/wiki/LockOSThread code:
|
# ? Nov 20, 2015 16:19 |
|
During the weekend I went to the bay area Forth programming group's annual event and I thought I'd post some reflections thereon. Neat things are happening in Forth. I say "neat," not "big." Certainly there will be no comeback, but among the presentations were many fresh ideas and examples of what Forth can do in combination with other techs. I noted two recurring themes during this year's event: - Recognition of JavaScript as a gotta-know-it PL. Even Chuck Moore, the notoriously NIH-minded inventor of Forth, understands this. - Pretty much everyone, including OGs, have embraced GitHub as a community medium. Several presenters had the combination of Forth and JavaScript involved somewhere. One guy presented a Forth->JavaScript compiler and mentioned his work on a JavaScript->Forth one. The former produces essentially bytecode for a JavaScript Forth VM. Stack ripping severely complicates the latter, but he did have a prototype for a restricted class of input programs. Another presented a Forth-based minimalist demoscene that he's set up. I was pretty fascinated by this because I've been reading a lot about digital media theory. The Forth community tends to be predominantly EEs and embedded programmers focused on very practical applications, and it's rare to see a Forther embrace the artistic side of computing to that degree. One of the regular presenters had some Arduinos running Forth. Each one had an attached 8x8 LED grid and a serial line to a laptop running HyperTerm. He left those running all day for people to experiment with. I tried to draw an 8x8 Sierpinski triangle on one. Sadly, since I am not a Forth programmer, I didn't even get as far as plotting a pixel. There was no built-in (1 << n) operation that I could use for masking, and the one I coded myself didn't work. There were multiple presentations on doing things with GreenArrays, Chuck Moore's chip architecture that is like FPGAs, but with tiny clockless CPUs instead of gates. Some grad students who have presented in years past showed their progress with a C compiler for GreenArrays. There was another presentation on programming GreenArrays as a transceiver for magnetic tracking chips. Then Chuck Moore stunned me with the news that he doesn't program close to the metal anymore; he's moving on to iPhone apps and the web. I'm not sure how far he'll get since he has a proud reputation of loathing everything that has been built above the metal during the last 60 years. Guess we'll see. Culture shock A graybeard presented something that was allegedly a combination of Forth and K, the latest language derived from APL. He showed his presentation in some kind of custom text-based environment that I can only describe as ncurses from Mars. I literally could not make head or tail of what he was putting on the screen, and I don't mean just the code parts. Couldn't parse his commentary either. I suppose this would be expected of a seasoned Forth/APL fan. Many graybeards show up at the Forth group meetings. I have to respect them; they're true Silicon Valley OG's who have seen it all. Yet as I mentioned above, there is a substantial generation gap. I overheard one of the OG's saying that he was baffled by the way the grad students used the computer in their presentation. But their presentation was all done in xterms on Linux. Everything they were doing, UI-wise, was being done in the 1980s. Not every Forth OG ends up this way. In 2006 or so I encountered Leo Brodie, who wrote the most popular intro book on Forth, when we both worked at RealNetworks. His skills are current and he communicated just fine with young folks. He had a copy of his book on his shelf, but he didn't give the impression that he swears by it. Moral of the story: Explore the nooks and crannies of technology; learn from them what you can, but don't settle down in them or the world will leave you behind. Gazpacho fucked around with this message at 07:45 on Nov 24, 2015 |
# ? Nov 24, 2015 07:08 |
|
Gazpacho posted:A graybeard presented something that was allegedly a combination of Forth and K, the latest language derived from APL. He showed his presentation in some kind of custom text-based environment that I can only describe as ncurses from Mars. I literally could not make head or tail of what he was putting on the screen, and I don't mean just the code parts. Couldn't parse his commentary either. I suppose this would be expected of a seasoned Forth/APL fan. Any more details (names, urls?) on this? K remains one of my great loves, but suffers from its proprietary nature (as well as from being entirely incomprehensible until you have some practice, which I understand has been carried over).
|
# ? Nov 24, 2015 08:11 |
|
good luck https://www.youtube.com/watch?v=0u2_jKfo0A8&t=10151s http://cosy.com/CoSy/4th.CoSy.html the presentation software he used was his own version of CoSy, some 1980s collab system along the lines of Engelbart's NLS I guess? still mystified and kinda suspect that he might be nuts Gazpacho fucked around with this message at 08:47 on Nov 24, 2015 |
# ? Nov 24, 2015 08:32 |
|
Gazpacho posted:Moral of the story: Explore the nooks and crannies of technology; learn from them what you can, but don't settle down in them or the world will leave you behind. This is why I'm glad left haskell, both the community and the language. I miss is, but I'm doing something different and learning new things in a way that I wouldn't be otherwise gonadic io fucked around with this message at 09:23 on Nov 24, 2015 |
# ? Nov 24, 2015 09:18 |
|
Cybernetic Vermin posted:Any more details (names, urls?) on this? K remains one of my great loves, but suffers from its proprietary nature (as well as from being entirely incomprehensible until you have some practice, which I understand has been carried over). *opens wikipedia* quote:
|
# ? Nov 24, 2015 12:42 |
|
Gazpacho posted:and kinda suspect that he might be nuts probably. doesn't make him wrong or uninformed! dude sounds like the dude, btw.
|
# ? Nov 24, 2015 14:10 |
|
fart simpson posted:*opens wikipedia* enjoy instead this production-level xml parser shipped with the system: http://kx.com/a/k/examples/xml.k
|
# ? Nov 24, 2015 14:51 |
|
nope lol
|
# ? Nov 24, 2015 16:06 |
|
Cybernetic Vermin posted:enjoy instead this production-level xml parser shipped with the system: http://kx.com/a/k/examples/xml.k that file must be corrupt because all i got was a screenful of noise
|
# ? Nov 24, 2015 16:23 |
|
Cybernetic Vermin posted:Any more details (names, urls?) on this? K remains one of my great loves, but suffers from its proprietary nature (as well as from being entirely incomprehensible until you have some practice, which I understand has been carried over). How about a browser-based implementation of K with a set of graphical programming extensions that can be used to make pointless but pretty tech demo things?
|
# ? Nov 24, 2015 17:41 |
|
sup IJ, glad u stopped by
|
# ? Nov 24, 2015 17:44 |
|
You guys were basically launching signal flares with my name on them. It's very interesting to see that the Forth and APL communities seem to have so much overlap. "write only" languages evidently have to stick together. One of these years I'm seriously going to have to make the trip to Forth Day- thanks for the trip report, Gazpacho. edit: Listened to the CoSy talk. It was a bit meandering and rambly but I think it mostly made sense to me. CoSy aims to be a forth-like, low-level language and programming environment which provides direct access to hardware, with the high level expression and data manipulation of APL. APL implies managed memory, so CoSy, like K, uses reference counting. CoSy structures have a uniform header structure which tracks a type (including types for unityped vectors versus heterogenous lists), a size, a refcount and a slot which permits any data structure to be annotated with arbitrary metadata- similar to Lisp plists. Forth typically stores all static data and word definitions in a dictionary. Special words for manipulating this dictionary are part of a typical kernel, and for most purposes it is append-only. CoSy keeps its dictionary in one of its refcounted structures (named R), permitting all the APL-style words to operate on it. Recommended video, a Google Tech Talk about the current state of Dyalog APL: https://youtu.be/PlM9BXfu7UY For the most part the curses ASCII-art visuals are just the way code or comments happen to be formatted for the presentation, and don't have anything to do with the language. It looks like the pipe character (|) is being used to delimit line comments, if that helps. You can see some evidence of a "block oriented" approach to breaking up/storing code in fixed-size "pages", which is a historical artifact of how early forth systems and their built-in text editors worked. The IDE you can see in most of the presentation has a REPL output panel on top and a persistent text editor at the bottom, and the presenter is navigating his notes and occasionally evaluating fragments of them, displayed at the top. Emphasis is placed on CoSy's features for searching, timestamping, and interactively testing code- CoSy is essentially similar to Mathematica's "workbook" concept of blended interactive examples, output and notes, centered around a Forthy environment and permitting dropping into x86 assembly language when desired. Internet Janitor fucked around with this message at 21:20 on Nov 24, 2015 |
# ? Nov 24, 2015 17:55 |
|
Perl 6 looks pretty cool. It's still Perl, but it's unicode handling looks pretty legit, and built in grammars are neat. Also a static type system Plus a bunch of modernization like better functional junk, proper OO, etc.
|
# ? Nov 29, 2015 03:36 |
|
Arcsech posted:Also a static type system a static type system with an insane set of built in types. what do Array, Backtrace, Bool, Int, Map, List, Set, and Str have in common? among other things, they all have an arccotangent method
|
# ? Nov 29, 2015 04:03 |
|
b0lt posted:a static type system with an insane set of built in types. wait why the gently caress does all of this poo poo inherit from Cool? I admit I hadn't looked at it very closely that seems like a very poor decision, most of Cool's methods dont make sense on most of those types for those not familiar: Cool is perl6's name for a type that can be treated as either a string or a number depending on context, and here's the list of types that inherit from it: Array Backtrace Bag Baggy Bool Complex Cool Duration Enumeration Map FatRat Hash Instant Int KeyHash KeySet List Match Nil Num Numeric Range Real Seq Set Stash Str Stringy so all of the above types have an arccotangent and an uppercase method. Arcsech fucked around with this message at 05:59 on Nov 29, 2015 |
# ? Nov 29, 2015 05:57 |
|
actually i suppose it kind of makes sense - all of the stdlib stuff that needs to work with dynamically typed stuff takes Cools to help it work with gradually typed stuff. kinda seems like the solution is to just never ever use Cool in your own code still really fuckin plangy though
|
# ? Nov 29, 2015 06:02 |
|
perl sounds like a loving dumpster fire of a language also lol at how all dynamically typed languages try to crawl toward static typing eventually. dynamic typing is so lovely.
|
# ? Nov 29, 2015 06:08 |
|
Arcsech posted:actually i suppose it kind of makes sense - all of the stdlib stuff that needs to work with dynamically typed stuff takes Cools to help it work with gradually typed stuff. kinda seems like the solution is to just never ever use Cool in your own code i can't believe i didn't see your username although, asech shows up twice consecutively in the table of what methods coerce to what and zero times in the actual list of methods, lol?? they actually seem to be missing a lot of the hyperbolic trig functions. what will i do when i want to compute the hyperbolic cosecant of my backtrace????
|
# ? Nov 29, 2015 06:46 |
|
what is a fatrat
|
# ? Nov 29, 2015 08:16 |
|
whats a baggy
|
# ? Nov 29, 2015 08:17 |
|
FamDav posted:what is a fatrat arbitrary precision rational number
|
# ? Nov 29, 2015 08:22 |
|
gonadic io posted:This is why I'm glad left haskell, both the community and the language. I miss is, but I'm doing something different and learning new things in a way that I wouldn't be otherwise I'm learning it on my free time, any warnings or favorite bits of the language you'd care to share?
|
# ? Nov 29, 2015 10:54 |
|
Ericadia posted:I'm learning it on my free time, any warnings or favorite bits of the language you'd care to share? i love answering questions about it, so just ask if you need anything. yes the syntax using spaces for both function application and pattern matching (although they can never be done in the same place so there's no language ambiguity) takes some getting used to, it'll come in time. 2 most common mistakes for beginners: - 'return' doesn't do what you expect it to coming from OO so code:
- this is the same for all languages, but it bites really hard in haskell: recognise the weaknesses of the default list time which is singly-linked. If you find yourself using (!!), especially in a loop, take a real hard think about whether an array or set (mutable or immutable) would be a better choice. By extension, the default String type (a singly linked list of chars) is really really bad for most string-type operations. The library Data.Text is rich and really fast. Learn you a haskell is the standard first recommended text, then if you want to see some more complicated but better uses once you've finished that i'd recommend parallel and concurrent programming in haskell (both available for free online). if you feel lost, then start writing code in it just to practice. i (and also the haskell subreddit) are very happy to give tips. haskell is one of the more beginner friendly lang's communities i've come across gonadic io fucked around with this message at 16:29 on Nov 29, 2015 |
# ? Nov 29, 2015 14:06 |
|
as for favourite parts, well, statically-verified pattern matching is just the best. it's amazing. i wish absolutely every language had it and the lightweight way to declare unions/records that ADTs (haskell's 'data' keyword) gives you. if you find yourself with a lot of nested data fields (like when programming with rich datastructures like json or a game state or whatever), then it's probably worth learning how to use (although never look at the source) lens or one if it's clones.
|
# ? Nov 29, 2015 14:09 |
|
FamDav posted:what is a fatrat you're going to love the method FatRat.nude
|
# ? Nov 29, 2015 14:28 |
|
the standard defence for Perl 6's asinine design decisions seems to be "Aww, some people just don't like fun!"
|
# ? Nov 29, 2015 14:36 |
|
FamDav posted:what is a fatrat it's u!!!
|
# ? Nov 29, 2015 16:26 |
|
I can't believe the perl6 people stuck to making == converts strings to numbers to compare them
|
# ? Nov 29, 2015 18:05 |
|
http://bitemyapp.com/posts/2014-12-31-functional-education.html how do people feel about these learning-haskell recommendations
|
# ? Nov 29, 2015 18:06 |
|
gonadic io posted:recognise the weaknesses of the default list time which is singly-linked gonadic io posted:as for favourite parts, well, statically-verified pattern matching is just the best. it's amazing. i wish absolutely every language had it and the lightweight way to declare unions/records that ADTs (haskell's 'data' keyword) gives you. I will say that readability has been an issue for me coming from a mostly C++ background. For example, I stared at the quick sort implementation for a long time before I understood exactly what was going on code:
|
# ? Nov 29, 2015 19:11 |
|
idk i used lyah and then just forced myself to start using haskell for projects, asking questions when i got stuck. that worked ok for me
|
# ? Nov 29, 2015 19:11 |
|
if you split that up using 'where' and use 'filter' instead of list comprehensions, it becomes a lot clearer imo this is what i'd write it as (no actually I'd write it as data.list.sort which is a merge sort but let's ignore that for now). also i'd use data.list.partition instead of two separate filters but i'll leave that as an exercise code:
gonadic io fucked around with this message at 19:30 on Nov 29, 2015 |
# ? Nov 29, 2015 19:26 |
|
i think the haskell style guides recommend not using list comprehensions anymore
|
# ? Nov 29, 2015 19:27 |
|
me circa 1999: perl is the best language ever! use it for everything! me now: I will be glad never to touch perl again
|
# ? Nov 29, 2015 19:47 |
|
i too had a perl boner circa '99, i remember hearing about perl 6 then. are they still working on it?? who would use it. sheesh
|
# ? Nov 29, 2015 19:49 |
|
|
# ? May 22, 2024 09:55 |
|
Perl 5 was and remains a massive, massive, wholly welcome improvement on Bash scripting.
|
# ? Nov 29, 2015 19:59 |