HackerReposA FIELD GUIDE TO OPEN SOURCE
ProSponsor the shelf♧ 0
← Back to top all-time
antlr
grammars-v4
ANTLR2017–2025
antlr / grammars-v4

grammars-v4

Grammars written for ANTLR v4; expectation that the grammars are free of actions.

22Distinct people
23Mentions
0Explicit recommenders
11.1KGitHub stars
REPOSITORY AT A GLANCE

What to know before exploring

What it is

Grammars written for ANTLR v4; expectation that the grammars are free of actions.

GitHub

Where it is used

No documented product use was verified in the last source check.

What people are saying

No recommendation phrase was found in the indexed comments.

No classified warning is attached to this page. Read the discussions before treating silence as approval.

Also in these discussions

Mentioned in the same Hacker News threads. That is not proof they are substitutes.

This week on Hacker News

Nov 7–Nov 14 UTC · Direct repository links and separately labeled related project stories. Indexed through 11/14/2026, 3:56:07 PM UTC.

No direct repository links were found in the indexed HN discussions over the past seven days. Older discussions are available below.

Mentions over time

HN mentions by year23 dated mentions

Observed mentions: 2017-04-24 21:55:08 UTC to 2025-11-11 02:24:29 UTC.

012342017-01-01 00:00:00 UTC to 2018-01-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments20172018-01-01 00:00:00 UTC to 2019-01-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments2019-01-01 00:00:00 UTC to 2020-01-01 00:00:00 UTC (exclusive): 3 mentions; 0 submissions, 3 comments2020-01-01 00:00:00 UTC to 2021-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments2021-01-01 00:00:00 UTC to 2022-01-01 00:00:00 UTC (exclusive): 1 mentions; 0 submissions, 1 comments20212022-01-01 00:00:00 UTC to 2023-01-01 00:00:00 UTC (exclusive): 4 mentions; 0 submissions, 4 comments2023-01-01 00:00:00 UTC to 2024-01-01 00:00:00 UTC (exclusive): 4 mentions; 0 submissions, 4 comments2024-01-01 00:00:00 UTC to 2025-01-01 00:00:00 UTC (exclusive): 2 mentions; 0 submissions, 2 comments2025-01-01 00:00:00 UTC to 2026-01-01 00:00:00 UTC (exclusive): 4 mentions; 1 submissions, 3 comments2025

Counts come from the repository’s dated source evidence. Index cutoff: 2026-11-02 08:16:59 UTC.

View mention counts and date ranges
UTC ranges include their start and exclude their end. Select a period to filter the source evidence.
PeriodStart (UTC)End (exclusive, UTC)MentionsSubmissionsComments
20172017-01-01 00:00:00 UTC2018-01-01 00:00:00 UTC202
20182018-01-01 00:00:00 UTC2019-01-01 00:00:00 UTC202
20192019-01-01 00:00:00 UTC2020-01-01 00:00:00 UTC303
20202020-01-01 00:00:00 UTC2021-01-01 00:00:00 UTC101
20212021-01-01 00:00:00 UTC2022-01-01 00:00:00 UTC101
20222022-01-01 00:00:00 UTC2023-01-01 00:00:00 UTC404
20232023-01-01 00:00:00 UTC2024-01-01 00:00:00 UTC404
20242024-01-01 00:00:00 UTC2025-01-01 00:00:00 UTC202
20252025-01-01 00:00:00 UTC2026-01-01 00:00:00 UTC413

What Hacker News says

23 sources
I found some benchmarks in the ANTLR project: https://github.com/antlr/grammars-v4/blob/master/java/java/B... Project Parsing/Lexing Ratio ---------------------------------------- jdk8 5.34x Spring Framework 3.81x Elasticsearch 5.76x RxJava 5.69x JUnit4 4.51x Guava 5.37x Log4j 2.92x Obviously this is just one toolkit, one language, and one set of examples. But in these benchmarks, the tokenization (lexing) time is a small fraction of the total parse time.
In Ohm: A user-friendly parsing toolkit for JavaScript and TypeScript
https://en.wikipedia.org/wiki/HyperCard : > It is among the first successful hypermedia systems predating the World Wide Web. But HyperCard was not ported to OSX, now MacOS; which has Slides and TextEdit for HTML without MacPorts, or Brew,. HTML is Hypertext because it has <a name= href=> edges and scripting IIUC. Then there was Flash by Macromedia, which also created Dreamweaver for HTML editing before Adobe acquired Macromedia. By now there are Open Web Standards like HTML5 and ECMAscript (ES (JS not JavaScript)), WebSockets, WebRTC, WebGL, WebGPU, WASM, and various UI-to-state bindings, as Flash called what e.g. React is used for today. Instead of the DOM and JS addEventHandler, with React/preact you call setState(attr, val) to mutate the application state dict/object so that Components can register to be updated when keys in the state
Read the rest
dict are changed with useState() https://react.dev/learn/adding-interactivity#responding-to-e... The HyperTalk language has a fairly simple grammar compared to creating a static SPA (Single Page Application) with all of JS and e.g React and a router to support the browser back button and deeplink bookmarks with URI fragments that "don't break the web": https://github.com/antlr/grammars-v4/blob/master/hypertalk/H... TodoMVC or HyperTalk? False dilemma.
In HyperCard Simulator
Where is the SQLite test suite, please? I'd be very interested. There are already SQL grammars, check https://github.com/antlr/grammars-v4 specifically in here I think https://github.com/antlr/grammars-v4/tree/master/sql I contributed to one of them, and I wrote my own for some personal work. Be warned, it's very involved, very complex and MSSQL is rather ill-defined. Names bracket identifiers) in SQL are bloody awful. Sometimes square brackets are even compulsory, and why you can usually replace [...] with the SQL standard "..." , not always! Trust me, it gets worse. I don't find antlr grammars to be brittle, and while they can lose in performance (by how much I don't know, perhaps quite considerably) they are very easy to maintain and I am very fortunate to have antlr to work with. Edit: unless you are very familiar with the SQL and als
Read the rest
o a masochist, please don't try and write your own grammar. For someone with my background it was very time-consuming, without that background it will be a nightmare. Friendly warning.
In Postgres Language Server: Implementing the Parser
> ...than it would be to learn the exact syntax and quirks and possibly bugs of someone else's implementation... Yup. Also, having deep knowledge of the language is required. SQLite's grammar is neat, modest. Creating a compatible parser would make a fun project. Here's a pretty good example: https://github.com/bkiers/sqlite-parser (Actual ANTLR 4 grammar: https://github.com/bkiers/sqlite-parser/blob/master/src/main... ) Postgres, which tries to be compliant with the latest standards, however... SQL-2016 is a beast. Not to mention all the dialects. I'm updating my personal (soon to be FOSS) SQL DML grammar from ANTLR 3 LL(k) to ANTLR 4 ALL(Star). I've long had a working knowledge of SQL-92, with some SQL-1999 (eg common table expressions). But all the new structures and extensions are a bit overwhelming. Fortunately, ANTLR project has ~do
Read the rest
zen FOSS grammars to learn from. https://github.com/antlr/grammars-v4/tree/master/sql They mostly mechanically translate BNFs to LL(k) with some ALL(Star). Meaning few take advantage of left-recursion. https://github.com/antlr/antlr4/blob/master/doc/left-recursi... Honestly, I struggled to understand these grammars. Plus, not being conversant with the SQL-2016 was a huge impediment. Just finding a succinct corbis of test cases was a huge hurdle for me. Fortunately, the H2 Database project is a great resource. https://github.com/h2database/h2database/tree/master/h2/src/... Now for the exciting conclusion... My ANTLR grammar which passes all of H2's tests diverges significantly from the official or product specific BNFs. Mostly wrt recursion. Further, I found discrepancies between misc product's BNFs and their implementations. So a lot of trial & error is required for a "real world" parser. Which would explain why the professional SQL parsing tools ask for money. I still think creating a parser for SQLite is a great project. Hand-made or using grammar toolkit of choice. (I hope to play around with Pratt and PEG parsers some day.)
In SQLite internals: How the most-used database works
Why use types? Why not introduce built in parsers to provide validations instead? (i.e. https://github.com/antlr/grammars-v4) I think hush is going in the wrong direction. The majority of shell automation is associated with running IaC and container images / orchestration tools. Shell scripts don't need to follow functional programming or OOP. They need to be container-oriented / VM-oriented / image-oriented with a conformation to YAML notation as this is already the adopted norm for containers and IaC.
In Hush, a modern shell scripting language

Showing the 15 most recent of 23 sources. Enable JavaScript to search and browse every indexed mention.

MAKE YOURSELF AT HOME

A few shortcuts

/
Search the collection
?
Open this guide
Esc
Close dialogs and navigation

Your saved repositories and interests stay in this browser.