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

@toml-tools/parser

Package Overview
Dependencies
Maintainers
1
Versions
11
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@toml-tools/parser - npm Package Compare versions

Comparing version 0.1.0 to 0.1.1

26

lib/parser.js

@@ -50,3 +50,3 @@ const { Parser } = require("chevrotain");

$.CONSUME(t.IKey);
$.OPTION(() => {
$.MANY(() => {
$.CONSUME(t.Dot);

@@ -81,11 +81,17 @@ $.CONSUME2(t.IKey);

$.SUBRULE($.val);
$.MANY(() => {
$.CONSUME(t.Comma);
$.SUBRULE2($.commentNewline);
$.SUBRULE2($.val);
let notDangling = true;
$.MANY({
GATE: () => notDangling,
DEF: () => {
$.CONSUME(t.Comma);
$.SUBRULE2($.commentNewline);
const foundVal = $.OPTION2(() => {
$.SUBRULE2($.val);
});
if (foundVal === false) {
notDangling = false;
}
}
});
// Dangling Comma
$.OPTION2(() => {
$.CONSUME2(t.Comma);
});
});

@@ -103,3 +109,3 @@

$.SUBRULE($.keyval);
$.OPTION(() => {
$.MANY(() => {
$.CONSUME(t.Comma);

@@ -106,0 +112,0 @@ $.SUBRULE2($.keyval);

{
"name": "@toml-tools/parser",
"version": "0.1.0",
"version": "0.1.1",
"description": "TOML Parser Implemented in JavaScript",

@@ -9,3 +9,3 @@ "main": "lib/api.js",

"dependencies": {
"@toml-tools/lexer": "^0.1.0",
"@toml-tools/lexer": "^0.1.1",
"chevrotain": "4.1.1"

@@ -19,3 +19,3 @@ },

},
"gitHead": "7f92498e805472213e9500b32fe5295534cecd31"
"gitHead": "985568629950665054ac56fd2601d465cb9aa716"
}
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