Hacker Newsnew | past | comments | ask | show | jobs | submit | wjbr's commentslogin

I've been reminded of this while playing Metroid Prime 4.

I wonder what kinds of modern games we could make with these same ideas.


static int pretty_float_equal (float a, float b) { return fabsf(a - b) < FLT_EPSILON; }


I've been enjoying `cody` for exploring old open source code bases.

https://docs.sourcegraph.com/cody/overview

I've not used the copilot like features, but asking questions has been very useful.


If the lisp has read macros you can add it yourself.

There's: sweet-expression

https://srfi.schemers.org/srfi-110/srfi-110.html

https://sourceforge.net/p/readable/wiki/Examples/

    define fibfast(n)  ; Typical function notation
      if {n < 2}       ; Indentation, infix {...}
        n              ; Single expr = no new list
        fibup(n 2 1 0) ; Simple function calls

    define fibup(maxnum count n-1 n-2)
      if {maxnum = count}
        {n-1 + n-2}
        fibup maxnum {count + 1} {n-1 + n-2} n-1

    define factorial(n)
      if {n <= 1}
        1
        {n * factorial{n - 1}} ; f{...} => f({...})


How would it work with more than two arguments?

  (+ 1 2 3)


How would you do it?


Well, if you've defined valid representation (and if not, you can by just copying the specs from the Python constructor functions you are calling, whose documentation has the definition they support), match to that before calling the conversion function rather than trapping conversion errors.

Even with the exact same representation, it will speed up the no cases at the expense of slightly slowing down the yes cases (assuming that that is also what the function itself does), but since this is called on tokens with no a-priori reason to expect a match as the normal case, you’ll have more no than yes, so even if it was symmetric speed swap that'd be a win (and I think the existing way you lose more to each exception that you gain avoiding duplicating the check on matches, so it should be a bigger gain that you'd expect if it was symmetric.)


I think Foone has been asking about this for 15+ years at this point.

I'd love to see classic Notepad and MS Paint too.


I think that Notepad and MS Paint were part of the Windows 2000 or NT leaks.

But the most important part of notepad was the editing component, which was a standard win32 component, and wasn’t part of the leak. It’s also unlikely they’ll release it since it’s part of current windows.


The full XP (SP0?) source code leaked and is complete enough that you can almost build and install it as a working OS. It's still missing components (perhaps most importantly, winlogon) but there's a good chance the edit control is in there.

You can find torrents of the source code online and dig around in it if you don't mind breaking the law (or ruining your chances of being allowed to contribute to Wine or ReactOS in the future).


The edit control was part of the leaks. It's in editec.c and a few nearby files. Don't ask me how I know.


Thanks for the correction.


https://developer.android.com/ndk

Android NDK

The Android NDK is a toolset that lets you implement parts of your app in native code, using languages such as C and C++. For certain types of apps, this can help you reuse code libraries written in those languages.


Interesting. I was under the impression that all apps on Android would run inside a Java sandbox, but apparently this is not the case. However, now I'm wondering how safe it is to run apps that might contain native code.


'The Machine to build the Machines' https://www.youtube.com/watch?v=sT6aphdX0rI


Shift-tab works with SuperTab in the console.


Then it should work with YCM in your console as well (whether it works depends on the terminal emulator). A map is a map.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: