Jane Street
Jane Street
  • Видео 121
  • Просмотров 1 622 876
Get to Know Us: Rory Talks Production Engineering at Jane Street
Get to Know Us | Meet Rory who is based in Jane Street's New York office. He works on the Production Engineering team and has been full-time since 2020.
The people featured in these videos were excited to share what makes Jane Street a rewarding place to work. Whether in Trading & Research, HR & Recruiting, or Cybersecurity, everyone plays a key part in fostering our open and collaborative working culture.
While it’s hard to capture all the nuance of our firm in a series of short videos, we hope that they give you a real sense of who we are and what we do.
Просмотров: 358

Видео

How to Play Figgie | Jane Street Card Game Tutorial
Просмотров 1 тыс.21 час назад
Figgie is a card game that was invented at Jane Street in 2013. It was designed to simulate open-outcry commodities trading. Most of the skill in Figgie is in negotiating trades that benefit both the buyer and seller. Like in poker, your objective in Figgie is to make money over a series of rounds. Discover more on figgie.com!
Get to Know Us: Matt Talks Machine Learning at Jane Street
Просмотров 1 тыс.14 дней назад
Get to Know Us | Meet Matt who is based in Jane Street's Hong Kong office. He works on the Trading team and has been full-time since 2012. The people featured in these videos were excited to share what makes Jane Street a rewarding place to work. Whether in Trading & Research, HR & Recruiting, or Cybersecurity, everyone plays a key part in fostering our open and collaborative working culture. W...
Get to Know Us: JP Talks Machine Learning at Jane Street
Просмотров 90414 дней назад
Get to Know Us | Meet JP who is based in Jane Street's Hong Kong office. He works on the Trading team and has been full-time since 2017. The people featured in these videos were excited to share what makes Jane Street a rewarding place to work. Whether in Trading & Research, HR & Recruiting, or Cybersecurity, everyone plays a key part in fostering our open and collaborative working culture. Whi...
From the Lab to the Trading Floor: Designing for Expert Users with Erin Murphy
Просмотров 1,3 тыс.14 дней назад
Erin Murphy is a UX designer at Jane Street, and before that, she worked at NASA’s Jet Propulsion Laboratory building user interfaces for space missions. She’s also an illustrator with her own quarterly journal. In this episode, Erin and Ron discuss the challenge of doing user-centered design in an organization where experts are used to building tools for themselves. How do you bring a command-...
Programming with OCaml's Local Mode | OCaml Unboxed
Просмотров 1,1 тыс.Месяц назад
This OCaml Unboxed episode demonstrates some of the twists and turns you might encounter while programming with locals and introduces the *global modality*. Watching this video might help you learn what to look for when programming with locals! View instructions to get the compiler I use in this video: github.com/janestreet/opam-repository/tree/with-extensions Full documentation of locals: gith...
Regions with OCaml's Local Types | OCaml Unboxed
Просмотров 855Месяц назад
This OCaml Unboxed episode describes regions and the hidden regional mode in OCaml's local types, as developed by Jane Street. It turns out that local parameters aren't really local: they're regional! This explains how some impossible-looking programs actually work. View instructions to get the compiler I use in this video: github.com/janestreet/opam-repository/tree/with-extensions Full documen...
Get to Know Us: Declan Talks Research at Jane Street
Просмотров 1,4 тыс.Месяц назад
Get to Know Us | Meet Declan who is based in Jane Street's London office. He works on the Research team and has been full time since 2021. The people featured in these videos were excited to share what makes Jane Street a rewarding place to work. Whether in Trading & Research, HR & Recruiting, or Cybersecurity, everyone plays a key part in fostering our open and collaborative working culture. W...
Get to Know Us: Alok from Research at Jane Street
Просмотров 2,1 тыс.2 месяца назад
Get to Know Us | Meet Alok who is based in Jane Street's New York office. He works on the Research team and has been full time since 2020. The people featured in these videos were excited to share what makes Jane Street a rewarding place to work. Whether in Trading & Research, HR & Recruiting, or Cybersecurity, everyone plays a key part in fostering our open and collaborative working culture. W...
Exploring the Hidden Secrets within OCaml’s Local Function Types | OCaml Unboxed
Просмотров 9952 месяца назад
This OCaml Unboxed episode demonstrates how partial application and currying can cause trouble when mixed with locals. It turns out that putting "local_" in your function type may do more than you bargained for! Code used in this video: github.com/goldfirere/janestreet-videos/blob/main/locals/08-function-types/local.ml View instructions to get the compiler I use in this video: github.com/janest...
Pitfalls with Tail Calls and Locals in OCaml | OCaml Unboxed
Просмотров 1,5 тыс.2 месяца назад
This is the seventh in a series about locals in OCaml. This episode explains the challenges around tail-call optimization and how to keep local variables from escaping their region. I introduce the [@nontail] annotation to prevent tail-call optimization, which is often needed when writing code with locals. Code used in this video: github.com/goldfirere/janestreet-videos/blob/main/locals/07-tail...
OCaml Unboxed: An Exploration of Jane Street's Experiments with OCaml
Просмотров 3,9 тыс.4 месяца назад
This video introduces the OCaml Unboxed series, which will dive into topics like local mode, unboxed types, and many more fun detours along the way. Join me, Richard Eisenberg, as we explore the frontiers of functional programming language design in OCaml! Oxidizing OCaml blog posts: - Locality: blog.janestreet.com/oxidizing-ocaml-locality - Ownership: blog.janestreet.com/oxidizing-ocaml-owners...
Stack Allocation with Locals in OCaml | OCaml Unboxed
Просмотров 1,5 тыс.5 месяцев назад
This is the sixth installment in the video series explaining OCaml's locals. In this episode, I demonstrate how stack allocation works with locals. (And yes, even though locals use stack allocation, I guarantee this is not the stack you’re thinking of!) Code used in this video: github.com/goldfirere/janestreet-videos/blob/main/locals/05-programming-with-locals/local.ml
OCaml Locals Save Allocations | OCaml Unboxed
Просмотров 1,9 тыс.5 месяцев назад
This is the fifth video in a series about OCaml’s locals. This episode demonstrates how using locals reduces garbage-collected allocations. Watch as I demonstrate how to use locals, fending off plenty of error messages along the way. View instructions to get the compiler I use in this video: github.com/janestreet/opam-repository/tree/with-extensions Code used in this video: github.com/goldfirer...
Inferring Locality in OCaml | OCaml Unboxed
Просмотров 1,3 тыс.5 месяцев назад
This is the fourth video in a series about OCaml’s locals. It covers how the compiler infers what variables can be marked as local_ and it gives a glimpse into some compiler output that you can use to see the inferred modes on variables. I also explain how the compiler infers conversions between locals and globals and introduce *mode-crossing*, showing how ints can be both local and global. Vie...
Understanding OCaml Locals as a Mode (with Sub-Moding) | OCaml Unboxed
Просмотров 1,3 тыс.6 месяцев назад
Understanding OCaml Locals as a Mode (with Sub-Moding) | OCaml Unboxed
Annotating OCaml Variables and Returns with local_ | OCaml Unboxed
Просмотров 1,7 тыс.6 месяцев назад
Annotating OCaml Variables and Returns with local_ | OCaml Unboxed
Introducing the OCaml Local Mode | OCaml Unboxed
Просмотров 5 тыс.6 месяцев назад
Introducing the OCaml Local Mode | OCaml Unboxed
Performance Engineering on Hard Mode with Andrew Hunter
Просмотров 3,3 тыс.8 месяцев назад
Performance Engineering on Hard Mode with Andrew Hunter
A Poet's Guide to Product Management with Peter Bogart-Johnson
Просмотров 3,3 тыс.11 месяцев назад
A Poet's Guide to Product Management with Peter Bogart-Johnson
Get to Know Us: Sean Talks Hospitality at Jane Street
Просмотров 2,8 тыс.Год назад
Get to Know Us: Sean Talks Hospitality at Jane Street
Get to Know Us: Dan Talks Trading Desk Operations at Jane Street
Просмотров 3,8 тыс.Год назад
Get to Know Us: Dan Talks Trading Desk Operations at Jane Street
Get to Know Us: Simone Talks Hospitality at Jane Street
Просмотров 894Год назад
Get to Know Us: Simone Talks Hospitality at Jane Street
Get to Know Us: Varun Talks Software Engineering at Jane Street
Просмотров 13 тыс.Год назад
Get to Know Us: Varun Talks Software Engineering at Jane Street
Get to Know Us: Jason Talks Operations at Jane Street
Просмотров 2,1 тыс.Год назад
Get to Know Us: Jason Talks Operations at Jane Street
Get to Know Us: Jorge Talks Hospitality at Jane Street
Просмотров 887Год назад
Get to Know Us: Jorge Talks Hospitality at Jane Street
Get to Know Us: Nitya Talks Trading at Jane Street
Просмотров 10 тыс.Год назад
Get to Know Us: Nitya Talks Trading at Jane Street
FAQ: Applying and Interviewing at Jane Street
Просмотров 7 тыс.Год назад
FAQ: Applying and Interviewing at Jane Street
Get to Know Us: Nicole Talks Trading at Jane Street
Просмотров 6 тыс.Год назад
Get to Know Us: Nicole Talks Trading at Jane Street
Get to Know Us: Ian Talks Software Engineering at Jane Street
Просмотров 7 тыс.Год назад
Get to Know Us: Ian Talks Software Engineering at Jane Street

Комментарии

  • @moazzammoriani1656
    @moazzammoriani1656 11 дней назад

    Thank you for this series! I'm curious about the speedup and performance gains that modal types offer. Are there any benchmarks currently available?

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 11 дней назад

      I don't have benchmarks to report. Part of the problem with benchmarks is that it's hard to make any that are not misleading. That is, I bet I could get an arbitrary percentage speedup by switching to locals, if I have the freedom to write my own program, so writing my own program is not a good way to address this. I could use existing programs, but because using locals well requires some annotations, those programs would have to be edited. How much should we edit? Now that locals exist, we might be able to make large restructuring to a program that will make it clearer without losing performance.... but how does the benchmark take that into account? I'm not trying to say that these problems don't have solutions, just that "measure the perf improvement" is never quite as easy as it sounds. Incidentally, the biggest place within Jane Street that makes use of locals isn't around performance improvement, but is instead around code improvement. That is, there are some applications with performance requirements. Previous to locals, those applications used other techniques to meet their needs. Now with locals, programs can be written more idiomatically (making them easier to maintain), all without losing performance. So the biggest win -- maintainability -- is even harder to measure.

  • @bjzaba
    @bjzaba 14 дней назад

    Great series, thank you, this feature is very exciting! It would be nice to get some clarification on what modes are compared to modalities (this came up in passing when talking about the global field). I was thinking this whole video series that "modes" were a Jane Street-ism for "modality". I had felt it was a little bit unfortunate, as there is already a notion of "mode" in logic programming which is in relation to how the parameters of a predicate can be instantiated. If you're familiar with bidirectional typing, this is the same as how you can mark parts of the typing judgements as inputs or outputs - I even think some authors refer to these as modes as well.

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 14 дней назад

      Yes, there are lots of different uses of the terminology out there. I don't particularly defend our choices, but instead I acknowledge that I think any choice of term would have thrown off some potential learners. As for modality vs mode: We use modality to mean a function from mode to mode. Suppose we have a record r at mode m whose type has a field x with a modality f. Then an access of r.x is at mode f(m). The `global` modality is the constant function that always returns `global`. But we have imagined other modalities that actually depend on their argument.

    • @bjzaba
      @bjzaba 13 дней назад

      @@RichardEisenberg-JS Cool, thanks for the explanation! Yeah figuring out terminology for new things is definitely hard, and I don’t envy the compromises you have to make. There's always going to be people confused or frustrated and it's hard to predict that in the future - it could be fine, or it could be grumbled about for years, and there's only so many words to choose. Anyway, thanks again for your work and your efforts in explaining this stuff, it's greatly appreciated!

  • @huge_letters
    @huge_letters Месяц назад

    thanks for the series :) still hard to wrap my head around most of the concepts, probably will once I get to actually use this but was very interesting to watch

    • @12332a
      @12332a Месяц назад

      Heyy can u plzz tell me that a B.E Cse graduate can apply in jane street or not..

  • @edwardc.2135
    @edwardc.2135 Месяц назад

    "What have i done wrong"-Everyone have been to this on any language

  • @alurma
    @alurma 2 месяца назад

    Interesting.

  • @didyoustealmyfood8729
    @didyoustealmyfood8729 2 месяца назад

    Nah bruh too much yapping where the good docs at

    • @zyptoskid
      @zyptoskid Месяц назад

      hey now that's rude. respect your programming elders especially when they volunteer their time to show you stuff that entitled behavior is no good

  • @mndrix
    @mndrix 2 месяца назад

    It seems like a lot of type annotations. I wonder if the escape analysis could be done beneath the covers so it doesn't surface through the types. I recall Go's escape analysis being pretty good without guidance like this. I'm probably missing something.

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 2 месяца назад

      Most of the annotations here aren't necessary. They're there to make everything more explicit for the video. The `exclave_`s are necessary, but nothing else. Marking lcoals in mli files is necessary though, to enable separate compilation.

  • @edwardc.2135
    @edwardc.2135 3 месяца назад

    Interesting, but i couldn't understand how that changes the fact that computer memory break when you attempt to read and write the same variable at the same time.🤔🤔

  • @anshuman1987
    @anshuman1987 4 месяца назад

    I am currently 15 yo already started my basics in Ocaml , already have knowledge in fintech,risk analysis and will do much more...In 2028 u all will be interviewing me and i will be joyous to work st Jane Street my dream company❤️ I am Coming Soon , See you

    • @theCornellJerald
      @theCornellJerald 4 месяца назад

      check out cornell's cs 3110 with professor clarkson! i am taking that now lmk if u have any questions.

    • @bhavyajoshi7620
      @bhavyajoshi7620 3 месяца назад

      In which year are you going to give JEE Advanced exam?

  • @cryptodone3906
    @cryptodone3906 4 месяца назад

    ocaml is functional, so will be relatively easier to write elegant code and do the compiler do optimization specific to JaneS needs. at the end the machine code generated on the CPU that matters.

    • @cryptodone3906
      @cryptodone3906 4 месяца назад

      i hoope microsoft do the serious works with F# on CLR, it's ocmal inspired language basically.

    • @cryptodone3906
      @cryptodone3906 4 месяца назад

      the lesser the language can do in term of syntax (concise/suctinct), the more optimization can be done. as it's narrow down the possiblity of developer `creatitivy` that sometimes abuse the language features

  • @thomasmeslin8399
    @thomasmeslin8399 4 месяца назад

    Interesting

  • @groovediggr8777
    @groovediggr8777 4 месяца назад

    Looking forward to the series

  • @Winium
    @Winium 4 месяца назад

    "Performance is really predictable" Haskell folks shaking rn. Does branchless programming help (against branch mispredict inconsistency)?

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 4 месяца назад

      Branchless programming definitely helps! But of course isn't always possible.

  • @MirceaPricop
    @MirceaPricop 5 месяцев назад

    It's very interesting that this also makes lists allocate closely together in memory space, thus potentially leading to much better cache locality in addition to saving garbage collection costs.

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 5 месяцев назад

      Yes that's a good point! I wish I had made that point in the video. :)

  • @sami9323
    @sami9323 5 месяцев назад

    Wonderful video with great explanations and code. Love the work going on at Jane Street with OCaml!

  • @MirceaPricop
    @MirceaPricop 5 месяцев назад

    Why do the contents of a local_ list have to also be local_? I feel like that was glanced over but it's not obvious to me. What would be the problem if the argument to iter leaks a reference to a list element? We can still clean up the list itself at the end of the region, right?

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 5 месяцев назад

      Spot on, yes. In general, we have a free choice here: we could say (A) that the contents of a local list are local or (B) the contents of a local list are global. (A) means that we can store local things in a list but we can't let the contents of a local list escape; (B) means that we can let the contents of a local list escape, but we can't store local things in a list. We can't have both. But we can, actually, via a thing called the global modality. We'll get there in a few videos. In brief, it allows you to label a field of a structure as acting like (B). So you get an (A)-list (the normal list type) and a (B)-list (something you'd have to write yourself). These would be different types. This is a bit annoying, for sure, but having one type that can both store local things and then let them escape is definitely worse!

  • @adicide9070
    @adicide9070 5 месяцев назад

    Do you know if this stuff will be part of the language?

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 5 месяцев назад

      I know we will work with the OCaml community maintainers to get this to be a part of the language -- but not for a while. Our approach is to experiment locally (ha ha) here at Jane Street, gain experience about what's good and what's bad, and then to work to upstream when we have more confidence. In the end, language design is hard to get right, and we want to take advantage of the fact that we can somewhat easily undo mistakes before this is all part of the official language.

    • @adicide9070
      @adicide9070 5 месяцев назад

      @@RichardEisenberg-JS aaah the puun! :D nice to watch though. not sure if OCaml can get more popular and widely adopted at this point but ML is the bomb, so here's hoping something ML does!

  • @a_external_ways.fully_arrays
    @a_external_ways.fully_arrays 5 месяцев назад

    Hmm, so this was just to solve for simple functions like iter and init, where even here, I find the process too complex by itself - imagine doing this for complex functions, and depending on libraries that doesn't support locals. Also, my guess is that this will make people copy other libraries code to their own codebase, to add locals support - so it breaks the modularity of libraries

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 5 месяцев назад

      Decent points, indeed. (Though these functions have the complexity that hits locals -- bigger functions aren't necessarily harder in this respect.) We're currently working our way through `base` (our open-source standard library), adding local annotations throughout. It's not particularly easy! And yet the benefits we're seeing seem worth the cost. A big question we're thinking about is how this will all shake out in the end, which is one of the reasons we want to develop this on a branch of the compiler instead of pushing early for inclusion in general OCaml.

  • @alicaglayanrulzok
    @alicaglayanrulzok 5 месяцев назад

    So is the plan to make this inferred by the compiler? Otherwise it seems like a lot of hassle unless you have some hotspots you want to speed up.

    • @goodnight_noom
      @goodnight_noom 5 месяцев назад

      But then does it mean that for functions we want to explicitly type we wont benefit from the inferred locality and have to go through the hassle anyway?

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 5 месяцев назад

      This is a bit subtle. We're not going to infer exclaves, because doing so can change the asymptotic runtime of your program. (Actually, I should make a video about that. But not for a few weeks!) We can infer everything else -- but (as @goodnight_noom suggests) every time you write a type, you potentially interrupt that inference. So it really is some hassle. And yet my colleagues here at Jane Street are happy to put in the time adding the annotations to get their speedup. The whole system is opt-in, so indeed you'd probably only want to do this where it really counts.

    • @pdp11
      @pdp11 5 месяцев назад

      @@RichardEisenberg-JS Why can't there be mode inference even if you specify the types? Why does specifying a type without a mode annotation mean it's global?

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 5 месяцев назад

      @@pdp11 I suppose we could have something like `_ t1 -> _ t2` that indicates we should infer the mode. (Well, not that syntax.) But we need to know what `t1 -> t2` means: is it saying global implicitly? Or does it want inference? Right now, if you write a type, its modes are considered known. (This has to be the case in interface files, regardless of what we do on function annotations.)

  • @karavanidet
    @karavanidet 5 месяцев назад

    I am subscribed, I have a bell - I only see this now

  • @user-lq6fx6sk4j
    @user-lq6fx6sk4j 5 месяцев назад

    does anybody know that colorscheme. its so clean

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 5 месяцев назад

      It's One Monokai in VS Code, with a bunch (~15 lines) of customizations.

    • @vinylwarmth
      @vinylwarmth 5 месяцев назад

      @@RichardEisenberg-JScould you share please? 😁

    • @kozmicluis2552
      @kozmicluis2552 5 месяцев назад

      Looks like a custom high-contrast monokai but I use 2 similar high contrast themes that I am satisfied with: Nigh Wolf - No Italics Dark Moon

  • @moonbird2266
    @moonbird2266 5 месяцев назад

    What an awesome video!

  • @adicide9070
    @adicide9070 5 месяцев назад

    you trying to do some rust here now?

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 5 месяцев назад

      Well, yes! Rust is an inspiration for what we're up to, but we're not trying to mimic it directly. Instead, we see how Rust uses lifetimes to effectively allow stack allocation, and we want that, too. :)

    • @adicide9070
      @adicide9070 5 месяцев назад

      @@RichardEisenberg-JS, sure, I get it. but as a dude that is trying to get into ML, with OCaml already being a hard sell -- queries like "Why Ocaml sucks" bring up interesting, if sometimes outdated, results -- it looks a bit cumbersome to throw this in the mix. just like the sentence I just wrote, inadvertently!

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 5 месяцев назад

      @@adicide9070 Makes sense. There's always a delicate balance between expressiveness and simplicity. We're hoping to gain experience by targeting primarily fellow Jane Streeters, figure out where the pain points are, and then try to make it so that all of this becomes simple. One nice bit of feedback I've gotten roaming the office is that some programmers here don't even really know what locals are -- that means that you can successfully use OCaml without knowing about this niche feature.

  • @paulspl2581
    @paulspl2581 5 месяцев назад

    Don't know why youtube recommended me this, but really cool video man ! I started out programming with ocaml and this is making me nostalgic ! Your explanations are really clear

  • @VIDEOS-qf5jk
    @VIDEOS-qf5jk 5 месяцев назад

    Please sir give me LinkedIn link I can follow you

  • @huge_letters
    @huge_letters 5 месяцев назад

    Is there any difference between these? 1) let f: local_ 'a -> local_ 'a = fun x -> x (* I think I need to put exclave here somewhere - assume the function returns a local *) let x = f "str" (* x is local? *) 2) let f: 'a -> 'a = fun x -> x let x: local_ string = f "str"

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 5 месяцев назад

      It depends on what you mean by "difference". Your two `f`s (I'll call them f1 and f2) have different types. Because f1's argument is local_, the compiler will try to treat its argument as local. While explored more in the next video, this means that allocations that happen in the argument can be made on the stack, instead of on the heap. (This is good.) In the actual code here, though, the argument is just a constant, so no allocation is necessary. In both cases, `x` is local. (But actually this won't compile as written, because the syntax you've used is for elements of a module, and a variable in a module cannot be local. You don't need exclave_ because there is no allocation in your f.)

    • @huge_letters
      @huge_letters 5 месяцев назад

      @@RichardEisenberg-JSyeah, sorry - I was mostly interested in the difference for the variable x declared on the 2nd line. It should be local in both cases - so I was curious if there were any advantages to the first option over the second one. Maybe the first option doesn't require a local_ mode on the function parameter for this example, it would probably make my question clearer then - my intuition on all of this isn't that good yet.

  • @huge_letters
    @huge_letters 6 месяцев назад

    How would something like let y = "string" in let local_ z = y in y work? Doesn't this kinda escape its region - but y is global so it should be fine but it's not in terms of z being local also being equal to y? What about if it's not just a string but a ref?

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 6 месяцев назад

      Global/local is something that applies to expressions and values, not memory locations. So in your example, z is local (and would not be allowed to escape) and y is global. So returning y is just fine -- even if y and z are aliased in memory. The same is true for a mutable reference: a local variable can be aliased with a global, and the global one is allowed to escape.

    • @huge_letters
      @huge_letters 6 месяцев назад

      @@RichardEisenberg-JS I see I was just thinking in terms of your previous example with a file handle. Say, a function creates and returns a file handle - wouldn't it be able to retain it through those means? Or it then just guarantees that the ref is local, not the underlying value? Anyways I'm glad to be learning OCaml during such resurgence :)

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 6 месяцев назад

      @@huge_letters There's a subtlety in the way that question is phrased, mentioning returning the file handle. If a function returns a file handle, then the handle can't be local -- there's no way to control where it will end up (as you rightly surmise). But we can still protect file handles by using a callback (or continuation, if you prefer that term): `with_file : string -> (local_ handle -> 'r) -> 'r`. Once something is local, it can't be made global, so that file handle will be protected.

  • @Metruzanca
    @Metruzanca 6 месяцев назад

    Would love more of these ocaml unboxed

  • @JeanNoelAvila
    @JeanNoelAvila 6 месяцев назад

    Very interesting! Maybe a dumb question: why annotate when the compiler can check whether the variables do not escape their context?

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 6 месяцев назад

      By annotating, we can check whether our belief meets reality, turning a mistaken belief into a compile-time error. Annotating also informs future readers of our code and makes the code easier to understand.

    • @JeanNoelAvila
      @JeanNoelAvila 6 месяцев назад

      @@RichardEisenberg-JS Thank you. Is the stack allocation not implemented if it is not annotated?

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 6 месяцев назад

      @@JeanNoelAvila Inferring stack allocation (not covered in depth in the video, but it will be!) works just fine. You don't need to annotate for that.

  • @hsyl20
    @hsyl20 6 месяцев назад

    It would be nice to have this in Haskell too! We could assert that a param isn't stored in a thunk (think `DynFlags` in GHC itself). How difficult would that be to implement?

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 6 месяцев назад

      I think thunks should be fine; it's just that the thunk itself would have to be local in order to capture local data. It would be a pretty major lift, though -- getting this working in OCaml wasn't easy. (I don't take credit, as most of it was implemented before I started at Jane Street.)

  • @jslee0909
    @jslee0909 6 месяцев назад

    So it's like Rust lifecycles without that manual memory management. Nice

  • @vedthiru575
    @vedthiru575 6 месяцев назад

    FYI, there's a typo in the link to the compiler (it takes me to the branch "with-extepensions" instead of "with-extensions").

  • @SkinnyGeek_1010
    @SkinnyGeek_1010 6 месяцев назад

    What an excellent video! I fully expected to watch a dry whitepaper type of video but this was easy to absorb :)

  • @jameslew7269
    @jameslew7269 6 месяцев назад

    all fun and games until you can't unpack GADTs bc they'll escape );

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 6 месяцев назад

      Do you have an example? Should work fine with unpacking GADTs.

    • @jameslew7269
      @jameslew7269 6 месяцев назад

      @@RichardEisenberg-JS i had an issue with unpacking GADTs where their type escaped the region. it works as intended but have to be careful bc so many ways fail. which is good since thats partially why local_ is there, to spot mistakes

  • @drew-et1mm
    @drew-et1mm 6 месяцев назад

    its a lifetime annotation!

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 6 месяцев назад

      Indeed! Well, it's a little different from Rust's interpretations of lifetime (ours are simpler; Rust's are more expressive). But I didn't want to start by assuming knowledge of Rust.

  • @dmmulroy
    @dmmulroy 6 месяцев назад

    This is cool, great intro to the topic!

  • @mathiassven
    @mathiassven 7 месяцев назад

    Glad to see you back on YT! I might pick up OCaml just so I can follow along, your videos are always incredibly insightful on whatever topic you speak on

  • @donbasti
    @donbasti 7 месяцев назад

    Eisenberg - "IO monad is nothing but passing in the World as a parameter to your function" (or smth like this) <3

  • @worgenzwithm14z
    @worgenzwithm14z 7 месяцев назад

    It's the guy from the Tweag videos 😃

  • @SlickMona
    @SlickMona 7 месяцев назад

    FYI the Github link is currently broken.

    • @RichardEisenberg-JS
      @RichardEisenberg-JS 7 месяцев назад

      It seems to work for me, even when I log out. Looks like YT redirects to snag some analytics; maybe that's the problem somehow? If you search for "Jane Street opam repository", you'll find it. You might need to follow a link at the bottom to get our compiler extensions; should be hopefully clear from context.

    • @jugsma6676
      @jugsma6676 5 месяцев назад

      Now, i think it's fixed

  • @clementdato6328
    @clementdato6328 7 месяцев назад

    is this extension publicly available?