Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

antlr4ng

Package Overview
Dependencies
Maintainers
1
Versions
38
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

antlr4ng - npm Package Compare versions

Comparing version 2.0.3 to 2.0.4

8

dist/CommonToken.d.ts

@@ -32,13 +32,11 @@ import { CharStream } from "./CharStream.js";

/**
* This is the backing field for {@link #getLine} and {@link #setLine}.
* The (one-based) line number on which the 1st character of this token was.
*/
line: number;
/**
* This is the backing field for {@link #getCharPositionInLine} and
* {@link #setCharPositionInLine}.
* The zero-based index of the first character position in its line.
*/
column: number;
/**
* This is the backing field for {@link #getChannel} and
* {@link #setChannel}.
* The token's channel.
*/

@@ -45,0 +43,0 @@ channel: number;

@@ -9,4 +9,4 @@ import { ATNConfigSet } from "./atn/ATNConfigSet.js";

deadEndConfigs: ATNConfigSet;
constructor(lexer: Lexer, input: CharStream | TokenStream, startIndex: number, deadEndConfigs: ATNConfigSet);
constructor(lexer: Lexer | null, input: CharStream | TokenStream, startIndex: number, deadEndConfigs: ATNConfigSet);
toString(): string;
}
export declare class BitSet implements Iterable<number> {
private data;
/** Creates a new bit set. All bits are initially `false`. */
constructor();
/**
* Creates a new bit set. All bits are initially `false`.
*
* @param data Optional initial data.
*/
constructor(data?: bigint[]);
/**
* @returns an iterator over all set bits.
*/
[Symbol.iterator](): IterableIterator<number>;

@@ -47,5 +54,5 @@ /**

*
* @param bitIndex a bit index
* @param index a bit index
*/
set(bitIndex: number): void;
set(index: number): void;
/**

@@ -52,0 +59,0 @@ * @returns a string representation of this bit set.

@@ -78,3 +78,3 @@ import { RuleContext } from "./RuleContext.js";

getChild(i: number): RuleContext | null;
getChild<T extends ParseTree>(i: number, type: new (parent: ParserRuleContext | null, invokingStateNumber: number) => T): T | null;
getChild<T extends ParseTree>(i: number, type: new (...args: unknown[]) => T): T | null;
getToken(ttype: number, i: number): TerminalNode | null;

@@ -81,0 +81,0 @@ getTokens(ttype: number): TerminalNode[];

{
"name": "antlr4ng",
"version": "2.0.3",
"version": "2.0.4",
"type": "module",

@@ -26,15 +26,15 @@ "description": "Alternative JavaScript/TypeScript runtime for ANTLR4",

"devDependencies": {
"@types/jest": "29.5.7",
"@types/node": "20.8.10",
"@typescript-eslint/eslint-plugin": "6.10.0",
"@typescript-eslint/parser": "6.10.0",
"esbuild": "0.19.5",
"eslint": "8.53.0",
"eslint-plugin-import": "2.29.0",
"eslint-plugin-jsdoc": "46.8.2",
"@types/jest": "29.5.11",
"@types/node": "20.10.4",
"@typescript-eslint/eslint-plugin": "6.14.0",
"@typescript-eslint/parser": "6.14.0",
"esbuild": "0.19.9",
"eslint": "8.56.0",
"eslint-plugin-import": "2.29.1",
"eslint-plugin-jsdoc": "46.9.1",
"eslint-plugin-prefer-arrow": "1.2.3",
"jest": "29.7.0",
"ts-jest": "29.1.1",
"ts-node": "10.9.1",
"typescript": "5.2.2"
"ts-node": "10.9.2",
"typescript": "5.3.3"
},

@@ -41,0 +41,0 @@ "scripts": {

@@ -146,5 +146,11 @@ [![GitHub Workflow Status (with event)](https://img.shields.io/github/actions/workflow/status/mike-lischke/antlr4ng/nodejs.yml?style=for-the-badge&logo=github)](https://github.com/mike-lischke/antlr4ng/actions/workflows/nodejs.yml)

### 2.0.4
- Code generation improvements, especially for local rule attributes. Attributes in a rule (which are implemented as local variables in the generated code) can be unassigned and need extra null-safety checks (the ? operator) or non-null assertions. The code generator now adds these checks automatically.
- `ParserRuleContext.getChild` now accepts any constructor type.
### 2.0.3
Removed last reference to a Node.js specific type (Buffer), which avoids the automatic reference to the Node.js typings and an "resolution-mode" assertion for "require" (CommonJS).
- Removed last reference to a Node.js specific type (Buffer), which avoids the automatic reference to the Node.js typings and an "resolution-mode" assertion for "require" (CommonJS).
- Upgraded the ANTLR4 jar, which now produces optional attributes in rule contexts.

@@ -151,0 +157,0 @@ ### 2.0.1 - 2.0.2

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc