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

There are 3 syntactic modes in typst: markup, code and math. In markup, everything is literal, unless you put a `#` sigil like `#expr` in which case `expr` is parsed in code mode. In code mode everything is an identifier, as usual in programming. In math its a bit of an ugly tradeoff but its ok: single-letter things are parsed as literals but multi-letter tokens are parsed as identifiers. Finally, in code you can enclose in `[...]` to parse in markup mode. So typically, your document will be mostly in markup mode and you will encounter stuff like `#something[An argument]`, which is a function call to which you pass one content-typed argument.

So above, `y` is parsed as literal, while `dt` is parsed as an identifier, hence function call.


> In markup, everything is literal, unless you put a `#` sigil

Unless it's a "=", then it begins a new section. And unless it's a "-" or a "+" or a "/", then it's a list item. And unless it's a "<", then it defines a label, or a "@", then it's a reference to one. And unless it's a "_" or "*" or "`", then it changes font or style.


Right. Markup mode supports markup features - including all of that stuff for headings, lists, bold, italics and so on. It’s clearly inspired by markdown and similar languages. Personally I prefer * to \em{xxx} since it’s easier to type and it makes the text easier to read while I’m editing. (Or maybe just more familiar since give written so much markdown at this point).


I think I would have preferred a consistent sigil, but I guess with fast enough feedback you'd get used to the quirks.

I do wonder if this has over-optimised on short equations—to me heavy maths use implies multi-page equations with very specific formatting requirements (something amsmath has no issues with, which isn't surprising given who the authors are).


Datalog is a nice query language but it is far more limited than prolog or general purpose logic programming.


there is a really interesting space between queries and prolog which includes mundane junk like encoding and rendering and data formatting changes that benefits in evaluation from having less power but maintains the lovely expressibility and analysis that we get from 'real' logic programming.

there's lots of exploring left to do


That's why embedded Datalog is so good. You can delegate all that to the host language.


Sure, but people don't owe them respect. illegal != immoral.


I guess you meant 2 operations and 3 laws?


See? You knew it :3


I'm gettin it now! :)


I got interested into the hashgraph algorithm quite early and wrote a toy implementation in python (in fact discovering an error in the paper in the process). Unless something changed it's entirely useless for open-membership internet-scale consensus. As I remember, the processing time of a message at a node is linear in the number of nodes and same for the local storage at a node, meaning it's not very scalable. Moreover, the nodes must somehow a priori agree on the list of participants of the consensus process, again something which is not realistic for internet-wide consensus. The protocol is quite neat and not too hard to implement but it's similar in scope to paxos/raft: consensus inside an organization, where some things are a priori agreed upon.


Always infuriating to see that people always focus on the his pre-70s (hardcore math) or post-80s period (borderline mysticism ramp up). In the 70s he was most politically active and _definitely_ not delirious in any sense of the word and in fact according to Leila Schneps this is one of the few periods of his life he described as happy, the "sunday of his life" [1]. I translated the '72 CERN talk, its baffling how relevant it is, to this day [2].

[1] french, https://www.youtube.com/watch?v=V8BbFTEyvIw

[2] https://github.com/Lapin0t/grothendieck-cern


Demonstrating how some languages and some compilers are bad at tasks such as writing constant-time crypto routines is fine. Concluding that all compilers and non-asm languages are bad is a non sequitur. Just because you don't want non-branching code to change into branching code doesn't mean you should have to do register allocation by hand. Write simple domain-specific compilers and languages people.


Every heard about https://typst.app/?


I don’t think the global standard of scientific paper writing will be replaced by something that has a pricing tab at the top of the page.



> This has nothing to do with science and is really a point about the division of labor/economics.

This is not a critic of the idea science, ie some kind of pursuit of knowledge using any reasonable means. It is a critic of the modern institution that academic science currently is. As such, yes, some critics are in fact more generally applicable than just for science (as you say, division of labor). But these are particularly visible in science and have specific consequences in this context.


For a bit more background on Grothendieck's position on science, I've recently translated Grothendieck's talk on science at CERN, which was quite hard to find at some point: https://github.com/Lapin0t/grothendieck-cern/.


Hey, thank you for your service! you should post this to the front page as its own article!

>I think that agriculture, stockbreeding, decentralized energy production, medicine of a certain kind, very different from the medicine that prevails today, will come to the fore.

>In general, people see two extreme alternatives and see no middle ground between the two. If the person I'm talking to has chosen a certain alternative and I have a vision that lies beyond the one they considers good, they'll immediately accuse me of having chosen the opposite extreme alternative, because they can't see the middle ground.


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

Search: